Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/csharp/pattern-matching.md
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ end with a `break`, `return`, or `goto`.

> [!NOTE]
> The `goto` statements to jump to another label are valid only
> for the constant pattern, the classic switch statement.
> for the constant pattern (the classic switch statement).

There are important new rules governing the `switch` statement. The restrictions
on the type of the variable in the `switch` expression have been removed.
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
177 changes: 177 additions & 0 deletions docs/csharp/roslyn-sdk/get-started/syntax-transformation.md

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions docs/csharp/roslyn-sdk/toc.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@
## Quick Starts
### [Syntax analysis](get-started/syntax-analysis.md)
### [Semantic analysis](get-started/semantic-analysis.md)
### [Syntax Transformation](get-started/syntax-transformation.md)


<!-- Taken from https://github.com/dotnet/roslyn/wiki/Samples-and-Walkthroughs -->
<!--
### Get started with semantic analysis
### Get started with Syntax transformation
### Get started writing custom analyzers and code fixes

<!--
Expand Down
14 changes: 7 additions & 7 deletions docs/framework/wcf/samples/x-509-certificate-validator.md
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ This sample demonstrates how to implement a custom X.509 Certificate Validator.

The client implementation sets the client certificate to use.

```
```csharp
// Create a client with Certificate endpoint configuration
CalculatorClient client = new CalculatorClient("Certificate");
try
Expand Down Expand Up @@ -194,7 +194,7 @@ catch (Exception e)

This sample uses a custom X509CertificateValidator to validate certificates. The sample implements CustomX509CertificateValidator, derived from <xref:System.IdentityModel.Selectors.X509CertificateValidator>. See documentation about <xref:System.IdentityModel.Selectors.X509CertificateValidator> for more information. This particular custom validator sample implements the Validate method to accept any X.509 certificate that is self-issued as shown in the following code.

```
```csharp
public class CustomX509CertificateValidator : X509CertificateValidator
{
public override void Validate ( X509Certificate2 certificate )
Expand All @@ -208,7 +208,7 @@ public class CustomX509CertificateValidator : X509CertificateValidator

Once the validator is implemented in service code, the service host must be informed about the validator instance to use. This is done using the following code.

```
```csharp
serviceHost.Credentials.ClientCertificate.Authentication.CertificateValidationMode = X509CertificateValidationMode.Custom;
serviceHost.Credentials.ClientCertificate.Authentication.CustomCertificateValidator = new CustomX509CertificateValidator();
```
Expand Down Expand Up @@ -252,7 +252,7 @@ serviceHost.Credentials.ClientCertificate.Authentication.CustomCertificateValida

The following lines from the Setup.bat batch file create the server certificate to be used. The %SERVER_NAME% variable specifies the server name. Change this variable to specify your own server name. The default value is localhost.

```
```bash
echo ************
echo Server cert setup starting
echo %SERVER_NAME%
Expand All @@ -266,7 +266,7 @@ serviceHost.Credentials.ClientCertificate.Authentication.CustomCertificateValida

The following lines in the Setup.bat batch file copy the server certificate into the client trusted people store. This step is required since certificates generated by Makecert.exe are not implicitly trusted by the client system. If you already have a certificate that is rooted in a client trusted root certificate—for example, a Microsoft issued certificate—this step of populating the client certificate store with the server certificate is not required.

```
```bash
certmgr.exe -add -r LocalMachine -s My -c -n %SERVER_NAME% -r CurrentUser -s TrustedPeople
```

Expand All @@ -276,7 +276,7 @@ serviceHost.Credentials.ClientCertificate.Authentication.CustomCertificateValida

The certificate is stored in My (Personal) store under the CurrentUser store location.

```
```bash
echo ************
echo Client cert setup starting
echo %USER_NAME%
Expand All @@ -290,7 +290,7 @@ serviceHost.Credentials.ClientCertificate.Authentication.CustomCertificateValida

The following lines in the Setup.bat batch file copy the client certificate into the trusted people store. This step is required because certificates generated by Makecert.exe are not implicitly trusted by the server system. If you already have a certificate that is rooted in a trusted root certificate—for example, a Microsoft issued certificate—this step of populating the server certificate store with the client certificate is not required.

```
```bash
certmgr.exe -add -r CurrentUser -s My -c -n %USER_NAME% -r LocalMachine -s TrustedPeople
```

Expand Down
Loading