Package io.quarkus.amazon.lambda.http
Class CognitoPrincipal
java.lang.Object
io.quarkus.amazon.lambda.http.CognitoPrincipal
- All Implemented Interfaces:
Principal
,org.eclipse.microprofile.jwt.JsonWebToken
Represents a Cognito JWT used to authenticate request
Will only be allocated if requestContext.authorizer.jwt.claims.cognito:username is set
in the http event sent by API Gateway
-
Constructor Summary
ConstructorsConstructorDescriptionCognitoPrincipal
(com.amazonaws.services.lambda.runtime.events.APIGatewayV2HTTPEvent.RequestContext.Authorizer.JWT jwt) -
Method Summary
Modifier and TypeMethodDescription<T> T
com.amazonaws.services.lambda.runtime.events.APIGatewayV2HTTPEvent.RequestContext.Authorizer.JWT
long
long
getName()
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.eclipse.microprofile.jwt.JsonWebToken
claim, claim, containsClaim, getClaim, getIssuer, getRawToken, getSubject, getTokenID
-
Constructor Details
-
CognitoPrincipal
public CognitoPrincipal(com.amazonaws.services.lambda.runtime.events.APIGatewayV2HTTPEvent.RequestContext.Authorizer.JWT jwt)
-
-
Method Details
-
getName
-
getClaimNames
- Specified by:
getClaimNames
in interfaceorg.eclipse.microprofile.jwt.JsonWebToken
-
getClaim
- Specified by:
getClaim
in interfaceorg.eclipse.microprofile.jwt.JsonWebToken
-
getAudience
- Specified by:
getAudience
in interfaceorg.eclipse.microprofile.jwt.JsonWebToken
-
getExpirationTime
public long getExpirationTime()- Specified by:
getExpirationTime
in interfaceorg.eclipse.microprofile.jwt.JsonWebToken
-
getIssuedAtTime
public long getIssuedAtTime()- Specified by:
getIssuedAtTime
in interfaceorg.eclipse.microprofile.jwt.JsonWebToken
-
getGroups
- Specified by:
getGroups
in interfaceorg.eclipse.microprofile.jwt.JsonWebToken
-
getClaims
public com.amazonaws.services.lambda.runtime.events.APIGatewayV2HTTPEvent.RequestContext.Authorizer.JWT getClaims()
-