Skip to content
Merged
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
62 changes: 17 additions & 45 deletions xml/System.Net/Authorization.xml
Original file line number Diff line number Diff line change
Expand Up @@ -49,16 +49,7 @@
</Attributes>
<Docs>
<summary>Contains an authentication message for an Internet server.</summary>
<remarks>
<format type="text/markdown"><![CDATA[

## Remarks
The <xref:System.Net.AuthenticationManager> returns an instance of the <xref:System.Net.Authorization> class that contains an authentication message. This message is sent to the Internet server to indicate that the client (such as <xref:System.Net.WebRequest> or one of its descendants) is authorized to access the server.

The <xref:System.Net.Authorization> instance is created by the authentication module that the <xref:System.Net.AuthenticationManager> designates to handle the request.

]]></format>
</remarks>
<remarks>To be added.</remarks>
<altmember cref="T:System.Net.IAuthenticationModule" />
</Docs>
<Members>
Expand Down Expand Up @@ -115,13 +106,11 @@
<format type="text/markdown"><![CDATA[

## Remarks
The <xref:System.Net.Authorization> instance is created with the <xref:System.Net.Authorization.Message%2A> property set to `token` and the <xref:System.Net.Authorization.Complete%2A> property set to `true`.


The <xref:System.Net.Authorization> instance is created with the <xref:System.Net.Authorization.Message> property set to `token` and the <xref:System.Net.Authorization.Complete> property set to `true`.

## Examples
The following code example shows how to create an <xref:System.Net.Authorization> object. For a complete example, refer to the <xref:System.Net.AuthenticationManager> class.
The following code example shows how to create an <xref:System.Net.Authorization> object.

:::code language="csharp" source="~/snippets/csharp/System.Net/AuthenticationManager/Overview/custombasicauthentication.cs" id="Snippet3":::
:::code language="vb" source="~/snippets/visualbasic/System.Net/AuthenticationManager/Overview/custombasicauthentication.vb" id="Snippet3":::

Expand Down Expand Up @@ -174,9 +163,7 @@
<format type="text/markdown"><![CDATA[

## Remarks
The <xref:System.Net.Authorization> instance is created with the <xref:System.Net.Authorization.Message%2A> property set to `token` and the <xref:System.Net.Authorization.Complete%2A> property set to `finished`.


The <xref:System.Net.Authorization> instance is created with the <xref:System.Net.Authorization.Message> property set to `token` and the <xref:System.Net.Authorization.Complete> property set to `finished`.

## Examples
The following code example creates a new instance of the <xref:System.Net.Authorization> class with the specified authorization message and completion status.
Expand Down Expand Up @@ -299,12 +286,10 @@
<format type="text/markdown"><![CDATA[

## Remarks
The <xref:System.Net.Authorization.Complete%2A> property is set to `true` when the authentication process between the client and the server is finished. Some authentication modules, such as the Kerberos module, use multiple round trips between the client and server to complete the authentication process. To keep the <xref:System.Net.WebRequest> or descendant that initiated the authentication process from interrupting while authorization is taking place, the authentication module sets the <xref:System.Net.Authorization.Complete%2A> property to `false`.


The <xref:System.Net.Authorization.Complete> property is set to `true` when the authentication process between the client and the server is finished. Some authentication modules, such as the Kerberos module, use multiple round trips between the client and server to complete the authentication process. To keep the <xref:System.Net.WebRequest> or descendant that initiated the authentication process from interrupting while authorization is taking place, the authentication module sets the <xref:System.Net.Authorization.Complete> property to `false`.

## Examples
The following code example uses the <xref:System.Net.Authorization.Complete%2A> property to get the completion status of the authorization. For a complete example, refer to the <xref:System.Net.AuthenticationManager> class.
The following code example uses the <xref:System.Net.Authorization.Complete> property to get the completion status of the authorization.

:::code language="csharp" source="~/snippets/csharp/System.Net/AuthenticationManager/Overview/custombasicauthentication.cs" id="Snippet5":::
:::code language="vb" source="~/snippets/visualbasic/System.Net/AuthenticationManager/Overview/custombasicauthentication.vb" id="Snippet5":::
Expand Down Expand Up @@ -363,12 +348,10 @@
<format type="text/markdown"><![CDATA[

## Remarks
The <xref:System.Net.Authorization.ConnectionGroupId%2A> property is a unique string that associates a connection with a specific authenticating entity. For example, the NTLM authorization module ties the authentication credential information to a specific connection to prevent invalid reuse of the connection.


The <xref:System.Net.Authorization.ConnectionGroupId> property is a unique string that associates a connection with a specific authenticating entity. For example, the NTLM authorization module ties the authentication credential information to a specific connection to prevent invalid reuse of the connection.

## Examples
The following code example uses the <xref:System.Net.Authorization.ConnectionGroupId%2A> property to get the group identifier returned by the server. For a complete example, refer to the <xref:System.Net.AuthenticationManager> class.
The following code example uses the <xref:System.Net.Authorization.ConnectionGroupId> property to get the group identifier returned by the server.

:::code language="csharp" source="~/snippets/csharp/System.Net/AuthenticationManager/Overview/custombasicauthentication.cs" id="Snippet5":::
:::code language="vb" source="~/snippets/visualbasic/System.Net/AuthenticationManager/Overview/custombasicauthentication.vb" id="Snippet5":::
Expand Down Expand Up @@ -426,14 +409,12 @@
<format type="text/markdown"><![CDATA[

## Remarks
The <xref:System.Net.Authorization.Message%2A> property contains the authorization string that the client will return to the server when accessing protected resources. The actual contents of the message are defined by the authentication type the client and server are using. Basic HTTP authentication, for example, uses a different message than Kerberos authentication.

When an authentication module supports preauthentication, the <xref:System.Net.Authorization.Message%2A> property is sent with the initial request.

The <xref:System.Net.Authorization.Message> property contains the authorization string that the client will return to the server when accessing protected resources. The actual contents of the message are defined by the authentication type the client and server are using. Basic HTTP authentication, for example, uses a different message than Kerberos authentication.

When an authentication module supports preauthentication, the <xref:System.Net.Authorization.Message> property is sent with the initial request.

## Examples
The following code example uses the <xref:System.Net.Authorization.Message%2A> property to get the message returned to the server in response to an authentication challenge. For a complete example, refer to the <xref:System.Net.AuthenticationManager> class.
The following code example uses the <xref:System.Net.Authorization.Message> property to get the message returned to the server in response to an authentication challenge.

:::code language="csharp" source="~/snippets/csharp/System.Net/AuthenticationManager/Overview/custombasicauthentication.cs" id="Snippet5":::
:::code language="vb" source="~/snippets/visualbasic/System.Net/AuthenticationManager/Overview/custombasicauthentication.vb" id="Snippet5":::
Expand Down Expand Up @@ -484,17 +465,10 @@
<ReturnType>System.Boolean</ReturnType>
</ReturnValue>
<Docs>
<summary>Gets or sets a <see cref="T:System.Boolean" /> value that indicates whether mutual authentication occurred.</summary>
<summary>Gets or sets a value that indicates whether mutual authentication occurred.</summary>
<value>
<see langword="true" /> if both client and server were authenticated; otherwise, <see langword="false" />.</value>
<remarks>
<format type="text/markdown"><![CDATA[

## Remarks
This property returns `false` if the authentication has not completed.

]]></format>
</remarks>
<see langword="true" /> if both client and server were authenticated; <see langword="false" /> if client or server weren't authenticated or if authentication hasn't completed.</value>
<remarks>To be added.</remarks>
</Docs>
</Member>
<Member MemberName="ProtectionRealm">
Expand Down Expand Up @@ -550,12 +524,10 @@
<format type="text/markdown"><![CDATA[

## Remarks
The <xref:System.Net.Authorization.ProtectionRealm%2A> property contains a list of URI prefixes that the <xref:System.Net.Authorization.Message%2A> property can be used to authenticate. <xref:System.Net.WebRequest> and its descendants compare a URI to this list to determine if the <xref:System.Net.Authorization> is valid for a particular URI.


The <xref:System.Net.Authorization.ProtectionRealm> property contains a list of URI prefixes that the <xref:System.Net.Authorization.Message> property can be used to authenticate. <xref:System.Net.WebRequest> and its descendants compare a URI to this list to determine if the <xref:System.Net.Authorization> is valid for a particular URI.

## Examples
The following code example gets or sets the prefix for URIs that can be authenticated with the <xref:System.Net.Authorization.Message%2A> property.
The following code example gets or sets the prefix for URIs that can be authenticated with the <xref:System.Net.Authorization.Message> property.

:::code language="csharp" source="~/snippets/csharp/System.Net/Authorization/.ctor/authorization_protectionrealm.cs" id="Snippet1":::
:::code language="vb" source="~/snippets/visualbasic/System.Net/Authorization/.ctor/authorization_protectionrealm.vb" id="Snippet1":::
Expand Down
Loading