2009-11-25 | Paul Boddie | file changeset files shortlog | Added a test for empty identifiers in OpenID initiation. Changed the user identity to be the claimed identity (not the local identity from the provider) for users authenticated via OpenID. Made the local identities distinct from the claimed identities in the login/provider example. |
paulb@139 | 1 | #!/usr/bin/env python |
paulb@139 | 2 | |
paulb@139 | 3 | """ |
paulb@139 | 4 | Webware context for the Login application (post Webware 0.8.1). |
paulb@139 | 5 | """ |
paulb@139 | 6 | |
paulb@560 | 7 | from WebStack.Adapters.Webware import deploy |
paulb@156 | 8 | from WebStack.Resources.Login import LoginResource, LoginAuthenticator |
paulb@139 | 9 | |
paulb@139 | 10 | # NOTE: Initialising a shared resource. |
paulb@139 | 11 | |
paulb@139 | 12 | resource = LoginResource( |
paulb@139 | 13 | LoginAuthenticator( |
paulb@139 | 14 | secret_key="horses", |
paulb@139 | 15 | credentials=( |
paulb@139 | 16 | ("badger", "abc"), |
paulb@139 | 17 | ("vole", "xyz"), |
paulb@139 | 18 | ) |
paulb@150 | 19 | ) |
paulb@139 | 20 | ) |
paulb@139 | 21 | |
paulb@718 | 22 | urlParser = deploy(resource, handle_errors=0) |
paulb@139 | 23 | |
paulb@139 | 24 | # vim: tabstop=4 expandtab shiftwidth=4 |