Freigeben über


DataProtectionAdvancedExtensions.Protect Methode

Definition

Überlädt

Protect(ITimeLimitedDataProtector, Byte[], TimeSpan)

Schützt einen Teil von Klartextdaten kryptografisch, wobei die Daten nach Ablauf der angegebenen Zeit ablaufen.

Protect(ITimeLimitedDataProtector, String, DateTimeOffset)

Schützt kryptografisch einen Teil von Klartextdaten, wobei die Daten zum gewählten Zeitpunkt ablaufen.

Protect(ITimeLimitedDataProtector, String, TimeSpan)

Schützt einen Teil von Klartextdaten kryptografisch, wobei die Daten nach Ablauf der angegebenen Zeit ablaufen.

Protect(ITimeLimitedDataProtector, Byte[], TimeSpan)

Quelle:
DataProtectionAdvancedExtensions.cs
Quelle:
DataProtectionAdvancedExtensions.cs
Quelle:
DataProtectionAdvancedExtensions.cs
Quelle:
DataProtectionAdvancedExtensions.cs
Quelle:
DataProtectionAdvancedExtensions.cs
Quelle:
DataProtectionAdvancedExtensions.cs
Quelle:
DataProtectionAdvancedExtensions.cs
Quelle:
DataProtectionAdvancedExtensions.cs

Schützt einen Teil von Klartextdaten kryptografisch, wobei die Daten nach Ablauf der angegebenen Zeit ablaufen.

public:
[System::Runtime::CompilerServices::Extension]
 static cli::array <System::Byte> ^ Protect(Microsoft::AspNetCore::DataProtection::ITimeLimitedDataProtector ^ protector, cli::array <System::Byte> ^ plaintext, TimeSpan lifetime);
public static byte[] Protect (this Microsoft.AspNetCore.DataProtection.ITimeLimitedDataProtector protector, byte[] plaintext, TimeSpan lifetime);
static member Protect : Microsoft.AspNetCore.DataProtection.ITimeLimitedDataProtector * byte[] * TimeSpan -> byte[]
<Extension()>
Public Function Protect (protector As ITimeLimitedDataProtector, plaintext As Byte(), lifetime As TimeSpan) As Byte()

Parameter

protector
ITimeLimitedDataProtector

Die zu verwendende Schutzvorrichtung.

plaintext
Byte[]

Die zu schützenden Klartextdaten.

lifetime
TimeSpan

Die Zeitspanne, nach der die Nutzlast nicht mehr geschützt werden darf.

Gibt zurück

Byte[]

Die geschützte Form der Klartextdaten.

Gilt für:

Protect(ITimeLimitedDataProtector, String, DateTimeOffset)

Quelle:
DataProtectionAdvancedExtensions.cs
Quelle:
DataProtectionAdvancedExtensions.cs
Quelle:
DataProtectionAdvancedExtensions.cs
Quelle:
DataProtectionAdvancedExtensions.cs
Quelle:
DataProtectionAdvancedExtensions.cs
Quelle:
DataProtectionAdvancedExtensions.cs
Quelle:
DataProtectionAdvancedExtensions.cs
Quelle:
DataProtectionAdvancedExtensions.cs

Schützt kryptografisch einen Teil von Klartextdaten, wobei die Daten zum gewählten Zeitpunkt ablaufen.

public:
[System::Runtime::CompilerServices::Extension]
 static System::String ^ Protect(Microsoft::AspNetCore::DataProtection::ITimeLimitedDataProtector ^ protector, System::String ^ plaintext, DateTimeOffset expiration);
public static string Protect (this Microsoft.AspNetCore.DataProtection.ITimeLimitedDataProtector protector, string plaintext, DateTimeOffset expiration);
static member Protect : Microsoft.AspNetCore.DataProtection.ITimeLimitedDataProtector * string * DateTimeOffset -> string
<Extension()>
Public Function Protect (protector As ITimeLimitedDataProtector, plaintext As String, expiration As DateTimeOffset) As String

Parameter

protector
ITimeLimitedDataProtector

Die zu verwendende Schutzvorrichtung.

plaintext
String

Die zu schützenden Klartextdaten.

expiration
DateTimeOffset

Der Zeitpunkt, zu dem diese Nutzlast abläuft.

Gibt zurück

Die geschützte Form der Klartextdaten.

Gilt für:

Protect(ITimeLimitedDataProtector, String, TimeSpan)

Quelle:
DataProtectionAdvancedExtensions.cs
Quelle:
DataProtectionAdvancedExtensions.cs
Quelle:
DataProtectionAdvancedExtensions.cs
Quelle:
DataProtectionAdvancedExtensions.cs
Quelle:
DataProtectionAdvancedExtensions.cs
Quelle:
DataProtectionAdvancedExtensions.cs
Quelle:
DataProtectionAdvancedExtensions.cs
Quelle:
DataProtectionAdvancedExtensions.cs

Schützt einen Teil von Klartextdaten kryptografisch, wobei die Daten nach Ablauf der angegebenen Zeit ablaufen.

public:
[System::Runtime::CompilerServices::Extension]
 static System::String ^ Protect(Microsoft::AspNetCore::DataProtection::ITimeLimitedDataProtector ^ protector, System::String ^ plaintext, TimeSpan lifetime);
public static string Protect (this Microsoft.AspNetCore.DataProtection.ITimeLimitedDataProtector protector, string plaintext, TimeSpan lifetime);
static member Protect : Microsoft.AspNetCore.DataProtection.ITimeLimitedDataProtector * string * TimeSpan -> string
<Extension()>
Public Function Protect (protector As ITimeLimitedDataProtector, plaintext As String, lifetime As TimeSpan) As String

Parameter

protector
ITimeLimitedDataProtector

Die zu verwendende Schutzvorrichtung.

plaintext
String

Die zu schützenden Klartextdaten.

lifetime
TimeSpan

Die Zeitspanne, nach der die Nutzlast nicht mehr geschützt werden darf.

Gibt zurück

Die geschützte Form der Klartextdaten.

Gilt für: