Update app check debug provider to match other firebase sdks - #1911
Update app check debug provider to match other firebase sdks#1911AustinBenoit wants to merge 1 commit into
Conversation
There was a problem hiding this comment.
Code Review
This pull request updates the desktop debug provider for App Check to automatically generate a UUID-based debug token if the APP_CHECK_DEBUG_TOKEN environment variable is not provided, and logs a warning message with registration instructions. Feedback points out a critical compilation error due to an incomplete declaration of GenerateDebugToken and suggests a minor optimization to avoid calling std::getenv twice.
86b3f8c to
c5a9883
Compare
|
/gemini review |
There was a problem hiding this comment.
Code Review
This pull request updates the App Check Desktop Debug Provider to automatically generate a local debug token using a UUID if the 'APP_CHECK_DEBUG_TOKEN' environment variable is not set, and logs instructions for registering it. The review feedback correctly identifies a potential data race in 'GetTokenInternal' when lazy-initializing the debug token and modifying the static logging flag concurrently, and suggests using a 'std::mutex' along with including the '' header to ensure thread safety.
To alight with other SDK's the cpp app check debug provider will create a token on behalf of the user if they have not already created and registered one. Users will be prompted to register token
c5a9883 to
230c8b7
Compare
a-maurice
left a comment
There was a problem hiding this comment.
Unlike the other platforms, won't this generate a different debug token each time the app is run? I feel like this is more likely to cause confusion, cause the token we are telling them to use will change each time. I'd prefer if either it saved the generated token in someway and used it each time (which is admittedly going to be complicated), or to avoid doing this.
To alight with other SDK's the cpp app check debug provider will create a token on behalf of the user if they have not already created and registered one. Users will be prompted to register token
Description
Update app check debug provider to match other firebase sdks
Testing
Ran a test ensuring the new phrase is output
Type of Change
Place an
xthe applicable box:Notes
Release Notessection ofrelease_build_files/readme.md.