Class TokenVerifier (1.19.0)

public class TokenVerifier

Handle verification of Google-signed JWT tokens.

Inheritance

java.lang.Object > TokenVerifier

Static Methods

newBuilder()

public static TokenVerifier.Builder newBuilder()
Returns
TypeDescription
TokenVerifier.Builder

Methods

verify(String token)

public JsonWebSignature verify(String token)

Verify an encoded JWT token.

Parameter
NameDescription
tokenString

encoded JWT token

Returns
TypeDescription
com.google.api.client.json.webtoken.JsonWebSignature

the parsed JsonWebSignature instance for additional validation if necessary

Exceptions
TypeDescription
TokenVerifier.VerificationException

thrown if any verification fails