public class SecureTokenServiceImpl extends Object implements SecureTokenService
BEAN_NAME
Modifier | Constructor and Description |
---|---|
protected |
SecureTokenServiceImpl() |
|
SecureTokenServiceImpl(XStreamFactory xStreamFactory) |
Modifier and Type | Method and Description |
---|---|
SecureToken |
generate(Key key)
Generates a
SecureToken for a given Key |
void |
invalidate(Key key)
Invalidates the
SecureToken for the given Key |
boolean |
isValid(SecureToken tokenToValidate)
Checks if the given
SecureToken is valid |
boolean |
isValid(SecureToken tokenToValidate,
Key key)
Checks if the given
SecureToken is valid for given Key |
void |
restoreState()
Restore tokens on server restart.
|
@TestOnly protected SecureTokenServiceImpl()
public SecureTokenServiceImpl(XStreamFactory xStreamFactory)
@NotNull public SecureToken generate(@NotNull Key key)
SecureTokenService
SecureToken
for a given Key
generate
in interface SecureTokenService
public boolean isValid(@NotNull SecureToken tokenToValidate)
SecureTokenService
SecureToken
is validisValid
in interface SecureTokenService
public boolean isValid(@NotNull SecureToken tokenToValidate, @NotNull Key key)
SecureTokenService
SecureToken
is valid for given Key
isValid
in interface SecureTokenService
public void invalidate(@NotNull Key key)
SecureTokenService
SecureToken
for the given Key
invalidate
in interface SecureTokenService
public void restoreState()
restoreState
in interface SecureTokenService
Copyright © 2019 Atlassian Software Systems Pty Ltd. All rights reserved.