Package com.iizix.device
Class SignInPermissions
java.lang.Object
com.iizix.device.SignInPermissions
- All Implemented Interfaces:
Cloneable
Sign in permissions class.
- Author:
- Christopher Mindus
Field Summary
Modifier and TypeFieldDescriptionstatic final SignInPermissions
The sign-in permissions with nothing allowed.Method Summary
Modifier and TypeMethodDescriptionstatic SignInPermissions
builder()
Creates the builder of sign-in permissions.boolean
Checks if two instances are equal.fromTokens
(String tokens) Creates the sign-in permissions from an initial permissions set combined with an additional saved set.Returns the permission as a tokenized string.int
hashCode()
Returns a hash code value for the object.boolean
Gets the flag indicating Administrator password strength entropy is required.boolean
Get the flag for sign-in storing of parameters is allowed.boolean
Gets the flag indicating auto-sign with user + sign-in provider is allowed.boolean
Gets the flag indicating auto-sign with user + password is allowed.boolean
Gets the flag indicating biometric authentication is required.boolean
Gets the flag indicating External Authenticator program required, e.g.boolean
Gets the flag enabling "Remember Password" (for user/password) settings on the device in question.boolean
Gets the flag enabling "Remember User" (not password) settings on the device in question.toString()
Gets the string representation of this instance with all "allow" or "required" parameters.Creates a new instance with "Admin Password Entropy Strength Required" enabled.withAdminPasswordEntropyStrengthRequired
(boolean on) Creates a new instance with "Admin Password Entropy Strength Required" enabled.Creates a new instance with "allowed", by default no permissions are allowed at all.withAllowed
(boolean on) Creates a new instance with "allowed", by default no permissions are allowed at all.Creates a new instance with "Auto Sign-InUser Password/Allowed" enabled.withAutoSignInProviderAllowed
(boolean on) Creates a new instance with "Auto Sign-In Provider Allowed" enabled.Creates a new instance with "Auto Sign-InUser Password/Allowed" enabled.withAutoSignInUserPasswordAllowed
(boolean on) Creates a new instance with "Auto Sign-InUser Password/Allowed" enabled.Creates a new instance with "Biometrics Required" enabled.withBiometricsRequired
(boolean on) Creates a new instance with "Biometrics Required" enabled.Creates a new instance with flag enabling "External Authenticator Required" settings on the device in question.withExternalAuthenticatorRequired
(boolean on) Creates a new instance with flag enabling "External Authenticator Required" settings on the device in question.Creates a new instance with "Remember Password Allowed" (for user).withRememberPasswordAllowed
(boolean on) Creates a new instance with "Remember Password Allowed" (for user).Creates a new instance with "Remember User Allowed" (not password).withRememberUserAllowed
(boolean on) Creates a new instance with "Remember User Allowed" (not password).
Field Details
NONE
The sign-in permissions with nothing allowed.
Method Details
getTokenizedString
Returns the permission as a tokenized string.- Returns:
- The tokenized string.
- Throws:
IllegalArgumentException
- In case of token errors.
isAllowed
public boolean isAllowed()Get the flag for sign-in storing of parameters is allowed. If denied, everything is disabled.- Returns:
- The flag.
isRememberUserAllowed
public boolean isRememberUserAllowed()Gets the flag enabling "Remember User" (not password) settings on the device in question.- Returns:
- The flag.
isRememberPasswordAllowed
public boolean isRememberPasswordAllowed()Gets the flag enabling "Remember Password" (for user/password) settings on the device in question.- Returns:
- The flag.
isBiometricsRequired
public boolean isBiometricsRequired()Gets the flag indicating biometric authentication is required.- Returns:
- The flag.
isExternalAuthenticatorRequired
public boolean isExternalAuthenticatorRequired()Gets the flag indicating External Authenticator program required, e.g. MFA authentication using a TOTP based QR code.- Returns:
- The flag.
isAdminPasswordEntropyStrengthRequired
public boolean isAdminPasswordEntropyStrengthRequired()Gets the flag indicating Administrator password strength entropy is required.- Returns:
- The flag.
isAutoSignInUserPasswordAllowed
public boolean isAutoSignInUserPasswordAllowed()Gets the flag indicating auto-sign with user + password is allowed.- Returns:
- The flag.
isAutoSignInProviderAllowed
public boolean isAutoSignInProviderAllowed()Gets the flag indicating auto-sign with user + sign-in provider is allowed.- Returns:
- The flag.
equals
Checks if two instances are equal.hashCode
public int hashCode()Returns a hash code value for the object.toString
Gets the string representation of this instance with all "allow" or "required" parameters.builder
Creates the builder of sign-in permissions.- Returns:
- The instance of the sign-in permission class with everything NOT ALLOWED.
fromTokens
Creates the sign-in permissions from an initial permissions set combined with an additional saved set.- Parameters:
tokens
- The tokens string of previous set of permissions.- Returns:
- The new permissions instance, or the same if there is no difference.
- Throws:
IllegalArgumentException
- In case of token errors.
withAllowed
Creates a new instance with "allowed", by default no permissions are allowed at all.- Returns:
- The new instance of the class, or the same if flag is already set.
withAllowed
Creates a new instance with "allowed", by default no permissions are allowed at all.- Parameters:
on
- Enablement flag.- Returns:
- The new instance of the class, or the same if flag is already set.
withRememberUserAllowed
Creates a new instance with "Remember User Allowed" (not password).- Returns:
- The new instance of the class, or the same if flag is already set.
withRememberUserAllowed
Creates a new instance with "Remember User Allowed" (not password).- Parameters:
on
- Enablement flag.- Returns:
- The new instance of the class, or the same if flag is already set.
withRememberPasswordAllowed
Creates a new instance with "Remember Password Allowed" (for user).- Returns:
- The new instance of the class, or the same if flag is already set.
withRememberPasswordAllowed
Creates a new instance with "Remember Password Allowed" (for user).- Parameters:
on
- Enablement flag.- Returns:
- The new instance of the class, or the same if flag is already set.
withBiometricsRequired
Creates a new instance with "Biometrics Required" enabled.- Returns:
- The new instance of the class, or the same if flag is already set.
withBiometricsRequired
Creates a new instance with "Biometrics Required" enabled.- Parameters:
on
- Enablement flag.- Returns:
- The new instance of the class, or the same if flag is already set.
withExternalAuthenticatorRequired
Creates a new instance with flag enabling "External Authenticator Required" settings on the device in question.- Returns:
- The new instance of the class, or the same if flag is already set.
withExternalAuthenticatorRequired
Creates a new instance with flag enabling "External Authenticator Required" settings on the device in question.- Parameters:
on
- Enablement flag.- Returns:
- The new instance of the class, or the same if flag is already set.
withAdminPasswordEntropyStrengthRequired
Creates a new instance with "Admin Password Entropy Strength Required" enabled.- Returns:
- The new instance of the class, or the same if flag is already set.
withAdminPasswordEntropyStrengthRequired
Creates a new instance with "Admin Password Entropy Strength Required" enabled.- Parameters:
on
- Enablement flag.- Returns:
- The new instance of the class, or the same if flag is already set.
withAutoSignInUserPasswordAllowed
Creates a new instance with "Auto Sign-InUser Password/Allowed" enabled.- Returns:
- The new instance of the class, or the same if flag is already set.
withAutoSignInUserPasswordAllowed
Creates a new instance with "Auto Sign-InUser Password/Allowed" enabled.- Parameters:
on
- Enablement flag.- Returns:
- The new instance of the class, or the same if flag is already set.
withAutoSignInProviderAllowed
Creates a new instance with "Auto Sign-InUser Password/Allowed" enabled.- Returns:
- The new instance of the class, or the same if flag is already set.
withAutoSignInProviderAllowed
Creates a new instance with "Auto Sign-In Provider Allowed" enabled.- Parameters:
on
- Enablement flag.- Returns:
- The new instance of the class, or the same if flag is already set.