[Twisted-web] Sessions and Authentication for Web2

Clark C. Evans cce at clarkevans.com
Thu Nov 17 14:29:36 MST 2005


On Thu, Nov 17, 2005 at 01:17:11PM +0100, Valentino Volonghi aka Dialtone:
| Currently the filter signature is the following (none of the below
| functions exist yet):
| 
| def sessionfilter(req, res, ctx):
|     # do session handling here
| 
| def authenticationfilter(req, res, ctx):
|     # do authentication handling here
|

1. How do I know what the response is before I even authenticate or
   create a session?

2. Which comes first, I assume session then authentication.

3. These need to come _before_ any of my other resources get
   the request.

It seems that the dispatch mechansim might need a way to "register"
that a filter should be applied at the end of processing; so that
once the Response is generated, it can be wrapped on the way out.

| We are trying to find a new way to do things without boundaries to old APIs
| and such :). So many changes have to be made that discussing with backwards
| compatibility in mind is just a waste of time IMHO. It is good if we could
| just brainstorm some stuff and bash each other. :)

Web2 is already substantially different from Web: don't stop now!

Clark



More information about the Twisted-web mailing list