Class AesEcryptionSettings
Namespace: Aspose.Zip.Saving
Assembly: Aspose.Zip.dll (25.1.0)
Classe base para configurações de vários métodos de criptografia zip.
public class AesEcryptionSettings : EncryptionSettings
Herança
object ← EncryptionSettings ← AesEcryptionSettings
Membros Herdados
EncryptionSettings.Method, EncryptionSettings.Password, object.GetType(), object.MemberwiseClone(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()
Observações
Veja mais em https://www.winzip.com/win/en/aes_info.html
Construtores
AesEcryptionSettings(string, EncryptionMethod)
Inicializa uma nova instância da classe Aspose.Zip.Saving.AesEcryptionSettings.
public AesEcryptionSettings(string password, EncryptionMethod method)
Parâmetros
password
string
Senha para criptografia ou descriptografia.
method
EncryptionMethod
Opção de algoritmo indicando o tamanho do bloco do cifrador.
Exemplos
using (var archive = new Archive(new ArchiveEntrySettings(null, new AesEcryptionSettings("p@s$", EncryptionMethod.AES256))))
{
archive.CreateEntry("data.bin", "data.bin");
archive.Save("archive.zip");
}
Exceções
method
não é um dos Aspose.Zip.Saving.EncryptionMethod.AES128, Aspose.Zip.Saving.EncryptionMethod.AES192 ou Aspose.Zip.Saving.EncryptionMethod.AES256.
AesEcryptionSettings(EncryptionMethod)
Inicializa uma nova instância da classe Aspose.Zip.Saving.AesEcryptionSettings sem uma senha.
public AesEcryptionSettings(EncryptionMethod method)
Parâmetros
method
EncryptionMethod
Opção de algoritmo indicando o tamanho do bloco do cifrador.