共用方式為


NegotiateStream.IsSigned 屬性

定義

取得 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( L"IsAuthenticated: {0}", stream->IsAuthenticated );
   Console::WriteLine( L"IsMutuallyAuthenticated: {0}", stream->IsMutuallyAuthenticated );
   Console::WriteLine( L"IsEncrypted: {0}", stream->IsEncrypted );
   Console::WriteLine( L"IsSigned: {0}", stream->IsSigned );
   Console::WriteLine( L"ImpersonationLevel: {0}", stream->ImpersonationLevel );
   Console::WriteLine( L"IsServer: {0}", stream->IsServer );
}


 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);
}

備註

數據簽署有助於保護數據的完整性;也就是,它可協助收件者判斷數據是否在傳輸時遭到竄改。

適用於