Changeset 5723


Ignore:
Timestamp:
17/09/09 14:43:39 (10 years ago)
Author:
pjkersha
Message:

Tested with local db config

Location:
TI12-security/trunk/python/ndg_security_common_utils_openid_dbinterface/ndg/security/common/utils/openid
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • TI12-security/trunk/python/ndg_security_common_utils_openid_dbinterface/ndg/security/common/utils/openid/dbinterface.py

    r5722 r5723  
    227227            if not pwd: 
    228228                import getpass 
    229                 pwd = getpass.getpass(prompt=prompt) 
     229                pwd = getpass.getpass(prompt) 
    230230 
    231231        try: 
     
    364364     
    365365        if not opt.command: 
    366             msg = "Error, no command set.\n\n" + parser.print_help() 
     366            msg = "Error, no command set.\n\n" + parser.format_help() 
    367367            raise SystemExit(msg) 
    368368 
     
    376376            if not opt.userIdentifier: 
    377377                msg = "Error, no user identifier set for query command.\n\n" +\ 
    378                     parser.print_help() 
     378                    parser.format_help() 
    379379                raise SystemExit(msg) 
    380380             
     
    387387        else: 
    388388            msg = "Command %s not recognised.\n\n" % opt.command + \ 
    389                     parser.print_help() 
     389                    parser.format_help() 
    390390            raise SystemExit(msg) 
    391391         
  • TI12-security/trunk/python/ndg_security_common_utils_openid_dbinterface/ndg/security/common/utils/openid/openid_dbinterface.cfg

    r5722 r5723  
    77[DatabaseOpenIDUserIdentifiers] 
    88# name of database 
    9 dbName:  
     9dbName: testUserDb 
    1010 
    1111# database host machine 
    12 host:  
     12host: localhost 
    1313 
    1414# database account username 
    15 username:  
     15username: pjkersha 
    1616 
    1717# Password - comment out to prompt from stdin instead 
    1818pwd:  
    1919 
    20 query.generate =  
    21 query.uniqIdentifier =  
     20query.generate = select distinct username, first_names, surname from users where username != ''  
     21query.uniqIdentifier = select distinct openid_username_component from users where openid_username_component = '${openIdUserComponent}' 
Note: See TracChangeset for help on using the changeset viewer.