Skip to content

Commit d3c623e

Browse files
authored
Merge branch 'main' into gewarren-patch-2
2 parents 031294a + a6a6ed7 commit d3c623e

File tree

2,593 files changed

+281133
-282428
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

2,593 files changed

+281133
-282428
lines changed

.github/copilot-instructions.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
Code comments should end with a period.
2+
3+
When you add a code snippet to the XML remarks of an API, add the code as a separate code file (.cs file) and not as an inline (```) code block. Also add a .csproj file to compile the code if one doesn't already exist in the snippet folder.
4+
5+
Don't use the word "may". Use "might" to indicate possibility or "can" to indicate permission.
6+
7+
There should always be a comma before a clause that begins with "which".
8+
9+
Use a conversational tone with contractions.
10+
11+
Be concise.
12+
13+
Break up long sentences.
14+
15+
Use the present tense for instructions and descriptions. For example, "The method returns a value" instead of "The method will return a value."
16+
17+
Use the Oxford comma in lists of three or more items.

.github/policies/mention-owners.yml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -359,7 +359,6 @@ configuration:
359359
- mentionUsers:
360360
mentionees:
361361
- roji
362-
- ajcvickers
363362
replyTemplate: >-
364363
Tagging subscribers to this area: ${mentionees}
365364
assignMentionees: False
@@ -370,7 +369,6 @@ configuration:
370369
- mentionUsers:
371370
mentionees:
372371
- roji
373-
- ajcvickers
374372
replyTemplate: >-
375373
Tagging subscribers to this area: ${mentionees}
376374
assignMentionees: False
@@ -381,7 +379,6 @@ configuration:
381379
- mentionUsers:
382380
mentionees:
383381
- roji
384-
- ajcvickers
385382
replyTemplate: >-
386383
Tagging subscribers to this area: ${mentionees}
387384
assignMentionees: False
@@ -402,7 +399,7 @@ configuration:
402399
then:
403400
- mentionUsers:
404401
mentionees:
405-
- ajcvickers
402+
- dotnet/area-system-componentmodel-dataannotations
406403
replyTemplate: >-
407404
Tagging subscribers to this area: ${mentionees}
408405
assignMentionees: False

snippets/csharp/System.Globalization/CultureInfo/DisplayName/getcultures.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@ CULTURE ISO ISO WIN DISPLAYNAME ENGLISHNAME
3232
ar ar ara ARA Arabic Arabic
3333
bg bg bul BGR Bulgarian Bulgarian
3434
ca ca cat CAT Catalan Catalan
35-
zh-Hans zh zho CHS Chinese (Simplified) Chinese (Simplified)
3635
cs cs ces CSY Czech Czech
3736
da da dan DAN Danish Danish
3837
de de deu DEU German German
@@ -41,9 +40,10 @@ en en eng ENU English English
4140
es es spa ESP Spanish Spanish
4241
fi fi fin FIN Finnish Finnish
4342
zh zh zho CHS Chinese Chinese
44-
zh-Hant zh zho CHT Chinese (Traditional) Chinese (Traditional)
45-
zh-CHS zh zho CHS Chinese (Simplified) Legacy Chinese (Simplified) Legacy
46-
zh-CHT zh zho CHT Chinese (Traditional) Legacy Chinese (Traditional) Legacy
43+
zh-Hans zh zho CHS Chinese (Simplified) Chinese (Simplified)
44+
zh-Hant zh zho ZHH Chinese (Traditional) Chinese (Traditional)
45+
46+
Note: zh-Hant returns ZHH when using ICU (default). When NLS mode is enabled, it returns CHT.
4747
4848
*/
4949
// </snippet1>
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
<Project Sdk="Microsoft.NET.Sdk">
2+
3+
<PropertyGroup>
4+
<OutputType>Library</OutputType>
5+
<TargetFramework>net9.0</TargetFramework>
6+
</PropertyGroup>
7+
8+
<ItemGroup>
9+
<PackageReference Include="System.Net.Http.WinHttpHandler" Version="9.0.6" />
10+
</ItemGroup>
11+
12+
</Project>
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
using System;
2+
using System.Net;
3+
using System.Net.Http;
4+
using System.Net.Security;
5+
6+
class WinHttpHandler_SecureExample
7+
{
8+
static void Main()
9+
{
10+
if (!OperatingSystem.IsWindows())
11+
{
12+
Console.WriteLine("This example requires Windows.");
13+
return;
14+
}
15+
// <Snippet1>
16+
var handler = new WinHttpHandler();
17+
handler.ServerCertificateValidationCallback = (httpRequestMessage, certificate, chain, sslPolicyErrors) =>
18+
{
19+
if (sslPolicyErrors == SslPolicyErrors.None)
20+
{
21+
// TODO: Implement additional custom certificate validation logic here.
22+
return true;
23+
}
24+
// Do not allow this client to communicate with unauthenticated servers.
25+
return false;
26+
};
27+
// </Snippet1>
28+
}
29+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
using System;
2+
using System.Security.Cryptography.X509Certificates;
3+
4+
public class ChainElementsOrdering
5+
{
6+
public static void DemonstrateChainElementsOrdering(X509Certificate2 certificate)
7+
{
8+
//<SNIPPET6>
9+
using var chain = new X509Chain();
10+
chain.Build(certificate);
11+
12+
// chain.ChainElements[0] is the leaf (end-entity) certificate
13+
// chain.ChainElements[^1] is the root (trust anchor) certificate
14+
15+
Console.WriteLine("Certificate chain from leaf to root:");
16+
for (int i = 0; i < chain.ChainElements.Count; i++)
17+
{
18+
var cert = chain.ChainElements[i].Certificate;
19+
var role = i == 0 ? "Leaf" :
20+
i == chain.ChainElements.Count - 1 ? "Root" : "Intermediate";
21+
Console.WriteLine($"[{i}] {role}: {cert.Subject}");
22+
}
23+
//</SNIPPET6>
24+
}
25+
}

snippets/csharp/System.Windows/DependencyProperty/DefaultMetadata/SDKSampleLibrary/Class1.cs

Lines changed: 0 additions & 90 deletions
This file was deleted.

snippets/csharp/System.Windows/DependencyProperty/DefaultMetadata/SDKSampleLibrary/SDKSampleLibrary.csproj

Lines changed: 0 additions & 14 deletions
This file was deleted.

snippets/csharp/System.Windows/DependencyProperty/DefaultMetadata/XAMLAPP.sln

Lines changed: 0 additions & 41 deletions
This file was deleted.

snippets/csharp/System.Windows/DependencyProperty/DefaultMetadata/XamlApp/XAMLAPP.csproj

Lines changed: 0 additions & 46 deletions
This file was deleted.

0 commit comments

Comments
 (0)