package documentation

Undocumented

Module admin Undocumented
Module apps Undocumented
Module backends No module docstring; 0/1 variable, 2/5 classes documented
Module base_user This module allows importing AbstractBaseUser even when django.contrib.auth is not in INSTALLED_APPS.
Module checks Undocumented
Module context_processors No module docstring; 1/1 function, 0/2 class documented
Module decorators No module docstring; 3/3 functions documented
Module forms No module docstring; 0/1 variable, 1/1 function, 5/10 classes documented
Package handlers Undocumented
Module hashers No module docstring; 0/2 constant, 6/10 functions, 12/12 classes documented
Package management Creates permissions for all installed apps that need permissions.
Module middleware No module docstring; 0/1 function, 2/3 classes documented
Package migrations Undocumented
Module mixins No module docstring; 4/4 classes documented
Module models No module docstring; 3/4 functions, 6/9 classes documented
Module password_validation No module docstring; 0/1 variable, 5/7 functions, 4/4 classes documented
Module signals Undocumented
Module tokens No module docstring; 0/1 variable, 1/1 class documented
Module urls Undocumented
Module validators Undocumented
Module views No module docstring; 0/1 variable, 0/1 constant, 2/2 functions, 2/10 classes documented

From __init__.py:

Function authenticate If the given credentials are valid, return a User object.
Function get_backends Undocumented
Function get_permission_codename Return the codename of the permission for the specified action.
Function get_user Return the user model instance associated with the given request session. If no user is retrieved, return an instance of `AnonymousUser`.
Function get_user_model Return the User model that is active in this project.
Function load_backend Undocumented
Function login Persist a user id and a backend in the request. This way a user doesn't have to reauthenticate on every request. Note that data set during the anonymous session is retained when the user logs in.
Function logout Remove the authenticated user's ID from the request and flush their session data.
Function update_session_auth_hash Updating a user's password logs out all sessions for the user.
Constant BACKEND_SESSION_KEY Undocumented
Constant HASH_SESSION_KEY Undocumented
Constant REDIRECT_FIELD_NAME Undocumented
Constant SESSION_KEY Undocumented
Function _clean_credentials Clean a dictionary of credentials of potentially sensitive info before sending to less secure functions.
Function _get_backends Undocumented
Function _get_user_session_key Undocumented
SESSION_KEY: str = (source)

Undocumented

Value
'_auth_user_id'
BACKEND_SESSION_KEY: str = (source)

Undocumented

Value
'_auth_user_backend'
HASH_SESSION_KEY: str = (source)

Undocumented

Value
'_auth_user_hash'
REDIRECT_FIELD_NAME: str = (source)

Undocumented

Value
'next'
def load_backend(path): (source)

Undocumented

def _get_backends(return_tuples=False): (source)

Undocumented

def get_backends(): (source)

Undocumented

@sensitive_variables('credentials')
def _clean_credentials(credentials): (source)

Clean a dictionary of credentials of potentially sensitive info before sending to less secure functions. Not comprehensive - intended for user_login_failed signal

def _get_user_session_key(request): (source)

Undocumented

@sensitive_variables('credentials')
def authenticate(request=None, **credentials): (source)

If the given credentials are valid, return a User object.

def login(request, user, backend=None): (source)

Persist a user id and a backend in the request. This way a user doesn't have to reauthenticate on every request. Note that data set during the anonymous session is retained when the user logs in.

def logout(request): (source)

Remove the authenticated user's ID from the request and flush their session data.

def get_user_model(): (source)

Return the User model that is active in this project.

def get_user(request): (source)

Return the user model instance associated with the given request session. If no user is retrieved, return an instance of `AnonymousUser`.

def get_permission_codename(action, opts): (source)

Return the codename of the permission for the specified action.

def update_session_auth_hash(request, user): (source)

Updating a user's password logs out all sessions for the user. Take the current request and the updated user object from which the new session hash will be derived and update the session hash appropriately to prevent a password change from logging out the session from which the password was changed.