Class TokenService
java.lang.Object
org.chenile.security.auth.server.service.TokenService
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final Stringprivate final AuthServerPropertiesprivate final com.nimbusds.jose.jwk.RSAKey -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionlongprivate com.nimbusds.jose.jwk.RSAKeybooleanisAdminToken(String tokenValue) issueClientToken(String tenant, String clientId, List<String> scopes) issueUserToken(String tenant, String clientId, String username, String userId, List<String> scopes, List<String> acls, Map<String, Object> additionalClaims) issueUserToken(String tenant, String clientId, String username, List<String> scopes, List<String> acls) issueUserToken(String tenant, String clientId, String username, List<String> scopes, List<String> acls, Map<String, Object> additionalClaims) jwks()private StringsignToken(String tenant, String subject, String authorizedParty, List<String> scopes, List<String> acls, String userId, Map<String, Object> additionalClaims) com.nimbusds.jwt.JWTClaimsSetverifiedClaims(String tokenValue)
-
Field Details
-
issuerBase
-
properties
-
rsaKey
private final com.nimbusds.jose.jwk.RSAKey rsaKey
-
-
Constructor Details
-
TokenService
public TokenService(@Value("${chenile.security.issuer-base:http://localhost:9000}") String issuerBase, AuthServerProperties properties)
-
-
Method Details
-
issuer
-
jwks
-
accessTokenTtlSeconds
public long accessTokenTtlSeconds() -
issueClientToken
-
issueUserToken
-
issueUserToken
-
issueUserToken
-
isAdminToken
-
verifiedClaims
-
signToken
-
generateKey
private com.nimbusds.jose.jwk.RSAKey generateKey()
-
CHENILE