SslStream.CipherAlgorithm 속성

정의

SslStream에서 사용하는 일괄 암호화 알고리즘을 식별하는 값을 가져옵니다.

public:
 virtual property System::Security::Authentication::CipherAlgorithmType CipherAlgorithm { System::Security::Authentication::CipherAlgorithmType get(); };
public virtual System.Security.Authentication.CipherAlgorithmType CipherAlgorithm { get; }
member this.CipherAlgorithm : System.Security.Authentication.CipherAlgorithmType
Public Overridable ReadOnly Property CipherAlgorithm As CipherAlgorithmType

속성 값

SslStream에서 사용하는 대량 암호화 알고리즘을 식별하는 값입니다.

예외

인증 프로세스 완료 또는 인증 프로세스 실패 전에 CipherAlgorithm 속성에 액세스한 경우

예제

다음 코드 예제에서는 지정된 스트림에 대한 암호화 설정을 표시합니다.

static void DisplaySecurityLevel( SslStream^ stream )
{
   Console::WriteLine( L"Cipher: {0} strength {1}", stream->CipherAlgorithm, stream->CipherStrength );
   Console::WriteLine( L"Hash: {0} strength {1}", stream->HashAlgorithm, stream->HashStrength );
   Console::WriteLine( L"Key exchange: {0} strength {1}", stream->KeyExchangeAlgorithm, stream->KeyExchangeStrength );
   Console::WriteLine( L"Protocol: {0}", stream->SslProtocol );
}
static void DisplaySecurityLevel(SslStream stream)
{
   Console.WriteLine("Cipher: {0} strength {1}", stream.CipherAlgorithm, stream.CipherStrength);
   Console.WriteLine("Hash: {0} strength {1}", stream.HashAlgorithm, stream.HashStrength);
   Console.WriteLine("Key exchange: {0} strength {1}", stream.KeyExchangeAlgorithm, stream.KeyExchangeStrength);
   Console.WriteLine("Protocol: {0}", stream.SslProtocol);
}
Private Shared Sub DisplaySecurityLevel(stream As SslStream)
    Console.WriteLine("Cipher: {0} strength {1}", stream.CipherAlgorithm, stream.CipherStrength)
    Console.WriteLine("Hash: {0} strength {1}", stream.HashAlgorithm, stream.HashStrength)
    Console.WriteLine("Key exchange: {0} strength {1}", stream.KeyExchangeAlgorithm, stream.KeyExchangeStrength)
    Console.WriteLine("Protocol: {0}", stream.SslProtocol)
End Sub

설명

값은 열거형 값 Null 이 instance 생성하는 데 사용되는 경우 속성 NoEncryptionSslStream 필요합니다CipherAlgorithm.

Windows Server 2003 및 Windows XP는 Null 이 값을 지원하지 않습니다. 따라서 값이 Null instance 생성하는 SslStream 데 사용되더라도 속성은 EncryptionPolicy 입니다None. 값은 Null Windows Vista 이상에서만 반환됩니다.

적용 대상