Changeset 8058


Ignore:
Timestamp:
14/05/12 15:28:35 (7 years ago)
Author:
rwilkinson
Message:

Added modified repoze.who SQL authenticator that allows configuration via the repoze.who configuration file.
Minor fixes: added missing init.py files, corrected logging statement.

Location:
trunk/ndg_oauth
Files:
5 added
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/ndg_oauth/ndg_oauth_client/ndg/oauth/client/lib/http_get_with_credential.py

    r8057 r8058  
    8282            log.debug("Token ID: %s", current_token) 
    8383        else: 
    84             log.debug("No token found with environ key: %d", 
     84            log.debug("No token found with environ key: %s", 
    8585                      self.token_env_key) 
    8686        if ((self.token != current_token) or not self.user_ssl_context): 
  • trunk/ndg_oauth/ndg_oauth_server/repoze_who.ini

    r8057 r8058  
    2424check_fn = repoze.who.plugins.htpasswd:crypt_check 
    2525 
    26 #[plugin:sqlusers] 
    27 ## authentication 
     26[plugin:sqlusers] 
     27# authentication 
     28use = ndg.security.server.utils.repoze_who_utils:make_authenticator_plugin 
     29# Use #(login)s, which is translated to %(login)s - this gets round lack of escaping in ConfigParser. 
     30query = SELECT openid, md5passwd FROM tbusers where accountid = #(login)s 
     31conn_factory = ndg.oauth.server.lib.utils.repoze_who_utils:make_psycopg_conn_factory 
     32compare_fn = ndg.security.server.utils.repoze_who_utils:md5_password_compare 
     33connection_string = host=<databasehost> dbname=<databasename> user=<user> password=<password> 
     34# The recommended configuration does not work, at least with repoze.who v2.0: 
    2835#use = repoze.who.plugins.sql:make_authenticator_plugin 
    2936#query = "SELECT userid, password FROM users where login = %(login)s;" 
     
    5360plugins = 
    5461      auth_tkt 
    55       htpasswd 
    56 #      sqlusers 
     62#      htpasswd 
     63      sqlusers 
    5764 
    5865[challengers] 
Note: See TracChangeset for help on using the changeset viewer.