Class AesEcryptionSettings
Namespace: Aspose.Zip.Saving
Assembly: Aspose.Zip.dll (25.1.0)
Základní třída pro nastavení pro několik metod šifrování zipu.
public class AesEcryptionSettings : EncryptionSettings
Dědičnost
object ← EncryptionSettings ← AesEcryptionSettings
Děděné členy
EncryptionSettings.Method, EncryptionSettings.Password, object.GetType(), object.MemberwiseClone(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()
Poznámky
Více informací naleznete na https://www.winzip.com/win/en/aes_info.html
Konstruktor
AesEcryptionSettings(string, EncryptionMethod)
Inicializuje novou instanci třídy Aspose.Zip.Saving.AesEcryptionSettings.
public AesEcryptionSettings(string password, EncryptionMethod method)
Parametry
password
string
Heslo pro šifrování nebo dešifrování.
method
EncryptionMethod
Možnost algoritmu určující velikost bloku šifry.
Příklady
using (var archive = new Archive(new ArchiveEntrySettings(null, new AesEcryptionSettings("p@s$", EncryptionMethod.AES256))))
{
archive.CreateEntry("data.bin", "data.bin");
archive.Save("archive.zip");
}
Výjimky
method
není jednou z hodnot Aspose.Zip.Saving.EncryptionMethod.AES128, Aspose.Zip.Saving.EncryptionMethod.AES192 nebo Aspose.Zip.Saving.EncryptionMethod.AES256.
AesEcryptionSettings(EncryptionMethod)
Inicializuje novou instanci třídy Aspose.Zip.Saving.AesEcryptionSettings bez hesla.
public AesEcryptionSettings(EncryptionMethod method)
Parametry
method
EncryptionMethod
Možnost algoritmu určující velikost bloku šifry.