The branch, uccsoutput has been updated via 23c88c33da8d3294bb74e854bc6f883ea63b7c9a (commit) from ad4f3af5a457d985aba08002d37bc3941528eba9 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 23c88c33da8d3294bb74e854bc6f883ea63b7c9a Author: Mike Gabriel <mike.gabriel@das-netzwerkteam.de> Date: Fri Apr 19 13:57:46 2013 +0200 some nice cosmetics on x2gobroker-testauth ----------------------------------------------------------------------- Summary of changes: bin/x2gobroker-testauth | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) The diff of changes is: diff --git a/bin/x2gobroker-testauth b/bin/x2gobroker-testauth index 12db7da..fd8a5a7 100755 --- a/bin/x2gobroker-testauth +++ b/bin/x2gobroker-testauth @@ -50,10 +50,10 @@ if __name__ == "__main__": ] misc_options = [ {'args':['-C','--config-file'], 'default': None, 'metavar': 'CONFIG_FILE', 'help': 'Specify a special configuration file name, default is: {default}'.format(default=x2gobroker.defaults.X2GOBROKER_CONFIG), }, - {'args':['-b','--backend'], 'default': 'zeroconf', 'metavar': 'BACKEND', 'help': 'Use this specific backend for testing authentication, see x2gobroker.conf for a list of configured backends', }, + {'args':['-b','--backend'], 'default': 'zeroconf', 'metavar': 'BACKEND', 'help': 'Use this specific backend for testing authentication, see x2gobroker.conf for a list of configured and enabled backends', }, {'args':['-d','--debug'], 'default': False, 'action': 'store_true', 'help': 'enable debugging code', }, ] - p = argparse.ArgumentParser(description='X2Go Session Broker (Authservice Test Utility)',\ + p = argparse.ArgumentParser(description='X2Go Session Broker (Authentication Test Utility)',\ epilog="WARNING: Using this utility from the command line is not recommended!!!\nYour credentials will get revealed in your shells history file.",\ formatter_class=argparse.RawDescriptionHelpFormatter, \ add_help=True, argument_default=None) @@ -92,17 +92,24 @@ try: except ImportError: p.print_help() print - print "*** No such backend: {backend} or backend not enabled... ***".format(backend=cmdline_args.backend) + print "*** No such backend: {backend} ***".format(backend=cmdline_args.backend) print - sys.exit(-1) + sys.exit(-2) +broker = _backend.X2GoBroker(config_file=config_file, config_defaults=config_defaults) +if not broker.is_enabled(): + p.print_help() + print + print "*** Backend not enabled: {backend} ***".format(backend=cmdline_args.backend) + print + sys.exit(-3) -def check_password(environ, username, password): - return _backend.X2GoBroker(config_file=config_file, config_defaults=config_defaults)._do_authenticate(username=username, password=password) +def check_password(username, password): + return broker._do_authenticate(username=username, password=password) if __name__ == "__main__": - if check_password(os.environ, username, password): + if check_password(username, password): print "authentication succeeded" sys.exit(0) else: hooks/post-receive -- x2gobroker.git (HTTP(S) Session broker for X2Go) This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "x2gobroker.git" (HTTP(S) Session broker for X2Go).