com.atlassian.jira.user
Class DefaultSecureUserTokenManager
java.lang.Object
com.atlassian.jira.user.DefaultSecureUserTokenManager
- All Implemented Interfaces:
- SecureUserTokenManager
public class DefaultSecureUserTokenManager
- extends Object
- implements SecureUserTokenManager
- See Also:
SecureUserTokenManager} for details
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DefaultSecureUserTokenManager
public DefaultSecureUserTokenManager()
generateToken
public String generateToken(com.atlassian.crowd.embedded.api.User user,
SecureUserTokenManager.TokenType tokenType)
- Description copied from interface:
SecureUserTokenManager
- Given a user and tokentype this method creates a new secure token and returns this token. A particular user can
have multiple tokens mapped at any given time.
- Specified by:
generateToken
in interface SecureUserTokenManager
- Parameters:
user
- The user this token is fortokenType
- The SecureUserTokenManager.TokenType
for this token
- Returns:
- A new token or null if no user was provided
useToken
public com.atlassian.crowd.embedded.api.User useToken(String token,
SecureUserTokenManager.TokenType tokenType)
- Description copied from interface:
SecureUserTokenManager
- Given a token and tokenType, this method returns the User that was mapped to this token and then revokes the
token to ensure it can't be used again.
- Specified by:
useToken
in interface SecureUserTokenManager
- Parameters:
token
- A secure tokentokenType
- The SecureUserTokenManager.TokenType
for this token
- Returns:
- The User mapped to this token, or null if no mapping can be found.
onClearCache
@EventListener
public void onClearCache(ClearCacheEvent event)
Copyright © 2002-2013 Atlassian. All Rights Reserved.