<PackageReference Include="Microsoft.Identity.Client" Version="4.82.1" />

Microsoft.Identity.Client.ManagedIdentity.IManagedIdentityKeyProvider

Provides managed identity keys for authentication scenarios. Implementations of this interface are responsible for obtaining or creating the best available key type (CredentialGuard, Hardware, or InMemory) for managed identity authentication.

Gets an existing managed identity key or creates a new one if none exists. The method returns the best available key type based on the provider's capabilities and the current environment.