|
1 | 1 | # Azure Identity client library for Python
|
2 | 2 |
|
3 |
| -The Azure Identity library provides [Microsoft Entra ID](https://learn.microsoft.com/azure/active-directory/fundamentals/active-directory-whatis) ([formerly Azure Active Directory](https://learn.microsoft.com/azure/active-directory/fundamentals/new-name)) token authentication support across the Azure SDK. It provides a set of [`TokenCredential`](https://learn.microsoft.com/python/api/azure-core/azure.core.credentials.tokencredential?view=azure-python) implementations, which can be used to construct Azure SDK clients that support Microsoft Entra token authentication. |
| 3 | +The Azure Identity library provides [Microsoft Entra ID](https://learn.microsoft.com/entra/fundamentals/whatis) ([formerly Azure Active Directory](https://learn.microsoft.com/entra/fundamentals/new-name)) token authentication support across the Azure SDK. It provides a set of [`TokenCredential`](https://learn.microsoft.com/python/api/azure-core/azure.core.credentials.tokencredential?view=azure-python) implementations, which can be used to construct Azure SDK clients that support Microsoft Entra token authentication. |
4 | 4 |
|
5 | 5 | [Source code](https://github.com/Azure/azure-sdk-for-python/blob/main/sdk/identity/azure-identity)
|
6 | 6 | | [Package (PyPI)](https://pypi.org/project/azure-identity/)
|
@@ -178,15 +178,15 @@ client = SecretClient("https://my-vault.vault.azure.net", default_credential)
|
178 | 178 |
|
179 | 179 | ## Managed identity support
|
180 | 180 |
|
181 |
| -[Managed identity authentication](https://learn.microsoft.com/azure/active-directory/managed-identities-azure-resources/overview) is supported via either the `DefaultAzureCredential` or the `ManagedIdentityCredential` directly for the following Azure services: |
| 181 | +[Managed identity authentication](https://learn.microsoft.com/entra/identity/managed-identities-azure-resources/overview) is supported via either the `DefaultAzureCredential` or the `ManagedIdentityCredential` directly for the following Azure services: |
182 | 182 |
|
183 | 183 | - [Azure App Service and Azure Functions](https://learn.microsoft.com/azure/app-service/overview-managed-identity?tabs=python)
|
184 | 184 | - [Azure Arc](https://learn.microsoft.com/azure/azure-arc/servers/managed-identity-authentication)
|
185 | 185 | - [Azure Cloud Shell](https://learn.microsoft.com/azure/cloud-shell/msi-authorization)
|
186 | 186 | - [Azure Kubernetes Service](https://learn.microsoft.com/azure/aks/use-managed-identity)
|
187 | 187 | - [Azure Service Fabric](https://learn.microsoft.com/azure/service-fabric/concepts-managed-identity)
|
188 |
| -- [Azure Virtual Machines](https://learn.microsoft.com/azure/active-directory/managed-identities-azure-resources/how-to-use-vm-token) |
189 |
| -- [Azure Virtual Machines Scale Sets](https://learn.microsoft.com/azure/active-directory/managed-identities-azure-resources/qs-configure-powershell-windows-vmss) |
| 188 | +- [Azure Virtual Machines](https://learn.microsoft.com/entra/identity/managed-identities-azure-resources/how-to-use-vm-token) |
| 189 | +- [Azure Virtual Machines Scale Sets](https://learn.microsoft.com/entra/identity/managed-identities-azure-resources/qs-configure-powershell-windows-vmss) |
190 | 190 |
|
191 | 191 | ### Examples
|
192 | 192 |
|
@@ -250,19 +250,19 @@ Not all credentials require this configuration. Credentials that authenticate th
|
250 | 250 |
|
251 | 251 | |Credential|Usage|Reference
|
252 | 252 | |-|-|-
|
253 |
| -|[`CertificateCredential`][cert_cred_ref]| Authenticates a service principal using a certificate. | [Service principal authentication](https://learn.microsoft.com/azure/active-directory/develop/app-objects-and-service-principals) |
| 253 | +|[`CertificateCredential`][cert_cred_ref]| Authenticates a service principal using a certificate. | [Service principal authentication](https://learn.microsoft.com/entra/identity-platform/app-objects-and-service-principals) |
254 | 254 | |[`ClientAssertionCredential`][client_assertion_cred_ref]| Authenticates a service principal using a signed client assertion. |
|
255 |
| -|[`ClientSecretCredential`][client_secret_cred_ref]| Authenticates a service principal using a secret. | [Service principal authentication](https://learn.microsoft.com/azure/active-directory/develop/app-objects-and-service-principals) |
| 255 | +|[`ClientSecretCredential`][client_secret_cred_ref]| Authenticates a service principal using a secret. | [Service principal authentication](https://learn.microsoft.com/entra/identity-platform/app-objects-and-service-principals) |
256 | 256 |
|
257 | 257 | ### Authenticate users
|
258 | 258 |
|
259 | 259 | |Credential|Usage| Reference | Notes
|
260 | 260 | |-|-|-|-
|
261 |
| -|[`AuthorizationCodeCredential`][auth_code_cred_ref]| Authenticates a user with a previously obtained authorization code. | [OAuth2 authentication code](https://learn.microsoft.com/azure/active-directory/develop/v2-oauth2-auth-code-flow)| |
262 |
| -|[`DeviceCodeCredential`][device_code_cred_ref]| Interactively authenticates a user on devices with limited UI. | [Device code authentication](https://learn.microsoft.com/azure/active-directory/develop/v2-oauth2-device-code)| |
263 |
| -|[`InteractiveBrowserCredential`][interactive_cred_ref]| Interactively authenticates a user with the default system browser. | [OAuth2 authentication code](https://learn.microsoft.com/azure/active-directory/develop/v2-oauth2-auth-code-flow)| `InteractiveBrowserCredential` doesn't support GitHub Codespaces. As a workaround, use [`DeviceCodeCredential`][device_code_cred_ref]. |
264 |
| -|[`OnBehalfOfCredential`][obo_cred_ref]| Propagates the delegated user identity and permissions through the request chain. | [On-behalf-of authentication](https://learn.microsoft.com/azure/active-directory/develop/v2-oauth2-on-behalf-of-flow)| |
265 |
| -|[`UsernamePasswordCredential`][userpass_cred_ref]| Authenticates a user with a username and password (doesn't support multi-factor authentication). | [Username + password authentication](https://learn.microsoft.com/azure/active-directory/develop/v2-oauth-ropc)| |
| 261 | +|[`AuthorizationCodeCredential`][auth_code_cred_ref]| Authenticates a user with a previously obtained authorization code. | [OAuth2 authentication code](https://learn.microsoft.com/entra/identity-platform/v2-oauth2-auth-code-flow)| |
| 262 | +|[`DeviceCodeCredential`][device_code_cred_ref]| Interactively authenticates a user on devices with limited UI. | [Device code authentication](https://learn.microsoft.com/entra/identity-platform/v2-oauth2-device-code)| |
| 263 | +|[`InteractiveBrowserCredential`][interactive_cred_ref]| Interactively authenticates a user with the default system browser. | [OAuth2 authentication code](https://learn.microsoft.com/entra/identity-platform/v2-oauth2-auth-code-flow)| `InteractiveBrowserCredential` doesn't support GitHub Codespaces. As a workaround, use [`DeviceCodeCredential`][device_code_cred_ref]. |
| 264 | +|[`OnBehalfOfCredential`][obo_cred_ref]| Propagates the delegated user identity and permissions through the request chain. | [On-behalf-of authentication](https://learn.microsoft.com/entra/identity-platform/v2-oauth2-on-behalf-of-flow)| |
| 265 | +|[`UsernamePasswordCredential`][userpass_cred_ref]| Authenticates a user with a username and password (doesn't support multi-factor authentication). | [Username + password authentication](https://learn.microsoft.com/entra/identity-platform/v2-oauth-ropc)| |
266 | 266 |
|
267 | 267 | ### Authenticate via development tools
|
268 | 268 |
|
@@ -333,7 +333,7 @@ Credentials raise `CredentialUnavailableError` when they're unable to attempt au
|
333 | 333 |
|
334 | 334 | Credentials raise `azure.core.exceptions.ClientAuthenticationError` when they fail to authenticate. `ClientAuthenticationError` has a `message` attribute, which describes why authentication failed. When raised by `DefaultAzureCredential` or `ChainedTokenCredential`, the message collects error messages from each credential in the chain.
|
335 | 335 |
|
336 |
| -For more information on handling specific Microsoft Entra ID errors, see the Microsoft Entra ID [error code documentation](https://learn.microsoft.com/azure/active-directory/develop/reference-error-codes). |
| 336 | +For more information on handling specific Microsoft Entra ID errors, see the Microsoft Entra ID [error code documentation](https://learn.microsoft.com/entra/identity-platform/reference-error-codes). |
337 | 337 |
|
338 | 338 | ### Logging
|
339 | 339 |
|
@@ -383,7 +383,7 @@ This project has adopted the [Microsoft Open Source Code of Conduct](https://ope
|
383 | 383 | [azure_keyvault_secrets]: https://github.com/Azure/azure-sdk-for-python/blob/main/sdk/keyvault/azure-keyvault-secrets
|
384 | 384 | [azure_storage_blob]: https://github.com/Azure/azure-sdk-for-python/blob/main/sdk/storage/azure-storage-blob
|
385 | 385 | [b2c]: https://learn.microsoft.com/azure/active-directory-b2c/overview
|
386 |
| -[cae]: https://learn.microsoft.com/azure/active-directory/conditional-access/concept-continuous-access-evaluation |
| 386 | +[cae]: https://learn.microsoft.com/entra/identity/conditional-access/concept-continuous-access-evaluation |
387 | 387 | [cert_cred_ref]: https://aka.ms/azsdk/python/identity/certificatecredential
|
388 | 388 | [chain_cred_ref]: https://aka.ms/azsdk/python/identity/chainedtokencredential
|
389 | 389 | [cli_cred_ref]: https://aka.ms/azsdk/python/identity/azclicredential
|
|
0 commit comments