Class AES256SHA256Decoder
java.lang.Object
org.apache.commons.compress.archivers.sevenz.AbstractCoder
org.apache.commons.compress.archivers.sevenz.AES256SHA256Decoder
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static final classprivate static final class -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) InputStreamdecode(String archiveName, InputStream in, long uncompressedLength, Coder coder, byte[] passwordBytes, int maxMemoryLimitInKb) Decodes using stream that reads from in using the configured coder and password.(package private) OutputStreamencode(OutputStream out, Object options) Encodes using a stream that writes to out using the given configuration.(package private) byte[]getOptionsAsProperties(Object options) Gets property bytes to write in a Folder block.(package private) static byte[]sha256Password(byte[] password, int numCyclesPower, byte[] salt) (package private) static byte[]sha256Password(char[] password, int numCyclesPower, byte[] salt) (package private) static byte[]utf16Decode(char[] chars) Convenience method that encodes Unicode characters into bytes in UTF-16 (little-endian byte order) charsetMethods inherited from class org.apache.commons.compress.archivers.sevenz.AbstractCoder
getOptionsFromCoder, isOptionInstance, toInt
-
Constructor Details
-
AES256SHA256Decoder
AES256SHA256Decoder()
-
-
Method Details
-
sha256Password
static byte[] sha256Password(byte[] password, int numCyclesPower, byte[] salt) -
sha256Password
static byte[] sha256Password(char[] password, int numCyclesPower, byte[] salt) -
utf16Decode
static byte[] utf16Decode(char[] chars) Convenience method that encodes Unicode characters into bytes in UTF-16 (little-endian byte order) charset- Parameters:
chars- characters to encode- Returns:
- encoded characters
- Since:
- 1.23
-
decode
InputStream decode(String archiveName, InputStream in, long uncompressedLength, Coder coder, byte[] passwordBytes, int maxMemoryLimitInKb) Description copied from class:AbstractCoderDecodes using stream that reads from in using the configured coder and password.- Specified by:
decodein classAbstractCoder- Returns:
- a stream that reads from in using the configured coder and password.
-
encode
Description copied from class:AbstractCoderEncodes using a stream that writes to out using the given configuration.- Overrides:
encodein classAbstractCoder- Returns:
- a stream that writes to out using the given configuration.
- Throws:
IOException- Optionally thrown by subclassses.
-
getOptionsAsProperties
Description copied from class:AbstractCoderGets property bytes to write in a Folder block.- Overrides:
getOptionsAsPropertiesin classAbstractCoder- Returns:
- property bytes to write in a Folder block.
- Throws:
IOException- Optionally thrown by subclassses.
-