-
Notifications
You must be signed in to change notification settings - Fork 232
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
fix: fix service account credentials createScopedRequired #601
Conversation
Codecov Report
@@ Coverage Diff @@
## master #601 +/- ##
=========================================
Coverage 83.49% 83.49%
- Complexity 599 600 +1
=========================================
Files 42 42
Lines 2708 2709 +1
Branches 288 288
=========================================
+ Hits 2261 2262 +1
Misses 304 304
Partials 143 143
Continue to review full report at Codecov.
|
oauth2_http/javatests/com/google/auth/oauth2/ServiceAccountCredentialsTest.java
Outdated
Show resolved
Hide resolved
oauth2_http/javatests/com/google/auth/oauth2/ServiceAccountCredentialsTest.java
Outdated
Show resolved
Hide resolved
…dentialsTest.java
/** Returns whether the scopes are empty, meaning createScoped must be called before use. */ | ||
@Override | ||
public boolean createScopedRequired() { | ||
return scopes.isEmpty(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think without having defaultScopes.isEmpty()
here as well, the Client Library for Storage will never use self-signed JWTs. And there may be more APIs like this.
This can be fixed in a future PR, however.
Fixes: GoogleCloudPlatform/java-docs-samples#4907 (comment)