Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: fix code block formatting in 'user-guide.rst' #794

Merged
merged 2 commits into from
Jul 8, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions docs/user-guide.rst
Original file line number Diff line number Diff line change
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