Class AesEcryptionSettings

Class AesEcryptionSettings

Namn på plats: Aspose.Zip.Saving Sammanfattning: Aspose.Zip.dll (25.5.0)

Basklassen för inställningar för flera zip krypteringsmetoder.

public class AesEcryptionSettings : EncryptionSettings

Inheritance

object EncryptionSettings AesEcryptionSettings

Arvsmedlemmar

EncryptionSettings.Method , EncryptionSettings.Password , object.GetType() , object.MemberwiseClone() , object.ToString() , object.Equals(object?) , object.Equals(object?, object?) , object.ReferenceEquals(object?, object?) , object.GetHashCode()

Remarks

Se mer på https://www.winzip.com/win/en/aes_info.html

Constructors

AesEcryptionSettings(String, krypteringMetod)

Initialiserar en ny instans av Aspose.Zip.Saving.AesEcryptionSettings klass.

public AesEcryptionSettings(string password, EncryptionMethod method)

Parameters

password string

Password för kryptering eller dekryptering.

method EncryptionMethod

Algoritm alternativ som indikerar blockstorleken på cipher.

Examples

using (var archive = new Archive(new ArchiveEntrySettings(null, new AesEcryptionSettings("p@s$", EncryptionMethod.AES256))))
{
   archive.CreateEntry("data.bin", "data.bin");
   archive.Save("archive.zip");
}

Exceptions

NotSupportedException

method’ is not one of Aspose.Zip.Saving.EncryptionMethod.AES128, Aspose.Zip.Saving.EncryptionMethod.AES192, or Aspose.Zip.Saving.EncryptionMethod.AES256.

AesEcryptionSettings(EncryptionMethod)

Initialiserar en ny instans av Aspose.Zip.Saving.AesEcryptionSettings klass utan lösenord.

public AesEcryptionSettings(EncryptionMethod method)

Parameters

method EncryptionMethod

Algoritm alternativ som indikerar blockstorleken på cipher.

 Svenska