changeset 8:93c835b645af

nicer logging.
author casties
date Fri, 09 Nov 2012 18:12:47 +0100
parents 279473355e9b
children 41f264620073
files AuthTokenGenerator.py
diffstat 1 files changed, 2 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/AuthTokenGenerator.py	Fri Nov 09 18:05:11 2012 +0100
+++ b/AuthTokenGenerator.py	Fri Nov 09 18:12:47 2012 +0100
@@ -85,16 +85,15 @@
             # everybody can be anonymous
             return user
         
-        # get logged in user
+        # get logged in user from Zope
         authuser = getSecurityManager().getUser()
         authname = authuser.getUserName()
-        logging.debug("token_allowed: user=%s authuser=%s username=%s"%(user, repr(authuser), repr(authname)))
         if authname == user:
             # user is logged in
             return authname
         
         if password:
-            logging.debug("trying password")
+            logging.debug("trying password for token for user %s"%user)
             # try all user folders in aq_chain
             authuser = None
             userfolder = None