[Twisted-web] Re: Basic authentication in twisted.web

Nicola Larosa twisted-web@twistedmatrix.com
Thu, 11 Mar 2004 12:44:23 +0100


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

> Since I'm rather new to twisted web, it would be nice if someone could
> comment on this code.

See below.


> Perhaps it is helpful as an example for others solving the same problem or
> trying to understand twisted.web and twisted.cred.

Indeed, it came at the right moment, thanks. :^)


> By the way, twisted is fantastic.

Indeed #2. :^)


>     def getChild(self, path, request):
>         def loginSuccess(result):
>             interface, avatar, logout = result
>             return avatar

In order to make it return the right resource, I changed this last line as
follows:

            return avatar.getChildWithDefault(path, request)


- --
Nicola Larosa - nico@tekNico.net

"Inside every old guy is a young guy wondering WTF happened."
 -- big-giant-head on Slashdot


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (GNU/Linux)

iD8DBQFAUFEWXv0hgDImBm4RAqJPAKCRqUVbreP9Xz/JLKtJS33w3XzrYgCgu4Rv
U/PjSECLf7LhDqZlCs2w93U=
=syKk
-----END PGP SIGNATURE-----