IMDS Source Detection Logic Improvement - #5602
Merged
Merged
Conversation
… back to imdsv1 when determining source.
… tests in MangedIdentityTests.cs
bgavrilMS
reviewed
Nov 27, 2025
bgavrilMS
reviewed
Nov 27, 2025
bgavrilMS
reviewed
Nov 27, 2025
bgavrilMS
reviewed
Nov 27, 2025
bgavrilMS
reviewed
Nov 27, 2025
bgavrilMS
reviewed
Nov 27, 2025
bgavrilMS
approved these changes
Nov 27, 2025
gladjohn
reviewed
Dec 1, 2025
| ManagedIdentityApplication mi = miBuilder.Build() as ManagedIdentityApplication; | ||
|
|
||
| Assert.AreEqual(expectedManagedIdentitySource, await mi.GetManagedIdentitySourceAsync().ConfigureAwait(false)); | ||
| if (managedIdentitySource == ManagedIdentitySource.ImdsV2) |
Contributor
There was a problem hiding this comment.
Do we have a test where we first get a bearer and then request a POP token?
Contributor
Author
There was a problem hiding this comment.
This is currently not possible, we throw an error. We even have a unit test for this: ApplicationsCannotSwitchBetweenImdsVersionsForPreview
public const string CannotSwitchBetweenImdsVersionsForPreview = "ImdsV2 is currently experimental - A Bearer token has already been received; Please restart the application to receive a mTLS PoP token.";
bgavrilMS
reviewed
Dec 4, 2025
2 tasks
bgavrilMS
approved these changes
Dec 7, 2025
This was referenced May 20, 2026
This was referenced Jun 5, 2026
Closed
Closed
This was referenced Jun 19, 2026
Closed
Closed
This was referenced Jun 29, 2026
Closed
This was referenced Jul 9, 2026
Closed
This was referenced Jul 16, 2026
Closed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Implemented ImdsV2 and ImdsV1 probing
Implements #5594