NegotiateStream.IsAuthenticated Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets a Boolean value that indicates whether authentication was successful.
public:
virtual property bool IsAuthenticated { bool get(); };
public override bool IsAuthenticated { get; }
member this.IsAuthenticated : bool
Public Overrides ReadOnly Property IsAuthenticated As Boolean
Property Value
true
if successful authentication occurred; otherwise, false
.
Examples
The following code example demonstrates displaying the value of this property.
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);
}
Remarks
Clients authenticate by calling the AuthenticateAsClient or BeginAuthenticateAsClient methods. Servers authenticate by calling the AuthenticateAsServer or BeginAuthenticateAsServer methods.
Applies to
التعاون معنا على GitHub
يمكن العثور على مصدر هذا المحتوى على GitHub حيث يمكنك أيضاً إضافة مشاكل وطلبات سحب ومراجعتها. للحصول على معلومات إضافية، اطلع على دليل المساهم لدينا.