Class AuthenticationController
java.lang.Object
com.atlassian.crowd.plugin.rest.service.controller.AbstractResourceController
com.atlassian.crowd.plugin.rest.service.controller.AuthenticationController
User authentication controller.
-
Constructor Summary
ConstructorDescriptionAuthenticationController
(ApplicationService applicationService, AuthenticatedApplicationHolder authenticatedApplicationHolder) -
Method Summary
Modifier and TypeMethodDescriptionauthenticateUser
(String username, PasswordEntity password, URI baseUri) Authenticates the user with the givenusername
andpassword
.userAuthenticated
(String username, URI baseUri) Methods inherited from class com.atlassian.crowd.plugin.rest.service.controller.AbstractResourceController
getAuthenticatedApplication
-
Constructor Details
-
AuthenticationController
@Inject public AuthenticationController(ApplicationService applicationService, AuthenticatedApplicationHolder authenticatedApplicationHolder)
-
-
Method Details
-
authenticateUser
public UserEntity authenticateUser(String username, PasswordEntity password, URI baseUri) throws UserNotFoundException, ExpiredCredentialException, InactiveAccountException, InvalidAuthenticationException, OperationFailedException Authenticates the user with the givenusername
andpassword
. Does not generate a token.- Parameters:
username
- username to authenticate the userpassword
- password to authenticate the userbaseUri
- Base URI of the REST service- Returns:
- UserEntity if the authentication succeeded
- Throws:
ExpiredCredentialException
- if the user's credentials have expired.InactiveAccountException
- if the user's account is inactive.InvalidAuthenticationException
- if the authentication details provided are not valid, or if the user does not exist.OperationFailedException
- if the underlying directory implementation failed to execute the operation.UserNotFoundException
-
userAuthenticated
public UserEntity userAuthenticated(String username, URI baseUri) throws UserNotFoundException, OperationFailedException, InactiveAccountException, InvalidAuthenticationException
-