Package org.gluu.oxauth.service
Class GrantService
- java.lang.Object
-
- org.gluu.oxauth.service.GrantService
-
@ApplicationScoped public class GrantService extends java.lang.Object
- Version:
- November 28, 2018
- Author:
- Yuriy Zabrovarnyy, Javier Rojas Blum
-
-
Constructor Summary
Constructors Constructor Description GrantService()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
buildDn(java.lang.String p_hashedToken)
static java.lang.String
generateGrantId()
ClientTokens
getCacheClientTokens(java.lang.String clientId)
java.util.List<TokenLdap>
getCacheClientTokensEntries(java.lang.String clientId)
SessionTokens
getCacheSessionTokens(java.lang.String sessionDn)
java.util.List<TokenLdap>
getCacheTokensEntries(java.util.Set<java.lang.String> tokenHashes)
TokenLdap
getGrantByCode(java.lang.String p_code)
java.util.List<TokenLdap>
getGrantsByAuthorizationCode(java.lang.String p_authorizationCode)
java.util.List<TokenLdap>
getGrantsByGrantId(java.lang.String p_grantId)
java.util.List<TokenLdap>
getGrantsBySessionDn(java.lang.String sessionDn)
java.util.List<TokenLdap>
getGrantsFromCacheBySessionDn(java.lang.String sessionDn)
java.util.List<TokenLdap>
getGrantsOfClient(java.lang.String p_clientId)
void
logout(java.lang.String sessionDn)
void
merge(TokenLdap p_token)
void
mergeSilently(TokenLdap p_token)
void
persist(TokenLdap token)
void
remove(java.util.List<TokenLdap> p_entries)
void
remove(AuthorizationGrant p_grant)
void
remove(TokenLdap p_token)
void
removeAllByAuthorizationCode(java.lang.String p_authorizationCode)
void
removeAllByGrantId(java.lang.String p_grantId)
void
removeAllTokensBySession(java.lang.String sessionDn, boolean logout)
void
removeAuthorizationCode(java.lang.String code)
void
removeByCode(java.lang.String p_code)
Removes grant with particular code.void
removeSilently(java.util.List<TokenLdap> p_entries)
void
removeSilently(TokenLdap token)
-
-
-
Method Detail
-
generateGrantId
public static java.lang.String generateGrantId()
-
buildDn
public java.lang.String buildDn(java.lang.String p_hashedToken)
-
merge
public void merge(TokenLdap p_token)
-
mergeSilently
public void mergeSilently(TokenLdap p_token)
-
persist
public void persist(TokenLdap token)
-
getCacheClientTokens
public ClientTokens getCacheClientTokens(java.lang.String clientId)
-
getCacheSessionTokens
public SessionTokens getCacheSessionTokens(java.lang.String sessionDn)
-
remove
public void remove(TokenLdap p_token)
-
removeSilently
public void removeSilently(TokenLdap token)
-
remove
public void remove(java.util.List<TokenLdap> p_entries)
-
removeSilently
public void removeSilently(java.util.List<TokenLdap> p_entries)
-
remove
public void remove(AuthorizationGrant p_grant)
-
getGrantsOfClient
public java.util.List<TokenLdap> getGrantsOfClient(java.lang.String p_clientId)
-
getGrantByCode
public TokenLdap getGrantByCode(java.lang.String p_code)
-
getGrantsByGrantId
public java.util.List<TokenLdap> getGrantsByGrantId(java.lang.String p_grantId)
-
getGrantsByAuthorizationCode
public java.util.List<TokenLdap> getGrantsByAuthorizationCode(java.lang.String p_authorizationCode)
-
getGrantsBySessionDn
public java.util.List<TokenLdap> getGrantsBySessionDn(java.lang.String sessionDn)
-
getGrantsFromCacheBySessionDn
public java.util.List<TokenLdap> getGrantsFromCacheBySessionDn(java.lang.String sessionDn)
-
getCacheClientTokensEntries
public java.util.List<TokenLdap> getCacheClientTokensEntries(java.lang.String clientId)
-
getCacheTokensEntries
public java.util.List<TokenLdap> getCacheTokensEntries(java.util.Set<java.lang.String> tokenHashes)
-
logout
public void logout(java.lang.String sessionDn)
-
removeAllTokensBySession
public void removeAllTokensBySession(java.lang.String sessionDn, boolean logout)
-
removeByCode
public void removeByCode(java.lang.String p_code)
Removes grant with particular code.- Parameters:
p_code
- code
-
removeAuthorizationCode
public void removeAuthorizationCode(java.lang.String code)
-
removeAllByAuthorizationCode
public void removeAllByAuthorizationCode(java.lang.String p_authorizationCode)
-
removeAllByGrantId
public void removeAllByGrantId(java.lang.String p_grantId)
-
-