Changeset - ba49541187d9
[Not reviewed]
beta
0 1 0
Marcin Kuzminski - 13 years ago 2012-06-14 13:32:58
marcin@python-works.com
Little more verbose logging for auth
1 file changed with 3 insertions and 2 deletions:
0 comments (0 inline, 0 general)
rhodecode/lib/auth.py
Show inline comments
 
@@ -460,8 +460,9 @@ class LoginRequired(object):
 
        loc = "%s:%s" % (cls.__class__.__name__, func.__name__)
 
        log.debug('Checking if %s is authenticated @ %s' % (user.username, loc))
 
        if user.is_authenticated or api_access_ok:
 
            log.info('user %s is authenticated and granted access to %s' % (
 
                       user.username, loc)
 
            reason = 'RegularAuth' if user.is_authenticated else 'APIAuth'
 
            log.info('user %s is authenticated and granted access to %s '
 
                     'using %s' % (user.username, loc, reason)
 
            )
 
            return func(*fargs, **fkwargs)
 
        else:
0 comments (0 inline, 0 general)