共用方式為


KestrelServerOptionsHttpsExtensions.UseHttps 方法

定義

多載

UseHttps(KestrelServerOptions, HttpsConnectionFilterOptions)

設定 Kestrel 使用 HTTPS。

UseHttps(KestrelServerOptions, X509Certificate2)

設定 Kestrel 使用 HTTPS。

UseHttps(KestrelServerOptions, String)

設定 Kestrel 使用 HTTPS。

UseHttps(KestrelServerOptions, String, String)

設定 Kestrel 使用 HTTPS。

UseHttps(KestrelServerOptions, HttpsConnectionFilterOptions)

設定 Kestrel 使用 HTTPS。

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::AspNetCore::Server::Kestrel::KestrelServerOptions ^ UseHttps(Microsoft::AspNetCore::Server::Kestrel::KestrelServerOptions ^ options, Microsoft::AspNetCore::Server::Kestrel::Https::HttpsConnectionFilterOptions ^ httpsOptions);
public static Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions UseHttps (this Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions options, Microsoft.AspNetCore.Server.Kestrel.Https.HttpsConnectionFilterOptions httpsOptions);
static member UseHttps : Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions * Microsoft.AspNetCore.Server.Kestrel.Https.HttpsConnectionFilterOptions -> Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions
<Extension()>
Public Function UseHttps (options As KestrelServerOptions, httpsOptions As HttpsConnectionFilterOptions) As KestrelServerOptions

參數

options
KestrelServerOptions

要設定的 Microsoft.AspNetCore.Server.KestrelServerOptions。

httpsOptions
HttpsConnectionFilterOptions

設定 HTTPS 的選項。

傳回

Microsoft.AspNetCore.Server.KestrelServerOptions。

適用於

UseHttps(KestrelServerOptions, X509Certificate2)

設定 Kestrel 使用 HTTPS。

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::AspNetCore::Server::Kestrel::KestrelServerOptions ^ UseHttps(Microsoft::AspNetCore::Server::Kestrel::KestrelServerOptions ^ options, System::Security::Cryptography::X509Certificates::X509Certificate2 ^ serverCertificate);
public static Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions UseHttps (this Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions options, System.Security.Cryptography.X509Certificates.X509Certificate2 serverCertificate);
static member UseHttps : Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions * System.Security.Cryptography.X509Certificates.X509Certificate2 -> Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions
<Extension()>
Public Function UseHttps (options As KestrelServerOptions, serverCertificate As X509Certificate2) As KestrelServerOptions

參數

options
KestrelServerOptions

要設定的 Microsoft.AspNetCore.Server.KestrelServerOptions。

serverCertificate
X509Certificate2

X.509 憑證。

傳回

Microsoft.AspNetCore.Server.KestrelServerOptions。

適用於

UseHttps(KestrelServerOptions, String)

設定 Kestrel 使用 HTTPS。

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::AspNetCore::Server::Kestrel::KestrelServerOptions ^ UseHttps(Microsoft::AspNetCore::Server::Kestrel::KestrelServerOptions ^ options, System::String ^ fileName);
public static Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions UseHttps (this Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions options, string fileName);
static member UseHttps : Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions * string -> Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions
<Extension()>
Public Function UseHttps (options As KestrelServerOptions, fileName As String) As KestrelServerOptions

參數

options
KestrelServerOptions

要設定的 Microsoft.AspNetCore.Server.KestrelServerOptions。

fileName
String

憑證檔案的名稱,相對於包含應用程式內容檔案的目錄。

傳回

Microsoft.AspNetCore.Server.KestrelServerOptions。

適用於

UseHttps(KestrelServerOptions, String, String)

設定 Kestrel 使用 HTTPS。

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::AspNetCore::Server::Kestrel::KestrelServerOptions ^ UseHttps(Microsoft::AspNetCore::Server::Kestrel::KestrelServerOptions ^ options, System::String ^ fileName, System::String ^ password);
public static Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions UseHttps (this Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions options, string fileName, string password);
static member UseHttps : Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions * string * string -> Microsoft.AspNetCore.Server.Kestrel.KestrelServerOptions
<Extension()>
Public Function UseHttps (options As KestrelServerOptions, fileName As String, password As String) As KestrelServerOptions

參數

options
KestrelServerOptions

要設定的 Microsoft.AspNetCore.Server.KestrelServerOptions。

fileName
String

憑證檔案的名稱,相對於包含應用程式內容檔案的目錄。

password
String

存取 X.509 憑證資料所需的密碼。

傳回

Microsoft.AspNetCore.Server.KestrelServerOptions。

適用於