diff --git a/.github/policies/close-issues.yml b/.github/policies/close-issues.yml index c7a4be4800945..9405d590b3a93 100644 --- a/.github/policies/close-issues.yml +++ b/.github/policies/close-issues.yml @@ -43,3 +43,5 @@ configuration: label: code-of-conduct then: - closeIssue + - removeLabel: + label: ':watch: Not Triaged' diff --git a/.github/workflows/check-for-build-warnings.yml b/.github/workflows/check-for-build-warnings.yml index 839162daa8eef..27def4ba21480 100644 --- a/.github/workflows/check-for-build-warnings.yml +++ b/.github/workflows/check-for-build-warnings.yml @@ -1,6 +1,6 @@ name: 'OPS status checker' -on: +on: pull_request_target: types: [opened, synchronize, reopened] @@ -20,8 +20,6 @@ jobs: with: egress-policy: audit - - uses: dotnet/docs-tools/actions/status-checker@main + - uses: dotnet/docs-tools/actions/status-checker@e761d65daef04078de70423f735850919b4c8610 # main with: repo_token: ${{ secrets.GITHUB_TOKEN }} - docs_path: "docs" - url_base_path: "dotnet" diff --git a/.github/workflows/generate-preview-links.yml b/.github/workflows/generate-preview-links.yml new file mode 100644 index 0000000000000..35f759da9db02 --- /dev/null +++ b/.github/workflows/generate-preview-links.yml @@ -0,0 +1,27 @@ +name: 'Preview link generator' + +on: + pull_request_target: + types: [opened, synchronize, reopened] + +permissions: + contents: read + +jobs: + preview_link_generator_job: + name: Generate preview link table + runs-on: ubuntu-latest + permissions: + statuses: read + pull-requests: write + steps: + - name: Harden Runner + uses: step-security/harden-runner@bf7454d06d71f1098171f2acdf0cd4708d7b5920 # v2.20.0 + with: + egress-policy: audit + + - uses: dotnet/docs-tools/actions/preview-link-generator@e761d65daef04078de70423f735850919b4c8610 # main + with: + repo_token: ${{ secrets.GITHUB_TOKEN }} + docs_path: "docs" + url_base_path: "dotnet" diff --git a/.github/workflows/snippets5000.yml b/.github/workflows/snippets5000.yml index d1d583065917c..a106f217695da 100644 --- a/.github/workflows/snippets5000.yml +++ b/.github/workflows/snippets5000.yml @@ -41,7 +41,7 @@ jobs: # Get the latest preview SDK (or sdk not installed by the runner) - name: Setup .NET if: ${{ env.DOTNET_DO_INSTALL == 'true' }} - uses: actions/setup-dotnet@26b0ec14cb23fa6904739307f278c14f94c95bf1 #@5.4.0 + uses: actions/setup-dotnet@a98b56852c35b8e3190ac28c8c2271da59106c68 #@6.0.0 with: dotnet-version: ${{ env.DOTNET_VERSION }} dotnet-quality: ${{ env.DOTNET_QUALITY }} diff --git a/docs/ai/evaluation/snippets/evaluate-safety/EvaluateResponseSafety.csproj b/docs/ai/evaluation/snippets/evaluate-safety/EvaluateResponseSafety.csproj index d786108938172..ce4e5475fb009 100644 --- a/docs/ai/evaluation/snippets/evaluate-safety/EvaluateResponseSafety.csproj +++ b/docs/ai/evaluation/snippets/evaluate-safety/EvaluateResponseSafety.csproj @@ -11,15 +11,15 @@ - - - + + + - - - - - + + + + + diff --git a/docs/ai/evaluation/snippets/evaluate-with-reporting/TestAIWithReporting.csproj b/docs/ai/evaluation/snippets/evaluate-with-reporting/TestAIWithReporting.csproj index e6aa6e6f3f975..96093d9c7962b 100644 --- a/docs/ai/evaluation/snippets/evaluate-with-reporting/TestAIWithReporting.csproj +++ b/docs/ai/evaluation/snippets/evaluate-with-reporting/TestAIWithReporting.csproj @@ -11,15 +11,15 @@ - - - - - - - - - + + + + + + + + + diff --git a/docs/ai/how-to/snippets/access-data/Project.csproj b/docs/ai/how-to/snippets/access-data/Project.csproj index 7f3e57a492884..c57c3b823fc50 100644 --- a/docs/ai/how-to/snippets/access-data/Project.csproj +++ b/docs/ai/how-to/snippets/access-data/Project.csproj @@ -11,10 +11,10 @@ - - - - + + + + diff --git a/docs/ai/how-to/snippets/hosted-app-auth/hosted-app-auth.csproj b/docs/ai/how-to/snippets/hosted-app-auth/hosted-app-auth.csproj index 4bb5dd0840d57..e2b58354ef241 100644 --- a/docs/ai/how-to/snippets/hosted-app-auth/hosted-app-auth.csproj +++ b/docs/ai/how-to/snippets/hosted-app-auth/hosted-app-auth.csproj @@ -10,9 +10,9 @@ - - - + + + diff --git a/docs/ai/quickstarts/snippets/assistants/AIAssistants.csproj b/docs/ai/quickstarts/snippets/assistants/AIAssistants.csproj index ea95ce7db3461..b2e4de73baa1a 100644 --- a/docs/ai/quickstarts/snippets/assistants/AIAssistants.csproj +++ b/docs/ai/quickstarts/snippets/assistants/AIAssistants.csproj @@ -10,7 +10,7 @@ - + diff --git a/docs/ai/quickstarts/snippets/mcp-client/MinimalMCPClient.csproj b/docs/ai/quickstarts/snippets/mcp-client/MinimalMCPClient.csproj index d864c58960e6e..b5c3a1e77ed26 100644 --- a/docs/ai/quickstarts/snippets/mcp-client/MinimalMCPClient.csproj +++ b/docs/ai/quickstarts/snippets/mcp-client/MinimalMCPClient.csproj @@ -10,9 +10,9 @@ - - - + + + diff --git a/docs/ai/quickstarts/snippets/mcp-server/SampleMcpServer.csproj b/docs/ai/quickstarts/snippets/mcp-server/SampleMcpServer.csproj index 3f434ae774dcc..bef872ee23b70 100644 --- a/docs/ai/quickstarts/snippets/mcp-server/SampleMcpServer.csproj +++ b/docs/ai/quickstarts/snippets/mcp-server/SampleMcpServer.csproj @@ -33,8 +33,8 @@ - - + + diff --git a/docs/ai/quickstarts/snippets/process-data/ProcessData.csproj b/docs/ai/quickstarts/snippets/process-data/ProcessData.csproj index 518df2a412544..1d74590eb9592 100644 --- a/docs/ai/quickstarts/snippets/process-data/ProcessData.csproj +++ b/docs/ai/quickstarts/snippets/process-data/ProcessData.csproj @@ -10,12 +10,12 @@ - - - + + + - + diff --git a/docs/ai/snippets/microsoft-extensions-ai/AI.Shared/AI.Shared.csproj b/docs/ai/snippets/microsoft-extensions-ai/AI.Shared/AI.Shared.csproj index 12221484fdaf0..5be95331ffd22 100644 --- a/docs/ai/snippets/microsoft-extensions-ai/AI.Shared/AI.Shared.csproj +++ b/docs/ai/snippets/microsoft-extensions-ai/AI.Shared/AI.Shared.csproj @@ -7,8 +7,8 @@ - - + + diff --git a/docs/ai/snippets/microsoft-extensions-ai/ConsoleAI.DependencyInjection/ConsoleAI.DependencyInjection.csproj b/docs/ai/snippets/microsoft-extensions-ai/ConsoleAI.DependencyInjection/ConsoleAI.DependencyInjection.csproj index 50e1e1fe6874e..0cc134ed3f9be 100644 --- a/docs/ai/snippets/microsoft-extensions-ai/ConsoleAI.DependencyInjection/ConsoleAI.DependencyInjection.csproj +++ b/docs/ai/snippets/microsoft-extensions-ai/ConsoleAI.DependencyInjection/ConsoleAI.DependencyInjection.csproj @@ -8,9 +8,9 @@ - - - + + + diff --git a/docs/ai/snippets/microsoft-extensions-ai/ConsoleAI.StatelessStateful/ConsoleAI.StatelessStateful.csproj b/docs/ai/snippets/microsoft-extensions-ai/ConsoleAI.StatelessStateful/ConsoleAI.StatelessStateful.csproj index 07ce1559e10ff..db7ac97ed3f5c 100644 --- a/docs/ai/snippets/microsoft-extensions-ai/ConsoleAI.StatelessStateful/ConsoleAI.StatelessStateful.csproj +++ b/docs/ai/snippets/microsoft-extensions-ai/ConsoleAI.StatelessStateful/ConsoleAI.StatelessStateful.csproj @@ -8,11 +8,11 @@ - + - + diff --git a/docs/ai/vector-stores/define-your-data-model.md b/docs/ai/vector-stores/define-your-data-model.md index b15e63d5e594d..79389a89f49ad 100644 --- a/docs/ai/vector-stores/define-your-data-model.md +++ b/docs/ai/vector-stores/define-your-data-model.md @@ -127,7 +127,7 @@ Use the attrib It's also possible to use on properties that don't have a vector type, for example, a property of type `string`. When a property is decorated in this way, you need to provide an instance to the vector store. When upserting the record, the text that's in the `string` property is automatically converted and stored as a vector in the database. (It's not possible to retrieve a vector using this mechanism.) ```csharp -[VectorStoreVector(Dimensions: 4, DistanceFunction = DistanceFunction.CosineSimilarity, IndexKind = IndexKind.Hnsw)] +[VectorStoreVector(dimensions: 4, DistanceFunction = DistanceFunction.CosineSimilarity, IndexKind = IndexKind.Hnsw)] public string DescriptionEmbedding { get; set; } ``` @@ -138,7 +138,7 @@ The following table shows the parameters for `VectorStoreVectorAttribute`. | Parameter | Required | Description | |------------------------------------------------------------------------------------|:--------:|-------------| -| | Yes | The number of dimensions that the vector has. This is required when creating a vector index for a collection. | +| `dimensions` | Yes | The number of dimensions that the vector has. This is required when creating a vector index for a collection. Pass as a constructor argument: `[VectorStoreVector(dimensions: 1536)]`. | | | No | The type of index to index the vector with. Default varies by vector store type. | | | No | The type of function to use when doing vector comparison during vector search over this vector. Default varies by vector store type. | | | No | Can be used to supply an alternative name for the property in the database. This parameter is not supported by all providers, for example, where alternatives like `JsonPropertyNameAttribute` is supported. | @@ -174,7 +174,7 @@ Vector databases are all about storing *embeddings* - or numerical representatio You can define your vector property as `float[]` or `ReadOnlyMemory`, representing the embedding directly, and generate embeddings yourself before each operation: ```csharp -[VectorStoreVector(Dimensions: 1536)] +[VectorStoreVector(dimensions: 1536)] public ReadOnlyMemory? DescriptionEmbedding { get; set; } ``` @@ -196,7 +196,7 @@ The recommended approach is to configure an > embeddingGenerator = ...; @@ -85,22 +85,19 @@ class Movie [VectorStoreData] public string Title { get; set; } - [VectorStoreVector(Dimensions: 1536)] + [VectorStoreVector(dimensions: 1536)] public string Description { get; set; } } ``` ## Vector store providers -The `Microsoft.Extensions.VectorData.Abstractions` package defines the abstractions, and separate [provider packages](/semantic-kernel/concepts/vector-store-connectors/out-of-the-box-connectors/) provide implementations for specific vector databases. Choose the provider that matches your vector database, for example, [Microsoft.SemanticKernel.Connectors.AzureAISearch](https://www.nuget.org/packages/Microsoft.SemanticKernel.Connectors.AzureAISearch). - -> [!NOTE] -> Despite the inclusion of "SemanticKernel" in the package names, these providers have nothing to do with Semantic Kernel and are usable anywhere in .NET, including Agent Framework. +The `Microsoft.Extensions.VectorData.Abstractions` package defines the abstractions, and separate provider packages provide implementations for specific vector databases. Choose the provider that matches your vector database, for example, [CommunityToolkit.VectorData.AzureAISearch](https://www.nuget.org/packages/CommunityToolkit.VectorData.AzureAISearch). All providers implement the same and abstract classes, so you can switch between them without changing your application logic. > [!TIP] -> Use the in-memory provider ([Microsoft.SemanticKernel.Connectors.InMemory](https://www.nuget.org/packages/Microsoft.SemanticKernel.Connectors.InMemory)) during initial development/prototyping - it doesn't require any external service or configuration, and you can swap it out for a production provider later. Avoid using the InMemory provider for testing, as there can be important differences between this provider and your production database. Consider using [testcontainers](https://dotnet.testcontainers.org/) to run tests against your production database system. +> Use the in-memory provider ([CommunityToolkit.VectorData.InMemory](https://www.nuget.org/packages/CommunityToolkit.VectorData.InMemory)) during initial development/prototyping - it doesn't require any external service or configuration, and you can swap it out for a production provider later. Avoid using the InMemory provider for testing, as there can be important differences between this provider and your production database. Consider using [testcontainers](https://dotnet.testcontainers.org/) to run tests against your production database system. ## Related content diff --git a/docs/ai/vector-stores/snippets/chat-with-data/azure-openai/CloudService.cs b/docs/ai/vector-stores/snippets/chat-with-data/azure-openai/CloudService.cs index 44b3d72a86c83..8bba97b150ad3 100644 --- a/docs/ai/vector-stores/snippets/chat-with-data/azure-openai/CloudService.cs +++ b/docs/ai/vector-stores/snippets/chat-with-data/azure-openai/CloudService.cs @@ -14,7 +14,7 @@ internal class CloudService public string Description { get; set; } [VectorStoreVector( - Dimensions: 384, + dimensions: 384, DistanceFunction = DistanceFunction.CosineSimilarity)] public ReadOnlyMemory Vector { get; set; } } diff --git a/docs/ai/vector-stores/snippets/chat-with-data/azure-openai/Program.cs b/docs/ai/vector-stores/snippets/chat-with-data/azure-openai/Program.cs index 426e977d37e64..cb5b65de6005b 100644 --- a/docs/ai/vector-stores/snippets/chat-with-data/azure-openai/Program.cs +++ b/docs/ai/vector-stores/snippets/chat-with-data/azure-openai/Program.cs @@ -3,7 +3,7 @@ using Microsoft.Extensions.AI; using Microsoft.Extensions.Configuration; using Microsoft.Extensions.VectorData; -using Microsoft.SemanticKernel.Connectors.InMemory; +using CommunityToolkit.VectorData.InMemory; using System.Linq; using VectorDataAI; diff --git a/docs/ai/vector-stores/snippets/chat-with-data/azure-openai/VectorDataAI.csproj b/docs/ai/vector-stores/snippets/chat-with-data/azure-openai/VectorDataAI.csproj index d2a9c4b4cfc60..fd9ce3938535a 100644 --- a/docs/ai/vector-stores/snippets/chat-with-data/azure-openai/VectorDataAI.csproj +++ b/docs/ai/vector-stores/snippets/chat-with-data/azure-openai/VectorDataAI.csproj @@ -14,7 +14,7 @@ - + diff --git a/docs/ai/vector-stores/snippets/chat-with-data/openai/CloudService.cs b/docs/ai/vector-stores/snippets/chat-with-data/openai/CloudService.cs index 44b3d72a86c83..8bba97b150ad3 100644 --- a/docs/ai/vector-stores/snippets/chat-with-data/openai/CloudService.cs +++ b/docs/ai/vector-stores/snippets/chat-with-data/openai/CloudService.cs @@ -14,7 +14,7 @@ internal class CloudService public string Description { get; set; } [VectorStoreVector( - Dimensions: 384, + dimensions: 384, DistanceFunction = DistanceFunction.CosineSimilarity)] public ReadOnlyMemory Vector { get; set; } } diff --git a/docs/ai/vector-stores/snippets/chat-with-data/openai/Program.cs b/docs/ai/vector-stores/snippets/chat-with-data/openai/Program.cs index c43fe9f6781e0..d2d6a8ab864b4 100644 --- a/docs/ai/vector-stores/snippets/chat-with-data/openai/Program.cs +++ b/docs/ai/vector-stores/snippets/chat-with-data/openai/Program.cs @@ -1,7 +1,7 @@ using Microsoft.Extensions.AI; using Microsoft.Extensions.Configuration; using Microsoft.Extensions.VectorData; -using Microsoft.SemanticKernel.Connectors.InMemory; +using CommunityToolkit.VectorData.InMemory; using OpenAI; using System.ClientModel; using VectorDataAI; diff --git a/docs/ai/vector-stores/snippets/chat-with-data/openai/VectorDataAI.csproj b/docs/ai/vector-stores/snippets/chat-with-data/openai/VectorDataAI.csproj index 9d1ab9069f6c2..c8fe66faf31b2 100644 --- a/docs/ai/vector-stores/snippets/chat-with-data/openai/VectorDataAI.csproj +++ b/docs/ai/vector-stores/snippets/chat-with-data/openai/VectorDataAI.csproj @@ -12,7 +12,7 @@ - + diff --git a/docs/ai/vector-stores/snippets/conceptual/VectorStoreSnippets.csproj b/docs/ai/vector-stores/snippets/conceptual/VectorStoreSnippets.csproj index fcb52214d0132..fc4da01253496 100644 --- a/docs/ai/vector-stores/snippets/conceptual/VectorStoreSnippets.csproj +++ b/docs/ai/vector-stores/snippets/conceptual/VectorStoreSnippets.csproj @@ -11,11 +11,10 @@ - - - + + + - diff --git a/docs/ai/vector-stores/snippets/conceptual/defining-your-data-model.cs b/docs/ai/vector-stores/snippets/conceptual/defining-your-data-model.cs index f1a03abf786ca..ca017fcb563b6 100644 --- a/docs/ai/vector-stores/snippets/conceptual/defining-your-data-model.cs +++ b/docs/ai/vector-stores/snippets/conceptual/defining-your-data-model.cs @@ -17,7 +17,7 @@ public class Hotel public required string Description { get; set; } // - [VectorStoreVector(Dimensions: 4, DistanceFunction = DistanceFunction.CosineSimilarity, IndexKind = IndexKind.Hnsw)] + [VectorStoreVector(dimensions: 4, DistanceFunction = DistanceFunction.CosineSimilarity, IndexKind = IndexKind.Hnsw)] public ReadOnlyMemory? DescriptionEmbedding { get; set; } // diff --git a/docs/ai/vector-stores/snippets/conceptual/dynamic-data-model.cs b/docs/ai/vector-stores/snippets/conceptual/dynamic-data-model.cs index c4c8f4fc499fd..3388dd6b5745d 100644 --- a/docs/ai/vector-stores/snippets/conceptual/dynamic-data-model.cs +++ b/docs/ai/vector-stores/snippets/conceptual/dynamic-data-model.cs @@ -1,5 +1,5 @@ using Microsoft.Extensions.VectorData; -using Microsoft.SemanticKernel.Connectors.Qdrant; +using CommunityToolkit.VectorData.Qdrant; using Qdrant.Client; public class DynamicDataModel diff --git a/docs/ai/vector-stores/snippets/how-to/Hotel.cs b/docs/ai/vector-stores/snippets/how-to/Hotel.cs index 632bffd5fe3ca..53e11824d2380 100644 --- a/docs/ai/vector-stores/snippets/how-to/Hotel.cs +++ b/docs/ai/vector-stores/snippets/how-to/Hotel.cs @@ -12,7 +12,7 @@ public record class Hotel [VectorStoreData(IsFullTextIndexed = true)] public string? Description { get; set; } - [VectorStoreVector(Dimensions: 1536, DistanceFunction = DistanceFunction.CosineSimilarity)] + [VectorStoreVector(dimensions: 1536, DistanceFunction = DistanceFunction.CosineSimilarity)] public ReadOnlyMemory? DescriptionEmbedding { get; set; } [VectorStoreData(IsIndexed = true)] diff --git a/docs/ai/vector-stores/snippets/how-to/HowToSnippets.csproj b/docs/ai/vector-stores/snippets/how-to/HowToSnippets.csproj index 96d5a548b0bb1..745167d1f4298 100644 --- a/docs/ai/vector-stores/snippets/how-to/HowToSnippets.csproj +++ b/docs/ai/vector-stores/snippets/how-to/HowToSnippets.csproj @@ -14,8 +14,8 @@ - - + + diff --git a/docs/ai/vector-stores/snippets/how-to/Program.cs b/docs/ai/vector-stores/snippets/how-to/Program.cs index 9031980080dcc..72c53333d4f84 100644 --- a/docs/ai/vector-stores/snippets/how-to/Program.cs +++ b/docs/ai/vector-stores/snippets/how-to/Program.cs @@ -1,5 +1,5 @@ using Microsoft.Extensions.VectorData; -using Microsoft.SemanticKernel.Connectors.InMemory; +using CommunityToolkit.VectorData.InMemory; // // Create an in-memory vector store (no external service required). diff --git a/docs/ai/vector-stores/snippets/how-to/PutItTogether.cs b/docs/ai/vector-stores/snippets/how-to/PutItTogether.cs index 82546657127b9..301fb77c75c0c 100644 --- a/docs/ai/vector-stores/snippets/how-to/PutItTogether.cs +++ b/docs/ai/vector-stores/snippets/how-to/PutItTogether.cs @@ -3,7 +3,7 @@ using Microsoft.Extensions.AI; using Microsoft.Extensions.DependencyInjection; using Microsoft.Extensions.VectorData; -using Microsoft.SemanticKernel.Connectors.Redis; +using CommunityToolkit.VectorData.Redis; using VectorIngest; public class PutItAllTogether diff --git a/docs/azure/includes/dotnet-all.md b/docs/azure/includes/dotnet-all.md index cf7bac980e943..574ccc41af79b 100644 --- a/docs/azure/includes/dotnet-all.md +++ b/docs/azure/includes/dotnet-all.md @@ -103,12 +103,12 @@ | Schema Registry | NuGet [1.4.0](https://www.nuget.org/packages/Azure.Data.SchemaRegistry/1.4.0) | [docs](/dotnet/api/overview/azure/Data.SchemaRegistry-readme) | GitHub [1.4.0](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Data.SchemaRegistry_1.4.0/sdk/schemaregistry/Azure.Data.SchemaRegistry/) | | Schema Registry - Avro | NuGet [1.0.1](https://www.nuget.org/packages/Microsoft.Azure.Data.SchemaRegistry.ApacheAvro/1.0.1) | [docs](/dotnet/api/overview/azure/Microsoft.Azure.Data.SchemaRegistry.ApacheAvro-readme) | GitHub [1.0.1](https://github.com/Azure/azure-sdk-for-net/tree/Microsoft.Azure.Data.SchemaRegistry.ApacheAvro_1.0.1/sdk/schemaregistry/Microsoft.Azure.Data.SchemaRegistry.ApacheAvro/) | | Service Bus | NuGet [7.20.2](https://www.nuget.org/packages/Azure.Messaging.ServiceBus/7.20.2) | [docs](/dotnet/api/overview/azure/Messaging.ServiceBus-readme) | GitHub [7.20.2](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Messaging.ServiceBus_7.20.2/sdk/servicebus/Azure.Messaging.ServiceBus/) | -| Storage - Blobs | NuGet [12.29.1](https://www.nuget.org/packages/Azure.Storage.Blobs/12.29.1) | [docs](/dotnet/api/overview/azure/Storage.Blobs-readme) | GitHub [12.29.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Blobs_12.29.1/sdk/storage/Azure.Storage.Blobs/) | +| Storage - Blobs | NuGet [12.29.1](https://www.nuget.org/packages/Azure.Storage.Blobs/12.29.1)
NuGet [12.30.0-beta.1](https://www.nuget.org/packages/Azure.Storage.Blobs/12.30.0-beta.1) | [docs](/dotnet/api/overview/azure/Storage.Blobs-readme) | GitHub [12.29.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Blobs_12.29.1/sdk/storage/Azure.Storage.Blobs/)
GitHub [12.30.0-beta.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Blobs_12.30.0-beta.1/sdk/storage/Azure.Storage.Blobs/) | | Storage - Blobs Batch | NuGet [12.26.0](https://www.nuget.org/packages/Azure.Storage.Blobs.Batch/12.26.0) | [docs](/dotnet/api/overview/azure/Storage.Blobs.Batch-readme) | GitHub [12.26.0](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Blobs.Batch_12.26.0/sdk/storage/Azure.Storage.Blobs.Batch/) | | Storage - Blobs ChangeFeed | NuGet [12.0.0-preview.63](https://www.nuget.org/packages/Azure.Storage.Blobs.ChangeFeed/12.0.0-preview.63) | [docs](/dotnet/api/overview/azure/Storage.Blobs.ChangeFeed-readme?view=azure-dotnet-preview&preserve-view=true) | GitHub [12.0.0-preview.63](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Blobs.ChangeFeed_12.0.0-preview.63/sdk/storage/Azure.Storage.Blobs.ChangeFeed/) | -| Storage - Files Data Lake | NuGet [12.27.1](https://www.nuget.org/packages/Azure.Storage.Files.DataLake/12.27.1) | [docs](/dotnet/api/overview/azure/Storage.Files.DataLake-readme) | GitHub [12.27.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Files.DataLake_12.27.1/sdk/storage/Azure.Storage.Files.DataLake/) | -| Storage - Files Share | NuGet [12.27.1](https://www.nuget.org/packages/Azure.Storage.Files.Shares/12.27.1) | [docs](/dotnet/api/overview/azure/Storage.Files.Shares-readme) | GitHub [12.27.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Files.Shares_12.27.1/sdk/storage/Azure.Storage.Files.Shares/) | -| Storage - Queues | NuGet [12.27.1](https://www.nuget.org/packages/Azure.Storage.Queues/12.27.1) | [docs](/dotnet/api/overview/azure/Storage.Queues-readme) | GitHub [12.27.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Queues_12.27.1/sdk/storage/Azure.Storage.Queues/) | +| Storage - Files Data Lake | NuGet [12.27.1](https://www.nuget.org/packages/Azure.Storage.Files.DataLake/12.27.1)
NuGet [12.28.0-beta.1](https://www.nuget.org/packages/Azure.Storage.Files.DataLake/12.28.0-beta.1) | [docs](/dotnet/api/overview/azure/Storage.Files.DataLake-readme) | GitHub [12.27.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Files.DataLake_12.27.1/sdk/storage/Azure.Storage.Files.DataLake/)
GitHub [12.28.0-beta.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Files.DataLake_12.28.0-beta.1/sdk/storage/Azure.Storage.Files.DataLake/) | +| Storage - Files Share | NuGet [12.27.1](https://www.nuget.org/packages/Azure.Storage.Files.Shares/12.27.1)
NuGet [12.28.0-beta.1](https://www.nuget.org/packages/Azure.Storage.Files.Shares/12.28.0-beta.1) | [docs](/dotnet/api/overview/azure/Storage.Files.Shares-readme) | GitHub [12.27.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Files.Shares_12.27.1/sdk/storage/Azure.Storage.Files.Shares/)
GitHub [12.28.0-beta.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Files.Shares_12.28.0-beta.1/sdk/storage/Azure.Storage.Files.Shares/) | +| Storage - Queues | NuGet [12.27.1](https://www.nuget.org/packages/Azure.Storage.Queues/12.27.1)
NuGet [12.28.0-beta.1](https://www.nuget.org/packages/Azure.Storage.Queues/12.28.0-beta.1) | [docs](/dotnet/api/overview/azure/Storage.Queues-readme) | GitHub [12.27.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Queues_12.27.1/sdk/storage/Azure.Storage.Queues/)
GitHub [12.28.0-beta.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Queues_12.28.0-beta.1/sdk/storage/Azure.Storage.Queues/) | | Synapse - AccessControl | NuGet [1.0.0-preview.5](https://www.nuget.org/packages/Azure.Analytics.Synapse.AccessControl/1.0.0-preview.5) | [docs](/dotnet/api/overview/azure/Analytics.Synapse.AccessControl-readme?view=azure-dotnet-preview&preserve-view=true) | GitHub [1.0.0-preview.5](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Analytics.Synapse.AccessControl_1.0.0-preview.5/sdk/synapse/Azure.Analytics.Synapse.AccessControl/) | | Synapse - Artifacts | NuGet [1.0.0-preview.23](https://www.nuget.org/packages/Azure.Analytics.Synapse.Artifacts/1.0.0-preview.23) | [docs](/dotnet/api/overview/azure/Analytics.Synapse.Artifacts-readme?view=azure-dotnet-preview&preserve-view=true) | GitHub [1.0.0-preview.23](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Analytics.Synapse.Artifacts_1.0.0-preview.23/sdk/synapse/Azure.Analytics.Synapse.Artifacts/) | | Synapse - Managed Private Endpoints | NuGet [1.0.0-beta.5](https://www.nuget.org/packages/Azure.Analytics.Synapse.ManagedPrivateEndpoints/1.0.0-beta.5) | [docs](/dotnet/api/overview/azure/Analytics.Synapse.ManagedPrivateEndpoints-readme?view=azure-dotnet-preview&preserve-view=true) | GitHub [1.0.0-beta.5](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Analytics.Synapse.ManagedPrivateEndpoints_1.0.0-beta.5/sdk/synapse/Azure.Analytics.Synapse.ManagedPrivateEndpoints/) | @@ -140,7 +140,7 @@ | Functions extension for Azure Tables | NuGet [1.4.0](https://www.nuget.org/packages/Microsoft.Azure.WebJobs.Extensions.Tables/1.4.0) | [docs](/dotnet/api/overview/azure/Microsoft.Azure.WebJobs.Extensions.Tables-readme) | GitHub [1.4.0](https://github.com/Azure/azure-sdk-for-net/tree/Microsoft.Azure.WebJobs.Extensions.Tables_1.4.0/sdk/tables/Microsoft.Azure.WebJobs.Extensions.Tables/) | | Key Encryptor for .NET Data Protection | NuGet [1.6.3](https://www.nuget.org/packages/Azure.Extensions.AspNetCore.DataProtection.Keys/1.6.3) | [docs](/dotnet/api/overview/azure/Extensions.AspNetCore.DataProtection.Keys-readme) | GitHub [1.6.3](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Extensions.AspNetCore.DataProtection.Keys_1.6.3/sdk/extensions/Azure.Extensions.AspNetCore.DataProtection.Keys/) | | Secrets Configuration Provider for .NET | NuGet [1.5.1](https://www.nuget.org/packages/Azure.Extensions.AspNetCore.Configuration.Secrets/1.5.1) | [docs](/dotnet/api/overview/azure/Extensions.AspNetCore.Configuration.Secrets-readme) | GitHub [1.5.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Extensions.AspNetCore.Configuration.Secrets_1.5.1/sdk/extensions/Azure.Extensions.AspNetCore.Configuration.Secrets/) | -| Storage - Common | NuGet [12.28.0](https://www.nuget.org/packages/Azure.Storage.Common/12.28.0) | [docs](/dotnet/api/overview/azure/Storage.Common-readme) | GitHub [12.28.0](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Common_12.28.0/sdk/storage/Azure.Storage.Common/) | +| Storage - Common | NuGet [12.28.0](https://www.nuget.org/packages/Azure.Storage.Common/12.28.0)
NuGet [12.29.0-beta.1](https://www.nuget.org/packages/Azure.Storage.Common/12.29.0-beta.1) | [docs](/dotnet/api/overview/azure/Storage.Common-readme) | GitHub [12.28.0](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Common_12.28.0/sdk/storage/Azure.Storage.Common/)
GitHub [12.29.0-beta.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Common_12.29.0-beta.1/sdk/storage/Azure.Storage.Common/) | | WebJobs Extensions - Event Grid | NuGet [3.5.0](https://www.nuget.org/packages/Microsoft.Azure.WebJobs.Extensions.EventGrid/3.5.0) | [docs](/dotnet/api/overview/azure/Microsoft.Azure.WebJobs.Extensions.EventGrid-readme) | GitHub [3.5.0](https://github.com/Azure/azure-sdk-for-net/tree/Microsoft.Azure.WebJobs.Extensions.EventGrid_3.5.0/sdk/eventgrid/Microsoft.Azure.WebJobs.Extensions.EventGrid/) | | WebJobs Extensions - Event Hubs | NuGet [6.5.3](https://www.nuget.org/packages/Microsoft.Azure.WebJobs.Extensions.EventHubs/6.5.3) | [docs](/dotnet/api/overview/azure/Microsoft.Azure.WebJobs.Extensions.EventHubs-readme) | GitHub [6.5.3](https://github.com/Azure/azure-sdk-for-net/tree/Microsoft.Azure.WebJobs.Extensions.EventHubs_6.5.3/sdk/eventhub/Microsoft.Azure.WebJobs.Extensions.EventHubs/) | | WebJobs Extensions - Service Bus | NuGet [5.17.0](https://www.nuget.org/packages/Microsoft.Azure.WebJobs.Extensions.ServiceBus/5.17.0) | [docs](/dotnet/api/overview/azure/Microsoft.Azure.WebJobs.Extensions.ServiceBus-readme) | GitHub [5.17.0](https://github.com/Azure/azure-sdk-for-net/tree/Microsoft.Azure.WebJobs.Extensions.ServiceBus_5.17.0/sdk/servicebus/Microsoft.Azure.WebJobs.Extensions.ServiceBus/) | @@ -206,7 +206,7 @@ | Resource Management - API Center | NuGet [1.0.0](https://www.nuget.org/packages/Azure.ResourceManager.ApiCenter/1.0.0)
NuGet [1.1.0-beta.1](https://www.nuget.org/packages/Azure.ResourceManager.ApiCenter/1.1.0-beta.1) | [docs](/dotnet/api/overview/azure/ResourceManager.ApiCenter-readme) | GitHub [1.0.0](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.ApiCenter_1.0.0/sdk/apicenter/Azure.ResourceManager.ApiCenter/)
GitHub [1.1.0-beta.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.ApiCenter_1.1.0-beta.1/sdk/apicenter/Azure.ResourceManager.ApiCenter/) | | Resource Management - API Management | NuGet [1.3.1](https://www.nuget.org/packages/Azure.ResourceManager.ApiManagement/1.3.1) | [docs](/dotnet/api/overview/azure/ResourceManager.ApiManagement-readme) | GitHub [1.3.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.ApiManagement_1.3.1/sdk/apimanagement/Azure.ResourceManager.ApiManagement/) | | Resource Management - App Compliance Automation | NuGet [1.0.2](https://www.nuget.org/packages/Azure.ResourceManager.AppComplianceAutomation/1.0.2) | [docs](/dotnet/api/overview/azure/ResourceManager.AppComplianceAutomation-readme) | GitHub [1.0.2](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.AppComplianceAutomation_1.0.2/sdk/appcomplianceautomation/Azure.ResourceManager.AppComplianceAutomation/) | -| Resource Management - App Configuration | NuGet [1.4.1](https://www.nuget.org/packages/Azure.ResourceManager.AppConfiguration/1.4.1)
NuGet [1.5.0-beta.1](https://www.nuget.org/packages/Azure.ResourceManager.AppConfiguration/1.5.0-beta.1) | [docs](/dotnet/api/overview/azure/ResourceManager.AppConfiguration-readme) | GitHub [1.4.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.AppConfiguration_1.4.1/sdk/appconfiguration/Azure.ResourceManager.AppConfiguration/)
GitHub [1.5.0-beta.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.AppConfiguration_1.5.0-beta.1/sdk/appconfiguration/Azure.ResourceManager.AppConfiguration/) | +| Resource Management - App Configuration | NuGet [1.4.1](https://www.nuget.org/packages/Azure.ResourceManager.AppConfiguration/1.4.1)
NuGet [1.5.0-beta.2](https://www.nuget.org/packages/Azure.ResourceManager.AppConfiguration/1.5.0-beta.2) | [docs](/dotnet/api/overview/azure/ResourceManager.AppConfiguration-readme) | GitHub [1.4.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.AppConfiguration_1.4.1/sdk/appconfiguration/Azure.ResourceManager.AppConfiguration/)
GitHub [1.5.0-beta.2](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.AppConfiguration_1.5.0-beta.2/sdk/appconfiguration/Azure.ResourceManager.AppConfiguration/) | | Resource Management - App Service | NuGet [1.5.0](https://www.nuget.org/packages/Azure.ResourceManager.AppService/1.5.0) | [docs](/dotnet/api/overview/azure/ResourceManager.AppService-readme) | GitHub [1.5.0](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.AppService_1.5.0/sdk/websites/Azure.ResourceManager.AppService/) | | Resource Management - Application Insights | NuGet [1.1.0](https://www.nuget.org/packages/Azure.ResourceManager.ApplicationInsights/1.1.0) | [docs](/dotnet/api/overview/azure/ResourceManager.ApplicationInsights-readme) | GitHub [1.1.0](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.ApplicationInsights_1.1.0/sdk/applicationinsights/Azure.ResourceManager.ApplicationInsights/) | | Resource Management - Appnetwork | NuGet [1.0.0-beta.1](https://www.nuget.org/packages/Azure.ResourceManager.AppNetwork/1.0.0-beta.1) | [docs](/dotnet/api/overview/azure/ResourceManager.AppNetwork-readme?view=azure-dotnet-preview&preserve-view=true) | GitHub [1.0.0-beta.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.AppNetwork_1.0.0-beta.1/sdk/appnetwork/Azure.ResourceManager.AppNetwork/) | @@ -493,12 +493,12 @@ | Microsoft.Azure.DataFactoryTestingFramework.Expressions | NuGet [0.2.7](https://www.nuget.org/packages/Microsoft.Azure.DataFactoryTestingFramework.Expressions/0.2.7) | | | | Microsoft.Azure.Functions.Worker.OpenTelemetry | NuGet [1.2.0](https://www.nuget.org/packages/Microsoft.Azure.Functions.Worker.OpenTelemetry/1.2.0) | | | | OpenTelemetry Profiler | NuGet [1.0.1-beta.7](https://www.nuget.org/packages/Azure.Monitor.OpenTelemetry.Profiler/1.0.1-beta.7) | | | -| Speech CLI | NuGet [1.50.0](https://www.nuget.org/packages/Microsoft.CognitiveServices.Speech.CLI/1.50.0) | | | -| Speech Extension Embedded SR | NuGet [1.50.0](https://www.nuget.org/packages/Microsoft.CognitiveServices.Speech.Extension.Embedded.SR/1.50.0) | | | -| Speech Extension Embedded TTS | NuGet [1.50.0](https://www.nuget.org/packages/Microsoft.CognitiveServices.Speech.Extension.Embedded.TTS/1.50.0) | | | -| Speech Extension MAS | NuGet [1.50.0](https://www.nuget.org/packages/Microsoft.CognitiveServices.Speech.Extension.MAS/1.50.0) | | | -| Speech Extension ONNX Runtime | NuGet [1.50.0](https://www.nuget.org/packages/Microsoft.CognitiveServices.Speech.Extension.ONNX.Runtime/1.50.0) | | | -| Speech Extension Telemetry | NuGet [1.50.0](https://www.nuget.org/packages/Microsoft.CognitiveServices.Speech.Extension.Telemetry/1.50.0) | | | +| Speech CLI | NuGet [1.51.0](https://www.nuget.org/packages/Microsoft.CognitiveServices.Speech.CLI/1.51.0) | | | +| Speech Extension Embedded SR | NuGet [1.51.0](https://www.nuget.org/packages/Microsoft.CognitiveServices.Speech.Extension.Embedded.SR/1.51.0) | | | +| Speech Extension Embedded TTS | NuGet [1.51.0](https://www.nuget.org/packages/Microsoft.CognitiveServices.Speech.Extension.Embedded.TTS/1.51.0) | | | +| Speech Extension MAS | NuGet [1.51.0](https://www.nuget.org/packages/Microsoft.CognitiveServices.Speech.Extension.MAS/1.51.0) | | | +| Speech Extension ONNX Runtime | NuGet [1.51.0](https://www.nuget.org/packages/Microsoft.CognitiveServices.Speech.Extension.ONNX.Runtime/1.51.0) | | | +| Speech Extension Telemetry | NuGet [1.51.0](https://www.nuget.org/packages/Microsoft.CognitiveServices.Speech.Extension.Telemetry/1.51.0) | | | | System Net Client Model | NuGet [1.0.0-beta.1](https://www.nuget.org/packages/System.Net.ClientModel/1.0.0-beta.1) | | | | Unknown Display Name | NuGet [5.0.0-preview.1](https://www.nuget.org/packages/Azure.Functions.Cli.Abstractions/5.0.0-preview.1) | | | | Unknown Display Name | NuGet [1.0.0-preview.1](https://www.nuget.org/packages/Azure.Functions.Cli.Workloads.DotNet/1.0.0-preview.1) | | | @@ -590,8 +590,8 @@ | Search - Common | NuGet [10.1.0](https://www.nuget.org/packages/Microsoft.Azure.Search.Common/10.1.0) | | GitHub [10.1.0](https://github.com/Azure/azure-sdk-for-net/tree/Microsoft.Azure.Search.Common_10.1.0/sdk/search/Microsoft.Azure.Search.Common/) | | Search - Data | NuGet [10.1.0](https://www.nuget.org/packages/Microsoft.Azure.Search.Data/10.1.0) | | GitHub [10.1.0](https://github.com/Azure/azure-sdk-for-net/tree/Microsoft.Azure.Search.Data_10.1.0/sdk/search/Microsoft.Azure.Search.Data/) | | Search - Service | NuGet [10.1.0](https://www.nuget.org/packages/Microsoft.Azure.Search.Service/10.1.0) | | GitHub [10.1.0](https://github.com/Azure/azure-sdk-for-net/tree/Microsoft.Azure.Search.Service_10.1.0/sdk/search/Microsoft.Azure.Search.Service/) | -| Speech | NuGet [1.50.0](https://www.nuget.org/packages/Microsoft.CognitiveServices.Speech/1.50.0)
NuGet [1.47.0-beta.0.357883](https://www.nuget.org/packages/Microsoft.CognitiveServices.Speech/1.47.0-beta.0.357883) | | | -| Speech Remote Conversation | NuGet [1.50.0](https://www.nuget.org/packages/Microsoft.CognitiveServices.Speech.Remoteconversation/1.50.0) | | | +| Speech | NuGet [1.51.0](https://www.nuget.org/packages/Microsoft.CognitiveServices.Speech/1.51.0)
NuGet [1.47.0-beta.0.357883](https://www.nuget.org/packages/Microsoft.CognitiveServices.Speech/1.47.0-beta.0.357883) | | | +| Speech Remote Conversation | NuGet [1.51.0](https://www.nuget.org/packages/Microsoft.CognitiveServices.Speech.Remoteconversation/1.51.0) | | | | Speech Xamarin iOS | NuGet [1.25.0](https://www.nuget.org/packages/Microsoft.CognitiveServices.Speech.Xamarin.iOS/1.25.0) | | | | Spell Check | NuGet [4.1.0-preview.1](https://www.nuget.org/packages/Microsoft.Azure.CognitiveServices.Language.SpellCheck/4.1.0-preview.1) | | GitHub [4.1.0-preview.1](https://github.com/Azure/azure-sdk-for-net/tree/Microsoft.Azure.CognitiveServices.Language.SpellCheck_4.1.0-preview.1/sdk/cognitiveservices/Language.SpellCheck) | | Spring Cloud Client | NuGet [2.0.0-preview.3](https://www.nuget.org/packages/Microsoft.Azure.SpringCloud.Client/2.0.0-preview.3) | | | diff --git a/docs/azure/includes/dotnet-new.md b/docs/azure/includes/dotnet-new.md index 6ea7a9cad4d85..87920bb47ce97 100644 --- a/docs/azure/includes/dotnet-new.md +++ b/docs/azure/includes/dotnet-new.md @@ -115,12 +115,12 @@ | Schema Registry | NuGet [1.4.0](https://www.nuget.org/packages/Azure.Data.SchemaRegistry/1.4.0) | [docs](/dotnet/api/overview/azure/Data.SchemaRegistry-readme) | GitHub [1.4.0](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Data.SchemaRegistry_1.4.0/sdk/schemaregistry/Azure.Data.SchemaRegistry/) | | Schema Registry - Avro | NuGet [1.0.1](https://www.nuget.org/packages/Microsoft.Azure.Data.SchemaRegistry.ApacheAvro/1.0.1) | [docs](/dotnet/api/overview/azure/Microsoft.Azure.Data.SchemaRegistry.ApacheAvro-readme) | GitHub [1.0.1](https://github.com/Azure/azure-sdk-for-net/tree/Microsoft.Azure.Data.SchemaRegistry.ApacheAvro_1.0.1/sdk/schemaregistry/Microsoft.Azure.Data.SchemaRegistry.ApacheAvro/) | | Service Bus | NuGet [7.20.2](https://www.nuget.org/packages/Azure.Messaging.ServiceBus/7.20.2) | [docs](/dotnet/api/overview/azure/Messaging.ServiceBus-readme) | GitHub [7.20.2](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Messaging.ServiceBus_7.20.2/sdk/servicebus/Azure.Messaging.ServiceBus/) | -| Storage - Blobs | NuGet [12.29.1](https://www.nuget.org/packages/Azure.Storage.Blobs/12.29.1) | [docs](/dotnet/api/overview/azure/Storage.Blobs-readme) | GitHub [12.29.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Blobs_12.29.1/sdk/storage/Azure.Storage.Blobs/) | +| Storage - Blobs | NuGet [12.29.1](https://www.nuget.org/packages/Azure.Storage.Blobs/12.29.1)
NuGet [12.30.0-beta.1](https://www.nuget.org/packages/Azure.Storage.Blobs/12.30.0-beta.1) | [docs](/dotnet/api/overview/azure/Storage.Blobs-readme) | GitHub [12.29.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Blobs_12.29.1/sdk/storage/Azure.Storage.Blobs/)
GitHub [12.30.0-beta.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Blobs_12.30.0-beta.1/sdk/storage/Azure.Storage.Blobs/) | | Storage - Blobs Batch | NuGet [12.26.0](https://www.nuget.org/packages/Azure.Storage.Blobs.Batch/12.26.0) | [docs](/dotnet/api/overview/azure/Storage.Blobs.Batch-readme) | GitHub [12.26.0](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Blobs.Batch_12.26.0/sdk/storage/Azure.Storage.Blobs.Batch/) | | Storage - Blobs ChangeFeed | NuGet [12.0.0-preview.63](https://www.nuget.org/packages/Azure.Storage.Blobs.ChangeFeed/12.0.0-preview.63) | [docs](/dotnet/api/overview/azure/Storage.Blobs.ChangeFeed-readme?view=azure-dotnet-preview&preserve-view=true) | GitHub [12.0.0-preview.63](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Blobs.ChangeFeed_12.0.0-preview.63/sdk/storage/Azure.Storage.Blobs.ChangeFeed/) | -| Storage - Files Data Lake | NuGet [12.27.1](https://www.nuget.org/packages/Azure.Storage.Files.DataLake/12.27.1) | [docs](/dotnet/api/overview/azure/Storage.Files.DataLake-readme) | GitHub [12.27.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Files.DataLake_12.27.1/sdk/storage/Azure.Storage.Files.DataLake/) | -| Storage - Files Share | NuGet [12.27.1](https://www.nuget.org/packages/Azure.Storage.Files.Shares/12.27.1) | [docs](/dotnet/api/overview/azure/Storage.Files.Shares-readme) | GitHub [12.27.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Files.Shares_12.27.1/sdk/storage/Azure.Storage.Files.Shares/) | -| Storage - Queues | NuGet [12.27.1](https://www.nuget.org/packages/Azure.Storage.Queues/12.27.1) | [docs](/dotnet/api/overview/azure/Storage.Queues-readme) | GitHub [12.27.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Queues_12.27.1/sdk/storage/Azure.Storage.Queues/) | +| Storage - Files Data Lake | NuGet [12.27.1](https://www.nuget.org/packages/Azure.Storage.Files.DataLake/12.27.1)
NuGet [12.28.0-beta.1](https://www.nuget.org/packages/Azure.Storage.Files.DataLake/12.28.0-beta.1) | [docs](/dotnet/api/overview/azure/Storage.Files.DataLake-readme) | GitHub [12.27.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Files.DataLake_12.27.1/sdk/storage/Azure.Storage.Files.DataLake/)
GitHub [12.28.0-beta.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Files.DataLake_12.28.0-beta.1/sdk/storage/Azure.Storage.Files.DataLake/) | +| Storage - Files Share | NuGet [12.27.1](https://www.nuget.org/packages/Azure.Storage.Files.Shares/12.27.1)
NuGet [12.28.0-beta.1](https://www.nuget.org/packages/Azure.Storage.Files.Shares/12.28.0-beta.1) | [docs](/dotnet/api/overview/azure/Storage.Files.Shares-readme) | GitHub [12.27.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Files.Shares_12.27.1/sdk/storage/Azure.Storage.Files.Shares/)
GitHub [12.28.0-beta.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Files.Shares_12.28.0-beta.1/sdk/storage/Azure.Storage.Files.Shares/) | +| Storage - Queues | NuGet [12.27.1](https://www.nuget.org/packages/Azure.Storage.Queues/12.27.1)
NuGet [12.28.0-beta.1](https://www.nuget.org/packages/Azure.Storage.Queues/12.28.0-beta.1) | [docs](/dotnet/api/overview/azure/Storage.Queues-readme) | GitHub [12.27.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Queues_12.27.1/sdk/storage/Azure.Storage.Queues/)
GitHub [12.28.0-beta.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Queues_12.28.0-beta.1/sdk/storage/Azure.Storage.Queues/) | | Synapse - AccessControl | NuGet [1.0.0-preview.5](https://www.nuget.org/packages/Azure.Analytics.Synapse.AccessControl/1.0.0-preview.5) | [docs](/dotnet/api/overview/azure/Analytics.Synapse.AccessControl-readme?view=azure-dotnet-preview&preserve-view=true) | GitHub [1.0.0-preview.5](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Analytics.Synapse.AccessControl_1.0.0-preview.5/sdk/synapse/Azure.Analytics.Synapse.AccessControl/) | | Synapse - Artifacts | NuGet [1.0.0-preview.23](https://www.nuget.org/packages/Azure.Analytics.Synapse.Artifacts/1.0.0-preview.23) | [docs](/dotnet/api/overview/azure/Analytics.Synapse.Artifacts-readme?view=azure-dotnet-preview&preserve-view=true) | GitHub [1.0.0-preview.23](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Analytics.Synapse.Artifacts_1.0.0-preview.23/sdk/synapse/Azure.Analytics.Synapse.Artifacts/) | | Synapse - Managed Private Endpoints | NuGet [1.0.0-beta.5](https://www.nuget.org/packages/Azure.Analytics.Synapse.ManagedPrivateEndpoints/1.0.0-beta.5) | [docs](/dotnet/api/overview/azure/Analytics.Synapse.ManagedPrivateEndpoints-readme?view=azure-dotnet-preview&preserve-view=true) | GitHub [1.0.0-beta.5](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Analytics.Synapse.ManagedPrivateEndpoints_1.0.0-beta.5/sdk/synapse/Azure.Analytics.Synapse.ManagedPrivateEndpoints/) | @@ -153,7 +153,7 @@ | Functions extension for Azure Tables | NuGet [1.4.0](https://www.nuget.org/packages/Microsoft.Azure.WebJobs.Extensions.Tables/1.4.0) | [docs](/dotnet/api/overview/azure/Microsoft.Azure.WebJobs.Extensions.Tables-readme) | GitHub [1.4.0](https://github.com/Azure/azure-sdk-for-net/tree/Microsoft.Azure.WebJobs.Extensions.Tables_1.4.0/sdk/tables/Microsoft.Azure.WebJobs.Extensions.Tables/) | | Key Encryptor for .NET Data Protection | NuGet [1.6.3](https://www.nuget.org/packages/Azure.Extensions.AspNetCore.DataProtection.Keys/1.6.3) | [docs](/dotnet/api/overview/azure/Extensions.AspNetCore.DataProtection.Keys-readme) | GitHub [1.6.3](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Extensions.AspNetCore.DataProtection.Keys_1.6.3/sdk/extensions/Azure.Extensions.AspNetCore.DataProtection.Keys/) | | Secrets Configuration Provider for .NET | NuGet [1.5.1](https://www.nuget.org/packages/Azure.Extensions.AspNetCore.Configuration.Secrets/1.5.1) | [docs](/dotnet/api/overview/azure/Extensions.AspNetCore.Configuration.Secrets-readme) | GitHub [1.5.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Extensions.AspNetCore.Configuration.Secrets_1.5.1/sdk/extensions/Azure.Extensions.AspNetCore.Configuration.Secrets/) | -| Storage - Common | NuGet [12.28.0](https://www.nuget.org/packages/Azure.Storage.Common/12.28.0) | [docs](/dotnet/api/overview/azure/Storage.Common-readme) | GitHub [12.28.0](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Common_12.28.0/sdk/storage/Azure.Storage.Common/) | +| Storage - Common | NuGet [12.28.0](https://www.nuget.org/packages/Azure.Storage.Common/12.28.0)
NuGet [12.29.0-beta.1](https://www.nuget.org/packages/Azure.Storage.Common/12.29.0-beta.1) | [docs](/dotnet/api/overview/azure/Storage.Common-readme) | GitHub [12.28.0](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Common_12.28.0/sdk/storage/Azure.Storage.Common/)
GitHub [12.29.0-beta.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.Storage.Common_12.29.0-beta.1/sdk/storage/Azure.Storage.Common/) | | WebJobs Extensions - Event Grid | NuGet [3.5.0](https://www.nuget.org/packages/Microsoft.Azure.WebJobs.Extensions.EventGrid/3.5.0) | [docs](/dotnet/api/overview/azure/Microsoft.Azure.WebJobs.Extensions.EventGrid-readme) | GitHub [3.5.0](https://github.com/Azure/azure-sdk-for-net/tree/Microsoft.Azure.WebJobs.Extensions.EventGrid_3.5.0/sdk/eventgrid/Microsoft.Azure.WebJobs.Extensions.EventGrid/) | | WebJobs Extensions - Event Hubs | NuGet [6.5.3](https://www.nuget.org/packages/Microsoft.Azure.WebJobs.Extensions.EventHubs/6.5.3) | [docs](/dotnet/api/overview/azure/Microsoft.Azure.WebJobs.Extensions.EventHubs-readme) | GitHub [6.5.3](https://github.com/Azure/azure-sdk-for-net/tree/Microsoft.Azure.WebJobs.Extensions.EventHubs_6.5.3/sdk/eventhub/Microsoft.Azure.WebJobs.Extensions.EventHubs/) | | WebJobs Extensions - Service Bus | NuGet [5.17.0](https://www.nuget.org/packages/Microsoft.Azure.WebJobs.Extensions.ServiceBus/5.17.0) | [docs](/dotnet/api/overview/azure/Microsoft.Azure.WebJobs.Extensions.ServiceBus-readme) | GitHub [5.17.0](https://github.com/Azure/azure-sdk-for-net/tree/Microsoft.Azure.WebJobs.Extensions.ServiceBus_5.17.0/sdk/servicebus/Microsoft.Azure.WebJobs.Extensions.ServiceBus/) | @@ -219,7 +219,7 @@ | Resource Management - API Center | NuGet [1.0.0](https://www.nuget.org/packages/Azure.ResourceManager.ApiCenter/1.0.0)
NuGet [1.1.0-beta.1](https://www.nuget.org/packages/Azure.ResourceManager.ApiCenter/1.1.0-beta.1) | [docs](/dotnet/api/overview/azure/ResourceManager.ApiCenter-readme) | GitHub [1.0.0](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.ApiCenter_1.0.0/sdk/apicenter/Azure.ResourceManager.ApiCenter/)
GitHub [1.1.0-beta.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.ApiCenter_1.1.0-beta.1/sdk/apicenter/Azure.ResourceManager.ApiCenter/) | | Resource Management - API Management | NuGet [1.3.1](https://www.nuget.org/packages/Azure.ResourceManager.ApiManagement/1.3.1) | [docs](/dotnet/api/overview/azure/ResourceManager.ApiManagement-readme) | GitHub [1.3.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.ApiManagement_1.3.1/sdk/apimanagement/Azure.ResourceManager.ApiManagement/) | | Resource Management - App Compliance Automation | NuGet [1.0.2](https://www.nuget.org/packages/Azure.ResourceManager.AppComplianceAutomation/1.0.2) | [docs](/dotnet/api/overview/azure/ResourceManager.AppComplianceAutomation-readme) | GitHub [1.0.2](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.AppComplianceAutomation_1.0.2/sdk/appcomplianceautomation/Azure.ResourceManager.AppComplianceAutomation/) | -| Resource Management - App Configuration | NuGet [1.4.1](https://www.nuget.org/packages/Azure.ResourceManager.AppConfiguration/1.4.1)
NuGet [1.5.0-beta.1](https://www.nuget.org/packages/Azure.ResourceManager.AppConfiguration/1.5.0-beta.1) | [docs](/dotnet/api/overview/azure/ResourceManager.AppConfiguration-readme) | GitHub [1.4.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.AppConfiguration_1.4.1/sdk/appconfiguration/Azure.ResourceManager.AppConfiguration/)
GitHub [1.5.0-beta.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.AppConfiguration_1.5.0-beta.1/sdk/appconfiguration/Azure.ResourceManager.AppConfiguration/) | +| Resource Management - App Configuration | NuGet [1.4.1](https://www.nuget.org/packages/Azure.ResourceManager.AppConfiguration/1.4.1)
NuGet [1.5.0-beta.2](https://www.nuget.org/packages/Azure.ResourceManager.AppConfiguration/1.5.0-beta.2) | [docs](/dotnet/api/overview/azure/ResourceManager.AppConfiguration-readme) | GitHub [1.4.1](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.AppConfiguration_1.4.1/sdk/appconfiguration/Azure.ResourceManager.AppConfiguration/)
GitHub [1.5.0-beta.2](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.AppConfiguration_1.5.0-beta.2/sdk/appconfiguration/Azure.ResourceManager.AppConfiguration/) | | Resource Management - App Platform | NuGet [1.1.2](https://www.nuget.org/packages/Azure.ResourceManager.AppPlatform/1.1.2) | [docs](/dotnet/api/overview/azure/ResourceManager.AppPlatform-readme) | GitHub [1.1.2](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.AppPlatform_1.1.2/sdk/appplatform/Azure.ResourceManager.AppPlatform/) | | Resource Management - App Service | NuGet [1.5.0](https://www.nuget.org/packages/Azure.ResourceManager.AppService/1.5.0) | [docs](/dotnet/api/overview/azure/ResourceManager.AppService-readme) | GitHub [1.5.0](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.AppService_1.5.0/sdk/websites/Azure.ResourceManager.AppService/) | | Resource Management - Application Insights | NuGet [1.1.0](https://www.nuget.org/packages/Azure.ResourceManager.ApplicationInsights/1.1.0) | [docs](/dotnet/api/overview/azure/ResourceManager.ApplicationInsights-readme) | GitHub [1.1.0](https://github.com/Azure/azure-sdk-for-net/tree/Azure.ResourceManager.ApplicationInsights_1.1.0/sdk/applicationinsights/Azure.ResourceManager.ApplicationInsights/) | diff --git a/docs/azure/sdk/snippets/aspnetcore-guidance/MinApiSample/MinApiSample.csproj b/docs/azure/sdk/snippets/aspnetcore-guidance/MinApiSample/MinApiSample.csproj index 55eb8cde9b0ff..362d4106b1f07 100644 --- a/docs/azure/sdk/snippets/aspnetcore-guidance/MinApiSample/MinApiSample.csproj +++ b/docs/azure/sdk/snippets/aspnetcore-guidance/MinApiSample/MinApiSample.csproj @@ -7,8 +7,8 @@ - - + + diff --git a/docs/azure/sdk/snippets/unit-testing/UnitTestingSampleApp.csproj b/docs/azure/sdk/snippets/unit-testing/UnitTestingSampleApp.csproj index ae2dd019f5061..2a4762046e5dc 100644 --- a/docs/azure/sdk/snippets/unit-testing/UnitTestingSampleApp.csproj +++ b/docs/azure/sdk/snippets/unit-testing/UnitTestingSampleApp.csproj @@ -12,9 +12,9 @@ - + - + runtime; build; native; contentfiles; analyzers; buildtransitive diff --git a/docs/core/compatibility/11.md b/docs/core/compatibility/11.md index 7450fa0d83314..369f0af6dd2a0 100644 --- a/docs/core/compatibility/11.md +++ b/docs/core/compatibility/11.md @@ -98,5 +98,6 @@ See [Breaking changes in EF Core 11](/ef/core/what-is-new/ef-core-11.0/breaking- | [dnx scripts bypass global.json SDK selection](sdk/11/dnx-scripts-bypass-global-json.md) | Behavioral change | | [mono launch target not set for .NET Framework apps](sdk/11/mono-launch-target-removed.md) | Behavioral change | | [NU1703 warns for packages that use deprecated MonoAndroid framework assets](sdk/11/nu1703-deprecated-monoandroid-framework.md) | Source incompatible | +| [NuGet pack warns for package IDs with restricted characters](sdk/11/nuget-pack-nu5052-packageid.md) | Behavioral change | | [Template engine packages no longer support netstandard2.0](sdk/11/template-engine-netstandard.md) | Binary/source incompatible | | [VSTest removes dependency on Newtonsoft.Json](sdk/11/vstest-removes-newtonsoft-json.md) | Binary/source incompatible | diff --git a/docs/core/compatibility/sdk/11/nuget-pack-nu5052-packageid.md b/docs/core/compatibility/sdk/11/nuget-pack-nu5052-packageid.md new file mode 100644 index 0000000000000..04184765851d6 --- /dev/null +++ b/docs/core/compatibility/sdk/11/nuget-pack-nu5052-packageid.md @@ -0,0 +1,50 @@ +--- +title: "Breaking change: NuGet pack warns for package IDs with restricted characters" +description: "Learn about the breaking change in .NET 11 where NuGet's pack command emits warning NU5052 for package IDs that use characters outside the restricted set." +ms.date: 07/22/2026 +ai-usage: ai-assisted +--- + +# NuGet pack warns for package IDs with restricted characters + +Starting in .NET 11, `dotnet pack` emits warning **NU5052** when a package ID contains characters outside the restricted character set enforced by nuget.org. + +## Version introduced + +.NET 11 Preview 6 + +## Previous behavior + +Previously, `dotnet pack` produced a package for any package ID that the legacy NuGet ID rules accepted, including IDs with characters outside ASCII letters, digits, dots, and dashes, or with consecutive `.` or `-` characters. + +## New behavior + +Starting in .NET 11 (with `SdkAnalysisLevel >= 11.0.100`), packing a project whose `PackageId` doesn't meet the restricted rules emits warning **NU5052**. A valid package ID: + +- Must start with a letter, digit, or underscore (`_`). +- Can contain only ASCII letters, digits, dots (`.`), dashes (`-`), and underscores (`_`). +- Can't contain consecutive `.` or `-` characters. +- Must be 100 characters or fewer. + +## Type of breaking change + +This change is a [behavioral change](../../categories.md#behavioral-change). + +## Reason for change + +NuGet derives strings such as URLs and file-system paths from a normalized version of the package ID. Normalization relies on built-in string libraries that are inconsistent across .NET Framework, modern .NET, Windows, and Linux, so two visibly different IDs can normalize to the same string. Restricting the allowed character set, as npm, PyPI, and other registries have done, closes this security and branding gap. + +For more information, see the [NuGet announcement](https://github.com/NuGet/Announcements/issues/75). + +## Recommended action + +Rename the package to an ID within the restricted character set—for example, transliterate non-ASCII characters to their ASCII equivalents (`Müller.Logging` becomes `Mueller.Logging`). Then deprecate the old package ID and point it at the new one. + +Because this warning doesn't block the build, you can also suppress it: + +- Add `NU5052` to the project file. +- Set `SdkAnalysisLevel` to a version below `11.0.100`. + +## Affected APIs + +None. diff --git a/docs/core/compatibility/toc.yml b/docs/core/compatibility/toc.yml index 6117c83450f24..438745e3a1f56 100644 --- a/docs/core/compatibility/toc.yml +++ b/docs/core/compatibility/toc.yml @@ -78,6 +78,8 @@ items: href: sdk/11/mono-launch-target-removed.md - name: NU1703 warns for packages that use deprecated MonoAndroid framework assets href: sdk/11/nu1703-deprecated-monoandroid-framework.md + - name: NuGet pack warns for package IDs with restricted characters + href: sdk/11/nuget-pack-nu5052-packageid.md - name: Template engine packages no longer support netstandard2.0 href: sdk/11/template-engine-netstandard.md - name: VSTest removes dependency on Newtonsoft.Json diff --git a/docs/core/diagnostics/ambient-metadata/snippets/buildmetadata/buildmetadata.csproj b/docs/core/diagnostics/ambient-metadata/snippets/buildmetadata/buildmetadata.csproj index 86d6c60bae071..021a6b849f1ad 100644 --- a/docs/core/diagnostics/ambient-metadata/snippets/buildmetadata/buildmetadata.csproj +++ b/docs/core/diagnostics/ambient-metadata/snippets/buildmetadata/buildmetadata.csproj @@ -8,9 +8,9 @@ - - - + + + diff --git a/docs/core/diagnostics/snippets/Metrics/metric-instr.csproj b/docs/core/diagnostics/snippets/Metrics/metric-instr.csproj index c7ba5f6123157..66df7dcf52103 100644 --- a/docs/core/diagnostics/snippets/Metrics/metric-instr.csproj +++ b/docs/core/diagnostics/snippets/Metrics/metric-instr.csproj @@ -9,7 +9,7 @@ - + diff --git a/docs/core/diagnostics/snippets/MetricsGen/MetricsGen.csproj b/docs/core/diagnostics/snippets/MetricsGen/MetricsGen.csproj index 34b3774bd08dd..d8b53abf14c44 100644 --- a/docs/core/diagnostics/snippets/MetricsGen/MetricsGen.csproj +++ b/docs/core/diagnostics/snippets/MetricsGen/MetricsGen.csproj @@ -8,7 +8,7 @@ - + diff --git a/docs/core/diagnostics/snippets/exception-summary/exception-summary.csproj b/docs/core/diagnostics/snippets/exception-summary/exception-summary.csproj index 9ffe8ffcd8d13..c00a631e07d4e 100644 --- a/docs/core/diagnostics/snippets/exception-summary/exception-summary.csproj +++ b/docs/core/diagnostics/snippets/exception-summary/exception-summary.csproj @@ -8,8 +8,8 @@ - - + + diff --git a/docs/core/diagnostics/snippets/health-checks/health-checks.csproj b/docs/core/diagnostics/snippets/health-checks/health-checks.csproj index cbf71f5887cbe..01d6e2763dca8 100644 --- a/docs/core/diagnostics/snippets/health-checks/health-checks.csproj +++ b/docs/core/diagnostics/snippets/health-checks/health-checks.csproj @@ -8,8 +8,8 @@ - - + + diff --git a/docs/core/diagnostics/snippets/lifetime-health-checks/lifetime-health-checks.csproj b/docs/core/diagnostics/snippets/lifetime-health-checks/lifetime-health-checks.csproj index 893df7d9d209e..326477cf25ee4 100644 --- a/docs/core/diagnostics/snippets/lifetime-health-checks/lifetime-health-checks.csproj +++ b/docs/core/diagnostics/snippets/lifetime-health-checks/lifetime-health-checks.csproj @@ -8,8 +8,8 @@ - - + + diff --git a/docs/core/diagnostics/snippets/resource-monitoring-with-manual-metrics/resource-monitoring-with-manual-metrics.csproj b/docs/core/diagnostics/snippets/resource-monitoring-with-manual-metrics/resource-monitoring-with-manual-metrics.csproj index feb8a4d60d635..af8b2e19e4615 100644 --- a/docs/core/diagnostics/snippets/resource-monitoring-with-manual-metrics/resource-monitoring-with-manual-metrics.csproj +++ b/docs/core/diagnostics/snippets/resource-monitoring-with-manual-metrics/resource-monitoring-with-manual-metrics.csproj @@ -10,10 +10,10 @@ - - - - + + + + diff --git a/docs/core/diagnostics/snippets/resource-monitoring/resource-monitoring.csproj b/docs/core/diagnostics/snippets/resource-monitoring/resource-monitoring.csproj index 42745c4be956e..cf6f7812068b1 100644 --- a/docs/core/diagnostics/snippets/resource-monitoring/resource-monitoring.csproj +++ b/docs/core/diagnostics/snippets/resource-monitoring/resource-monitoring.csproj @@ -8,11 +8,11 @@ - - - - - + + + + + diff --git a/docs/core/enrichment/snippets/applicationlogenricher/applogenricher.csproj b/docs/core/enrichment/snippets/applicationlogenricher/applogenricher.csproj index 45f35649861b2..6d6e0915c71d5 100644 --- a/docs/core/enrichment/snippets/applicationlogenricher/applogenricher.csproj +++ b/docs/core/enrichment/snippets/applicationlogenricher/applogenricher.csproj @@ -8,11 +8,11 @@ - - - - - + + + + + diff --git a/docs/core/enrichment/snippets/httpclientlogenricher/httpclientlogenricher.csproj b/docs/core/enrichment/snippets/httpclientlogenricher/httpclientlogenricher.csproj index 9d06e39d3a246..8c4609269d6f1 100644 --- a/docs/core/enrichment/snippets/httpclientlogenricher/httpclientlogenricher.csproj +++ b/docs/core/enrichment/snippets/httpclientlogenricher/httpclientlogenricher.csproj @@ -9,10 +9,10 @@ - - - - + + + + diff --git a/docs/core/extensions/snippets/async-state/csharp/IAsyncContextExample/IAsyncContextExample.csproj b/docs/core/extensions/snippets/async-state/csharp/IAsyncContextExample/IAsyncContextExample.csproj index cd76e807c5574..61fea351e24be 100644 --- a/docs/core/extensions/snippets/async-state/csharp/IAsyncContextExample/IAsyncContextExample.csproj +++ b/docs/core/extensions/snippets/async-state/csharp/IAsyncContextExample/IAsyncContextExample.csproj @@ -7,8 +7,8 @@ - - + + diff --git a/docs/core/extensions/snippets/async-state/csharp/RequestCorrelation/RequestCorrelation.csproj b/docs/core/extensions/snippets/async-state/csharp/RequestCorrelation/RequestCorrelation.csproj index 4ac9215c6e3dc..1ec7072f6099c 100644 --- a/docs/core/extensions/snippets/async-state/csharp/RequestCorrelation/RequestCorrelation.csproj +++ b/docs/core/extensions/snippets/async-state/csharp/RequestCorrelation/RequestCorrelation.csproj @@ -7,8 +7,8 @@ - - + + diff --git a/docs/core/extensions/snippets/caching/distributed/distributed-apis.csproj b/docs/core/extensions/snippets/caching/distributed/distributed-apis.csproj index e1f2f06397554..b57a08cd86768 100644 --- a/docs/core/extensions/snippets/caching/distributed/distributed-apis.csproj +++ b/docs/core/extensions/snippets/caching/distributed/distributed-apis.csproj @@ -9,8 +9,8 @@ - - + + diff --git a/docs/core/extensions/snippets/caching/hybrid-cache/csharp/HybridCacheExample.csproj b/docs/core/extensions/snippets/caching/hybrid-cache/csharp/HybridCacheExample.csproj index 393e50f91ab6b..99a0a133d5c99 100644 --- a/docs/core/extensions/snippets/caching/hybrid-cache/csharp/HybridCacheExample.csproj +++ b/docs/core/extensions/snippets/caching/hybrid-cache/csharp/HybridCacheExample.csproj @@ -8,9 +8,9 @@ - - - + + + diff --git a/docs/core/extensions/snippets/caching/memory-apis/memory-apis.csproj b/docs/core/extensions/snippets/caching/memory-apis/memory-apis.csproj index e729e99d85c91..1ba1abd4612ee 100644 --- a/docs/core/extensions/snippets/caching/memory-apis/memory-apis.csproj +++ b/docs/core/extensions/snippets/caching/memory-apis/memory-apis.csproj @@ -9,8 +9,8 @@ - - + + diff --git a/docs/core/extensions/snippets/caching/memory-worker/memory-worker.csproj b/docs/core/extensions/snippets/caching/memory-worker/memory-worker.csproj index 97f0e4a3f00e0..da9a75d1e0a0b 100644 --- a/docs/core/extensions/snippets/caching/memory-worker/memory-worker.csproj +++ b/docs/core/extensions/snippets/caching/memory-worker/memory-worker.csproj @@ -8,9 +8,9 @@ - - - + + + diff --git a/docs/core/extensions/snippets/configuration/app-lifetime/app-lifetime.csproj b/docs/core/extensions/snippets/configuration/app-lifetime/app-lifetime.csproj index da1084933c28e..9001a7ff3445a 100644 --- a/docs/core/extensions/snippets/configuration/app-lifetime/app-lifetime.csproj +++ b/docs/core/extensions/snippets/configuration/app-lifetime/app-lifetime.csproj @@ -9,8 +9,8 @@ - - + + diff --git a/docs/core/extensions/snippets/configuration/console-basic/console-basic.csproj b/docs/core/extensions/snippets/configuration/console-basic/console-basic.csproj index 7f466f05b72f2..1ea1c67fcacc5 100644 --- a/docs/core/extensions/snippets/configuration/console-basic/console-basic.csproj +++ b/docs/core/extensions/snippets/configuration/console-basic/console-basic.csproj @@ -14,8 +14,8 @@ - - + + diff --git a/docs/core/extensions/snippets/configuration/console-binder-gen/console-binder-gen.csproj b/docs/core/extensions/snippets/configuration/console-binder-gen/console-binder-gen.csproj index dca164ed282f6..b8b41b0643922 100644 --- a/docs/core/extensions/snippets/configuration/console-binder-gen/console-binder-gen.csproj +++ b/docs/core/extensions/snippets/configuration/console-binder-gen/console-binder-gen.csproj @@ -13,10 +13,10 @@ - - - - + + + + diff --git a/docs/core/extensions/snippets/configuration/console-custom-logging/console-custom-logging.csproj b/docs/core/extensions/snippets/configuration/console-custom-logging/console-custom-logging.csproj index 488918bc2b69b..a96c1b2a738a7 100644 --- a/docs/core/extensions/snippets/configuration/console-custom-logging/console-custom-logging.csproj +++ b/docs/core/extensions/snippets/configuration/console-custom-logging/console-custom-logging.csproj @@ -19,9 +19,9 @@ - - - + + + diff --git a/docs/core/extensions/snippets/configuration/console-env/console-env.csproj b/docs/core/extensions/snippets/configuration/console-env/console-env.csproj index 525342afd8fe1..57b09a5e26e20 100644 --- a/docs/core/extensions/snippets/configuration/console-env/console-env.csproj +++ b/docs/core/extensions/snippets/configuration/console-env/console-env.csproj @@ -9,8 +9,8 @@ - - + + diff --git a/docs/core/extensions/snippets/configuration/console-host/console-host.csproj b/docs/core/extensions/snippets/configuration/console-host/console-host.csproj index 4797e525a8e4a..77edb1c760afe 100644 --- a/docs/core/extensions/snippets/configuration/console-host/console-host.csproj +++ b/docs/core/extensions/snippets/configuration/console-host/console-host.csproj @@ -19,9 +19,9 @@ - - - + + + diff --git a/docs/core/extensions/snippets/configuration/console-indexer/console-indexer.csproj b/docs/core/extensions/snippets/configuration/console-indexer/console-indexer.csproj index 7f466f05b72f2..1ea1c67fcacc5 100644 --- a/docs/core/extensions/snippets/configuration/console-indexer/console-indexer.csproj +++ b/docs/core/extensions/snippets/configuration/console-indexer/console-indexer.csproj @@ -14,8 +14,8 @@ - - + + diff --git a/docs/core/extensions/snippets/configuration/console-ini/console-ini.csproj b/docs/core/extensions/snippets/configuration/console-ini/console-ini.csproj index 250e6cbf93f3d..9fef9a89d4740 100644 --- a/docs/core/extensions/snippets/configuration/console-ini/console-ini.csproj +++ b/docs/core/extensions/snippets/configuration/console-ini/console-ini.csproj @@ -19,9 +19,9 @@ - - - + + + diff --git a/docs/core/extensions/snippets/configuration/console-json/console-json.csproj b/docs/core/extensions/snippets/configuration/console-json/console-json.csproj index 17454ac1a225c..c2d1b89293077 100644 --- a/docs/core/extensions/snippets/configuration/console-json/console-json.csproj +++ b/docs/core/extensions/snippets/configuration/console-json/console-json.csproj @@ -19,9 +19,9 @@ - - - + + + diff --git a/docs/core/extensions/snippets/configuration/console-memory/console-memory.csproj b/docs/core/extensions/snippets/configuration/console-memory/console-memory.csproj index 8a6e2004bba5c..cefdf07dc9da0 100644 --- a/docs/core/extensions/snippets/configuration/console-memory/console-memory.csproj +++ b/docs/core/extensions/snippets/configuration/console-memory/console-memory.csproj @@ -9,8 +9,8 @@ - - + + diff --git a/docs/core/extensions/snippets/configuration/console-raw/console-raw.csproj b/docs/core/extensions/snippets/configuration/console-raw/console-raw.csproj index 5742ee222c0bf..4d696aa88c384 100644 --- a/docs/core/extensions/snippets/configuration/console-raw/console-raw.csproj +++ b/docs/core/extensions/snippets/configuration/console-raw/console-raw.csproj @@ -14,9 +14,9 @@ - - - + + + diff --git a/docs/core/extensions/snippets/configuration/console-validation-gen/console-validation-gen.csproj b/docs/core/extensions/snippets/configuration/console-validation-gen/console-validation-gen.csproj index 6a9b39fe1fd49..b315bec7c61b9 100644 --- a/docs/core/extensions/snippets/configuration/console-validation-gen/console-validation-gen.csproj +++ b/docs/core/extensions/snippets/configuration/console-validation-gen/console-validation-gen.csproj @@ -19,10 +19,10 @@ - - - - + + + + diff --git a/docs/core/extensions/snippets/configuration/console-xml/console-xml.csproj b/docs/core/extensions/snippets/configuration/console-xml/console-xml.csproj index 3cbcf3684da27..4834ba87d177f 100644 --- a/docs/core/extensions/snippets/configuration/console-xml/console-xml.csproj +++ b/docs/core/extensions/snippets/configuration/console-xml/console-xml.csproj @@ -23,9 +23,9 @@ - - - + + + diff --git a/docs/core/extensions/snippets/configuration/console/console.csproj b/docs/core/extensions/snippets/configuration/console/console.csproj index 209af39234498..5a71263c5a35a 100644 --- a/docs/core/extensions/snippets/configuration/console/console.csproj +++ b/docs/core/extensions/snippets/configuration/console/console.csproj @@ -9,8 +9,8 @@ - - + + diff --git a/docs/core/extensions/snippets/configuration/custom-provider/custom-provider.csproj b/docs/core/extensions/snippets/configuration/custom-provider/custom-provider.csproj index 3630bf9ae45f4..0d3d0196c0072 100644 --- a/docs/core/extensions/snippets/configuration/custom-provider/custom-provider.csproj +++ b/docs/core/extensions/snippets/configuration/custom-provider/custom-provider.csproj @@ -9,11 +9,11 @@ - - - - - + + + + + diff --git a/docs/core/extensions/snippets/configuration/options-action/options-action.csproj b/docs/core/extensions/snippets/configuration/options-action/options-action.csproj index 88a7fc4f8cc5e..d5e696233665f 100644 --- a/docs/core/extensions/snippets/configuration/options-action/options-action.csproj +++ b/docs/core/extensions/snippets/configuration/options-action/options-action.csproj @@ -9,8 +9,8 @@ - - + + diff --git a/docs/core/extensions/snippets/configuration/options-configparam/options-configparam.csproj b/docs/core/extensions/snippets/configuration/options-configparam/options-configparam.csproj index d6ea3614f5167..14f897709aa39 100644 --- a/docs/core/extensions/snippets/configuration/options-configparam/options-configparam.csproj +++ b/docs/core/extensions/snippets/configuration/options-configparam/options-configparam.csproj @@ -9,8 +9,8 @@ - - + + diff --git a/docs/core/extensions/snippets/configuration/options-noparams/options-noparams.csproj b/docs/core/extensions/snippets/configuration/options-noparams/options-noparams.csproj index 01c13487b7a8a..11e8848d1a623 100644 --- a/docs/core/extensions/snippets/configuration/options-noparams/options-noparams.csproj +++ b/docs/core/extensions/snippets/configuration/options-noparams/options-noparams.csproj @@ -9,8 +9,8 @@ - - + + diff --git a/docs/core/extensions/snippets/configuration/options-object/options-object.csproj b/docs/core/extensions/snippets/configuration/options-object/options-object.csproj index 750c7700efe42..2bf5062b847ef 100644 --- a/docs/core/extensions/snippets/configuration/options-object/options-object.csproj +++ b/docs/core/extensions/snippets/configuration/options-object/options-object.csproj @@ -9,8 +9,8 @@ - - + + diff --git a/docs/core/extensions/snippets/configuration/options-postconfig/options-postconfig.csproj b/docs/core/extensions/snippets/configuration/options-postconfig/options-postconfig.csproj index 8014ca1fdcdbb..ea2ca6d3d760c 100644 --- a/docs/core/extensions/snippets/configuration/options-postconfig/options-postconfig.csproj +++ b/docs/core/extensions/snippets/configuration/options-postconfig/options-postconfig.csproj @@ -9,8 +9,8 @@ - - + + diff --git a/docs/core/extensions/snippets/configuration/options-recursive-validation/options-recursive-validation.csproj b/docs/core/extensions/snippets/configuration/options-recursive-validation/options-recursive-validation.csproj index 231d1f456d421..c85243a8240c3 100644 --- a/docs/core/extensions/snippets/configuration/options-recursive-validation/options-recursive-validation.csproj +++ b/docs/core/extensions/snippets/configuration/options-recursive-validation/options-recursive-validation.csproj @@ -19,11 +19,11 @@ - - - - - + + + + + diff --git a/docs/core/extensions/snippets/configuration/options-validation-onstart/options-validation-onstart.csproj b/docs/core/extensions/snippets/configuration/options-validation-onstart/options-validation-onstart.csproj index 623433e9082b5..83680ad16e6c9 100644 --- a/docs/core/extensions/snippets/configuration/options-validation-onstart/options-validation-onstart.csproj +++ b/docs/core/extensions/snippets/configuration/options-validation-onstart/options-validation-onstart.csproj @@ -19,9 +19,9 @@ - - - + + + diff --git a/docs/core/extensions/snippets/configuration/worker-scope/worker-scope.csproj b/docs/core/extensions/snippets/configuration/worker-scope/worker-scope.csproj index a60641b00b4e4..712333d4c8b4a 100644 --- a/docs/core/extensions/snippets/configuration/worker-scope/worker-scope.csproj +++ b/docs/core/extensions/snippets/configuration/worker-scope/worker-scope.csproj @@ -8,7 +8,7 @@ - - + + diff --git a/docs/core/extensions/snippets/configuration/worker-service/worker-service.csproj b/docs/core/extensions/snippets/configuration/worker-service/worker-service.csproj index 20baa3b0994cc..022f177539b88 100644 --- a/docs/core/extensions/snippets/configuration/worker-service/worker-service.csproj +++ b/docs/core/extensions/snippets/configuration/worker-service/worker-service.csproj @@ -9,7 +9,7 @@ - - + + diff --git a/docs/core/extensions/snippets/dependency-injection-auto-activation/csharp/CompleteExample/CompleteExample.csproj b/docs/core/extensions/snippets/dependency-injection-auto-activation/csharp/CompleteExample/CompleteExample.csproj index 14d4830fd9e9b..716bb07130c8b 100644 --- a/docs/core/extensions/snippets/dependency-injection-auto-activation/csharp/CompleteExample/CompleteExample.csproj +++ b/docs/core/extensions/snippets/dependency-injection-auto-activation/csharp/CompleteExample/CompleteExample.csproj @@ -7,8 +7,8 @@ - - + + diff --git a/docs/core/extensions/snippets/dependency-injection-auto-activation/csharp/DependenciesExample/DependenciesExample.csproj b/docs/core/extensions/snippets/dependency-injection-auto-activation/csharp/DependenciesExample/DependenciesExample.csproj index 5be62298b235e..cfc422e274ddc 100644 --- a/docs/core/extensions/snippets/dependency-injection-auto-activation/csharp/DependenciesExample/DependenciesExample.csproj +++ b/docs/core/extensions/snippets/dependency-injection-auto-activation/csharp/DependenciesExample/DependenciesExample.csproj @@ -7,9 +7,9 @@ - - - + + + diff --git a/docs/core/extensions/snippets/fileglobbing/example/example.csproj b/docs/core/extensions/snippets/fileglobbing/example/example.csproj index 6871e1e56e24c..7d53301ff9632 100644 --- a/docs/core/extensions/snippets/fileglobbing/example/example.csproj +++ b/docs/core/extensions/snippets/fileglobbing/example/example.csproj @@ -59,8 +59,8 @@ - - + + diff --git a/docs/core/extensions/snippets/http/basic/basic.csproj b/docs/core/extensions/snippets/http/basic/basic.csproj index 7c38103d9ee8d..f9e9622f631ef 100644 --- a/docs/core/extensions/snippets/http/basic/basic.csproj +++ b/docs/core/extensions/snippets/http/basic/basic.csproj @@ -9,8 +9,8 @@ - - + + diff --git a/docs/core/extensions/snippets/http/configurehandler/configurehandler.csproj b/docs/core/extensions/snippets/http/configurehandler/configurehandler.csproj index aa062ed4ce1c1..6d80b27f18423 100644 --- a/docs/core/extensions/snippets/http/configurehandler/configurehandler.csproj +++ b/docs/core/extensions/snippets/http/configurehandler/configurehandler.csproj @@ -9,8 +9,8 @@ - - + + diff --git a/docs/core/extensions/snippets/http/generated/generated.csproj b/docs/core/extensions/snippets/http/generated/generated.csproj index ea326224db9cf..3eb80875f1423 100644 --- a/docs/core/extensions/snippets/http/generated/generated.csproj +++ b/docs/core/extensions/snippets/http/generated/generated.csproj @@ -9,8 +9,8 @@ - - + + diff --git a/docs/core/extensions/snippets/http/named/named.csproj b/docs/core/extensions/snippets/http/named/named.csproj index 45136dd55d1ec..b0af11be0cc3e 100644 --- a/docs/core/extensions/snippets/http/named/named.csproj +++ b/docs/core/extensions/snippets/http/named/named.csproj @@ -19,8 +19,8 @@ - - + + diff --git a/docs/core/extensions/snippets/http/typed/typed.csproj b/docs/core/extensions/snippets/http/typed/typed.csproj index 720350120db9c..c9f0fc2e9a50b 100644 --- a/docs/core/extensions/snippets/http/typed/typed.csproj +++ b/docs/core/extensions/snippets/http/typed/typed.csproj @@ -9,8 +9,8 @@ - - + + diff --git a/docs/core/extensions/snippets/localization/example/example.csproj b/docs/core/extensions/snippets/localization/example/example.csproj index 42e05d9efd62d..ae383d541528e 100644 --- a/docs/core/extensions/snippets/localization/example/example.csproj +++ b/docs/core/extensions/snippets/localization/example/example.csproj @@ -9,8 +9,8 @@ - - + + diff --git a/docs/core/extensions/snippets/logging/di-without-host/di-without-host.csproj b/docs/core/extensions/snippets/logging/di-without-host/di-without-host.csproj index 995d24dec7f1b..5643320ed19f1 100644 --- a/docs/core/extensions/snippets/logging/di-without-host/di-without-host.csproj +++ b/docs/core/extensions/snippets/logging/di-without-host/di-without-host.csproj @@ -9,9 +9,9 @@ - - - + + + diff --git a/docs/core/extensions/snippets/primitives/change/tokens.csproj b/docs/core/extensions/snippets/primitives/change/tokens.csproj index 3e3d10f3b81a2..ad24cf8309d9b 100644 --- a/docs/core/extensions/snippets/primitives/change/tokens.csproj +++ b/docs/core/extensions/snippets/primitives/change/tokens.csproj @@ -9,7 +9,7 @@ - + diff --git a/docs/core/extensions/snippets/primitives/string/tokenizers.csproj b/docs/core/extensions/snippets/primitives/string/tokenizers.csproj index 6e03087a245b1..4b5b13a940411 100644 --- a/docs/core/extensions/snippets/primitives/string/tokenizers.csproj +++ b/docs/core/extensions/snippets/primitives/string/tokenizers.csproj @@ -10,7 +10,7 @@ - + diff --git a/docs/core/testing/microsoft-testing-platform-cli-options.md b/docs/core/testing/microsoft-testing-platform-cli-options.md index 5d018601b41c4..6d01498c010e6 100644 --- a/docs/core/testing/microsoft-testing-platform-cli-options.md +++ b/docs/core/testing/microsoft-testing-platform-cli-options.md @@ -3,7 +3,7 @@ title: Microsoft.Testing.Platform (MTP) CLI options reference description: Find platform and extension command-line options for MTP in one place. author: Evangelink ms.author: amauryleve -ms.date: 06/16/2026 +ms.date: 07/09/2026 ai-usage: ai-assisted --- @@ -95,7 +95,7 @@ This article gives a central entry point for MTP command-line options. Filters the tests to run by their test node UIDs. Accepts one or more UIDs. > [!NOTE] - > This option is available in MTP starting with version 1.8.0. + > This option is available in MTP starting with version 1.8.0. Starting with MTP 2.3.0, you can't combine `--filter-uid` with `--treenode-filter`; specifying both fails command-line validation with the `InvalidCommandLine` exit code. - **`--help`** @@ -150,6 +150,9 @@ This article gives a central entry point for MTP command-line options. Filters the tests to run by using a tree filter expression. Tree filters offer richer matching than `--filter` for advanced scenarios. + > [!NOTE] + > Starting with MTP 2.3.0, you can't combine `--treenode-filter` with `--filter-uid`; specifying both fails command-line validation with the `InvalidCommandLine` exit code. + - **`--zero-tests-policy`** Controls whether a run that executes no tests because every test was skipped is treated as a failure. Valid values are `allow-skipped` (default) and `strict`. With `allow-skipped`, an all-skipped run succeeds; with `strict`, it fails with exit code 8 (the behavior before 2.3.0). diff --git a/docs/core/testing/order-unit-tests.md b/docs/core/testing/order-unit-tests.md index f3a0ce4a372b6..007e95a18c0c7 100644 --- a/docs/core/testing/order-unit-tests.md +++ b/docs/core/testing/order-unit-tests.md @@ -1,7 +1,7 @@ --- title: Order unit tests description: Learn how to order unit tests with .NET Core. -ms.date: 02/20/2026 +ms.date: 07/08/2026 ai-usage: ai-assisted zone_pivot_groups: unit-testing-framework-set-one --- @@ -49,6 +49,23 @@ Starting with MSTest 3.6, a new runsettings option lets you run tests by test na ``` +## Order randomly + +In MSTest 4.3 and later, run tests in a random order to surface hidden ordering dependencies between tests. To enable random order, set the `RandomizeTestOrder` setting to **true** in your runsettings file: + +```xml + + + + + true + + + +``` + +To make the random order reproducible, set the `RandomTestOrderSeed` setting to an integer seed. MSTest then replays the same order on every run. When you leave the seed unset, MSTest generates a new seed for each run. Don't combine `RandomizeTestOrder` with `OrderTestsByNameInClass`, because MSTest applies only one ordering mode at a time. For more information, see [Configure MSTest](unit-testing-mstest-configure.md). + :::zone-end :::zone pivot="xunit" diff --git a/docs/core/testing/selective-unit-tests.md b/docs/core/testing/selective-unit-tests.md index 7a5d0eee4ea68..92f46f951eafe 100644 --- a/docs/core/testing/selective-unit-tests.md +++ b/docs/core/testing/selective-unit-tests.md @@ -2,7 +2,8 @@ title: Run selected unit tests description: How to use a filter expression to run selected unit tests with the dotnet test command in .NET Core. author: smadala -ms.date: 10/29/2021 +ms.date: 07/22/2026 +ai-usage: ai-assisted zone_pivot_groups: unit-testing-framework-set-one ms.topic: reference --- @@ -29,7 +30,7 @@ dotnet test --filter | Test framework | Supported properties | | -------------- | -------------------- | - | MSTest | `FullyQualifiedName`
`Name`
`ClassName`
`Priority`
`TestCategory` | + | MSTest | `FullyQualifiedName`
`Name`
`ClassName`
`Priority`
`TestCategory`
`Id` | | xUnit | `FullyQualifiedName`
`DisplayName`
`Traits` | | Nunit | `FullyQualifiedName`
`Name`
`Priority`
`TestCategory` | @@ -95,6 +96,9 @@ namespace MSTestNamespace | `dotnet test --filter FullyQualifiedName!=MSTestNamespace.UnitTest1.TestMethod1` | Runs all tests except `MSTestNamespace.UnitTest1.TestMethod1`. | | `dotnet test --filter TestCategory=CategoryA` | Runs tests that are annotated with `[TestCategory("CategoryA")]`. | | `dotnet test --filter Priority=2` | Runs tests that are annotated with `[Priority(2)]`. | +| `dotnet test --filter "Id="` | Runs the test case whose discovered `TestCase.Id` value exactly matches the GUID. | + +`Id` filtering requires MSTest.TestAdapter 3.6 or later. Obtain the GUID from the test case that VSTest discovery returns in `TestCase.Id`. This filter can select one unfolded data-driven iteration without matching or escaping its display name. Each row must be discovered as an individual test case; a folded data-driven test exposes only one parent identity. Examples using the conditional operators `|` and `&`: diff --git a/docs/core/testing/snippets/order-unit-tests/csharp/MSTest.Project/MSTest.Project.csproj b/docs/core/testing/snippets/order-unit-tests/csharp/MSTest.Project/MSTest.Project.csproj index 1643fefc4f499..329152cd7b86b 100644 --- a/docs/core/testing/snippets/order-unit-tests/csharp/MSTest.Project/MSTest.Project.csproj +++ b/docs/core/testing/snippets/order-unit-tests/csharp/MSTest.Project/MSTest.Project.csproj @@ -8,9 +8,9 @@ - - - + + + all runtime; build; native; contentfiles; analyzers; buildtransitive diff --git a/docs/core/testing/snippets/order-unit-tests/csharp/NUnit.TestProject/NUnit.Project.csproj b/docs/core/testing/snippets/order-unit-tests/csharp/NUnit.TestProject/NUnit.Project.csproj index 5392d8f285cd0..52c129fc5ff8a 100644 --- a/docs/core/testing/snippets/order-unit-tests/csharp/NUnit.TestProject/NUnit.Project.csproj +++ b/docs/core/testing/snippets/order-unit-tests/csharp/NUnit.TestProject/NUnit.Project.csproj @@ -10,7 +10,7 @@ - + all runtime; build; native; contentfiles; analyzers diff --git a/docs/core/testing/snippets/order-unit-tests/csharp/XUnit.TestProject/XUnit.Project.csproj b/docs/core/testing/snippets/order-unit-tests/csharp/XUnit.TestProject/XUnit.Project.csproj index 96b1c4d168d38..767ca5e1f7b41 100644 --- a/docs/core/testing/snippets/order-unit-tests/csharp/XUnit.TestProject/XUnit.Project.csproj +++ b/docs/core/testing/snippets/order-unit-tests/csharp/XUnit.TestProject/XUnit.Project.csproj @@ -8,7 +8,7 @@ - + all diff --git a/docs/core/whats-new/dotnet-10/sdk.md b/docs/core/whats-new/dotnet-10/sdk.md index 03945bd68a88c..48249bb24d890 100644 --- a/docs/core/whats-new/dotnet-10/sdk.md +++ b/docs/core/whats-new/dotnet-10/sdk.md @@ -9,7 +9,7 @@ ms.update-cycle: 3650-days # What's new in the SDK and tooling for .NET 10 -This article describes new features and enhancements in the .NET SDK for .NET 10. +This article describes new features and enhancements in the .NET SDK for .NET 10. You can [download .NET 10 here](https://get.dot.net/10). ## .NET tools enhancements diff --git a/docs/core/whats-new/dotnet-11/sdk.md b/docs/core/whats-new/dotnet-11/sdk.md index e0ab112f7e596..096cb0045b9e7 100644 --- a/docs/core/whats-new/dotnet-11/sdk.md +++ b/docs/core/whats-new/dotnet-11/sdk.md @@ -9,7 +9,7 @@ ms.update-cycle: 3650-days # What's new in the SDK and tooling for .NET 11 -This article describes new features and enhancements in the .NET SDK for .NET 11. It was last updated for Preview 6. +This article describes new features and enhancements in the .NET SDK for .NET 11. It was last updated for Preview 6. You can [download .NET 11 here](https://dotnet.microsoft.com/download/dotnet/11.0). ## SDK footprint diff --git a/docs/core/whats-new/dotnet-8/sdk.md b/docs/core/whats-new/dotnet-8/sdk.md index 39fb2bd6dd4bf..744c4cf537875 100644 --- a/docs/core/whats-new/dotnet-8/sdk.md +++ b/docs/core/whats-new/dotnet-8/sdk.md @@ -8,7 +8,7 @@ ms.update-cycle: 3650-days --- # What's new in the SDK and tooling for .NET 8 -This article describes new features in the .NET SDK and tooling for .NET 8. +This article describes new features in the .NET SDK and tooling for .NET 8. You can [download .NET 8 here](https://dotnet.microsoft.com/download/dotnet/8.0). ## SDK diff --git a/docs/core/whats-new/dotnet-9/sdk.md b/docs/core/whats-new/dotnet-9/sdk.md index 5d08a0b3bb486..12c8aff503c0e 100644 --- a/docs/core/whats-new/dotnet-9/sdk.md +++ b/docs/core/whats-new/dotnet-9/sdk.md @@ -8,7 +8,7 @@ ms.update-cycle: 3650-days # What's new in the SDK and tooling for .NET 9 -This article describes new features in the .NET SDK and tooling for .NET 9. +This article describes new features in the .NET SDK and tooling for .NET 9. You can [download .NET 9 here](https://dotnet.microsoft.com/download/dotnet/9.0). ## Unit testing diff --git a/docs/csharp/language-reference/operators/operator-overloading.md b/docs/csharp/language-reference/operators/operator-overloading.md index c82eb1ed2601f..17fd7a9111d4e 100644 --- a/docs/csharp/language-reference/operators/operator-overloading.md +++ b/docs/csharp/language-reference/operators/operator-overloading.md @@ -34,12 +34,16 @@ You also use the `operator` keyword to define a custom type conversion. For more The following table shows the operators that can be overloaded: + + | Operators | Notes | | :--------------------: | ------------- | |[`+x`](arithmetic-operators.md#unary-plus-and-minus-operators), [`-x`](arithmetic-operators.md#unary-plus-and-minus-operators), [`!x`](boolean-logical-operators.md#logical-negation-operator-), [`~x`](bitwise-and-shift-operators.md#bitwise-complement-operator-), [`++`](arithmetic-operators.md#increment-operator-), [`--`](arithmetic-operators.md#decrement-operator---), [`true`](true-false-operators.md), [`false`](true-false-operators.md)|The `true` and `false` operators must be overloaded together.| |[`x + y`](arithmetic-operators.md#addition-operator-), [`x - y`](arithmetic-operators.md#subtraction-operator--), [`x * y`](arithmetic-operators.md#multiplication-operator-), [`x / y`](arithmetic-operators.md#division-operator-), [`x % y`](arithmetic-operators.md#remainder-operator-),
[`x & y`](boolean-logical-operators.md#logical-and-operator-), [x | y](boolean-logical-operators.md#logical-or-operator-), [`x ^ y`](boolean-logical-operators.md#logical-exclusive-or-operator-),
[`x << y`](bitwise-and-shift-operators.md#left-shift-operator-), [`x >> y`](bitwise-and-shift-operators.md#right-shift-operator-), [`x >>> y`](bitwise-and-shift-operators.md#unsigned-right-shift-operator-) | | |[`x == y`](equality-operators.md#equality-operator-), [`x != y`](equality-operators.md#inequality-operator-), [`x < y`](comparison-operators.md#less-than-operator-), [`x > y`](comparison-operators.md#greater-than-operator-), [`x <= y`](comparison-operators.md#less-than-or-equal-operator-), [`x >= y`](comparison-operators.md#greater-than-or-equal-operator-)|Must be overloaded in pairs as follows: `==` and `!=`, `<` and `>`, `<=` and `>=`.| -|[`+=`](arithmetic-operators.md#compound-assignment), [`-=`](arithmetic-operators.md#compound-assignment), [`*=`](arithmetic-operators.md#compound-assignment), [`/=`](arithmetic-operators.md#compound-assignment), [`%=`](arithmetic-operators.md#compound-assignment), [`&=`](boolean-logical-operators.md#compound-assignment), [`\|=`](boolean-logical-operators.md#compound-assignment), [`^=`](boolean-logical-operators.md#compound-assignment), [`<<=`](bitwise-and-shift-operators.md#compound-assignment), [`>>=`](bitwise-and-shift-operators.md#compound-assignment), [`>>>=`](bitwise-and-shift-operators.md#compound-assignment)|The compound assignment operators can be overloaded in C# 14 and later.| +|[`+=`](arithmetic-operators.md#compound-assignment), [`-=`](arithmetic-operators.md#compound-assignment), [`*=`](arithmetic-operators.md#compound-assignment), [`/=`](arithmetic-operators.md#compound-assignment), [`%=`](arithmetic-operators.md#compound-assignment), [`&=`](boolean-logical-operators.md#compound-assignment), [`|=`](boolean-logical-operators.md#compound-assignment), [`^=`](boolean-logical-operators.md#compound-assignment), [`<<=`](bitwise-and-shift-operators.md#compound-assignment), [`>>=`](bitwise-and-shift-operators.md#compound-assignment), [`>>>=`](bitwise-and-shift-operators.md#compound-assignment)|The compound assignment operators can be overloaded in C# 14 and later.| + + A compound assignment overloaded operator must follow these rules: diff --git a/docs/csharp/programming-guide/classes-and-structs/snippets/ExtensionMembers/CustomExtensionMembers.cs b/docs/csharp/programming-guide/classes-and-structs/snippets/ExtensionMembers/CustomExtensionMembers.cs index 3adc79b6718ce..ffcee5362483a 100644 --- a/docs/csharp/programming-guide/classes-and-structs/snippets/ExtensionMembers/CustomExtensionMembers.cs +++ b/docs/csharp/programming-guide/classes-and-structs/snippets/ExtensionMembers/CustomExtensionMembers.cs @@ -125,7 +125,8 @@ public static class AccountExtensions { extension(ref Account account) { - // ref keyword can also appear before the this keyword + // account is the receiver (analogous to the this parameter in extension methods). + // The ref modifier on the extension block means the receiver is passed by reference. public void Deposit(float amount) { account.balance += amount; diff --git a/docs/csharp/roslyn-sdk/tutorials/snippets/how-to-write-csharp-analyzer-code-fix/MakeConst/MakeConst.CodeFixes/MakeConst.CodeFixes.csproj b/docs/csharp/roslyn-sdk/tutorials/snippets/how-to-write-csharp-analyzer-code-fix/MakeConst/MakeConst.CodeFixes/MakeConst.CodeFixes.csproj index 34bebb27c13f2..a48924612fd42 100644 --- a/docs/csharp/roslyn-sdk/tutorials/snippets/how-to-write-csharp-analyzer-code-fix/MakeConst/MakeConst.CodeFixes/MakeConst.CodeFixes.csproj +++ b/docs/csharp/roslyn-sdk/tutorials/snippets/how-to-write-csharp-analyzer-code-fix/MakeConst/MakeConst.CodeFixes/MakeConst.CodeFixes.csproj @@ -8,7 +8,7 @@ - + diff --git a/docs/csharp/roslyn-sdk/tutorials/snippets/how-to-write-csharp-analyzer-code-fix/MakeConst/MakeConst.Test/MakeConst.Test.csproj b/docs/csharp/roslyn-sdk/tutorials/snippets/how-to-write-csharp-analyzer-code-fix/MakeConst/MakeConst.Test/MakeConst.Test.csproj index a6a2babaddc13..4f11bedc09ae5 100644 --- a/docs/csharp/roslyn-sdk/tutorials/snippets/how-to-write-csharp-analyzer-code-fix/MakeConst/MakeConst.Test/MakeConst.Test.csproj +++ b/docs/csharp/roslyn-sdk/tutorials/snippets/how-to-write-csharp-analyzer-code-fix/MakeConst/MakeConst.Test/MakeConst.Test.csproj @@ -9,8 +9,8 @@ - - + + diff --git a/docs/framework/release-notes/2024/01-09-january-security-and-quality-rollup.md b/docs/framework/release-notes/2024/01-09-january-security-and-quality-rollup.md index 2140e9c059316..d879642c7fe65 100644 --- a/docs/framework/release-notes/2024/01-09-january-security-and-quality-rollup.md +++ b/docs/framework/release-notes/2024/01-09-january-security-and-quality-rollup.md @@ -3,7 +3,7 @@ title: January 2024 security and quality rollup description: Learn about the improvements in the .NET Framework January 2024 security and quality rollup. ms.date: 01/08/2024 --- -# January 2024 security and quality rollup +# .NET Framework January 2024 security and quality rollup _Released January 8, 2024_ diff --git a/docs/framework/release-notes/2024/01-23-january-preview-cumulative-update.md b/docs/framework/release-notes/2024/01-23-january-preview-cumulative-update.md index 2b5290f8839a4..b6db86a932b93 100644 --- a/docs/framework/release-notes/2024/01-23-january-preview-cumulative-update.md +++ b/docs/framework/release-notes/2024/01-23-january-preview-cumulative-update.md @@ -3,7 +3,7 @@ title: January 2024 cumulative update preview description: Learn about the improvements in the .NET Framework January 2024 cumulative update preview. ms.date: 01/23/2024 --- -# January 2024 cumulative update preview +# .NET Framework January 2024 cumulative update preview _Released January 23, 2024_ diff --git a/docs/framework/release-notes/2024/02-14-february-security-and-quality-rollup.md b/docs/framework/release-notes/2024/02-14-february-security-and-quality-rollup.md index c6b8bffbef996..fe84aa8c3a95b 100644 --- a/docs/framework/release-notes/2024/02-14-february-security-and-quality-rollup.md +++ b/docs/framework/release-notes/2024/02-14-february-security-and-quality-rollup.md @@ -3,7 +3,7 @@ title: February 2024 security and quality rollup description: Learn about the improvements in the .NET Framework February 2024 security and quality rollup. ms.date: 02/14/2024 --- -# February 2024 security and quality rollup +# .NET Framework February 2024 security and quality rollup _Released February 14, 2024_ diff --git a/docs/framework/release-notes/2024/03-26-march-preview-cumulative-update.md b/docs/framework/release-notes/2024/03-26-march-preview-cumulative-update.md index 8b8281c67e8e4..8dcc3c9c2b127 100644 --- a/docs/framework/release-notes/2024/03-26-march-preview-cumulative-update.md +++ b/docs/framework/release-notes/2024/03-26-march-preview-cumulative-update.md @@ -3,7 +3,7 @@ title: March 2024 cumulative update preview description: Learn about the improvements in the .NET Framework March 2024 cumulative update preview. ms.date: 03/26/2024 --- -# March 2024 cumulative update preview +# .NET Framework March 2024 cumulative update preview _Released March 26, 2024_ diff --git a/docs/framework/release-notes/2024/04-09-april-security-and-quality-rollup.md b/docs/framework/release-notes/2024/04-09-april-security-and-quality-rollup.md index d6b38bb84086e..d3b9edd408642 100644 --- a/docs/framework/release-notes/2024/04-09-april-security-and-quality-rollup.md +++ b/docs/framework/release-notes/2024/04-09-april-security-and-quality-rollup.md @@ -3,7 +3,7 @@ title: April 2024 security and quality rollup description: Learn about the improvements in the .NET Framework April 2024 security and quality rollup. ms.date: 04/17/2024 --- -# April 2024 security and quality rollup +# .NET Framework April 2024 security and quality rollup _Released April 9, 2024_ diff --git a/docs/framework/release-notes/2024/04-23-april-preview-cumulative-update.md b/docs/framework/release-notes/2024/04-23-april-preview-cumulative-update.md index fec7566a11f30..7967e3c943b57 100644 --- a/docs/framework/release-notes/2024/04-23-april-preview-cumulative-update.md +++ b/docs/framework/release-notes/2024/04-23-april-preview-cumulative-update.md @@ -3,7 +3,7 @@ title: April 2024 cumulative update preview description: Learn about the improvements in the .NET Framework April 2024 cumulative update preview. ms.date: 04/23/2024 --- -# April 2024 cumulative update preview +# .NET Framework April 2024 cumulative update preview _Released April 23, 2024_ diff --git a/docs/framework/release-notes/2024/05-14-may-security-and-quality-rollup.md b/docs/framework/release-notes/2024/05-14-may-security-and-quality-rollup.md index 55b5a252ef048..d8859a43b6ef2 100644 --- a/docs/framework/release-notes/2024/05-14-may-security-and-quality-rollup.md +++ b/docs/framework/release-notes/2024/05-14-may-security-and-quality-rollup.md @@ -3,7 +3,7 @@ title: May 2024 security and quality rollup description: Learn about the improvements in the .NET Framework May 2024 security and quality rollup. ms.date: 05/14/2024 --- -# May 2024 security and quality rollup +# .NET Framework May 2024 security and quality rollup _Released May 14, 2024_ diff --git a/docs/framework/release-notes/2024/06-25-june-preview-cumulative-update.md b/docs/framework/release-notes/2024/06-25-june-preview-cumulative-update.md index 4c5d6d7a8ddc6..4261901b99179 100644 --- a/docs/framework/release-notes/2024/06-25-june-preview-cumulative-update.md +++ b/docs/framework/release-notes/2024/06-25-june-preview-cumulative-update.md @@ -3,7 +3,7 @@ title: June 2024 cumulative update preview description: Learn about the improvements in the .NET Framework June 2024 cumulative update preview. ms.date: 06/25/2024 --- -# June 2024 cumulative update preview +# .NET Framework June 2024 cumulative update preview _Released June 25, 2024_ diff --git a/docs/framework/release-notes/2024/07-09-july-security-and-quality-rollup.md b/docs/framework/release-notes/2024/07-09-july-security-and-quality-rollup.md index 0f63a6fa2efc6..4f34190bfb2f4 100644 --- a/docs/framework/release-notes/2024/07-09-july-security-and-quality-rollup.md +++ b/docs/framework/release-notes/2024/07-09-july-security-and-quality-rollup.md @@ -3,7 +3,7 @@ title: July 2024 security and quality rollup description: Learn about the improvements in the .NET Framework July 2024 security and quality rollup. ms.date: 07/09/2024 --- -# July 2024 security and quality rollup +# .NET Framework July 2024 security and quality rollup _Released July 9, 2024_ diff --git a/docs/framework/release-notes/2024/07-25-july-preview-cumulative-update.md b/docs/framework/release-notes/2024/07-25-july-preview-cumulative-update.md index 314a50e2320e7..61fdad0c58923 100644 --- a/docs/framework/release-notes/2024/07-25-july-preview-cumulative-update.md +++ b/docs/framework/release-notes/2024/07-25-july-preview-cumulative-update.md @@ -3,7 +3,7 @@ title: July 2024 cumulative update preview description: Learn about the improvements in the .NET Framework July 2024 cumulative update preview. ms.date: 07/25/2024 --- -# July 2024 cumulative update preview +# .NET Framework July 2024 cumulative update preview _Released July 25, 2024_ diff --git a/docs/framework/release-notes/2024/08-13-august-security-and-quality-rollup.md b/docs/framework/release-notes/2024/08-13-august-security-and-quality-rollup.md index 8652191a6a2dd..57c0a901c07c4 100644 --- a/docs/framework/release-notes/2024/08-13-august-security-and-quality-rollup.md +++ b/docs/framework/release-notes/2024/08-13-august-security-and-quality-rollup.md @@ -3,7 +3,7 @@ title: August 2024 security and quality rollup description: Learn about the improvements in the .NET Framework August 2024 security and quality rollup. ms.date: 08/13/2024 --- -# August 2024 security and quality rollup +# .NET Framework August 2024 security and quality rollup _Released August 13, 2024_ diff --git a/docs/framework/release-notes/2024/10-08-october-security-and-quality-rollup.md b/docs/framework/release-notes/2024/10-08-october-security-and-quality-rollup.md index 7f84c5ddac7d3..df3b438a0d8d3 100644 --- a/docs/framework/release-notes/2024/10-08-october-security-and-quality-rollup.md +++ b/docs/framework/release-notes/2024/10-08-october-security-and-quality-rollup.md @@ -3,7 +3,7 @@ title: October 2024 security and quality rollup description: Learn about the improvements in the .NET Framework October 2024 security and quality rollup. ms.date: 10/08/2024 --- -# October 2024 security and quality rollup +# .NET Framework October 2024 security and quality rollup _Released October 8, 2024_ diff --git a/docs/framework/release-notes/2024/10-22-october-preview-cumulative-update.md b/docs/framework/release-notes/2024/10-22-october-preview-cumulative-update.md index 00366fdd23233..29a79f59442b1 100644 --- a/docs/framework/release-notes/2024/10-22-october-preview-cumulative-update.md +++ b/docs/framework/release-notes/2024/10-22-october-preview-cumulative-update.md @@ -3,7 +3,7 @@ title: October 2024 cumulative update preview description: Learn about the improvements in the .NET Framework October 2024 cumulative update preview. ms.date: 10/22/2024 --- -# October 2024 cumulative update preview +# .NET Framework October 2024 cumulative update preview _Released October 22, 2024_ diff --git a/docs/framework/release-notes/2024/11-12-november-security-and-quality-rollup.md b/docs/framework/release-notes/2024/11-12-november-security-and-quality-rollup.md index fec8e79b8dac0..31037ea9d738a 100644 --- a/docs/framework/release-notes/2024/11-12-november-security-and-quality-rollup.md +++ b/docs/framework/release-notes/2024/11-12-november-security-and-quality-rollup.md @@ -3,7 +3,7 @@ title: November 2024 security and quality rollup description: Learn about the improvements in the .NET Framework November 2024 security and quality rollup. ms.date: 11/12/2024 --- -# November 2024 security and quality rollup +# .NET Framework November 2024 security and quality rollup _Released November 12, 2024_ diff --git a/docs/framework/release-notes/2024/11-21-november-preview-cumulative-update.md b/docs/framework/release-notes/2024/11-21-november-preview-cumulative-update.md index 8cfdb919dfaa3..c8678f252caca 100644 --- a/docs/framework/release-notes/2024/11-21-november-preview-cumulative-update.md +++ b/docs/framework/release-notes/2024/11-21-november-preview-cumulative-update.md @@ -3,7 +3,7 @@ title: November 2024 cumulative update preview description: Learn about the improvements in the .NET Framework November 2024 cumulative update preview. ms.date: 11/21/2024 --- -# November 2024 cumulative update preview +# .NET Framework November 2024 cumulative update preview _Released Novemeber 21, 2024_ _*Revised: December 18th, 2024 to updated the quality and reliability improvement. If you have already installed this update, no action is needed. diff --git a/docs/framework/release-notes/2025/01-14-january-cumulative-update.md b/docs/framework/release-notes/2025/01-14-january-cumulative-update.md index 96504974b6e8f..91622d944bfda 100644 --- a/docs/framework/release-notes/2025/01-14-january-cumulative-update.md +++ b/docs/framework/release-notes/2025/01-14-january-cumulative-update.md @@ -3,7 +3,7 @@ title: January 2025 cumulative update description: Learn about the improvements in the .NET Framework January 2025 cumulative update. ms.date: 01/14/2025 --- -# January 2025 cumulative update +# .NET Framework January 2025 cumulative update _Released January 14, 2025_ diff --git a/docs/framework/release-notes/2025/01-28-january-cumulative-update-preview.md b/docs/framework/release-notes/2025/01-28-january-cumulative-update-preview.md index a3a9963237d53..cf94c01141b01 100644 --- a/docs/framework/release-notes/2025/01-28-january-cumulative-update-preview.md +++ b/docs/framework/release-notes/2025/01-28-january-cumulative-update-preview.md @@ -3,7 +3,7 @@ title: January 2025 cumulative update preview description: Learn about the improvements in the .NET Framework January 2025 cumulative update preview. ms.date: 01/28/2025 --- -# January 2025 cumulative update preview +# .NET Framework January 2025 cumulative update preview _Released January 28, 2025_ diff --git a/docs/framework/release-notes/2025/03-25-march-cumulative-update-preview.md b/docs/framework/release-notes/2025/03-25-march-cumulative-update-preview.md index 08ffa4a415513..3438f94433f64 100644 --- a/docs/framework/release-notes/2025/03-25-march-cumulative-update-preview.md +++ b/docs/framework/release-notes/2025/03-25-march-cumulative-update-preview.md @@ -3,7 +3,7 @@ title: March 2025 cumulative update preview description: Learn about the improvements in the .NET Framework March 2025 cumulative update preview. ms.date: 03/27/2025 --- -# March 2025 cumulative update preview +# .NET Framework March 2025 cumulative update preview _Released March 25, 2025_ _Updated March 27, 2025_ diff --git a/docs/framework/release-notes/2025/04-08-april-cumulative-update.md b/docs/framework/release-notes/2025/04-08-april-cumulative-update.md index 808a47a22b65a..4712fd82f66d0 100644 --- a/docs/framework/release-notes/2025/04-08-april-cumulative-update.md +++ b/docs/framework/release-notes/2025/04-08-april-cumulative-update.md @@ -3,7 +3,7 @@ title: April 2025 security and quality rollup description: Learn about the improvements in the .NET Framework April 2025 security and quality rollup. ms.date: 04/08/2025 --- -# April 2025 security and quality rollup +# .NET Framework April 2025 security and quality rollup _Released April 8, 2025_ diff --git a/docs/framework/release-notes/2025/04-22-april-cumulative-update-preview.md b/docs/framework/release-notes/2025/04-22-april-cumulative-update-preview.md index 6e606f6d67435..42595c71c3c65 100644 --- a/docs/framework/release-notes/2025/04-22-april-cumulative-update-preview.md +++ b/docs/framework/release-notes/2025/04-22-april-cumulative-update-preview.md @@ -3,7 +3,7 @@ title: April 2025 cumulative update preview description: Learn about the improvements in the .NET Framework April 2025 cumulative update preview. ms.date: 04/22/2025 --- -# April 2025 cumulative update preview +# .NET Framework April 2025 cumulative update preview _Released April 22, 2025_ diff --git a/docs/framework/release-notes/2025/07-08-july-cumulative-update.md b/docs/framework/release-notes/2025/07-08-july-cumulative-update.md index 985a5dfff79ab..3eceb7712862b 100644 --- a/docs/framework/release-notes/2025/07-08-july-cumulative-update.md +++ b/docs/framework/release-notes/2025/07-08-july-cumulative-update.md @@ -3,7 +3,7 @@ title: July 2025 security and quality rollup description: Learn about the improvements in the .NET Framework July 2025 security and quality rollup. ms.date: 07/08/2025 --- -# July 2025 security and quality rollup +# .NET Framework July 2025 security and quality rollup _Released July 8, 2025_ diff --git a/docs/framework/release-notes/2025/08-26-august-cumulative-update-preview.md b/docs/framework/release-notes/2025/08-26-august-cumulative-update-preview.md index 372da75d034a7..82f98733c3330 100644 --- a/docs/framework/release-notes/2025/08-26-august-cumulative-update-preview.md +++ b/docs/framework/release-notes/2025/08-26-august-cumulative-update-preview.md @@ -3,7 +3,7 @@ title: August 2025 cumulative update preview description: Learn about the improvements in the .NET Framework August 2025 cumulative update preview. ms.date: 08/26/2025 --- -# August 2025 cumulative update preview +# .NET Framework August 2025 cumulative update preview _Released August 26, 2025_ _Update August 29, 2025 to include Windows 11, version 24H2_ diff --git a/docs/framework/release-notes/2025/09-09-september-cumulative-update.md b/docs/framework/release-notes/2025/09-09-september-cumulative-update.md index 1018ebc5caa33..7524fbd90ca29 100644 --- a/docs/framework/release-notes/2025/09-09-september-cumulative-update.md +++ b/docs/framework/release-notes/2025/09-09-september-cumulative-update.md @@ -3,7 +3,7 @@ title: September 2025 security and quality rollup description: Learn about the improvements in the .NET Framework September 2025 security and quality rollup. ms.date: 09/09/2025 --- -# September 2025 security and quality rollup +# .NET Framework September 2025 security and quality rollup _Released September 9, 2025_ diff --git a/docs/framework/release-notes/2025/10-14-october-cumulative-update.md b/docs/framework/release-notes/2025/10-14-october-cumulative-update.md index 87da53290dee6..8ab191b089ebb 100644 --- a/docs/framework/release-notes/2025/10-14-october-cumulative-update.md +++ b/docs/framework/release-notes/2025/10-14-october-cumulative-update.md @@ -3,7 +3,7 @@ title: October 2025 cumulative update description: Learn about the improvements in the .NET Framework October 2025 cumulative update. ms.date: 10/14/2025 --- -# October 2025 cumulative update +# .NET Framework October 2025 cumulative update _Released October 14, 2025_ _Updated November 10, 2025_ diff --git a/docs/framework/release-notes/2025/10-28-october-cumulative-update-preview.md b/docs/framework/release-notes/2025/10-28-october-cumulative-update-preview.md index ba9b2fcfe2573..c6c995601df64 100644 --- a/docs/framework/release-notes/2025/10-28-october-cumulative-update-preview.md +++ b/docs/framework/release-notes/2025/10-28-october-cumulative-update-preview.md @@ -3,7 +3,7 @@ title: October 2025 cumulative update preview description: Learn about the improvements in the .NET Framework October 2025 cumulative update preview. ms.date: 10/28/2025 --- -# October 2025 cumulative update preview +# .NET Framework October 2025 cumulative update preview _Released October 28, 2025_ diff --git a/docs/framework/release-notes/2026/01-29-january-cumulative-update-preview.md b/docs/framework/release-notes/2026/01-29-january-cumulative-update-preview.md index 62f290f96b70e..88cf2ce8103da 100644 --- a/docs/framework/release-notes/2026/01-29-january-cumulative-update-preview.md +++ b/docs/framework/release-notes/2026/01-29-january-cumulative-update-preview.md @@ -3,7 +3,7 @@ title: January 2026 cumulative update preview description: Learn about the improvements in the .NET Framework January 2026 cumulative update preview. ms.date: 01/29/2026 --- -# January 2026 cumulative update preview +# .NET Framework January 2026 cumulative update preview _Released January 29, 2026_ diff --git a/docs/framework/release-notes/2026/02-10-february-cumulative-update.md b/docs/framework/release-notes/2026/02-10-february-cumulative-update.md index b0a330afe7856..030d1dc73fa16 100644 --- a/docs/framework/release-notes/2026/02-10-february-cumulative-update.md +++ b/docs/framework/release-notes/2026/02-10-february-cumulative-update.md @@ -3,7 +3,7 @@ title: February 2026 cumulative update description: Learn about the improvements in the .NET Framework February 2026 cumulative update. ms.date: 02/10/2026 --- -# February 2026 cumulative update +# .NET Framework February 2026 cumulative update _Released February 10, 2026_ diff --git a/docs/framework/release-notes/2026/04-14-april-cumulative-update.md b/docs/framework/release-notes/2026/04-14-april-cumulative-update.md index 1175dd9d0f3ba..5e82a8aab9904 100644 --- a/docs/framework/release-notes/2026/04-14-april-cumulative-update.md +++ b/docs/framework/release-notes/2026/04-14-april-cumulative-update.md @@ -3,7 +3,7 @@ title: April 2026 cumulative update description: Learn about the improvements in the .NET Framework April 2026 cumulative update. ms.date: 04/28/2026 --- -# April 2026 cumulative update +# .NET Framework April 2026 cumulative update _Released April 14, 2026_ _Updated April 28, 2026, to include a known issue._ diff --git a/docs/framework/release-notes/2026/05-12-may-cumulative-update.md b/docs/framework/release-notes/2026/05-12-may-cumulative-update.md index e734fd7cfb4f4..4b5fc2b2feb05 100644 --- a/docs/framework/release-notes/2026/05-12-may-cumulative-update.md +++ b/docs/framework/release-notes/2026/05-12-may-cumulative-update.md @@ -3,7 +3,7 @@ title: May 2026 cumulative update description: Learn about the improvements in the .NET Framework May 2026 cumulative update. ms.date: 05/12/2026 --- -# May 2026 cumulative update +# .NET Framework May 2026 cumulative update _Released May 12, 2026_ diff --git a/docs/framework/release-notes/2026/05-26-may-cumulative-update-preview.md b/docs/framework/release-notes/2026/05-26-may-cumulative-update-preview.md index e93d8d7edab56..924d3b91fb7a0 100644 --- a/docs/framework/release-notes/2026/05-26-may-cumulative-update-preview.md +++ b/docs/framework/release-notes/2026/05-26-may-cumulative-update-preview.md @@ -3,7 +3,7 @@ title: May 2026 cumulative update preview description: Learn about the improvements in the .NET Framework May 2026 cumulative update preview. ms.date: 05/26/2026 --- -# May 2026 cumulative update preview +# .NET Framework May 2026 cumulative update preview _Released May 26, 2026_ diff --git a/docs/framework/release-notes/2026/07-14-july-cumulative-update.md b/docs/framework/release-notes/2026/07-14-july-cumulative-update.md index 378648c0d2c83..f1bc0a83323a4 100644 --- a/docs/framework/release-notes/2026/07-14-july-cumulative-update.md +++ b/docs/framework/release-notes/2026/07-14-july-cumulative-update.md @@ -3,7 +3,7 @@ title: July 2026 cumulative update description: Learn about the improvements in the .NET Framework July 2026 cumulative update. ms.date: 07/14/2026 --- -# July 2026 cumulative update +# .NET Framework July 2026 cumulative update _Released July 14, 2026_ diff --git a/docs/orleans/Directory.Build.props b/docs/orleans/Directory.Build.props index 56379750a2e76..0ea460721047a 100644 --- a/docs/orleans/Directory.Build.props +++ b/docs/orleans/Directory.Build.props @@ -17,7 +17,7 @@ - + diff --git a/docs/orleans/deployment/snippets/service-fabric/stateless/Orleans.ServiceFabric.Stateless.csproj b/docs/orleans/deployment/snippets/service-fabric/stateless/Orleans.ServiceFabric.Stateless.csproj index e0e2ce7594430..3cc4cbe4fb111 100644 --- a/docs/orleans/deployment/snippets/service-fabric/stateless/Orleans.ServiceFabric.Stateless.csproj +++ b/docs/orleans/deployment/snippets/service-fabric/stateless/Orleans.ServiceFabric.Stateless.csproj @@ -10,7 +10,7 @@ - + diff --git a/docs/orleans/host/snippets/aspire/ServiceDefaults/ServiceDefaults.csproj b/docs/orleans/host/snippets/aspire/ServiceDefaults/ServiceDefaults.csproj index 7243f55396099..76f55b3bedfb3 100644 --- a/docs/orleans/host/snippets/aspire/ServiceDefaults/ServiceDefaults.csproj +++ b/docs/orleans/host/snippets/aspire/ServiceDefaults/ServiceDefaults.csproj @@ -10,7 +10,7 @@ - + diff --git a/docs/orleans/streaming/snippets/broadcastchannel/BroadcastChannel.Silo/BroadcastChannel.Silo.csproj b/docs/orleans/streaming/snippets/broadcastchannel/BroadcastChannel.Silo/BroadcastChannel.Silo.csproj index c93535304ffe1..d4e2dd76dc0f7 100644 --- a/docs/orleans/streaming/snippets/broadcastchannel/BroadcastChannel.Silo/BroadcastChannel.Silo.csproj +++ b/docs/orleans/streaming/snippets/broadcastchannel/BroadcastChannel.Silo/BroadcastChannel.Silo.csproj @@ -5,7 +5,7 @@ - + diff --git a/docs/standard/native-interop/snippets/marshalling-data-with-platform-invoke/csharp/PInvokeLibManaged/NativeMethods.cs b/docs/standard/native-interop/snippets/marshalling-data-with-platform-invoke/csharp/PInvokeLibManaged/NativeMethods.cs index 95ad89611b78d..62856b31866d4 100644 --- a/docs/standard/native-interop/snippets/marshalling-data-with-platform-invoke/csharp/PInvokeLibManaged/NativeMethods.cs +++ b/docs/standard/native-interop/snippets/marshalling-data-with-platform-invoke/csharp/PInvokeLibManaged/NativeMethods.cs @@ -86,5 +86,11 @@ internal static extern int TestArrayOfStructs2( [DllImport("PinvokeLib.dll", CallingConvention = CallingConvention.Cdecl)] internal static extern void TestArrayInStruct(ref MyArrayStruct myStruct); + + [DllImport("PinvokeLib.dll", CallingConvention = CallingConvention.Cdecl)] + internal static extern unsafe void* CreateTestClass(); + + [DllImport("PinvokeLib.dll", CallingConvention = CallingConvention.Cdecl)] + internal static extern unsafe void DeleteTestClass(void* instance); } // diff --git a/docs/standard/native-interop/snippets/marshalling-data-with-platform-invoke/csharp/PInvokeLibManaged/PInvokeLibManaged.csproj b/docs/standard/native-interop/snippets/marshalling-data-with-platform-invoke/csharp/PInvokeLibManaged/PInvokeLibManaged.csproj index ed9781c223ab9..598db52879f65 100644 --- a/docs/standard/native-interop/snippets/marshalling-data-with-platform-invoke/csharp/PInvokeLibManaged/PInvokeLibManaged.csproj +++ b/docs/standard/native-interop/snippets/marshalling-data-with-platform-invoke/csharp/PInvokeLibManaged/PInvokeLibManaged.csproj @@ -5,6 +5,7 @@ net10.0 enable enable + true diff --git a/docs/standard/native-interop/snippets/marshalling-data-with-platform-invoke/vb/PInvokeLibManaged/NativeMethods.vb b/docs/standard/native-interop/snippets/marshalling-data-with-platform-invoke/vb/PInvokeLibManaged/NativeMethods.vb index bbccef564a151..3234efc5ef2be 100644 --- a/docs/standard/native-interop/snippets/marshalling-data-with-platform-invoke/vb/PInvokeLibManaged/NativeMethods.vb +++ b/docs/standard/native-interop/snippets/marshalling-data-with-platform-invoke/vb/PInvokeLibManaged/NativeMethods.vb @@ -90,5 +90,13 @@ Friend Class NativeMethods Friend Shared Sub TestArrayInStruct(ByRef myStruct As MyArrayStruct) End Sub + + + Friend Shared Function CreateTestClass() As IntPtr + End Function + + + Friend Shared Sub DeleteTestClass(ByVal instance As IntPtr) + End Sub End Class ' diff --git a/docs/standard/security/how-to-use-data-protection.md b/docs/standard/security/how-to-use-data-protection.md index 82d6a27053a4f..30a8d9c228cb1 100644 --- a/docs/standard/security/how-to-use-data-protection.md +++ b/docs/standard/security/how-to-use-data-protection.md @@ -1,7 +1,8 @@ --- -title: "How to: Use Data Protection" +title: "How to use data protection" description: Learn how to use data protection by accessing the data protection API (DPAPI) in .NET. -ms.date: 07/14/2020 +ms.date: 07/22/2026 +ai-usage: ai-assisted dev_langs: - "csharp" - "vb" @@ -17,16 +18,16 @@ helpviewer_keywords: - "data [.NET], encryption" ms.assetid: 606698b0-cb1a-42ca-beeb-0bea34205d20 --- -# How to: Use Data Protection +# How to use data protection > [!NOTE] > This article applies to Windows. > > For information about ASP.NET Core, see [ASP.NET Core Data Protection](/aspnet/core/security/data-protection/introduction). -.NET provides access to the data protection API (DPAPI), which allows you to encrypt data using information from the current user account or computer. When you use the DPAPI, you alleviate the difficult problem of explicitly generating and storing a cryptographic key. +.NET provides access to the data protection API (DPAPI), which lets you encrypt data using information from the current user account or computer. When you use the DPAPI, you avoid the difficult problem of explicitly generating and storing a cryptographic key. -Use the class to encrypt a copy of an array of bytes. You can specify that data encrypted by the current user account can be decrypted only by the same user account, or you can specify that data encrypted by the current user account can be decrypted by any account on the computer. See the enumeration for a detailed description of options. +Use the class to encrypt a copy of an array of bytes. You can specify that only the same user account can decrypt the data, or that any account on the computer can decrypt it. For a detailed description of options, see the enumeration. ## Encrypt data to a file or stream using data protection @@ -44,24 +45,32 @@ Use the class to encrypt a cop ## Example -The following code example demonstrates two forms of encryption and decryption. First, the code example encrypts and then decrypts an in-memory array of bytes. Next, the code example encrypts a copy of a byte array, saves it to a file, loads the data back from the file, and then decrypts the data. The example displays the original data, the encrypted data, and the decrypted data. +The following code example shows two forms of encryption and decryption. First, the code encrypts and then decrypts an in-memory array of bytes. Next, the code encrypts a copy of a byte array, saves it to a file, loads the data back from the file, and then decrypts the data. The example displays the original data, the encrypted data, and the decrypted data. -[!code-csharp[DPAPI-HowTO#1](../../../samples/snippets/csharp/VS_Snippets_CLR/DPAPI-HowTO/cs/sample.cs#1)] -[!code-vb[DPAPI-HowTO#1](../../../samples/snippets/visualbasic/VS_Snippets_CLR/DPAPI-HowTO/vb/sample.vb#1)] +> [!IMPORTANT] +> is only available for .NET Framework. is available on .NET and .NET Framework. -## Compiling the Code +### [.NET](#tab/net) -This example compiles and runs only when targeting .NET Framework and running on Windows. +This sample compiles and runs when you target .NET on Windows. To compile the sample, add the [`System.Security.Cryptography.ProtectedData`](https://www.nuget.org/packages/System.Security.Cryptography.ProtectedData/) NuGet package. -- Include a reference to `System.Security.dll`. +:::code language="csharp" source="./snippets/how-to-use-data-protection/net/csharp/sample.cs"::: +:::code language="vb" source="./snippets/how-to-use-data-protection/net/vb/sample.vb"::: -- Include the , , , and namespace. +### [.NET Framework](#tab/net-framework) + +This sample compiles and runs when you target .NET Framework on Windows. To compile the sample, add reference to the `System.Security.dll` library. + +:::code language="csharp" source="./snippets/how-to-use-data-protection/framework/csharp/sample.cs"::: +:::code language="vb" source="./snippets/how-to-use-data-protection/framework/vb/sample.vb"::: + +--- ## See also -- [Cryptography Model](cryptography-model.md) -- [Cryptographic Services](cryptographic-services.md) -- [Cross-Platform Cryptography](cross-platform-cryptography.md) +- [Cryptography model](cryptography-model.md) +- [Cryptographic services](cryptographic-services.md) +- [Cross-platform cryptography](cross-platform-cryptography.md) - - - [ASP.NET Core Data Protection](/aspnet/core/security/data-protection/introduction) diff --git a/docs/standard/security/snippets/how-to-use-data-protection/framework/csharp/DataProtectionSample.csproj b/docs/standard/security/snippets/how-to-use-data-protection/framework/csharp/DataProtectionSample.csproj new file mode 100644 index 0000000000000..1bebf6d9b6210 --- /dev/null +++ b/docs/standard/security/snippets/how-to-use-data-protection/framework/csharp/DataProtectionSample.csproj @@ -0,0 +1,42 @@ + + + + + Debug + AnyCPU + {9B14A2C4-4E4E-4A8E-9C3B-8F5F8D9C6A21} + Exe + DataProtectionSample + DataProtectionSample + v4.8 + 512 + true + + + AnyCPU + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + AnyCPU + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + + + + + + + diff --git a/samples/snippets/csharp/VS_Snippets_CLR/DPAPI-HowTO/cs/sample.cs b/docs/standard/security/snippets/how-to-use-data-protection/framework/csharp/sample.cs similarity index 88% rename from samples/snippets/csharp/VS_Snippets_CLR/DPAPI-HowTO/cs/sample.cs rename to docs/standard/security/snippets/how-to-use-data-protection/framework/csharp/sample.cs index 335f0103d116a..7f3d47a4acbb7 100644 --- a/samples/snippets/csharp/VS_Snippets_CLR/DPAPI-HowTO/cs/sample.cs +++ b/docs/standard/security/snippets/how-to-use-data-protection/framework/csharp/sample.cs @@ -1,14 +1,11 @@ -// -using System; +using System; using System.IO; using System.Text; using System.Security.Cryptography; public class MemoryProtectionSample { - public static void Main() => Run(); - - public static void Run() + public static void Main() { try { @@ -19,21 +16,21 @@ public static void Run() /////////////////////////////// // Create the original data to be encrypted (The data length should be a multiple of 16). - byte[] toEncrypt = UnicodeEncoding.ASCII.GetBytes("ThisIsSomeData16"); + byte[] toEncrypt = Encoding.ASCII.GetBytes("ThisIsSomeData16"); - Console.WriteLine($"Original data: {UnicodeEncoding.ASCII.GetString(toEncrypt)}"); + Console.WriteLine(value: $"Original data: {Encoding.ASCII.GetString(toEncrypt)}"); Console.WriteLine("Encrypting..."); // Encrypt the data in memory. EncryptInMemoryData(toEncrypt, MemoryProtectionScope.SameLogon); - Console.WriteLine($"Encrypted data: {UnicodeEncoding.ASCII.GetString(toEncrypt)}"); + Console.WriteLine($"Encrypted data: {Encoding.ASCII.GetString(toEncrypt)}"); Console.WriteLine("Decrypting..."); // Decrypt the data in memory. DecryptInMemoryData(toEncrypt, MemoryProtectionScope.SameLogon); - Console.WriteLine($"Decrypted data: {UnicodeEncoding.ASCII.GetString(toEncrypt)}"); + Console.WriteLine($"Decrypted data: {Encoding.ASCII.GetString(toEncrypt)}"); /////////////////////////////// // @@ -42,7 +39,7 @@ public static void Run() /////////////////////////////// // Create the original data to be encrypted - toEncrypt = UnicodeEncoding.ASCII.GetBytes("This is some data of any length."); + toEncrypt = Encoding.ASCII.GetBytes("This is some data of any length."); // Create a file. FileStream fStream = new FileStream("Data.dat", FileMode.OpenOrCreate); @@ -51,7 +48,7 @@ public static void Run() byte[] entropy = CreateRandomEntropy(); Console.WriteLine(); - Console.WriteLine($"Original data: {UnicodeEncoding.ASCII.GetString(toEncrypt)}"); + Console.WriteLine($"Original data: {Encoding.ASCII.GetString(toEncrypt)}"); Console.WriteLine("Encrypting and writing to disk..."); // Encrypt a copy of the data to the stream. @@ -69,7 +66,7 @@ public static void Run() fStream.Close(); - Console.WriteLine($"Decrypted data: {UnicodeEncoding.ASCII.GetString(decryptData)}"); + Console.WriteLine($"Decrypted data: {Encoding.ASCII.GetString(decryptData)}"); } catch (Exception e) { @@ -172,4 +169,3 @@ public static byte[] DecryptDataFromStream(byte[] Entropy, DataProtectionScope S return outBuffer; } } -// diff --git a/docs/standard/security/snippets/how-to-use-data-protection/framework/csharp/snippets.5000.json b/docs/standard/security/snippets/how-to-use-data-protection/framework/csharp/snippets.5000.json new file mode 100644 index 0000000000000..da9ebf8da2f9d --- /dev/null +++ b/docs/standard/security/snippets/how-to-use-data-protection/framework/csharp/snippets.5000.json @@ -0,0 +1,3 @@ +{ + "host": "visualstudio" +} diff --git a/docs/standard/security/snippets/how-to-use-data-protection/framework/vb/DataProtectionSample.vbproj b/docs/standard/security/snippets/how-to-use-data-protection/framework/vb/DataProtectionSample.vbproj new file mode 100644 index 0000000000000..c40d75bd4b768 --- /dev/null +++ b/docs/standard/security/snippets/how-to-use-data-protection/framework/vb/DataProtectionSample.vbproj @@ -0,0 +1,56 @@ + + + + + Debug + AnyCPU + {A4B12E1F-3C6D-4B25-9E5B-2E7D3A9F1B04} + Exe + DataProtectionSample + DataProtectionSample + v4.8 + Console + DataProtectionSample.MemoryProtectionSample + 512 + true + On + Binary + Off + On + + + AnyCPU + true + full + true + true + bin\Debug\ + DataProtectionSample.xml + 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022 + + + AnyCPU + pdbonly + false + true + true + bin\Release\ + DataProtectionSample.xml + 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022 + + + + + + + + + + + + + + + + + diff --git a/samples/snippets/visualbasic/VS_Snippets_CLR/DPAPI-HowTO/vb/sample.vb b/docs/standard/security/snippets/how-to-use-data-protection/framework/vb/sample.vb similarity index 80% rename from samples/snippets/visualbasic/VS_Snippets_CLR/DPAPI-HowTO/vb/sample.vb rename to docs/standard/security/snippets/how-to-use-data-protection/framework/vb/sample.vb index 1b2ea95b3e31c..e954812dcd77c 100644 --- a/samples/snippets/visualbasic/VS_Snippets_CLR/DPAPI-HowTO/vb/sample.vb +++ b/docs/standard/security/snippets/how-to-use-data-protection/framework/vb/sample.vb @@ -1,42 +1,31 @@ -' -Imports System.IO +Imports System.IO Imports System.Text Imports System.Security.Cryptography - - Public Module MemoryProtectionSample - Sub Main() - Run() - - End Sub - - - Sub Run() Try - '''''''''''''''''''''''''''''''''''' ' ' Memory Encryption - ProtectedMemory ' '''''''''''''''''''''''''''''''''''' ' Create the original data to be encrypted (The data length should be a multiple of 16). - Dim toEncrypt As Byte() = UnicodeEncoding.ASCII.GetBytes("ThisIsSomeData16") + Dim toEncrypt As Byte() = Encoding.ASCII.GetBytes("ThisIsSomeData16") - Console.WriteLine("Original data: " + UnicodeEncoding.ASCII.GetString(toEncrypt)) + Console.WriteLine("Original data: " + Encoding.ASCII.GetString(toEncrypt)) Console.WriteLine("Encrypting...") ' Encrypt the data in memory. EncryptInMemoryData(toEncrypt, MemoryProtectionScope.SameLogon) - Console.WriteLine("Encrypted data: " + UnicodeEncoding.ASCII.GetString(toEncrypt)) + Console.WriteLine("Encrypted data: " + Encoding.ASCII.GetString(toEncrypt)) Console.WriteLine("Decrypting...") ' Decrypt the data in memory. DecryptInMemoryData(toEncrypt, MemoryProtectionScope.SameLogon) - Console.WriteLine("Decrypted data: " + UnicodeEncoding.ASCII.GetString(toEncrypt)) + Console.WriteLine("Decrypted data: " + Encoding.ASCII.GetString(toEncrypt)) '''''''''''''''''''''''''''''''''''' @@ -45,7 +34,7 @@ Public Module MemoryProtectionSample ' '''''''''''''''''''''''''''''''''''' ' Create the original data to be encrypted - toEncrypt = UnicodeEncoding.ASCII.GetBytes("This is some data of any length.") + toEncrypt = Encoding.ASCII.GetBytes("This is some data of any length.") ' Create a file. Dim fStream As New FileStream("Data.dat", FileMode.OpenOrCreate) @@ -54,7 +43,7 @@ Public Module MemoryProtectionSample Dim entropy As Byte() = CreateRandomEntropy() Console.WriteLine() - Console.WriteLine("Original data: " + UnicodeEncoding.ASCII.GetString(toEncrypt)) + Console.WriteLine("Original data: " + Encoding.ASCII.GetString(toEncrypt)) Console.WriteLine("Encrypting and writing to disk...") ' Encrypt a copy of the data to the stream. @@ -72,8 +61,7 @@ Public Module MemoryProtectionSample fStream.Close() - Console.WriteLine("Decrypted data: " + UnicodeEncoding.ASCII.GetString(decryptData)) - + Console.WriteLine("Decrypted data: " + Encoding.ASCII.GetString(decryptData)) Catch e As Exception Console.WriteLine("ERROR: " + e.Message) @@ -81,9 +69,7 @@ Public Module MemoryProtectionSample End Sub - - - Sub EncryptInMemoryData(ByVal Buffer() As Byte, ByVal Scope As MemoryProtectionScope) + Sub EncryptInMemoryData(Buffer() As Byte, Scope As MemoryProtectionScope) If Buffer Is Nothing Then Throw New ArgumentNullException("Buffer") End If @@ -96,8 +82,7 @@ Public Module MemoryProtectionSample End Sub - - Sub DecryptInMemoryData(ByVal Buffer() As Byte, ByVal Scope As MemoryProtectionScope) + Sub DecryptInMemoryData(Buffer() As Byte, Scope As MemoryProtectionScope) If Buffer Is Nothing Then Throw New ArgumentNullException("Buffer") End If @@ -110,7 +95,6 @@ Public Module MemoryProtectionSample End Sub - Function CreateRandomEntropy() As Byte() ' Create a byte array to hold the random value. Dim entropy(15) As Byte @@ -126,9 +110,7 @@ Public Module MemoryProtectionSample End Function 'CreateRandomEntropy - - - Function EncryptDataToStream(ByVal Buffer() As Byte, ByVal Entropy() As Byte, ByVal Scope As DataProtectionScope, ByVal S As Stream) As Integer + Function EncryptDataToStream(Buffer() As Byte, Entropy() As Byte, Scope As DataProtectionScope, S As Stream) As Integer If Buffer Is Nothing Then Throw New ArgumentNullException("Buffer") End If @@ -161,8 +143,7 @@ Public Module MemoryProtectionSample End Function 'EncryptDataToStream - - Function DecryptDataFromStream(ByVal Entropy() As Byte, ByVal Scope As DataProtectionScope, ByVal S As Stream, ByVal Length As Integer) As Byte() + Function DecryptDataFromStream(Entropy() As Byte, Scope As DataProtectionScope, S As Stream, Length As Integer) As Byte() If S Is Nothing Then Throw New ArgumentNullException("S") End If @@ -176,7 +157,6 @@ Public Module MemoryProtectionSample Throw New ArgumentException("Entropy") End If - Dim inBuffer(Length - 1) As Byte Dim outBuffer() As Byte @@ -194,4 +174,3 @@ Public Module MemoryProtectionSample End Function 'DecryptDataFromStream End Module 'MemoryProtectionSample -' diff --git a/docs/standard/security/snippets/how-to-use-data-protection/framework/vb/snippets.5000.json b/docs/standard/security/snippets/how-to-use-data-protection/framework/vb/snippets.5000.json new file mode 100644 index 0000000000000..da9ebf8da2f9d --- /dev/null +++ b/docs/standard/security/snippets/how-to-use-data-protection/framework/vb/snippets.5000.json @@ -0,0 +1,3 @@ +{ + "host": "visualstudio" +} diff --git a/docs/standard/security/snippets/how-to-use-data-protection/net/csharp/DataProtectionSample.csproj b/docs/standard/security/snippets/how-to-use-data-protection/net/csharp/DataProtectionSample.csproj new file mode 100644 index 0000000000000..a7c0dff8bc269 --- /dev/null +++ b/docs/standard/security/snippets/how-to-use-data-protection/net/csharp/DataProtectionSample.csproj @@ -0,0 +1,14 @@ + + + + Exe + net10.0-windows + enable + enable + + + + + + + diff --git a/docs/standard/security/snippets/how-to-use-data-protection/net/csharp/sample.cs b/docs/standard/security/snippets/how-to-use-data-protection/net/csharp/sample.cs new file mode 100644 index 0000000000000..3d8a584dac688 --- /dev/null +++ b/docs/standard/security/snippets/how-to-use-data-protection/net/csharp/sample.cs @@ -0,0 +1,90 @@ +using System.Security.Cryptography; +using System.Text; + +try +{ + // Data Encryption - ProtectedData + + // Create the original data to be encrypted. + byte[] toEncrypt = Encoding.ASCII.GetBytes("This is some data of any length."); + + // Create some random entropy. + byte[] entropy = CreateRandomEntropy(); + + Console.WriteLine(); + Console.WriteLine($"Original data: {Encoding.ASCII.GetString(toEncrypt)}"); + Console.WriteLine("Encrypting and writing to disk..."); + + int bytesWritten; + + // Encrypt a copy of the data to the stream. + using (FileStream writeStream = new("Data.dat", FileMode.OpenOrCreate)) + { + bytesWritten = EncryptDataToStream(toEncrypt, entropy, DataProtectionScope.CurrentUser, writeStream); + } + + Console.WriteLine("Reading data from disk and decrypting..."); + + // Read from the stream and decrypt the data. + byte[] decryptData; + using (FileStream readStream = new("Data.dat", FileMode.Open)) + { + decryptData = DecryptDataFromStream(entropy, DataProtectionScope.CurrentUser, readStream, bytesWritten); + } + + Console.WriteLine($"Decrypted data: {Encoding.ASCII.GetString(decryptData)}"); +} +catch (Exception e) +{ + Console.WriteLine($"ERROR: {e.Message}"); +} + +static byte[] CreateRandomEntropy() +{ + // Create a byte array to hold the random value and fill it with a random value. + byte[] entropy = new byte[16]; + RandomNumberGenerator.Fill(entropy); + + return entropy; +} + +static int EncryptDataToStream(byte[] buffer, byte[] entropy, DataProtectionScope scope, Stream stream) +{ + ArgumentNullException.ThrowIfNull(buffer); + ArgumentOutOfRangeException.ThrowIfZero(buffer.Length, nameof(buffer)); + ArgumentNullException.ThrowIfNull(entropy); + ArgumentOutOfRangeException.ThrowIfZero(entropy.Length, nameof(entropy)); + ArgumentNullException.ThrowIfNull(stream); + + int length = 0; + + // Encrypt the data and store the result in a new byte array. The original data remains unchanged. + byte[] encryptedData = ProtectedData.Protect(buffer, entropy, scope); + + // Write the encrypted data to a stream. + if (stream.CanWrite) + { + stream.Write(encryptedData, 0, encryptedData.Length); + length = encryptedData.Length; + } + + // Return the length that was written to the stream. + return length; +} + +static byte[] DecryptDataFromStream(byte[] entropy, DataProtectionScope scope, Stream stream, int length) +{ + ArgumentNullException.ThrowIfNull(stream); + ArgumentOutOfRangeException.ThrowIfZero(length, nameof(length)); + ArgumentNullException.ThrowIfNull(entropy); + ArgumentOutOfRangeException.ThrowIfZero(entropy.Length, nameof(entropy)); + + if (!stream.CanRead) + throw new IOException("Could not read the stream."); + + byte[] inBuffer = new byte[length]; + stream.ReadExactly(inBuffer, 0, length); + + // Return the decrypted data. + return ProtectedData.Unprotect(inBuffer, entropy, scope); +} diff --git a/docs/standard/security/snippets/how-to-use-data-protection/net/vb/DataProtectionSample.vbproj b/docs/standard/security/snippets/how-to-use-data-protection/net/vb/DataProtectionSample.vbproj new file mode 100644 index 0000000000000..c43bb9e43aaa3 --- /dev/null +++ b/docs/standard/security/snippets/how-to-use-data-protection/net/vb/DataProtectionSample.vbproj @@ -0,0 +1,13 @@ + + + + Exe + DataProtectionSample + net10.0-windows + + + + + + + diff --git a/docs/standard/security/snippets/how-to-use-data-protection/net/vb/sample.vb b/docs/standard/security/snippets/how-to-use-data-protection/net/vb/sample.vb new file mode 100644 index 0000000000000..c3ceb8624e597 --- /dev/null +++ b/docs/standard/security/snippets/how-to-use-data-protection/net/vb/sample.vb @@ -0,0 +1,90 @@ +Imports System.IO +Imports System.Security.Cryptography +Imports System.Text + +Public Module DataProtectionSample + + Sub Main() + Try + ' Data Encryption - ProtectedData + + ' Create the original data to be encrypted. + Dim toEncrypt As Byte() = Encoding.ASCII.GetBytes("This is some data of any length.") + + ' Create some random entropy. + Dim entropy As Byte() = CreateRandomEntropy() + + Console.WriteLine() + Console.WriteLine($"Original data: {Encoding.ASCII.GetString(toEncrypt)}") + Console.WriteLine("Encrypting and writing to disk...") + + Dim bytesWritten As Integer + + ' Encrypt a copy of the data to the stream. + Using writeStream As New FileStream("Data.dat", FileMode.OpenOrCreate) + bytesWritten = EncryptDataToStream(toEncrypt, entropy, DataProtectionScope.CurrentUser, writeStream) + End Using + + Console.WriteLine("Reading data from disk and decrypting...") + + ' Read from the stream and decrypt the data. + Dim decryptData As Byte() + Using readStream As New FileStream("Data.dat", FileMode.Open) + decryptData = DecryptDataFromStream(entropy, DataProtectionScope.CurrentUser, readStream, bytesWritten) + End Using + + Console.WriteLine($"Decrypted data: {Encoding.ASCII.GetString(decryptData)}") + + Catch e As Exception + Console.WriteLine($"ERROR: {e.Message}") + End Try + End Sub + + Function CreateRandomEntropy() As Byte() + ' Create a byte array to hold the random value and fill it with a random value. + Dim entropy(15) As Byte + RandomNumberGenerator.Fill(entropy) + + Return entropy + End Function + + Function EncryptDataToStream(buffer As Byte(), entropy As Byte(), scope As DataProtectionScope, stream As Stream) As Integer + ArgumentNullException.ThrowIfNull(buffer) + ArgumentOutOfRangeException.ThrowIfZero(buffer.Length, NameOf(buffer)) + ArgumentNullException.ThrowIfNull(entropy) + ArgumentOutOfRangeException.ThrowIfZero(entropy.Length, NameOf(entropy)) + ArgumentNullException.ThrowIfNull(stream) + + Dim length As Integer = 0 + + ' Encrypt the data and store the result in a new byte array. The original data remains unchanged. + Dim encryptedData As Byte() = ProtectedData.Protect(buffer, entropy, scope) + + ' Write the encrypted data to a stream. + If stream.CanWrite Then + stream.Write(encryptedData, 0, encryptedData.Length) + length = encryptedData.Length + End If + + ' Return the length that was written to the stream. + Return length + End Function + + Function DecryptDataFromStream(entropy As Byte(), scope As DataProtectionScope, stream As Stream, length As Integer) As Byte() + ArgumentNullException.ThrowIfNull(stream) + ArgumentOutOfRangeException.ThrowIfZero(length, NameOf(length)) + ArgumentNullException.ThrowIfNull(entropy) + ArgumentOutOfRangeException.ThrowIfZero(entropy.Length, NameOf(entropy)) + + If Not stream.CanRead Then + Throw New IOException("Could not read the stream.") + End If + + Dim inBuffer(length - 1) As Byte + stream.ReadExactly(inBuffer, 0, length) + + ' Return the decrypted data. + Return ProtectedData.Unprotect(inBuffer, entropy, scope) + End Function + +End Module diff --git a/samples/snippets/csharp/VS_Snippets_CLR/DPAPI-HowTO/cs/sample.csproj b/samples/snippets/csharp/VS_Snippets_CLR/DPAPI-HowTO/cs/sample.csproj deleted file mode 100644 index 18b78dcf3f1a5..0000000000000 --- a/samples/snippets/csharp/VS_Snippets_CLR/DPAPI-HowTO/cs/sample.csproj +++ /dev/null @@ -1,12 +0,0 @@ - - - - Exe - net461 - - - - - - - \ No newline at end of file diff --git a/samples/snippets/standard/data/sqlite/AggregateFunctionSample/AggregateFunctionSample.csproj b/samples/snippets/standard/data/sqlite/AggregateFunctionSample/AggregateFunctionSample.csproj index 7d7c58f1cb436..d1cc7c09833c2 100644 --- a/samples/snippets/standard/data/sqlite/AggregateFunctionSample/AggregateFunctionSample.csproj +++ b/samples/snippets/standard/data/sqlite/AggregateFunctionSample/AggregateFunctionSample.csproj @@ -7,7 +7,7 @@ - + diff --git a/samples/snippets/standard/data/sqlite/AsyncSample/AsyncSample.csproj b/samples/snippets/standard/data/sqlite/AsyncSample/AsyncSample.csproj index 7d7c58f1cb436..d1cc7c09833c2 100644 --- a/samples/snippets/standard/data/sqlite/AsyncSample/AsyncSample.csproj +++ b/samples/snippets/standard/data/sqlite/AsyncSample/AsyncSample.csproj @@ -7,7 +7,7 @@ - + diff --git a/samples/snippets/standard/data/sqlite/BackupSample/BackupSample.csproj b/samples/snippets/standard/data/sqlite/BackupSample/BackupSample.csproj index 7d7c58f1cb436..d1cc7c09833c2 100644 --- a/samples/snippets/standard/data/sqlite/BackupSample/BackupSample.csproj +++ b/samples/snippets/standard/data/sqlite/BackupSample/BackupSample.csproj @@ -7,7 +7,7 @@ - + diff --git a/samples/snippets/standard/data/sqlite/BatchingSample/BatchingSample.csproj b/samples/snippets/standard/data/sqlite/BatchingSample/BatchingSample.csproj index 7d7c58f1cb436..d1cc7c09833c2 100644 --- a/samples/snippets/standard/data/sqlite/BatchingSample/BatchingSample.csproj +++ b/samples/snippets/standard/data/sqlite/BatchingSample/BatchingSample.csproj @@ -7,7 +7,7 @@ - + diff --git a/samples/snippets/standard/data/sqlite/BulkInsertSample/BulkInsertSample.csproj b/samples/snippets/standard/data/sqlite/BulkInsertSample/BulkInsertSample.csproj index 7d7c58f1cb436..d1cc7c09833c2 100644 --- a/samples/snippets/standard/data/sqlite/BulkInsertSample/BulkInsertSample.csproj +++ b/samples/snippets/standard/data/sqlite/BulkInsertSample/BulkInsertSample.csproj @@ -7,7 +7,7 @@ - + diff --git a/samples/snippets/standard/data/sqlite/CollationSample/CollationSample.csproj b/samples/snippets/standard/data/sqlite/CollationSample/CollationSample.csproj index 7d7c58f1cb436..d1cc7c09833c2 100644 --- a/samples/snippets/standard/data/sqlite/CollationSample/CollationSample.csproj +++ b/samples/snippets/standard/data/sqlite/CollationSample/CollationSample.csproj @@ -7,7 +7,7 @@ - + diff --git a/samples/snippets/standard/data/sqlite/DapperSample/DapperSample.csproj b/samples/snippets/standard/data/sqlite/DapperSample/DapperSample.csproj index 1eb56df80e775..d60e2d20753ad 100644 --- a/samples/snippets/standard/data/sqlite/DapperSample/DapperSample.csproj +++ b/samples/snippets/standard/data/sqlite/DapperSample/DapperSample.csproj @@ -8,7 +8,7 @@ - + diff --git a/samples/snippets/standard/data/sqlite/DateAndTimeSample/DateAndTimeSample.csproj b/samples/snippets/standard/data/sqlite/DateAndTimeSample/DateAndTimeSample.csproj index 7d7c58f1cb436..d1cc7c09833c2 100644 --- a/samples/snippets/standard/data/sqlite/DateAndTimeSample/DateAndTimeSample.csproj +++ b/samples/snippets/standard/data/sqlite/DateAndTimeSample/DateAndTimeSample.csproj @@ -7,7 +7,7 @@ - + diff --git a/samples/snippets/standard/data/sqlite/DeferredTransactionSample/DeferredTransactionSample.csproj b/samples/snippets/standard/data/sqlite/DeferredTransactionSample/DeferredTransactionSample.csproj index 7d7c58f1cb436..d1cc7c09833c2 100644 --- a/samples/snippets/standard/data/sqlite/DeferredTransactionSample/DeferredTransactionSample.csproj +++ b/samples/snippets/standard/data/sqlite/DeferredTransactionSample/DeferredTransactionSample.csproj @@ -7,7 +7,7 @@ - + diff --git a/samples/snippets/standard/data/sqlite/DirtyReadSample/DirtyReadSample.csproj b/samples/snippets/standard/data/sqlite/DirtyReadSample/DirtyReadSample.csproj index 7d7c58f1cb436..d1cc7c09833c2 100644 --- a/samples/snippets/standard/data/sqlite/DirtyReadSample/DirtyReadSample.csproj +++ b/samples/snippets/standard/data/sqlite/DirtyReadSample/DirtyReadSample.csproj @@ -7,7 +7,7 @@ - + diff --git a/samples/snippets/standard/data/sqlite/EncryptionSample/EncryptionSample.csproj b/samples/snippets/standard/data/sqlite/EncryptionSample/EncryptionSample.csproj index 7790320a30521..1d4a55d821c78 100644 --- a/samples/snippets/standard/data/sqlite/EncryptionSample/EncryptionSample.csproj +++ b/samples/snippets/standard/data/sqlite/EncryptionSample/EncryptionSample.csproj @@ -7,7 +7,7 @@ - + diff --git a/samples/snippets/standard/data/sqlite/ExtensionsSample/ExtensionsSample.csproj b/samples/snippets/standard/data/sqlite/ExtensionsSample/ExtensionsSample.csproj index 1d12ef76d9292..192296627b0f9 100644 --- a/samples/snippets/standard/data/sqlite/ExtensionsSample/ExtensionsSample.csproj +++ b/samples/snippets/standard/data/sqlite/ExtensionsSample/ExtensionsSample.csproj @@ -7,9 +7,9 @@ - + - + diff --git a/samples/snippets/standard/data/sqlite/HelloWorldSample/HelloWorldSample.csproj b/samples/snippets/standard/data/sqlite/HelloWorldSample/HelloWorldSample.csproj index 7d7c58f1cb436..d1cc7c09833c2 100644 --- a/samples/snippets/standard/data/sqlite/HelloWorldSample/HelloWorldSample.csproj +++ b/samples/snippets/standard/data/sqlite/HelloWorldSample/HelloWorldSample.csproj @@ -7,7 +7,7 @@ - + diff --git a/samples/snippets/standard/data/sqlite/InteropSample/InteropSample.csproj b/samples/snippets/standard/data/sqlite/InteropSample/InteropSample.csproj index 7d7c58f1cb436..d1cc7c09833c2 100644 --- a/samples/snippets/standard/data/sqlite/InteropSample/InteropSample.csproj +++ b/samples/snippets/standard/data/sqlite/InteropSample/InteropSample.csproj @@ -7,7 +7,7 @@ - + diff --git a/samples/snippets/standard/data/sqlite/RegularExpressionSample/RegularExpressionSample.csproj b/samples/snippets/standard/data/sqlite/RegularExpressionSample/RegularExpressionSample.csproj index 7d7c58f1cb436..d1cc7c09833c2 100644 --- a/samples/snippets/standard/data/sqlite/RegularExpressionSample/RegularExpressionSample.csproj +++ b/samples/snippets/standard/data/sqlite/RegularExpressionSample/RegularExpressionSample.csproj @@ -7,7 +7,7 @@ - + diff --git a/samples/snippets/standard/data/sqlite/ResultMetadataSample/ResultMetadataSample.csproj b/samples/snippets/standard/data/sqlite/ResultMetadataSample/ResultMetadataSample.csproj index 7d7c58f1cb436..d1cc7c09833c2 100644 --- a/samples/snippets/standard/data/sqlite/ResultMetadataSample/ResultMetadataSample.csproj +++ b/samples/snippets/standard/data/sqlite/ResultMetadataSample/ResultMetadataSample.csproj @@ -7,7 +7,7 @@ - + diff --git a/samples/snippets/standard/data/sqlite/SavepointSample/SavepointSample.csproj b/samples/snippets/standard/data/sqlite/SavepointSample/SavepointSample.csproj index 7d7c58f1cb436..d1cc7c09833c2 100644 --- a/samples/snippets/standard/data/sqlite/SavepointSample/SavepointSample.csproj +++ b/samples/snippets/standard/data/sqlite/SavepointSample/SavepointSample.csproj @@ -7,7 +7,7 @@ - + diff --git a/samples/snippets/standard/data/sqlite/ScalarFunctionSample/ScalarFunctionSample.csproj b/samples/snippets/standard/data/sqlite/ScalarFunctionSample/ScalarFunctionSample.csproj index 7d7c58f1cb436..d1cc7c09833c2 100644 --- a/samples/snippets/standard/data/sqlite/ScalarFunctionSample/ScalarFunctionSample.csproj +++ b/samples/snippets/standard/data/sqlite/ScalarFunctionSample/ScalarFunctionSample.csproj @@ -7,7 +7,7 @@ - + diff --git a/samples/snippets/standard/data/sqlite/SqliteProviderSample/SqliteProviderSample.csproj b/samples/snippets/standard/data/sqlite/SqliteProviderSample/SqliteProviderSample.csproj index 826f1797825ad..02cf69613721f 100644 --- a/samples/snippets/standard/data/sqlite/SqliteProviderSample/SqliteProviderSample.csproj +++ b/samples/snippets/standard/data/sqlite/SqliteProviderSample/SqliteProviderSample.csproj @@ -7,7 +7,7 @@ - + diff --git a/samples/snippets/standard/data/sqlite/StreamingSample/StreamingSample.csproj b/samples/snippets/standard/data/sqlite/StreamingSample/StreamingSample.csproj index 19feeca42140a..9cae31648a533 100644 --- a/samples/snippets/standard/data/sqlite/StreamingSample/StreamingSample.csproj +++ b/samples/snippets/standard/data/sqlite/StreamingSample/StreamingSample.csproj @@ -7,7 +7,7 @@ - + diff --git a/samples/snippets/standard/data/sqlite/SystemLibrarySample/SystemLibrarySample.csproj b/samples/snippets/standard/data/sqlite/SystemLibrarySample/SystemLibrarySample.csproj index 8a6ba908b4140..1e838c4e5d739 100644 --- a/samples/snippets/standard/data/sqlite/SystemLibrarySample/SystemLibrarySample.csproj +++ b/samples/snippets/standard/data/sqlite/SystemLibrarySample/SystemLibrarySample.csproj @@ -7,7 +7,7 @@ - +