From 2335a26625c617316ffd672d8cb22ca01e43d28b Mon Sep 17 00:00:00 2001 From: Michael Zappe Date: Thu, 12 Feb 2026 11:13:20 +0100 Subject: [PATCH 1/2] Deprecation release for azure-mixedreality-authentication --- .../CHANGELOG.md | 3 +- .../README.md | 196 +----------------- .../pyproject.toml | 4 + .../setup.py | 2 +- 4 files changed, 8 insertions(+), 197 deletions(-) diff --git a/sdk/mixedreality/azure-mixedreality-authentication/CHANGELOG.md b/sdk/mixedreality/azure-mixedreality-authentication/CHANGELOG.md index a6212e593184..4a56f83ff0e2 100644 --- a/sdk/mixedreality/azure-mixedreality-authentication/CHANGELOG.md +++ b/sdk/mixedreality/azure-mixedreality-authentication/CHANGELOG.md @@ -1,6 +1,6 @@ # Release History -## 1.0.0b2 (Unreleased) +## 1.0.0b2 (2026-02-12) ### Features Added @@ -11,6 +11,7 @@ ### Other Changes - Python 2.7 is no longer supported. Please use Python version 3.7 or later. +- This package has been deprecated and will no longer be maintained after 10-01-2025. This package will only receive security fixes until 10-01-2025. ## 1.0.0b1 (2021-11-12) diff --git a/sdk/mixedreality/azure-mixedreality-authentication/README.md b/sdk/mixedreality/azure-mixedreality-authentication/README.md index f938b0ea2681..d7eb6c0c787e 100644 --- a/sdk/mixedreality/azure-mixedreality-authentication/README.md +++ b/sdk/mixedreality/azure-mixedreality-authentication/README.md @@ -1,195 +1 @@ -[![Build Status](https://dev.azure.com/azure-sdk/public/_apis/build/status/azure-sdk-for-python.client?branchName=master)](https://dev.azure.com/azure-sdk/public/_build/latest?definitionId=46?branchName=master) - -# Azure Mixed Reality Authentication Package client library for Python - -Mixed Reality services, like Azure Remote Rendering use the Mixed Reality security -token service (STS) for authentication. This package supports exchanging Mixed Reality account credentials for an access -token from the STS that can be used to access Mixed Reality services. - -# Getting started - -## Currently supported environments - -This package has been tested with Python 3.7+. - -## Prerequisites - -- An [Azure subscription][azure_sub]. -- You must have an account with an [Azure Mixed Reality service](https://azure.microsoft.com/topic/mixed-reality/): - - [Azure Remote Rendering](https://docs.microsoft.com/azure/remote-rendering/) -- Familiarity with the authentication and credential concepts from the [Azure Identity library][azure_identity]. -- Python 3.7 or later is required to use this package. - -## Install the package - -Install the Azure Mixed Reality Authentication SDK. - -```bash -pip install --pre azure-mixedreality-authentication -``` - -## Create and authenticate the client - -To create a client object to request an access token for a Mixed Reality service, you will need the `account identifier` -and `account domain` of your Mixed Reality service resource and a `credential`. - -Mixed Reality services support a few different forms of authentication: - -- Account Key authentication - - Account keys enable you to get started quickly with using Mixed Reality services. But before you deploy your application - to production, we recommend that you update your app to use Azure AD authentication. -- Azure Active Directory (AD) token authentication - - If you're building an enterprise application and your company is using Azure AD as its identity system, you can use - user-based Azure AD authentication in your app. You then grant access to your Mixed Reality accounts by using your - existing Azure AD security groups. You can also grant access directly to users in your organization. - - Otherwise, we recommend that you obtain Azure AD tokens from a web service that supports your app. We recommend this - method for production applications because it allows you to avoid embedding the credentials for access to a Mixed - Reality service in your client application. - -See [here][register_aad_app] for detailed instructions and information. - -### Using account key authentication - -Use the [Azure Portal][azure_portal] to browse to your Mixed Reality service resource and retrieve an `account key`. - -Once you have an account key, you can use the `AzureKeyCredential` class to authenticate the client as follows: - -```python -from azure.core.credentials import AzureKeyCredential -from azure.mixedreality.authentication import MixedRealityStsClient - -account_id = "" -account_domain = "" -account_key = "" -key_credential = AzureKeyCredential(account_key) - -client = MixedRealityStsClient(account_id, account_domain, key_credential) -``` - -> Note: Account key authentication is **not recommended** for production applications. - -### Using an Azure Active Directory Credential - -Account key authentication is used in most of the examples, but you can also authenticate with Azure Active Directory -using the [Azure Identity library][azure_identity]. This is the recommended method for production applications. To use -the [DefaultAzureCredential][defaultazurecredential] provider shown below, or other credential providers provided with -the Azure SDK, please install the `@azure/identity` package: - -You will also need to [register a new AAD application][register_aad_app] and grant access to your Mixed Reality resource -by assigning the appropriate role for your Mixed Reality service to your service principal. - -```python -from azure.identity import DefaultAzureCredential -from azure.mixedreality.authentication import MixedRealityStsClient - -account_id = "" -account_domain = "" -default_credential = DefaultAzureCredential() - -client = MixedRealityStsClient(account_id, account_domain, default_credential) -``` - -# Key concepts - -## MixedRealityStsClient - -The `MixedRealityStsClient` is the client library used to access the Mixed Reality STS to get an access token. An access -token can be retrieved by calling `get_token()` on an `MixedRealityStsClient` instance. - -Tokens obtained from the Mixed Reality STS have a lifetime of **24 hours**. - -### Token result value - -The return value for a successful call to `get_token` is an `azure.core.credentials.AccessToken`. - -See the authentication examples [above](#create-and-authenticate-the-client) or [Azure Identity][azure_identity] for more complex -authentication scenarios. - -## Retrieve an access token synchronously - -```python -from azure.core.credentials import AzureKeyCredential -from azure.mixedreality.authentication import MixedRealityStsClient - -account_id = "" -account_domain = "" -account_key = "" -key_credential = AzureKeyCredential(account_key) - -client = MixedRealityStsClient(account_id, account_domain, key_credential) - -token = client.get_token() -``` - -## Retrieve an access token asynchronously - -```python -from azure.core.credentials import AzureKeyCredential -from azure.mixedreality.authentication.aio import MixedRealityStsClient - -account_id = "" -account_domain = "" -account_key = "" -key_credential = AzureKeyCredential(account_key) - -client = MixedRealityStsClient(account_id, account_domain, key_credential) - -token = await client.get_token() -``` - -# Examples - -These are code samples that show common scenario operations with the Azure Mixed Reality Authentication client library. -The async versions of the samples (the python sample files appended with `_async`) show asynchronous operations, -and require Python 3.5 or later. -Before running the sample code, refer to Prerequisites - -to create a resource, then set some Environment Variables - -```bash -set MIXEDREALITY_ACCOUNT_DOMAIN="" -set MIXEDREALITY_ACCOUNT_ID="" -set MIXEDREALITY_ACCOUNT_KEY="" - -pip install azure-mixedreality-authentication - -python samples\client_sample.py -python samples\client_sample_async.py -``` - -# Troubleshooting - -The [troubleshooting](https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/identity/azure-identity#troubleshooting) -section for Azure Identity can be helpful when troubleshooting authentication issues. - -# Next steps - -## Mixed Reality client libraries - -- Coming soon - -## Contributing - -This project welcomes contributions and suggestions. Most contributions require you to agree to a -Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us -the rights to use your contribution. For details, visit https://cla.microsoft.com. - -When you submit a pull request, a CLA-bot will automatically determine whether you need to provide -a CLA and decorate the PR appropriately (e.g., label, comment). Simply follow the instructions -provided by the bot. You will only need to do this once across all repos using our CLA. - -This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). -For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or -contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments. - -If you'd like to contribute to this library, please read the -[contributing guide](https://github.com/Azure/azure-sdk-for-python/blob/main/CONTRIBUTING.md) to learn more about how to -build and test the code. - - - -[azure_cli]: https://docs.microsoft.com/cli/azure -[azure_sub]: https://azure.microsoft.com/free/ -[azure_portal]: https://portal.azure.com -[azure_identity]: https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/identity/azure-identity -[defaultazurecredential]: https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/identity/azure-identity#defaultazurecredential +This package has been deprecated and will no longer be maintained after 10-01-2025. This package will only receive security fixes until 10-01-2025. \ No newline at end of file diff --git a/sdk/mixedreality/azure-mixedreality-authentication/pyproject.toml b/sdk/mixedreality/azure-mixedreality-authentication/pyproject.toml index 1ea1e48c18ff..39a3d838744b 100644 --- a/sdk/mixedreality/azure-mixedreality-authentication/pyproject.toml +++ b/sdk/mixedreality/azure-mixedreality-authentication/pyproject.toml @@ -1,3 +1,7 @@ [tool.azure-sdk-build] +breaking = false +mypy = false pyright = false +type_check_samples = false +verifytypes = false ci_enabled = false diff --git a/sdk/mixedreality/azure-mixedreality-authentication/setup.py b/sdk/mixedreality/azure-mixedreality-authentication/setup.py index de2ff250d121..a69b7914d14e 100644 --- a/sdk/mixedreality/azure-mixedreality-authentication/setup.py +++ b/sdk/mixedreality/azure-mixedreality-authentication/setup.py @@ -44,7 +44,7 @@ license='MIT License', # ensure that the development status reflects the status of your package classifiers=[ - "Development Status :: 4 - Beta", + 'Development Status :: 7 - Inactive', 'Programming Language :: Python', 'Programming Language :: Python :: 3 :: Only', 'Programming Language :: Python :: 3', From ee650e289781aef8084c8b28501c314ac9cf046d Mon Sep 17 00:00:00 2001 From: Michael Zappe Date: Fri, 13 Feb 2026 11:33:25 +0100 Subject: [PATCH 2/2] Satisfy the piplines that should be disabled --- .../CHANGELOG.md | 6 - .../README.md | 202 +++++++++++++++++- 2 files changed, 201 insertions(+), 7 deletions(-) diff --git a/sdk/mixedreality/azure-mixedreality-authentication/CHANGELOG.md b/sdk/mixedreality/azure-mixedreality-authentication/CHANGELOG.md index 4a56f83ff0e2..b4957c6049db 100644 --- a/sdk/mixedreality/azure-mixedreality-authentication/CHANGELOG.md +++ b/sdk/mixedreality/azure-mixedreality-authentication/CHANGELOG.md @@ -2,12 +2,6 @@ ## 1.0.0b2 (2026-02-12) -### Features Added - -### Breaking Changes - -### Bugs Fixed - ### Other Changes - Python 2.7 is no longer supported. Please use Python version 3.7 or later. diff --git a/sdk/mixedreality/azure-mixedreality-authentication/README.md b/sdk/mixedreality/azure-mixedreality-authentication/README.md index d7eb6c0c787e..df7b335432e6 100644 --- a/sdk/mixedreality/azure-mixedreality-authentication/README.md +++ b/sdk/mixedreality/azure-mixedreality-authentication/README.md @@ -1 +1,201 @@ -This package has been deprecated and will no longer be maintained after 10-01-2025. This package will only receive security fixes until 10-01-2025. \ No newline at end of file +[![Build Status](https://dev.azure.com/azure-sdk/public/_apis/build/status/azure-sdk-for-python.client?branchName=master)](https://dev.azure.com/azure-sdk/public/_build/latest?definitionId=46?branchName=master) + +# Azure Mixed Reality Authentication Package client library for Python + +## Deprecation notice + +This package has been deprecated and will no longer be maintained after 10-01-2025. This package will only receive security fixes until 10-01-2025. + +## Overview + +Mixed Reality services, like Azure Remote Rendering use the Mixed Reality security +token service (STS) for authentication. This package supports exchanging Mixed Reality account credentials for an access +token from the STS that can be used to access Mixed Reality services. + +# Getting started + +## Currently supported environments + +This package has been tested with Python 3.7+. + +## Prerequisites + +- An [Azure subscription][azure_sub]. +- You must have an account with an [Azure Mixed Reality service](https://azure.microsoft.com/topic/mixed-reality/): + - [Azure Remote Rendering](https://docs.microsoft.com/azure/remote-rendering/) +- Familiarity with the authentication and credential concepts from the [Azure Identity library][azure_identity]. +- Python 3.7 or later is required to use this package. + +## Install the package + +Install the Azure Mixed Reality Authentication SDK. + +```bash +pip install --pre azure-mixedreality-authentication +``` + +## Create and authenticate the client + +To create a client object to request an access token for a Mixed Reality service, you will need the `account identifier` +and `account domain` of your Mixed Reality service resource and a `credential`. + +Mixed Reality services support a few different forms of authentication: + +- Account Key authentication + - Account keys enable you to get started quickly with using Mixed Reality services. But before you deploy your application + to production, we recommend that you update your app to use Azure AD authentication. +- Azure Active Directory (AD) token authentication + - If you're building an enterprise application and your company is using Azure AD as its identity system, you can use + user-based Azure AD authentication in your app. You then grant access to your Mixed Reality accounts by using your + existing Azure AD security groups. You can also grant access directly to users in your organization. + - Otherwise, we recommend that you obtain Azure AD tokens from a web service that supports your app. We recommend this + method for production applications because it allows you to avoid embedding the credentials for access to a Mixed + Reality service in your client application. + +See [here][register_aad_app] for detailed instructions and information. + +### Using account key authentication + +Use the [Azure Portal][azure_portal] to browse to your Mixed Reality service resource and retrieve an `account key`. + +Once you have an account key, you can use the `AzureKeyCredential` class to authenticate the client as follows: + +```python +from azure.core.credentials import AzureKeyCredential +from azure.mixedreality.authentication import MixedRealityStsClient + +account_id = "" +account_domain = "" +account_key = "" +key_credential = AzureKeyCredential(account_key) + +client = MixedRealityStsClient(account_id, account_domain, key_credential) +``` + +> Note: Account key authentication is **not recommended** for production applications. + +### Using an Azure Active Directory Credential + +Account key authentication is used in most of the examples, but you can also authenticate with Azure Active Directory +using the [Azure Identity library][azure_identity]. This is the recommended method for production applications. To use +the [DefaultAzureCredential][defaultazurecredential] provider shown below, or other credential providers provided with +the Azure SDK, please install the `@azure/identity` package: + +You will also need to [register a new AAD application][register_aad_app] and grant access to your Mixed Reality resource +by assigning the appropriate role for your Mixed Reality service to your service principal. + +```python +from azure.identity import DefaultAzureCredential +from azure.mixedreality.authentication import MixedRealityStsClient + +account_id = "" +account_domain = "" +default_credential = DefaultAzureCredential() + +client = MixedRealityStsClient(account_id, account_domain, default_credential) +``` + +# Key concepts + +## MixedRealityStsClient + +The `MixedRealityStsClient` is the client library used to access the Mixed Reality STS to get an access token. An access +token can be retrieved by calling `get_token()` on an `MixedRealityStsClient` instance. + +Tokens obtained from the Mixed Reality STS have a lifetime of **24 hours**. + +### Token result value + +The return value for a successful call to `get_token` is an `azure.core.credentials.AccessToken`. + +See the authentication examples [above](#create-and-authenticate-the-client) or [Azure Identity][azure_identity] for more complex +authentication scenarios. + +## Retrieve an access token synchronously + +```python +from azure.core.credentials import AzureKeyCredential +from azure.mixedreality.authentication import MixedRealityStsClient + +account_id = "" +account_domain = "" +account_key = "" +key_credential = AzureKeyCredential(account_key) + +client = MixedRealityStsClient(account_id, account_domain, key_credential) + +token = client.get_token() +``` + +## Retrieve an access token asynchronously + +```python +from azure.core.credentials import AzureKeyCredential +from azure.mixedreality.authentication.aio import MixedRealityStsClient + +account_id = "" +account_domain = "" +account_key = "" +key_credential = AzureKeyCredential(account_key) + +client = MixedRealityStsClient(account_id, account_domain, key_credential) + +token = await client.get_token() +``` + +# Examples + +These are code samples that show common scenario operations with the Azure Mixed Reality Authentication client library. +The async versions of the samples (the python sample files appended with `_async`) show asynchronous operations, +and require Python 3.5 or later. +Before running the sample code, refer to Prerequisites + +to create a resource, then set some Environment Variables + +```bash +set MIXEDREALITY_ACCOUNT_DOMAIN="" +set MIXEDREALITY_ACCOUNT_ID="" +set MIXEDREALITY_ACCOUNT_KEY="" + +pip install azure-mixedreality-authentication + +python samples\client_sample.py +python samples\client_sample_async.py +``` + +# Troubleshooting + +The [troubleshooting](https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/identity/azure-identity#troubleshooting) +section for Azure Identity can be helpful when troubleshooting authentication issues. + +# Next steps + +## Mixed Reality client libraries + +- Coming soon + +## Contributing + +This project welcomes contributions and suggestions. Most contributions require you to agree to a +Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us +the rights to use your contribution. For details, visit https://cla.microsoft.com. + +When you submit a pull request, a CLA-bot will automatically determine whether you need to provide +a CLA and decorate the PR appropriately (e.g., label, comment). Simply follow the instructions +provided by the bot. You will only need to do this once across all repos using our CLA. + +This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). +For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or +contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments. + +If you'd like to contribute to this library, please read the +[contributing guide](https://github.com/Azure/azure-sdk-for-python/blob/main/CONTRIBUTING.md) to learn more about how to +build and test the code. + + + +[azure_cli]: https://docs.microsoft.com/cli/azure +[azure_sub]: https://azure.microsoft.com/free/ +[azure_portal]: https://portal.azure.com +[azure_identity]: https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/identity/azure-identity +[defaultazurecredential]: https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/identity/azure-identity#defaultazurecredential