MachineKeySection.Decryption 屬性
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
指定用於加密與解密表單認證資料的加密演算法。
public:
property System::String ^ Decryption { System::String ^ get(); void set(System::String ^ value); };
[System.ComponentModel.TypeConverter(typeof(System.Configuration.WhiteSpaceTrimStringConverter))]
[System.Configuration.ConfigurationProperty("decryption", DefaultValue="Auto")]
[System.Configuration.StringValidator(MinLength=1)]
public string Decryption { get; set; }
[<System.ComponentModel.TypeConverter(typeof(System.Configuration.WhiteSpaceTrimStringConverter))>]
[<System.Configuration.ConfigurationProperty("decryption", DefaultValue="Auto")>]
[<System.Configuration.StringValidator(MinLength=1)>]
member this.Decryption : string with get, set
Public Property Decryption As String
屬性值
一個表示用於加密與解密表單認證資料的演算法的值。 (關於如何指定在視圖狀態加密時所使用的演算法,請參見該性質。 Validation ) Auto 是預設值。
- 屬性
例外狀況
所選值並非解密值之一。
備註
此 Decryption 特性支援以下解密值:
Auto預設值,指定 ASP.NET 根據設定預設決定使用哪種加密演算法。AES,該規則規定 ASP.NET 使用該 AES 演算法來加密資料。AES是加密資料的預設演算法。3DES,該規則規定 ASP.NET 使用該 TripleDES 演算法來加密資料。一個自訂演算法。
此屬性通常以宣告式方式設定於 decryption Web.config 檔案的 machineKey 元素屬性中。 欲了解更多資訊,請參閱 machineKey 元素。