NegotiateStream.IsSigned 屬性
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
會得到 Boolean 一個值,表示使用該串流傳送的資料是否帶有簽名。
public:
virtual property bool IsSigned { bool get(); };
public override bool IsSigned { get; }
member this.IsSigned : bool
Public Overrides ReadOnly Property IsSigned As Boolean
屬性值
true如果資料在傳送前已簽署;否則,。 false
範例
以下程式碼範例展示了此屬性的值。
static void DisplayAuthenticationProperties(NegotiateStream stream)
{
Console.WriteLine("IsAuthenticated: {0}", stream.IsAuthenticated);
Console.WriteLine("IsMutuallyAuthenticated: {0}", stream.IsMutuallyAuthenticated);
Console.WriteLine("IsEncrypted: {0}", stream.IsEncrypted);
Console.WriteLine("IsSigned: {0}", stream.IsSigned);
Console.WriteLine("ImpersonationLevel: {0}", stream.ImpersonationLevel);
Console.WriteLine("IsServer: {0}", stream.IsServer);
}
備註
資料簽章有助於保護資料的完整性;也就是說,它幫助接收者判斷資料在運送過程中是否被竄改。