Class SecretJwksKeyParserServiceFactory
- java.lang.Object
-
- net.officefloor.web.jwt.authority.jwks.parser.SecretJwksKeyParserServiceFactory
-
- All Implemented Interfaces:
ServiceFactory<JwksKeyParser>
,JwksKeyParser
,JwksKeyParserServiceFactory
public class SecretJwksKeyParserServiceFactory extends java.lang.Object implements JwksKeyParserServiceFactory, JwksKeyParser
SecretKeySpec
JwksKeyParserServiceFactory
.- Author:
- Daniel Sagenschneider
-
-
Constructor Summary
Constructors Constructor Description SecretJwksKeyParserServiceFactory()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description JwksKeyParser
createService(ServiceContext context)
Creates the service.java.security.Key
parseKey(JwksKeyParserContext context)
Parses theKey
from the JWKkey
JsonNode
.
-
-
-
Method Detail
-
createService
public JwksKeyParser createService(ServiceContext context) throws java.lang.Throwable
Description copied from interface:ServiceFactory
Creates the service.- Specified by:
createService
in interfaceServiceFactory<JwksKeyParser>
- Parameters:
context
-ServiceContext
.- Returns:
- Service.
- Throws:
java.lang.Throwable
- If fails to create the service.
-
parseKey
public java.security.Key parseKey(JwksKeyParserContext context) throws java.lang.Exception
Description copied from interface:JwksKeyParser
Parses theKey
from the JWKkey
JsonNode
.- Specified by:
parseKey
in interfaceJwksKeyParser
- Parameters:
context
-JwksKeyParserContext
.- Returns:
Key
ornull
if not able to parseKey
(indicating for anotherJwksKeyParser
to attempt to obtain theKey
).- Throws:
java.lang.Exception
- If failure parsing theKey
.
-
-