KestrelServerOptionsHttpsExtensions Class¶
- Namespace
Microsoft.AspNetCore.Hosting
- Assemblies
- Microsoft.AspNetCore.Server.Kestrel.Https
Syntax¶
public class KestrelServerOptionsHttpsExtensions
-
class
Microsoft.AspNetCore.Hosting.
KestrelServerOptionsHttpsExtensions
Methods¶
-
UseHttps
(Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions, Microsoft.AspNetCore.Server.Kestrel.Https.HttpsConnectionFilterOptions)¶ Configure Kestrel to use HTTPS.
Arguments: - options (Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions) – The Microsoft.AspNetCore.Server.KestrelServerOptions to configure.
- httpsOptions (Microsoft.AspNetCore.Server.Kestrel.Https.HttpsConnectionFilterOptions) – Options to configure HTTPS.
Return type: Returns: The Microsoft.AspNetCore.Server.KestrelServerOptions.
public static KestrelServerOptions UseHttps(this KestrelServerOptions options, HttpsConnectionFilterOptions httpsOptions)
-
UseHttps
(Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions, System.Security.Cryptography.X509Certificates.X509Certificate2) Configure Kestrel to use HTTPS.
Arguments: - options (Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions) – The Microsoft.AspNetCore.Server.KestrelServerOptions to configure.
- serverCertificate (System.Security.Cryptography.X509Certificates.X509Certificate2) – The X.509 certificate.
Return type: Returns: The Microsoft.AspNetCore.Server.KestrelServerOptions.
public static KestrelServerOptions UseHttps(this KestrelServerOptions options, X509Certificate2 serverCertificate)
-
UseHttps
(Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions, System.String) Configure Kestrel to use HTTPS.
Arguments: - options (Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions) – The Microsoft.AspNetCore.Server.KestrelServerOptions to configure.
- fileName (System.String) – The name of a certificate file, relative to the directory that contains the application content files.
Return type: Returns: The Microsoft.AspNetCore.Server.KestrelServerOptions.
public static KestrelServerOptions UseHttps(this KestrelServerOptions options, string fileName)
-
UseHttps
(Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions, System.String, System.String) Configure Kestrel to use HTTPS.
Arguments: - options (Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions) – The Microsoft.AspNetCore.Server.KestrelServerOptions to configure.
- fileName (System.String) – The name of a certificate file, relative to the directory that contains the application content files.
- password (System.String) – The password required to access the X.509 certificate data.
Return type: Returns: The Microsoft.AspNetCore.Server.KestrelServerOptions.
public static KestrelServerOptions UseHttps(this KestrelServerOptions options, string fileName, string password)
-