Skip to content

Commit

Permalink
docs: fix code block formatting in 'user-guide.rst' (#794)
Browse files Browse the repository at this point in the history
  • Loading branch information
mattseymour committed Jul 8, 2021
1 parent c5e112f commit 4fd84bd
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions docs/user-guide.rst
Expand Up @@ -479,16 +479,16 @@ IDToken verification can be done for various type of IDTokens using the
and ES256 algorithms. However, ES256 algorithm won't be available unless
`cryptography` dependency of version at least 1.4.0 is installed. You can check
the dependency with `pip freeze` or try `from google.auth.crypt import es256`.
The following is an example of verifying ID tokens:
The following is an example of verifying ID tokens ::

from google.auth2 import id_token

request = google.auth.transport.requests.Request()

try:
decoded_token = id_token.verify_token(token_to_verify,request)
decoded_token = id_token.verify_token(token_to_verify,request)
except ValueError:
# Verification failed.
# Verification failed.

A sample end-to-end flow using an ID Token against a Cloud Run endpoint maybe ::

Expand Down

0 comments on commit 4fd84bd

Please sign in to comment.