Package repoze :: Package who :: Module interfaces :: Class IChallenger
[hide private]

Class IChallenger

source code


On egress: Conditionally initiate a challenge to the user to provide credentials.

Only challenge plugins which match one of the the current response's classifications will be asked to perform a challenge.

Instance Methods [hide private]
 
challenge(environ, status, app_headers, forget_headers)
args -> WSGI application or None
source code
Class Variables [hide private]
  _InterfaceClass__attrs = {'challenge': <zope.interface.interfa...
  __bases__ = (<InterfaceClass repoze.who.interfaces.IPlugin>)
  __identifier__ = 'repoze.who.interfaces.IChallenger'
  __iro__ = (<InterfaceClass repoze.who.interfaces.IChallenger>,...
  __name__ = 'IChallenger'
  __sro__ = (<InterfaceClass repoze.who.interfaces.IChallenger>,...
  _implied = {<InterfaceClass repoze.who.interfaces.IChallenger>...
  dependents = <WeakKeyDictionary at 27503864>

Inherited from zope.interface.Interface (private): _Element__tagged_values

Method Details [hide private]

challenge(environ, status, app_headers, forget_headers)

source code 
args -> WSGI application or None

o 'environ' is the WSGI environment.

o 'status' is the status written into start_response by the
  downstream application.

o 'app_headers' is the headers list written into start_response by the
  downstream application.

o 'forget_headers' is a list of headers which must be passed
  back in the response in order to perform credentials reset
  (logout).  These come from the 'forget' method of
  IIdentifier plugin used to do the request's identification.

Examine the values passed in and return a WSGI application
(a callable which accepts environ and start_response as its
two positional arguments, ala PEP 333) which causes a
challenge to be performed.  Return None to forego performing a
challenge.


Class Variable Details [hide private]

_InterfaceClass__attrs

Value:
{'challenge': <zope.interface.interface.Method object at 0x1a3cf90>}

__iro__

Value:
(<InterfaceClass repoze.who.interfaces.IChallenger>,
 <InterfaceClass repoze.who.interfaces.IPlugin>,
 <InterfaceClass zope.interface.Interface>)

__sro__

Value:
(<InterfaceClass repoze.who.interfaces.IChallenger>,
 <InterfaceClass repoze.who.interfaces.IPlugin>,
 <InterfaceClass zope.interface.Interface>)

_implied

Value:
{<InterfaceClass repoze.who.interfaces.IChallenger>: (),
 <InterfaceClass repoze.who.interfaces.IPlugin>: (),
 <InterfaceClass zope.interface.Interface>: ()}