MachineKey.Decode(String, MachineKeyProtection) Methode

Definition

Achtung

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.

Decodiert und/oder überprüft Daten, die verschlüsselt oder mit einem Hash-basierten Nachrichtenauthentifizierungscode (HMAC) bereitgestellt wurden.

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

Parameter

encodedData
String

Die verschlüsselten Daten, die entschlüsselt und/oder überprüft werden sollen.

protectionOption
MachineKeyProtection

Gibt an, ob der encodedData Parameter verschlüsselt und/oder hashed werden soll.

Gibt zurück

Byte[]

Ein Byte Array, das die entschlüsselten Daten darstellt.

Attribute

Beispiele

Ein Codebeispiel finden Sie in der MachineKey Klassenübersicht.

Hinweise

Informationen dazu, welche Verschlüsselungs- und Hashingalgorithmen ASP.NET zum Entschlüsseln und Überprüfen der übergebenen Daten verwendet werden, finden Sie unter machineKey Element (ASP.NET Settings Schema).

Gilt für: