ENH: Clear authentication defaults with more fine-grained control
See original GitHub issueWe have about 220 lines of code which handles authentication - do we need that? Generally the answer to “do we need something we do a lot of” is ‘Yes’, but asking regardless
My prior is that we could:
- Check if creds are passed by the user
- Otherwise pass nothing through to the Google libraries, and let them manage the defaults
That would reduced the code we needed to maintain and conform to standards - Google have very reasonable defaults, and we make it harder for those to flow through - e.g. PANDAS_GBQ_CREDENTIALS_FILE is non-standard, every other implementation uses GOOGLE_APPLICATION_CREDENTIALS, so users need to have an additional setting to use this library
Issue Analytics
- State:
- Created 6 years ago
- Comments:8 (2 by maintainers)
Top Results From Across the Web
server: turn `--insecure` flag into more fine-grained controls · Issue ...
We're running Cockroach in single-tenant environments (i.e. don't care about per-user credentials etc.) over purely private networks (secure by default). In ...
Read more >Manage personal access tokens - Azure Databricks
Manage token-based authentication for Azure Databricks REST API clients. ... API 2.0 to control token usage at a more fine-grained level.
Read more >A Reference Architecture for Fine-Grained Access ... - InfoQ
A new access management architecture with a focus on a non-repudiable user identity, short-lived certificates or tokens, and a centralized fine- ...
Read more >Managing client configuration defaults - 11.2 - Documentation
On the Client Configuration Defaults tab, specify the default settings that are proprietary to PingFederate for clients created with the OAuth 2.0 Dynamic ......
Read more >Adding Windows Domain Authentication Method - Portnox
At the same time, ZTNA enables more granular and extensive network access control policies, improved scalability, and greater simplicity.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

I definitely think there is room for improvement here. My ideal flow would be:
google-auth.PANDAS_GBQ_CREDENTIALS_FILEenv var. (Should we keep doing this?)google-auth.Note that
google-authdefault credentials does not do three-legged OAuth, so I think that’s an area wherepandas-gbqwill need to keep some auth code around.Edit: Swapped items (1) and (2) so that explicitly passed credentials are always used first. Also, current behavior does default credentials before
PANDAS_GBQ_CREDENTIALS_FILE. If we keepPANDAS_GBQ_CREDENTIALS_FILEaround, we should prefer it to default credentials.I have fleshed out a design that accounts for this feedback at #161. Closing this issue as a duplicate of that proposal.