Class TokenVerifier (1.29.1-SNAPSHOT)

publicclass TokenVerifier

Handle verification of Google-signed JWT tokens.

Inheritance

java.lang.Object > TokenVerifier

Static Methods

newBuilder()

publicstaticTokenVerifier.BuildernewBuilder()
Returns
Type Description
TokenVerifier.Builder

Methods

verify(String token)

publicJsonWebSignatureverify(Stringtoken)

Verify an encoded JWT token.

Parameter
Name Description
token String

encoded JWT token

Returns
Type Description
com.google.api.client.json.webtoken.JsonWebSignature

the parsed JsonWebSignature instance for additional validation if necessary

Exceptions
Type Description
TokenVerifier.VerificationException

thrown if any verification fails

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025年10月30日 UTC.