MachineKey.Decode(String, MachineKeyProtection) Metoda

Definicja

Przestroga

This method is obsolete and is only provided for compatibility with existing code. It is recommended that new code use the Protect and Unprotect methods instead.

Dekoduje i/lub weryfikuje dane, które zostały zaszyfrowane lub dostarczone przy użyciu kodu uwierzytelniania komunikatów opartych na skrótach (HMAC).

public:
 static cli::array <System::Byte> ^ Decode(System::String ^ encodedData, System::Web::Security::MachineKeyProtection protectionOption);
public static byte[] Decode (string encodedData, System.Web.Security.MachineKeyProtection protectionOption);
[System.Obsolete("This method is obsolete and is only provided for compatibility with existing code. It is recommended that new code use the Protect and Unprotect methods instead.")]
public static byte[] Decode (string encodedData, System.Web.Security.MachineKeyProtection protectionOption);
static member Decode : string * System.Web.Security.MachineKeyProtection -> byte[]
[<System.Obsolete("This method is obsolete and is only provided for compatibility with existing code. It is recommended that new code use the Protect and Unprotect methods instead.")>]
static member Decode : string * System.Web.Security.MachineKeyProtection -> byte[]
Public Shared Function Decode (encodedData As String, protectionOption As MachineKeyProtection) As Byte()

Parametry

encodedData
String

Zaszyfrowane dane do odszyfrowywania i/lub weryfikowania.

protectionOption
MachineKeyProtection

Wskazuje, czy encodedData parametr powinien być zaszyfrowany i/lub skrót.

Zwraca

Byte[]

Tablica Byte reprezentująca odszyfrowane dane.

Atrybuty

Przykłady

Aby zapoznać się z przykładem kodu, zobacz MachineKey omówienie klasy.

Uwagi

Aby uzyskać informacje o tym, których algorytmów szyfrowania i skrótów ASP.NET używa do odszyfrowywania i weryfikowania przekazanych danych, zobacz machineKey, element (ASP.NET Ustawienia Schema).

Dotyczy