AnonymousIdentificationSection.CookieProtection 속성

정의

쿠키 암호화에 사용되는 암호화 형식을 가져오거나 설정합니다.

public:
 property System::Web::Security::CookieProtection CookieProtection { System::Web::Security::CookieProtection get(); void set(System::Web::Security::CookieProtection value); };
[System.Configuration.ConfigurationProperty("cookieProtection", DefaultValue=System.Web.Security.CookieProtection.Validation)]
public System.Web.Security.CookieProtection CookieProtection { get; set; }
[<System.Configuration.ConfigurationProperty("cookieProtection", DefaultValue=System.Web.Security.CookieProtection.Validation)>]
member this.CookieProtection : System.Web.Security.CookieProtection with get, set
Public Property CookieProtection As CookieProtection

속성 값

CookieProtection

CookieProtection 값 중 하나입니다. 기본값은 All입니다.

특성

예제

다음 코드 예제에서는 CookieProtection 속성에 액세스하는 방법을 보여 줍니다.

// Get CookieProtection.
System.Web.Security.CookieProtection cookieProtection =
    anonymousIdentificationSection.CookieProtection;
Console.WriteLine("Cookie protection: {0}",
           cookieProtection);
' Get CookieProtection.
Dim cookieProtection _
As System.Web.Security.CookieProtection = _
anonymousIdentificationSection.CookieProtection
Console.WriteLine( _
"Cookie protection: {0}", cookieProtection)

설명

사용자 쿠키 보안을 강화 하려면 설정 합니다 CookieRequireSSL 속성을 true입니다.

데이터 유효성 검사와 쿠키를 보호 하는 데 암호화 하려는 경우이 속성에 대 한 기본값을 사용 해야 합니다. 이 옵션은 구성된 데이터 유효성 검사 알고리즘을 사용합니다. 3DES(Triple DES)를 사용할 수 있으며 키 길이가 충분하면(48바이트 이상) 암호화에 3DES가 사용됩니다.

적용 대상