-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
Configure HttpTransport for proxied GoogleCredentials #17783
Conversation
b075587
to
468ef64
Compare
468ef64
to
c7be056
Compare
if (staticCredentialsConfig.getCredentialsFile().isPresent() || staticCredentialsConfig.getCredentialsKey().isPresent()) { | ||
credentialsSupplierBinder | ||
.setBinding() | ||
.to(StaticBigQueryCredentialsSupplier.class) |
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.
static one also needs the proxied transport. The service account key still requires to go talk to oauth2.googleapis.com to get an access token, the service account key itself is not an access token.
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.
Makes sense. Thanks for investigating that
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.
Done. I can indeed see extra proxied calls
Since this credentials could be obtained using proxied connections, it's not possible to validate those in a config class.
c7be056
to
2d9a83b
Compare
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.
LGTM.
I'll merge this after a run with secrets finishes.
/test-with-secrets sha=2d9a83b5d569dbade01ea4ba145c09557f54949e |
The CI workflow run with tests that require additional secrets finished as failure: https://github.com/trinodb/trino/actions/runs/5218792948 |
CI hit #16803 |
This would allow proxying communication with oauth2.googleapis.com when default credentials are used.