simpleauth Package

simpleauth Package

A simple auth handler for Google App Engine supporting OAuth 1.0a, 2.0 and OpenID.

handler Module

exception simpleauth.handler.AuthProviderResponseError[source]

Bases: simpleauth.handler.Error

Error coming from a provider

exception simpleauth.handler.Error[source]

Bases: exceptions.Exception

Base error class for this module

exception simpleauth.handler.InvalidCSRFTokenError[source]

Bases: simpleauth.handler.Error

Currently used only in OAuth 2.0 with CSRF protection enabled

exception simpleauth.handler.InvalidOAuthRequestToken[source]

Bases: simpleauth.handler.Error

OAuth1 request token -related error

exception simpleauth.handler.InvalidOpenIDUserError[source]

Bases: simpleauth.handler.Error

Error during OpenID auth callback

class simpleauth.handler.SimpleAuthHandler[source]

Bases: object

A mixin to be used with a real request handler, e.g. webapp2.RequestHandler. See README for getting started and a usage example, or look through the code. It really is simple.

See README for docs on authentication flows.

OAUTH2_CSRF_SESSION_PARAM = 'oauth2_state'
PROVIDERS = {'windows_live': ('oauth2', '{0}', ''), 'openid': ('openid', None), 'google': ('oauth2', '{0}', ''), 'twitter': ('oauth1', {'request': '', 'auth': '{0}'}, ''), 'linkedin': ('oauth2', '{0}', ''), 'foursquare': ('oauth2', '{0}', ''), 'facebook': ('oauth2', '{0}', '')}
TOKEN_RESPONSE_PARSERS = {'windows_live': '_json_parser', 'google': '_json_parser', 'twitter': '_query_string_parser', 'linkedin': '_json_parser', 'foursquare': '_json_parser', 'facebook': '_query_string_parser'}
exception simpleauth.handler.UnknownAuthMethodError[source]

Bases: simpleauth.handler.Error

Raised when there’s no method to call for a specific auth type

Table Of Contents

Previous topic

secrets-new Module

Next topic

task_handler Module

This Page