AbstractJwtProvider

abstract class AbstractJwtProvider(secretKey: SecretKey) : JwtProvider

Specification for JWT functions including Secret Key.

Throws

Inheritors

Constructors

Link copied to clipboard
constructor(secretKey: SecretKey)

Functions

Link copied to clipboard
fun createToken(authentication: JwtAuthentication, expire: Long): Token
fun createToken(payload: Map<String, String>, expire: Long): Token

Variant of JwtProvider.createToken using secretKey.

open override fun createToken(authentication: JwtAuthentication, expire: Long, secretKey: SecretKey): Token
open override fun createToken(payload: Map<String, String>, expire: Long, secretKey: SecretKey): Token
open override fun createToken(header: Map<String, String>, payload: Map<String, String>, expire: Long, secretKey: SecretKey): Token

Implementation of JwtProvider.createToken.

Link copied to clipboard

Method to get authentication. Implemented differently depending on the JwtAuthentication implementation used.

Link copied to clipboard
open override fun getHeader(token: Token): Map<String, String>

Implementation of JwtProvider.getHeader.

Link copied to clipboard
open override fun getPayload(token: Token): Map<String, String>

Implementation of JwtProvider.getPayload.