MachineKey.Decode(String, MachineKeyProtection) Metodo

Definizione

Attenzione

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.

Decodifica e/o convalida dati crittografati o forniti con un codice HMAC (Hash-based Message Authentication Code).

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()

Parametri

encodedData
String

I dati crittografati per decrittografare e/o convalidare.

protectionOption
MachineKeyProtection

Indica se il parametro encodedData deve essere crittografato e/o sottoposto a hashing.

Restituisce

Byte[]

Matrice Byte che rappresenta i dati decrittografati.

Attributi

Esempio

Per un esempio di codice, vedere panoramica della MachineKey classe.

Commenti

Per informazioni sugli algoritmi di crittografia e hashing usati ASP.NET per decrittografare e convalidare i dati passati, vedere Elemento machineKey (ASP.NET Impostazioni Schema).

Si applica a