Monday, July 25, 2011

Dirt cheap steganography

This steg module is based on code, ideas and images from .
It requires numpy & matplotlib but can be reworked to depend on pypng instead of matplotlib

Sample usage
$ python2.7 --help


Hide/Unhide info in images as described in this post:

usage: [options]


-h, --help show this help message and exit

-v DEBUG, --verbose=DEBUG

Debug. Higher integers increases verbosity

-e ENCODED_FILE, --encoded_file=ENCODED_FILE

Encoded PNG file to work with. Default is


-d DATA_FILE, --data_file=DATA_FILE

File with decoded data or with data to encode.

Example decode of data hidden in the wolfram blog images
$ python2.7 -e steg_chicken_secret.png -d chicken.txt
$ cat chicken.txt ;echo

This is a secret message.

$ python2.7 -e alice.png -d alice.txt

$ file alice.txt

alice.txt: UTF-8 Unicode English text, with very long lines, with no line terminators

$ python2.7 -e finalImage.png -d data.jpg

$ file data.jpg

data.jpg: JPEG image data, JFIF standard 1.01, comment: "Created by Wolfram Mathematica "

No comments:

Post a Comment