public class SimpleAuthenticationPlugin extends CRaSHPlugin<AuthenticationPlugin> implements AuthenticationPlugin<String>
Modifier and Type | Field and Description |
---|---|
private String |
password
.
|
static PropertyDescriptor<String> |
SIMPLE_PASSWORD
The password.
|
static PropertyDescriptor<String> |
SIMPLE_USERNAME
The username.
|
private String |
username
.
|
CONSTRUCTED, FAILED, INITIALIZED, INITIALIZING, log
AUTH, NULL
Constructor and Description |
---|
SimpleAuthenticationPlugin() |
Modifier and Type | Method and Description |
---|---|
boolean |
authenticate(String username,
String password)
Returns true if the user is authentified by its username and credential.
|
protected Iterable<PropertyDescriptor<?>> |
createConfigurationCapabilities()
Returns a list of
PropertyDescriptor this plugin requires for its configuration. |
Class<String> |
getCredentialType()
Returns the credential type.
|
AuthenticationPlugin |
getImplementation()
Returns the implementation.
|
String |
getName()
Returns the authentication plugin name.
|
void |
init()
Implement this method to know about init life cycle callback.
|
destroy, getConfigurationCapabilities, getContext, getStatus, getType, toString
public static final PropertyDescriptor<String> SIMPLE_USERNAME
public static final PropertyDescriptor<String> SIMPLE_PASSWORD
public SimpleAuthenticationPlugin()
protected Iterable<PropertyDescriptor<?>> createConfigurationCapabilities()
CRaSHPlugin
PropertyDescriptor
this plugin requires for its configuration.createConfigurationCapabilities
in class CRaSHPlugin<AuthenticationPlugin>
public Class<String> getCredentialType()
AuthenticationPlugin
getCredentialType
in interface AuthenticationPlugin<String>
public AuthenticationPlugin getImplementation()
CRaSHPlugin
getImplementation
in class CRaSHPlugin<AuthenticationPlugin>
public void init()
CRaSHPlugin
init
in class CRaSHPlugin<AuthenticationPlugin>
public String getName()
AuthenticationPlugin
getName
in interface AuthenticationPlugin<String>
public boolean authenticate(String username, String password) throws Exception
AuthenticationPlugin
authenticate
in interface AuthenticationPlugin<String>
username
- the usernamepassword
- the credentialException
- any exception that would prevent authentication to happenCopyright © 2015 eXo Platform SAS. All Rights Reserved.