public class StormpathAuthenticator extends AbstractUsernamePasswordAuthenticator
Modifier and Type | Field and Description |
---|---|
protected org.slf4j.Logger |
logger |
passwordEncoder
Constructor and Description |
---|
StormpathAuthenticator(String stormpathAccessId,
String stormpathSecretKey,
String applicationId)
Receives the Stormpath admin credentials and applicationId and sets up and instance of a Stormpath's Application resource
which will be used to authenticate users.
|
Modifier and Type | Method and Description |
---|---|
protected com.stormpath.sdk.account.Account |
authenticateAccount(UsernamePasswordCredentials credentials) |
protected Map<String,Object> |
buildAttributesFromStormpathAccount(com.stormpath.sdk.account.Account account) |
protected StormpathProfile |
createProfile(com.stormpath.sdk.account.Account account) |
void |
validate(UsernamePasswordCredentials credentials)
Validate the credentials.
|
getPasswordEncoder, setPasswordEncoder
public StormpathAuthenticator(String stormpathAccessId, String stormpathSecretKey, String applicationId)
stormpathAccessId
- accessId provided by Stormpath, for the admin user with the created API key.stormpathSecretKey
- secret key provided by Stormpath, for the admin user with the created API key.applicationId
- This is application id configured on Stormpath whose login source will be used to authenticate users.public void validate(UsernamePasswordCredentials credentials)
UsernamePasswordAuthenticator
CredentialsException
in case of failure.credentials
- the given credentials.protected com.stormpath.sdk.account.Account authenticateAccount(UsernamePasswordCredentials credentials) throws com.stormpath.sdk.resource.ResourceException
com.stormpath.sdk.resource.ResourceException
protected StormpathProfile createProfile(com.stormpath.sdk.account.Account account)
Copyright © 2016. All rights reserved.