Module Expr Str Import alias Import alias Import alias ImportFrom alias ImportFrom alias ImportFrom alias identifier ImportFrom alias identifier ImportFrom alias ImportFrom alias identifier ImportFrom alias Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Str ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam defaults body Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body If CompareIs AttributeLoad NameLoad attr NameLoad body Assign NameStore Call NameLoad NameLoad Str ListLoad Str Str Assign AttributeStore NameLoad attr ListComp Call Call NameLoad NameLoad comprehension NameStore NameLoad Return AttributeLoad NameLoad attr decorator_list NameLoad FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body If UnaryOpNot Call AttributeLoad NameLoad attr NameLoad NameLoad body Assign NameStore Call NameLoad Str Expr Call AttributeLoad NameLoad attr Str Raise Call AttributeLoad NameLoad attr NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str If BoolOpAnd Call NameLoad NameLoad Str CompareEq NameLoad SubscriptLoad AttributeLoad AttributeLoad NameLoad attr attr Index Str body Assign NameStore SubscriptLoad AttributeLoad AttributeLoad NameLoad attr attr Index Str Assign NameStore SubscriptLoad AttributeLoad AttributeLoad NameLoad attr attr Index Str Assign NameStore SubscriptLoad AttributeLoad AttributeLoad NameLoad attr attr Index Str Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad NameLoad NameLoad Return NameLoad orelse Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults NameLoad kwarg body Expr Str Expr Call AttributeLoad NameLoad attr Str If UnaryOpNot NameLoad body Assign NameStore AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad For NameStore AttributeLoad NameLoad attr body Assign NameStore Call AttributeLoad NameLoad attr keyword NameLoad NameLoad If NameLoad body Break orelse Assign NameStore Call NameLoad Str Expr Call AttributeLoad NameLoad attr Str Raise Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore AttributeLoad Call AttributeLoad NameLoad attr attr TryExcept body Assign NameStore Call AttributeLoad NameLoad attr NameLoad handlers ExceptHandler type AttributeLoad NameLoad attr name NameStore body Expr Call AttributeLoad NameLoad attr Call NameLoad NameLoad Assign NameStore Call NameLoad Str Raise Call AttributeLoad NameLoad attr NameLoad ExceptHandler type TupleLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr name NameStore body Expr Call AttributeLoad NameLoad attr Call NameLoad NameLoad Raise Call AttributeLoad NameLoad attr Call NameLoad Str ExceptHandler type TupleLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr name NameStore body Assign NameStore Call NameLoad Str Expr Call AttributeLoad NameLoad attr Call NameLoad NameLoad Raise Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad Assign NameStore NameLoad Assign NameStore NameLoad If BoolOpAnd CompareGtE Call AttributeLoad NameLoad attr Num CompareIn Str NameLoad body TryExcept body Assign NameStore AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad keyword SubscriptLoad NameLoad Index Str Assign NameStore Call AttributeLoad NameLoad attr NameLoad handlers ExceptHandler type NameLoad body Expr Call AttributeLoad NameLoad attr Str keyword NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad Assign NameStore ListComp NameLoad comprehension NameStore NameLoad AttributeLoad NameLoad attr If BoolOpAnd UnaryOpNot NameLoad UnaryOpNot NameLoad body Assign NameStore Call NameLoad Str If CompareGtE Call AttributeLoad NameLoad attr Num body Assign NameStore Call NameLoad Str Raise Call AttributeLoad NameLoad attr NameLoad Assign NameStore NameLoad Assign NameStore Call AttributeLoad NameLoad attr Str If NameLoad body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Str If NameLoad body For TupleStore NameStore NameStore Call NameLoad NameLoad body If CompareEq AttributeLoad NameLoad attr NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr Num NameLoad Break For NameStore NameLoad body Assign NameStore AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad keyword NameLoad keyword AttributeLoad NameLoad attr TryExcept body Assign NameStore Call AttributeLoad NameLoad attr NameLoad handlers ExceptHandler type TupleLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Pass orelse Break orelse If NameLoad body Assign NameStore NameLoad Assign NameStore NameLoad orelse Assign NameStore Call NameLoad Str Raise Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad Assign NameStore NameLoad Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr keyword Str For NameStore ListComp NameLoad comprehension NameStore SubscriptLoad NameLoad Index Str body If CompareIn NameLoad Call AttributeLoad NameLoad attr body Assign NameStore SubscriptLoad NameLoad Index Str Break Assign NameStore Call NameLoad NameLoad Str Str Assign NameStore Call AttributeLoad NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr keyword Str keyword NameLoad keyword NameLoad Assign NameStore AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad Call AttributeLoad NameLoad attr NameLoad keyword NameLoad NameLoad keyword NameLoad If CompareIsNot NameLoad NameLoad body Assign SubscriptStore AttributeLoad NameLoad attr Index Str NameLoad If NameLoad body If Call AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr Str orelse Assign SubscriptStore AttributeLoad NameLoad attr Index Str NameLoad Assign AttributeStore NameLoad attr NameLoad Assign NameStore Call NameLoad NameLoad Str Num Assign NameStore BinOpSub AttributeLoad AttributeLoad NameLoad attr attr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Assign NameStore Call NameLoad NameLoad AttributeLoad NameLoad attr Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Assign NameStore Call NameLoad keyword NameLoad keyword NameLoad Expr Call NameLoad NameLoad NameLoad NameLoad Expr Call AttributeLoad NameLoad attr Str Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body Expr Str Return Call NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body Expr Str If BoolOpOr Call AttributeLoad NameLoad attr CompareIsNot NameLoad NameLoad body Return Call NameLoad Assign NameStore SetComp Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index Str comprehension NameStore AttributeLoad NameLoad attr Assign NameStore ListLoad For NameStore AttributeLoad NameLoad attr body TryExcept body Assign NameStore SubscriptLoad NameLoad Index Str handlers ExceptHandler type NameLoad body Continue Assign NameStore ListComp Call AttributeLoad NameLoad attr NameLoad comprehension NameStore Call AttributeLoad NameLoad attr Str ListLoad If CompareIn AttributeLoad NameLoad attr NameLoad body Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Assign NameStore SetComp BinOpMod Str NameLoad comprehension NameStore NameLoad Return BinOpBitOr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults NameLoad body Expr Str If UnaryOpNot AttributeLoad NameLoad attr body Return NameLoad Return CompareIn NameLoad Call AttributeLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str If UnaryOpNot AttributeLoad NameLoad attr body Return NameLoad For NameStore Call AttributeLoad NameLoad attr NameLoad body If CompareEq SubscriptLoad NameLoad Slice Call AttributeLoad NameLoad attr Str NameLoad body Return NameLoad Return NameLoad decorator_list decorator_list
N/A N/A  Module defining the Django auth backend class for the Keystone API.  N/A datetime N/A logging N/A pytz django.conf settings django.utils.module_loading import_string django.utils.translation ugettext_lazy _ keystoneauth1 exceptions keystone_exceptions openstack_auth exceptions openstack_auth user auth_user openstack_auth utils N/A LOG N/A N/A logging getLogger __name__ N/A KEYSTONE_CLIENT_ATTR _keystoneclient KeystoneBackend N/A object N/A N/A Django authentication backend for use with ``django.contrib.auth``. __init__ N/A N/A self N/A N/A N/A N/A self _auth_plugins None N/A auth_plugins N/A N/A self N/A N/A N/A N/A N/A self _auth_plugins None N/A N/A plugins N/A getattr settings AUTHENTICATION_PLUGINS N/A openstack_auth.plugin.password.PasswordPlugin openstack_auth.plugin.token.TokenPlugin N/A N/A self _auth_plugins N/A N/A N/A import_string p N/A p plugins N/A N/A self _auth_plugins N/A property check_auth_expiry N/A N/A self auth_ref margin N/A None N/A N/A N/A N/A N/A utils is_token_valid auth_ref margin N/A N/A msg N/A _ The authentication token issued by the Identity service has expired. N/A N/A N/A LOG warning The authentication token issued by the Identity service appears to have expired before it was issued. This may indicate a problem with either your server or client configuration. N/A N/A N/A exceptions KeystoneAuthException msg N/A True N/A get_user N/A N/A self user_id N/A N/A N/A Returns the current user from the session data.

        If authenticated, this return the user object based on the user ID
        and session data.

        Note: this required monkey-patching the ``contrib.auth`` middleware
        to make the ``request`` object available to the auth backend class.
         N/A N/A N/A hasattr self request N/A user_id N/A N/A N/A self request session N/A user_id N/A N/A token N/A N/A N/A self request session N/A token N/A endpoint N/A N/A N/A self request session N/A region_endpoint N/A services_region N/A N/A N/A self request session N/A services_region N/A user N/A N/A auth_user create_user_from_token N/A self request token endpoint services_region N/A user N/A N/A None N/A authenticate N/A N/A self auth_url N/A None kwargs N/A N/A Authenticates a user via the Keystone Identity API. N/A N/A N/A LOG debug Beginning user authentication N/A N/A auth_url N/A N/A auth_url N/A settings OPENSTACK_KEYSTONE_URL N/A auth_url N/A N/A utils fix_auth_url_version auth_url N/A plugin N/A self auth_plugins N/A N/A unscoped_auth N/A N/A plugin get_plugin auth_url auth_url kwargs N/A unscoped_auth N/A N/A N/A N/A msg N/A _ No authentication backend could be determined to handle the provided credentials. N/A N/A N/A LOG warning No authentication backend could be determined to handle the provided credentials. This is likely a configuration error that should be addressed. N/A N/A N/A exceptions KeystoneAuthException msg N/A session N/A N/A utils get_session N/A keystone_client_class N/A N/A N/A utils get_keystone_client Client N/A N/A N/A unscoped_auth_ref N/A N/A unscoped_auth get_access session N/A N/A N/A N/A keystone_exceptions ConnectFailure N/A exc N/A N/A N/A N/A LOG error N/A str exc N/A msg N/A _ Unable to establish connection to keystone endpoint. N/A N/A N/A exceptions KeystoneAuthException msg N/A N/A N/A N/A keystone_exceptions Unauthorized N/A keystone_exceptions Forbidden N/A keystone_exceptions NotFound N/A exc N/A N/A N/A N/A LOG debug N/A str exc N/A N/A N/A exceptions KeystoneAuthException N/A _ Invalid credentials. N/A N/A N/A N/A keystone_exceptions ClientException N/A keystone_exceptions AuthorizationFailure N/A exc N/A N/A msg N/A _ An error occurred authenticating. Please try again later. N/A N/A N/A LOG debug N/A str exc N/A N/A N/A exceptions KeystoneAuthException msg N/A N/A N/A self check_auth_expiry unscoped_auth_ref N/A domain_auth None N/A domain_auth_ref None N/A N/A N/A N/A N/A utils get_keystone_version 3 N/A user_domain_name kwargs N/A N/A N/A N/A token N/A unscoped_auth_ref auth_token N/A domain_auth N/A N/A utils get_token_auth_plugin auth_url token domain_name N/A kwargs N/A user_domain_name N/A domain_auth_ref N/A N/A domain_auth get_access session N/A N/A N/A Exception N/A N/A N/A N/A LOG debug Error getting domain scoped token. exc_info True N/A projects N/A N/A plugin list_projects session unscoped_auth unscoped_auth_ref N/A projects N/A project N/A project projects N/A project enabled N/A N/A N/A projects N/A domain_auth_ref N/A N/A msg N/A _ You are not authorized for any projects. N/A N/A N/A N/A utils get_keystone_version 3 N/A N/A msg N/A _ You are not authorized for any projects or domains. N/A N/A N/A exceptions KeystoneAuthException msg N/A recent_project None N/A request N/A N/A kwargs get request N/A request N/A N/A recent_project N/A N/A N/A request COOKIES get recent_project N/A recent_project N/A N/A N/A pos project N/A enumerate projects N/A N/A N/A N/A project id recent_project N/A N/A N/A N/A projects pop pos N/A N/A N/A projects insert 0 project N/A N/A project projects N/A N/A token N/A unscoped_auth_ref auth_token N/A scoped_auth N/A N/A utils get_token_auth_plugin auth_url token token project_id N/A project id N/A N/A N/A scoped_auth_ref N/A N/A scoped_auth get_access session N/A N/A N/A N/A N/A keystone_exceptions ClientException N/A keystone_exceptions AuthorizationFailure N/A N/A N/A N/A N/A N/A domain_auth_ref N/A N/A scoped_auth domain_auth N/A scoped_auth_ref domain_auth_ref N/A N/A msg N/A _ Unable to authenticate to any available projects. N/A N/A N/A exceptions KeystoneAuthException msg N/A N/A N/A self check_auth_expiry scoped_auth_ref N/A region_name None N/A id_endpoints N/A N/A N/A scoped_auth_ref service_catalog get_endpoints service_type identity N/A id_endpoint N/A cat N/A cat N/A id_endpoints N/A identity N/A N/A N/A auth_url N/A N/A id_endpoint values N/A N/A region_name N/A id_endpoint N/A region N/A N/A interface N/A getattr settings OPENSTACK_ENDPOINT_TYPE public N/A endpoint N/A N/A utils fix_auth_url_version N/A N/A N/A scoped_auth_ref service_catalog url_for service_type identity interface interface region_name region_name N/A unscoped_token N/A unscoped_auth_ref auth_token N/A user N/A N/A auth_user create_user_from_token request N/A N/A auth_user Token scoped_auth_ref unscoped_token unscoped_token endpoint services_region region_name N/A N/A request None N/A N/A N/A N/A request session N/A unscoped_token unscoped_token N/A domain_auth_ref N/A N/A N/A N/A utils using_cookie_backed_sessions N/A N/A N/A N/A LOG error Using signed cookies as SESSION_ENGINE with OPENSTACK_KEYSTONE_MULTIDOMAIN_SUPPORT is enabled. This disables the ability to perform identity operations due to cookie size constraints. N/A N/A N/A N/A request session N/A domain_token domain_auth_ref N/A N/A request user user N/A timeout N/A getattr settings SESSION_TIMEOUT 3600 N/A token_life N/A N/A N/A user token expires N/A N/A N/A datetime datetime now N/A pytz utc N/A session_time N/A min timeout N/A token_life seconds N/A N/A N/A N/A request session set_expiry session_time N/A scoped_client N/A keystone_client_class session session auth scoped_auth N/A N/A setattr request KEYSTONE_CLIENT_ATTR scoped_client N/A N/A N/A LOG debug Authentication completed. N/A user N/A get_group_permissions N/A N/A self user obj N/A None N/A N/A Returns an empty set since Keystone doesn't support "groups". N/A N/A set N/A get_all_permissions N/A N/A self user obj N/A None N/A N/A Returns a set of permission strings that the user has.

        This permission available to the user is derived from the user's
        Keystone "roles".

        The permissions are returned as ``"openstack.{{ role.name }}"``.
         N/A N/A N/A N/A user is_anonymous N/A obj None N/A N/A N/A set N/A role_perms N/A N/A N/A utils get_role_permission N/A role N/A name N/A role N/A user roles N/A services N/A N/A service N/A user service_catalog N/A N/A N/A N/A service_type N/A service N/A type N/A N/A N/A KeyError N/A N/A N/A service_regions N/A N/A N/A utils get_endpoint_region endpoint N/A endpoint N/A N/A service get endpoints N/A N/A N/A N/A user services_region service_regions N/A N/A N/A N/A services append N/A N/A service_type lower N/A service_perms N/A N/A openstack.services.%s service N/A service services N/A N/A role_perms service_perms N/A has_perm N/A N/A self user perm obj N/A None N/A N/A Returns True if the given user has the specified permission. N/A N/A N/A user is_active N/A N/A False N/A N/A perm N/A N/A self get_all_permissions user obj N/A has_module_perms N/A N/A self user app_label N/A N/A N/A Returns True if user has any permissions in the given app_label.

        Currently this matches for the app_label ``"openstack"``.
         N/A N/A N/A user is_active N/A N/A False N/A perm N/A N/A self get_all_permissions user N/A N/A N/A N/A perm N/A N/A N/A perm index . app_label N/A N/A True N/A False N/A N/A