feat!(google-auth): require 'audience' in verify_firebase_token()

Open
#18,870 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
57/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Active
Tech stack
python

Research direction

Read google.oauth2.id_token.verify_firebase_token() and its async counterpart in google.oauth2._id_token_async, then inspect their tests and the warning added in #18777. Make audience required in both APIs and verify that the Firebase token's aud claim is checked; done when both implementations and their tests reflect the required project ID.

Written by the indexing model from the issue text.

Description

auth next major: breaking change

Currently, google.oauth2.id_token.verify_firebase_token() (and its async counterpart in google.oauth2._id_token_async) defaults audience=None, leaving the token's aud claim unverified and emitting a UserWarning (added in #18777).

In the next major release of google-auth (3.0.0), audience (the target Firebase project ID) should be required so that verify_firebase_token() always verifies the aud claim per the Firebase ID token verification specification.

Dominant language
Python
Stars
5.4k
Forks
1.8k
Avg merge
2d 7h
Merged PRs (30d)
173

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from googleapis/google-cloud-python

All issues in googleapis/google-cloud-python

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.