Class DefaultTokenProvider

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      dev.soffa.foundation.model.Token create​(dev.soffa.foundation.model.TokenType type, java.lang.String subjet, java.util.Map<java.lang.String,​java.lang.Object> claims)  
      dev.soffa.foundation.model.Token create​(dev.soffa.foundation.model.TokenType type, java.lang.String subjet, java.util.Map<java.lang.String,​java.lang.Object> claims, int ttlInMinutes)  
      dev.soffa.foundation.model.Authentication decode​(java.lang.String token)  
      dev.soffa.foundation.model.Authentication decode​(java.lang.String token, ClaimsExtractor extractor)  
      dev.soffa.foundation.model.Authentication decodejwtWithJwks​(java.lang.String token, ClaimsExtractor extractor)  
      dev.soffa.foundation.model.Authentication decodeJwtWithSecret​(java.lang.String token, ClaimsExtractor claimsExtractor)  
      dev.soffa.foundation.model.Authentication extractInfo​(dev.soffa.foundation.model.Token token)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • DefaultTokenProvider

        public DefaultTokenProvider​(TokensConfig config)
    • Method Detail

      • create

        public dev.soffa.foundation.model.Token create​(dev.soffa.foundation.model.TokenType type,
                                                       java.lang.String subjet,
                                                       java.util.Map<java.lang.String,​java.lang.Object> claims)
        Specified by:
        create in interface TokenProvider
      • create

        public dev.soffa.foundation.model.Token create​(dev.soffa.foundation.model.TokenType type,
                                                       java.lang.String subjet,
                                                       java.util.Map<java.lang.String,​java.lang.Object> claims,
                                                       int ttlInMinutes)
        Specified by:
        create in interface TokenProvider
      • decode

        public dev.soffa.foundation.model.Authentication decode​(java.lang.String token)
        Specified by:
        decode in interface TokenProvider
      • decode

        public dev.soffa.foundation.model.Authentication decode​(java.lang.String token,
                                                                ClaimsExtractor extractor)
        Specified by:
        decode in interface TokenProvider
      • decodejwtWithJwks

        public dev.soffa.foundation.model.Authentication decodejwtWithJwks​(java.lang.String token,
                                                                           ClaimsExtractor extractor)
      • decodeJwtWithSecret

        public dev.soffa.foundation.model.Authentication decodeJwtWithSecret​(java.lang.String token,
                                                                             ClaimsExtractor claimsExtractor)