<PackageReference Include="System.Net.Http.WinHttpHandler" Version="10.0.9" />

System.Net.Http.WinHttpHandler

Handles messages based on the WinHTTP interface of Windows. This class is intended for use in server environments.

Gets or sets the type of decompression method used by the handler for automatic decompression of the HTTP content response.

public bool AutomaticRedirection { get; set; }

Gets or sets a value that indicates whether the handler should follow HTTP redirection responses.

public bool CheckCertificateRevocationList { get; set; }

Gets or sets a value that indicates whether to check the revocation list of certificates during SSL certificate validation.

Gets or sets a value that indicates if the certificate is automatically picked from the certificate store or if the caller is allowed to pass in a specific client certificate.

Gets a collection of client authentication SSL certificates that are used for client authentication by the handler if the ClientCertificateOption property is set to Manual.

public CookieContainer CookieContainer { get; set; }

Gets or sets the managed cookie container object. This property is only used when the CookieUsePolicy property is set to UseSpecifiedCookieContainer. Otherwise, the SendAsync method will throw an exception.

public CookieUsePolicy CookieUsePolicy { get; set; }

Gets or sets a value that indicates how cookies should be managed and used. Developers can choose to ignore cookies, allow the handler to automatically manage them or manually handle them using a CookieContainer object.

When the default (system) proxy is used, gets or sets the credentials used to submit to the default proxy server for authentication.

public bool EnableMultipleHttp2Connections { get; set; }

Gets or sets a value that indicates whether additional HTTP/2 connections can be established to the same server when the maximum number of concurrent streams is reached on all existing connections.

public int MaxAutomaticRedirections { get; set; }

Gets or sets the maximum number of allowed HTTP redirects.

public int MaxConnectionsPerServer { get; set; }

Gets or sets the maximum number of TCP connections allowed to a single server.

public int MaxResponseDrainSize { get; set; }

Gets or sets the maximum amount of data that can be drained from responses in bytes.

public int MaxResponseHeadersLength { get; set; }

Gets or sets the maximum length, in kilobytes (1024 bytes), of the response headers.

public bool PreAuthenticate { get; set; }

Gets or sets a value that indicates whether the handler sends an Authorization header with the request.

public IDictionary<string, object> Properties { get; }

Gets a writable dictionary (that is, a map) of custom properties for the HttpClient requests. The dictionary is initialized empty; you can insert and query key-value pairs for your custom handlers and special processing.

public IWebProxy Proxy { get; set; }

Gets or sets the custom proxy when the WindowsProxyUsePolicy property is set to use a custom proxy.

public TimeSpan ReceiveDataTimeout { get; set; }

Gets or sets the timeout for receiving the data portion of a response from the server.

public TimeSpan ReceiveHeadersTimeout { get; set; }

Gets or sets the timeout for receiving the headers of a response from the server.

public TimeSpan SendTimeout { get; set; }

Gets or sets the timeout for sending a request.

Gets or sets a callback method to validate the server certificate. This callback is part of the SSL handshake.

public ICredentials ServerCredentials { get; set; }

Gets or sets the credentials to be used by the client to authenticate to the server.

public SslProtocols SslProtocols { get; set; }

Gets or sets the collection of TLS/SSL protocols supported by the client.

public bool TcpKeepAliveEnabled { get; set; }

Gets or sets a value indicating whether TCP keep-alive is enabled.

public TimeSpan TcpKeepAliveInterval { get; set; }

Gets or sets the TCP keep-alive interval.

public TimeSpan TcpKeepAliveTime { get; set; }

Gets or sets the TCP keep-alive timeout.

Gets or sets the proxy setting. This property can be set to disable the proxy, use a custom proxy, or use the proxy settings of WinHTTP or WinInet on the machine.

public WinHttpHandler()

Initializes a new instance of the WinHttpHandler class.