共用方式為


BasicHttpSecurity 類別

定義

設定 basicHttpBinding 繫結的安全性設定。

public ref class BasicHttpSecurity sealed
public sealed class BasicHttpSecurity
type BasicHttpSecurity = class
Public NotInheritable Class BasicHttpSecurity
繼承
BasicHttpSecurity

範例

BasicHttpBinding binding = new BasicHttpBinding();
binding.Name = "binding1";
binding.HostNameComparisonMode = HostNameComparisonMode.StrongWildcard;
binding.Security.Mode = BasicHttpSecurityMode.Message;

BasicHttpSecurity security = binding.Security;
BasicHttpMessageSecurity msgSecurity = security.Message;

BasicHttpSecurityMode secMode = security.Mode;

HttpTransportSecurity transSec = security.Transport;

Console.WriteLine("The message-level security setting is {0}", secMode.ToString());
Console.WriteLine("The transport-level security setting is {0}", transSec.ToString());
Dim binding As BasicHttpBinding = New BasicHttpBinding()
binding.Name = "binding1"
binding.HostNameComparisonMode = HostNameComparisonMode.StrongWildcard
binding.Security.Mode = BasicHttpSecurityMode.Message

Dim security As BasicHttpSecurity = binding.Security
Dim msgSecurity As BasicHttpMessageSecurity = security.Message

Dim secMode As BasicHttpSecurityMode = security.Mode

Dim transSec As HttpTransportSecurity = security.Transport

Console.WriteLine("The message-level security setting is {0}", secMode.ToString())
Console.WriteLine("The transport-level security setting is {0}", transSec.ToString())

建構函式

BasicHttpSecurity()

初始化 BasicHttpSecurity 類別的新執行個體。

屬性

Message

取得 basicHttpBinding 繫結的訊息層級安全性設定。

Mode

取得或設定 basicHttpBinding 繫結的安全性模式。

Transport

取得 basicHttpBinding 繫結的傳輸層級安全性設定。

方法

Equals(Object)

判斷指定的物件是否等於目前的物件。

(繼承來源 Object)
GetHashCode()

做為預設雜湊函式。

(繼承來源 Object)
GetType()

取得目前執行個體的 Type

(繼承來源 Object)
MemberwiseClone()

建立目前 Object 的淺層複製。

(繼承來源 Object)
ShouldSerializeMessage()

判斷訊息項目是否應該序列化。

ShouldSerializeTransport()

判斷傳輸項目是否應該序列化。

ToString()

傳回代表目前物件的字串。

(繼承來源 Object)

適用於