Property PreAuthenticateBehavior
PreAuthenticateBehavior
Gets or sets the behavior for setting the Authorization header.
Declaration
public PreAuthenticateBehavior PreAuthenticateBehavior { get; set; }
Property Value
Type | Description |
---|---|
PreAuthenticateBehavior | The behavior for setting the Authorization header. |
Remarks
By default, .NET will not send credentials via the Authorization header until it receives a 401 WWW-Authenticate Basic response from the server, even if credentials have already been specified. This results in at least two requests being sent for each endpoint. This property allows you to change this behavior for this credential.
Applies to
Platforms and versions
Target | Versions |
---|---|
.NET Standard 2.0 | 100.10 - 200.6 |
.NET | 100.13 - 200.6 |
.NET Windows | 100.13 - 200.6 |
.NET Android | 200.0 - 200.6 |
.NET iOS | 200.0 - 200.6 |
.NET Framework | 100.10 - 200.6 |
Xamarin.Android | 100.10 - 100.15 |
Xamarin.iOS | 100.10 - 100.15 |
UWP | 100.10 - 200.6 |