question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[QUERY] Log what DefaultAzureCredential picks up (managed identity or env vars)

See original GitHub issue

Is there a way to tell what type of credentials (env vars/managed identity) is DefaultAzureCredential using?

I would like to log something along these lines:

[Info] Using Managed Identity to acquire an access token.

or

[Info] Using Environment Variables (service principal) to acquire an access token.

after calling

DefaultAzureCredential credential = new DefaultAzureCredentialBuilder().build();

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:8 (8 by maintainers)

github_iconTop GitHub Comments

1reaction
jianghaolucommented, Apr 7, 2020

Just a quick update we are having a cross-language overhaul for our logging mechanisms including addressing this need. I’ll update here when a PR is open and community review is welcomed.

0reactions
jianghaolucommented, Jul 7, 2020
Read more comments on GitHub >

github_iconTop Results From Across the Web

Expose Credential type for DefaultAzureCredential and ...
[QUERY] Log what DefaultAzureCredential picks up (managed identity or env vars) Azure/azure-sdk-for-java#6591.
Read more >
azure.identity.DefaultAzureCredential class - Microsoft Learn
A default credential capable of handling most Azure SDK authentication scenarios. The identity it uses depends on the environment.
Read more >
Eliminate Secrets from Your Applications with Azure Managed ...
As I publish the app, I can leverage Managed Identity to remove even those secrets from the connection string and double-down on the...
Read more >
Overview (Azure SDK for Java Reference Documentation) - NET
Package containing various types of credentials and classes for retrieving access tokens from various configurations. Azure Identity client library for Java.
Read more >
Mickaël Derriey
Active Directory Default, DefaultAzureCredential, Local development, Environment variables, managed identity, VS Code, Visual Studio, Azure CLI ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found