Hide secrets with invisible characters in plain text securely using passwords 🧙🏻♂️⭐
OTHER License
Using npm,
$ npm install -g stegcloak
Using npm (to use it locally in your program),
$ npm install stegcloak
$ stegcloak hide
Options:
hide [options] [secret] [cover]
-fc, --fcover <file> Extract cover text from file
-fs, --fsecret <file> Extract secret text from file
-n, --nocrypt If you don't need encryption (default: false)
-i, --integrity If additional security of preventing tampering is needed (default: false)
-o, --output <output> Stream the results to an output file
-c, --config <file> Config file
-h, --help display help for command
$ stegcloak reveal
Options:
reveal [message]
-f, --file <file> Extract message from file
-cp, --clip Copy message directly from clipboard
-o, --output <output> Stream the secret to an output file
-c, --config <file> Config file
-h, --help display help for command
STEGCLOAK_PASSWORD environment variable, if set, will be used by default as password.
Configuration file support to configure StegCloak CLI and to avoid prompts. Read the config docs here.
const StegCloak = require('stegcloak');
const stegcloak = new StegCloak(true, false); // Initializes with encryption true and hmac false for hiding
// These arguments are used only during hide
// Can be changed later by switching boolean flags for stegcloak.encrypt and stegcloak.integrity
stegcloak.hide(secret, password, cover) -> string
const magic = stegcloak.hide("Voldemort is back", "mischief managed", "The WiFi's not working here!");
// Uses stegcloak.encrypt and stegcloak.integrity booleans for obfuscation
console.log(magic); // The WiFi's not working here!
stegcloak.reveal(data, password) -> string
const secret = stegcloak.reveal(magic, "mischief managed");
// Automatically detects if encryption or integrity checks were done during hide and acts accordingly
console.log(secret); // Voldemort is back
This amazing blog by Francesco Soncina shows how you could use the StegCloak API to watermark any text on your website.
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
MIT - Copyright (c) 2020 Jyothishmathi CV, Kandavel A, Mohanasundar M
The StegCloak logo was designed by Smashicons.