Classes | |
class | AuthenticationToken |
Public Member Functions | |
PreDefinedAuthenticator (boolean alwaysAllow) | |
PreDefinedAuthenticator (String securePasscode, List< AuthenticationToken > upfrontTokens) | |
CompletableFuture< Boolean > | addAuthentication (String name, UUID uuid, boolean needsApproval) |
void | removeAuthentication (String user) |
boolean | authenticate (String user, UUID uuid) |
boolean | doesPasscodeMatch (String passcode) |
ManagementCapabilities | managementCapabilities () |
List< String > | getAllNames () |
Implements the authentication interface using a pre-defined upfront set of name and UUID pairs that must be provided upfront. This implementation will never save authentication blocks to storage.
CompletableFuture<Boolean> com.thecoderscorner.menu.auth.PreDefinedAuthenticator.addAuthentication | ( | String | user, |
UUID | uuid, | ||
boolean | needsApproval | ||
) |
Attempt to add authentication for user and UUID, if it fails to be added false will be returned.
user | the user to add |
uuid | the uuid associated with the user |
needsApproval | true if this is being added from a remote connection and needs approval, otherwise false. |
Implements com.thecoderscorner.menu.auth.MenuAuthenticator.
boolean com.thecoderscorner.menu.auth.PreDefinedAuthenticator.authenticate | ( | String | user, |
UUID | uuid | ||
) |
Check if the user and UUID pair can connect to this board.
user | the user to check for |
uuid | the UUID to check for |
Implements com.thecoderscorner.menu.auth.MenuAuthenticator.
boolean com.thecoderscorner.menu.auth.PreDefinedAuthenticator.doesPasscodeMatch | ( | String | passcode | ) |
Checks if the provided passcode matches with the security passcode and returns false if it does not match.
passcode | the passcode to check |
Implements com.thecoderscorner.menu.auth.MenuAuthenticator.
List<String> com.thecoderscorner.menu.auth.PreDefinedAuthenticator.getAllNames | ( | ) |
Gets a list of all apps/users stored in the system
Implements com.thecoderscorner.menu.auth.MenuAuthenticator.
ManagementCapabilities com.thecoderscorner.menu.auth.PreDefinedAuthenticator.managementCapabilities | ( | ) |
Indicates how this authenticator can be edited, some don't support any, some remove only.
Implements com.thecoderscorner.menu.auth.MenuAuthenticator.
void com.thecoderscorner.menu.auth.PreDefinedAuthenticator.removeAuthentication | ( | String | user | ) |
Remove the authentication for the given user
user | the user to remove |
Implements com.thecoderscorner.menu.auth.MenuAuthenticator.