Skip to content

Make all credentials pickleable #33836

@xiangyan99

Description

@xiangyan99

msal.TokenCache is not pickleable now.

In the case that a credential has a member of msal.TokenCache, if it is provided by the user, we raise error and fail to pickle it.

If it is created by the class, we drop the token cache and recreate it when loading it.

  • AuthorizationCodeCredential
  • AzureDeveloperCliCredential
  • AzureCliCredential
  • AzurePowerShellCredential
  • CertificateCredential
  • ChainedTokenCredential
  • ClientAssertionCredential
  • ClientSecretCredential
  • DefaultAzureCredential
  • DeviceCodeCredential
  • EnvironmentCredential
  • InteractiveBrowserCredential
  • ManagedIdentityCredential
  • OnBehalfOfCredential
  • SharedTokenCacheCredential
  • UsernamePasswordCredential
  • VisualStudioCodeCredential
  • WorkloadIdentityCredential
  • AuthorizationCodeCredential-async
  • AzureDeveloperCliCredential-async
  • AzureCliCredential-async
  • AzurePowerShellCredential-async
  • CertificateCredential-async
  • ChainedTokenCredential-async
  • ClientSecretCredential-async
  • ClientAssertionCredential-async
  • DefaultAzureCredential-async
  • EnvironmentCredential-async
  • ManagedIdentityCredential-async
  • OnBehalfOfCredential-async
  • SharedTokenCacheCredential-async
  • VisualStudioCodeCredential-async
  • WorkloadIdentityCredential-async

#21996

Metadata

Metadata

Assignees

Labels

Azure.IdentityClientThis issue points to a problem in the data-plane of the library.

Type

No type

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions