public class OneTimePasswordCredential extends AbstractCredential
UsernamePasswordCredential is that the username/ID is optional
in the former and requisite in the latter.
This class implements CredentialMetaData since the one-time-password is safe for long-term storage after
authentication. Note that metadata is stored only _after_ authentication, at which time the OTP has already
been consumed and by definition is no longer useful for authentication.
UNKNOWN_ID| Constructor and Description |
|---|
OneTimePasswordCredential(String password)
Creates a one-time-password with just a password.
|
OneTimePasswordCredential(String id,
String password)
Creates a one-time-password with unique ID and password.
|
| Modifier and Type | Method and Description |
|---|---|
String |
getId()
Gets the unique ID commonly used to look up a one-time password in a system of record.
|
String |
getPassword()
Gets the cleartext one-time password value.
|
equals, hashCode, toStringpublic OneTimePasswordCredential(String password)
password - Non-null cleartext one-time password value.Copyright © 2004-2015 Apereo. All Rights Reserved.