Class AesEcryptionSettings
Namespace: Aspose.Zip.Saving
Assembly: Aspose.Zip.dll (25.1.0)
Klasa bazowa dla ustawień dla kilku metod szyfrowania zip.
public class AesEcryptionSettings : EncryptionSettings
Dziedziczenie
object ← EncryptionSettings ← AesEcryptionSettings
Członkowie dziedziczeni
EncryptionSettings.Method, EncryptionSettings.Password, object.GetType(), object.MemberwiseClone(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()
Uwagi
Zobacz więcej na https://www.winzip.com/win/en/aes_info.html
Konstruktory
AesEcryptionSettings(string, EncryptionMethod)
Inicjuje nową instancję klasy Aspose.Zip.Saving.AesEcryptionSettings.
public AesEcryptionSettings(string password, EncryptionMethod method)
Parametry
password
string
Hasło do szyfrowania lub deszyfrowania.
method
EncryptionMethod
Opcja algorytmu wskazująca rozmiar bloku szyfru.
Przykłady
using (var archive = new Archive(new ArchiveEntrySettings(null, new AesEcryptionSettings("p@s$", EncryptionMethod.AES256))))
{
archive.CreateEntry("data.bin", "data.bin");
archive.Save("archive.zip");
}
Wyjątki
method
nie jest jednym z Aspose.Zip.Saving.EncryptionMethod.AES128, Aspose.Zip.Saving.EncryptionMethod.AES192 lub Aspose.Zip.Saving.EncryptionMethod.AES256.
AesEcryptionSettings(EncryptionMethod)
Inicjuje nową instancję klasy Aspose.Zip.Saving.AesEcryptionSettings bez hasła.
public AesEcryptionSettings(EncryptionMethod method)
Parametry
method
EncryptionMethod
Opcja algorytmu wskazująca rozmiar bloku szyfru.