CHAOS(1) General Commands Manual
NAME
chaos - Encryption and decryption tool of file or stream data using Chaos-based encryption.
SYNOPSIS
| chaos | encrypt { -t <text> | -b <bytes> } [ { –hex | –base64 | –encoding <encoding> } ] [ { [ { –prompt | -p <password> | –context <context> | -x <x0> -a <a> -s <s> } ] [ –chaos-mode <chaosMode> ] | -c <certFile> [ { –prompt | -p <password> | –context <context> } ] } ] [ –copy-to ] [ –verify ] [ -v ] [ –debug ] |
| chaos | decrypt { -t <text> | -b <bytes> } [ { –base64 | –encoding <encoding> } ] [ –hex ] [ { [ { –prompt | -p <password> | –context <context> | -x <x0> -a <a> -s <s> } ] [ –chaos-mode <chaosMode> ] | -c <certFile> [ { –prompt | -p <password> | –context <context> } ] } ] [ –copy-to ] [ -v ] [ –debug ] |
| chaos | encrypt [ { -i <inputFile> | –paste-from } ] [ { -o <outputFile> | –copy-to } ] [ { –base64 | –encoding <encoding> } [ –line-width <lineWidth> ] ] [ { [ { –prompt | -p <password> | –context <context> | -x <x0> -a <a> -s <s> } ] [ –chaos-mode <chaosMode> ] | -c <certFile> [ { –prompt | -p <password> | –context <context> } ] } ] [ –verify ] [ -v ] [ –debug ] |
| chaos | decrypt [ { -i <inputFile> | –paste-from } ] [ { -o <outputFile> | –copy-to } ] [ { –base64 | –encoding <encoding> } ] [ { [ { –prompt | -p <password> | –context <context> | -x <x0> -a <a> -s <s> } ] [ –chaos-mode <chaosMode> ] | -c <certFile> [ { –prompt | -p <password> | –context <context> } ] } ] [ -v ] [ –debug ] |
| chaos | create-cert [ –line-width <lineWidth> ] [ -c <certFile> ] [ { –prompt | -p <password> | –context <context> } [ –cert-mode <certMode> ] ] [ { { –chain-length <chainLength> ? –chaos-mode <chaosMode> } | –spec-file <specFile> } ] [ -v ] [ –debug ] |
| chaos | cert-info <certFile> [ { –prompt | -p <password> | –context <context> } ] [ -v ] [ –debug ] |
| chaos | create-spec [ –spec-file <specFile> ] [ -v ] [ –debug ] |
| chaos | –help | { encoded-length | –sysinfo } [ -v ] [ –debug ] |
DESCRIPTION
This manual page documents the chaos command: The chaos command uses the
encrypt or decrypt operation to process an input file --input-file (or
STDIN) to an output file --output-file (or STDOUT) using a chaos key
constructed from the start value -x, a parable coefficient -a and an
expansion factor -s, or derived from a password --password or by prompting --prompt
for a password or (instead of a single chaos key) by using a certificate file
--cert-file (optionally being password protected as of --password or --prompt).
A certificate file may represent 1..* key files and be derived create-cert from
a specification --spec-file which, after creation create-spec, may be edited
as a CSV file. See the Examples section below for usage instructions.
Depending on the executable’s flavor the command might also be named chaos-x.y.z.jar, chaos-bundle-x86_64-x.y.z.elf, chaos-bundle-x86_64-x.y.z.exe, chaos-installer-x86_64-x.y.z.msi, chaos-launcher-x.y.z.sh, chaos-launcher-x86_64-x.y.z.elf, chaos-launcher-x86_64-x.y.z.exe, chaos-native-x86_64-x.y.z.elf where x.y.z stands for the version of the chaos command. The according executable’s name will be referenced to in this manual as chaos.
The command-line help follows the effective message locale. Set the Java system property org.refcodes.messages.locale or the environment variable ORG_REFCODES_MESSAGES_LOCALE to de to explicitly select German output; otherwise the JVM’s default display locale is used, with English as the fallback when no localized bundle is available.
The option --tui opens a text form with localized action and field labels, while command names and aliases remain unchanged. Supplied arguments prefill the form and are not executed automatically, and commands requiring additional terminal input must be invoked through the regular command line instead.
OPTIONS
| encrypt: | Encrypts the message (stream, file, text or bytes). |
| decrypt: | Decrypts the message (stream, file, text or bytes). |
| -a --parable-coefficient <a>: | The chaos key’s parable coefficient <a> to use: 3.57 ≤ a ≤ 4.0 |
| -b --bytes <bytes>: | The message in bytes (e.g. “127, 128, 0x10, 0xFF”) which to process. |
| --base64: | Use BASE64 encoding/decoding to be applied for handling encrypted data. |
| -c --cert-file <certFile>: | The cert file file which to use. |
| cert-info <certFile>: | Prints out information of a given cert. |
| --cert-mode <certMode>: | The chaos options (mode) to be used for the cert itself: { NONE, MUTATE, XOR, MUTATE_XOR, SALTED, SALTED_MUTATE, SALTED_XOR, SALTED_MUTATE_XOR } |
| --chain-length <chainLength>: | The length of the chaos key chain (e.g. number of nested chaos keys, defaults to <16>) |
| --chaos-mode <chaosMode>: | The mode to be used when encrypting/decrypting: { NONE, MUTATE, XOR, MUTATE_XOR, SALTED, SALTED_MUTATE, SALTED_XOR, SALTED_MUTATE_XOR } |
| --context <context>: | The system context providing the password: { APPLICATION, USER_APPLICATION, HOST_USER_APPLICATION, HOST_APPLICATION, USER, HOST_USER, HOST, SESSION, APPLICATION_SESSION, USER_APPLICATION_SESSION, HOST_USER_APPLICATION_SESSION, HOST_APPLICATION_SESSION, USER_SESSION, HOST_USER_SESSION, HOST_SESSION } |
| create-cert: | Create an according cert record (file). |
| create-spec: | Create an according spec record (file). |
| --debug: | Enables the debug mode with additional (developer readable) informational output. |
| encoded-length: | Prints length in bytes of a single chaos key encoding (being the additional length of a salted encryption). |
| --encoding <encoding>: | The BASE (e.g. BASE64) encoding/decoding to be applied for handling encrypted data: { BASE2, BINARY, BASE4, BASE8, OCTAL, ENCODED_AS_NUMBER, BASE16, HEXADECIMAL, BASE32, BASE64, BASE64_ARABIC, BASE64_URL } |
| -h --help: | Shows this help. |
| --hex: | Use a hexadecimal representation of (binary) output. |
| -i --input-file <inputFile>: | The input file which to process from. |
| --line-width <lineWidth>: | The line width for base64 encoded ASCII output |
| -o --output-file <outputFile>: | The output file which to process to. |
| -p --password <password>: | The password to use for encryption or decryption. |
| --prompt: | Prompt for the password to use for encryption or decryption. |
| -s --expansion-factor <s>: | The chaos key’s expansion factor <s> to use: -9007199254740992 ≤ s ≤ -16 or 16 ≤ s ≤ 9007199254740991 |
| --spec-file <specFile>: | The spec file file which to use. |
| --sysinfo: | Shows some system information for debugging purposes. |
| -t --text <text>: | The text message which to process. |
| -v --verbose: | Enables the verbose mode with additional (human readable) informational output. |
| --verify: | Verify the encryption process to make sure encryption decrypts flawlessly. |
| -x --start-value <x0>: | The chaos key’s <x0> start value to use: 0.0 < x0 ≤ 1.0 |
EXAMPLES
Encrypt (BASE64 encoded) a text message:
- chaos encrypt -t <text> --base64 --prompt
Decrypt a text message (BASE64 encoded):
- chaos decrypt -t <text> --base64 --prompt
Encrypt (BASE64 encoded) a text message and copy to clipboard:
- chaos encrypt -t <text> --base64 --prompt --copy-to
Decrypt a text message (BASE64 encoded) and copy to clipboard:
- chaos decrypt -t <text> --base64 --prompt --copy-to
Encrypt (BASE64 encoded) a text message using (x0, a , s):
- chaos encrypt -t <text> --base64 -x <x0> -a <a> -s <s>
Decrypt a text message (BASE64 encoded) using (x0, a and s):
- chaos decrypt -t <text> --base64 -x <x0> -a <a> -s <s>
Encrypt a text message with mode:
- chaos encrypt -t <text> -v --chaos-mode <chaosMode>
Decrypt a text message with mode:
- chaos decrypt -t <text> -v --chaos-mode <chaosMode>
Encrypt a message in bytes:
- chaos encrypt -b <bytes> --hex --prompt
Decrypt a message in bytes:
- chaos decrypt -b <bytes> --hex --prompt
Encrypt input file to output file (bound to context):
- chaos encrypt -i <inputFile> -o <outputFile> --context <context> -v
Decrypt input file to output file (bound to context):
- chaos decrypt -i <inputFile> -o <outputFile> --context <context> -v
Use password to encrypt input file to output file:
- chaos encrypt -i <inputFile> -o <outputFile> -p <password> -v
Use password to decrypt input file to output file:
- chaos decrypt -i <inputFile> -o <outputFile> -p <password> -v
Encrypt input file to output file, prompt for password:
- chaos encrypt -i <inputFile> -o <outputFile> --prompt -v
Decrypt input file to output file, prompt for password:
- chaos decrypt -i <inputFile> -o <outputFile> --prompt -v
Encrypt input file to output file with mode and password:
- chaos encrypt -i <inputFile> -o <outputFile> --chaos-mode <chaosMode> -p <password> -v
Decrypt input file to output file with mode and password:
- chaos decrypt -i <inputFile> -o <outputFile> --chaos-mode <chaosMode> -p <password> -v
Encrypt STDIN to output file with password:
- chaos encrypt -o <outputFile> -p <password>
Decrypt input file to STDOUT with password:
- chaos decrypt -i <inputFile> -p <password>
Encrypt STDIN to output file with mode for HOST_USER:
- chaos encrypt -o <outputFile> --chaos-mode <chaosMode>
Decrypt input file to STDOUT with mode for HOST_USER:
- chaos decrypt -i <inputFile> --chaos-mode <chaosMode>
Encrypt STDIN to STDOUT/BASE64 encoded for HOST_USER:
- chaos encrypt --base64
Decrypt STDIN/BASE64 encoded to STDOUT for HOST_USER:
- chaos decrypt --base64
Create and print cert with key chain length:
- chaos create-cert --chain-length <chainLength> -v
Create cert file with key chain length:
- chaos create-cert -c <certFile> --chain-length <chainLength> -v
Create secured cert file with key chain length and mode:
- chaos create-cert -c <certFile> --chain-length <chainLength> --chaos-mode <chaosMode> --prompt -v
Create sample cert spec file (for you to edit):
- chaos create-spec --spec-file <specFile> -v
Create secured cert file from (edited) cert spec file:
- chaos create-cert -c <certFile> --spec-file <specFile> --prompt -v
Encrypt input file to output file, use secured cert:
- chaos encrypt -i <inputFile> -o <outputFile> -c <certFile> --prompt -v
Decrypt input file to output file, use secured cert:
- chaos decrypt -i <inputFile> -o <outputFile> -c <certFile> --prompt -v
Print cert file info:
- chaos cert-info <certFile> -v
Print secured cert file info:
- chaos cert-info <certFile> --prompt -v
Print length of single chaos key (bytes):
- chaos encoded-length -v
To show the help text:
- chaos -h
To print the system info:
- chaos --sysinfo
BUGS
See Bitbucket issues at <https://bitbucket.org/funcodez/funcodes-chaos/issues>
AUTHOR
Siegfried Steiner steiner@refcodes.org
