|
10Duke Scale SDK for Java
|
Authorization provider that supplies 10Duke ScaleJWT tokens and headers.
Public Member Functions | |
| ScaleJwtAuthorizationProvider (final JwtService jwtService, final String issuer, final long exp, final List< String > apiPermissions) | |
| Creates a new instance of this class. | |
| String | buildAuthorizationHeader () |
| String | signingKeyId () |
| List< String > | apiPermissions () |
| Returns the API permissions defined for this instance. | |
Protected Member Functions | |
| void | addCustomClaims (final Map< String, Object > claims) |
| JWT build phase for adding custom claims. | |
Protected Member Functions inherited from tenduke.scale.api.JwtBuilderBase | |
| String | buildToken () |
Builds a JWT token with claims assembled in addAllClaims(Map<String, Object>). | |
| void | addAllClaims (final Map< String, Object > claims) |
| Adds all JWT claims to map as part of build JWT process. | |
| void | addStandardClaims (final Map< String, Object > claims) |
Adds jti, iat, iss and exp JWT claims to map as part of build JWT process. | |
| long | calculateExpiration () |
| Returns the effective expiration to be used in tokens. | |
| long | defaultExpiration () |
| Returns value of the default expiration for tokens. | |
| tenduke.scale.api.ScaleJwtAuthorizationProvider.ScaleJwtAuthorizationProvider | ( | final JwtService | jwtService, |
| final String | issuer, | ||
| final long | exp, | ||
| final List< String > | apiPermissions ) |
Creates a new instance of this class.
| jwtService | JwtService instance that is capable of building and signing JWT's. |
| issuer | Value to use for iss claim in JWT body. |
| exp | Value to use token expiration. |
| apiPermissions | List of permission grants that are set for tokens this class builds. |
|
protected |
JWT build phase for adding custom claims.
| claims | The claims map to add custom claims into. |
Reimplemented from tenduke.scale.api.JwtBuilderBase.
| List< String > tenduke.scale.api.ScaleJwtAuthorizationProvider.apiPermissions | ( | ) |
Returns the API permissions defined for this instance.
| String tenduke.scale.api.ScaleJwtAuthorizationProvider.buildAuthorizationHeader | ( | ) |
| String tenduke.scale.api.ScaleJwtAuthorizationProvider.signingKeyId | ( | ) |