globaleaks/GLBackend — pull request #142 by evilaliv3 (2013-08-17 09:12:12+00:00)
Title: addressed issue https://github.com/globaleaks/GlobaLeaks/issues/509

this pull request is ready for merge.

what follows is the description of the changes:
1) I've create "@unauthenticated" decorator
2) I've extracted a common part @authenticated and @unautenticated from decorators into a function called update_sessions(user)
3) i've added the @unhautenticated header to all unauthenticated handlers
4) i've reordered decorators in all handlers; please take care of theright order when you use it.
the right order is:

@transport_security_check('admin')
@authenticated('admin')
@inlineCallbacks

or
@transport_security_check('admin')
@authenticated('admin')
@inlineCallbacks

it's important that the @inlineCallbacks is the last one as it must not apply to the the wrapping functions.

@vecna / hellais can you take care of mergin it?