�
�Udac @` s\ d d l m Z m Z m Z e Z d d l m Z d d l m Z d e f d � � YZ
d S( i ( t absolute_importt divisiont print_function( t abstractmethod( t
AnsiblePlugint HttpApiBasec B` sM e Z d � Z d � Z d � Z d � Z d � Z d � Z e d � � Z RS( c C` s2 t t | � j � | | _ t | _ d | _ d S( Nt ( t superR t __init__t
connectiont Falset _becomet _become_pass( t selfR ( ( sD /usr/lib/python2.7/site-packages/ansible/plugins/httpapi/__init__.pyR
s c C` s( | j | _ t | d � p d | _ d S( Nt become_passR ( t becomeR t getattrR ( R
t become_context( ( sD /usr/lib/python2.7/site-packages/ansible/plugins/httpapi/__init__.pyt
set_become s c C` s d S( s Call a defined login endpoint to receive an authentication token.
This should only be implemented if the API has a single endpoint which
can turn HTTP basic auth into a token which can be reused for the rest
of the calls for the session.
N( ( R
t usernamet password( ( sD /usr/lib/python2.7/site-packages/ansible/plugins/httpapi/__init__.pyt login s c C` s d S( s� Call to implement session logout.
Method to clear session gracefully e.g. tokens granted in login
need to be revoked.
N( ( R
( ( sD /usr/lib/python2.7/site-packages/ansible/plugins/httpapi/__init__.pyt logout! s c C` s* | j � j d � } | r&