Top Description Fields Constructors Methods
org.apache.commons.compress.archivers.sevenz

pack-priv final Class AES256Options

extends Object
Class Inheritance
Imports
java.security.GeneralSecurityException, .NoSuchAlgorithmException, .SecureRandom, javax.crypto.Cipher, .SecretKey, javax.crypto.spec.IvParameterSpec, .SecretKeySpec

Options for SevenZMethod#AES256SHA256 encoder
Since
1.23
See Also
AES256SHA256Decoder

Field Summary

Modifier and TypeField and Description
pack-priv static final String
private final Cipher
private static final byte[]
private final byte[]
private final int
private final byte[]
pack-priv static final String

Constructor Summary

AccessConstructor and Description
pack-priv
AES256Options(final char[]
password used for encryption
password
)

pack-priv
AES256Options(final char[]
password used for encryption
password
,
final byte[]
for password hash salting (enforce password security)
salt
,
final byte[]
Initialization Vector (IV) used by cipher algorithm
iv
,
final int
another password security enforcer parameter that controls the cycles of password hashing. More the this number is high, more security you'll have but also high CPU usage
numCyclesPower
)

Method Summary

Modifier and TypeMethod and Description
pack-priv Cipher
pack-priv byte[]
pack-priv int
pack-priv byte[]
pack-priv static SecretKeySpec
newSecretKeySpec(final byte[] bytes)

private static byte[]
randomBytes(final int size)

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

ALGORITHMback to summary
pack-priv static final String ALGORITHM
cipherback to summary
private final Cipher cipher
EMPTY_BYTE_ARRAYback to summary
private static final byte[] EMPTY_BYTE_ARRAY
ivback to summary
private final byte[] iv
numCyclesPowerback to summary
private final int numCyclesPower
saltback to summary
private final byte[] salt
TRANSFORMATIONback to summary
pack-priv static final String TRANSFORMATION

Constructor Detail

AES256Optionsback to summary
pack-priv AES256Options(final char[] password)
Parameters
password:char[]

password used for encryption

AES256Optionsback to summary
pack-priv AES256Options(final char[] password, final byte[] salt, final byte[] iv, final int numCyclesPower)
Parameters
password:char[]

password used for encryption

salt:byte[]

for password hash salting (enforce password security)

iv:byte[]

Initialization Vector (IV) used by cipher algorithm

numCyclesPower:int

another password security enforcer parameter that controls the cycles of password hashing. More the this number is high, more security you'll have but also high CPU usage

Method Detail

getCipherback to summary
pack-priv Cipher getCipher()
getIvback to summary
pack-priv byte[] getIv()
getNumCyclesPowerback to summary
pack-priv int getNumCyclesPower()
getSaltback to summary
pack-priv byte[] getSalt()
newSecretKeySpecback to summary
pack-priv static SecretKeySpec newSecretKeySpec(final byte[] bytes)
randomBytesback to summary
private static byte[] randomBytes(final int size)