create_new_no_map_no_duplicated_helmholtz Strategy
Classes:
An authentication viewset. |
- class django_helmholtz_aai.views.auth.create_new_no_map_no_duplicated_helmholtz.AuthentificationViewset
Bases:
AuthentificationViewsetAn authentication viewset.
The following strategy is applied for new users:
when the email exists already: - prevent login
when the email does not exist: - create new user
Classes:
AuthentificationView(**kwargs)An authentification view.
- class AuthentificationView(**kwargs)
Bases:
CheckEmailMixin,AuthentificationViewAn authentification view.
Classes:
PermissionDeniedReasons(value)An enumeration.
Methods:
handle_new_user(userinfo)Handle the registration of a new user.
Check if the user has permission to login.
- class PermissionDeniedReasons(value)
Bases:
TextChoicesAn enumeration.
Attributes:
- email_exists = 'email_exists'
- email_not_verified = 'email_not_verified'
- helmholtz_email_exists = 'helmholtz_email_exists'
- no_user_exists = 'no_user_exists'
- vo_not_allowed = 'vo_not_allowed'
- handle_new_user(userinfo: Dict[str, Any]) Tuple[HelmholtzUser | None, Any]
Handle the registration of a new user.
- has_permission() bool
Check if the user has permission to login.
This method checks, if the user belongs to the specified
HELMHOLTZ_ALLOWED_VOSand verifies that the email does not exist (if this is desired, seeHELMHOLTZ_EMAIL_DUPLICATES_ALLOWEDsetting).