Β· Steganography Β· 3 min read
Steganography Cheatsheet for CTF Beginners

Table of Contents
- 1.π Step-by-Step File Analysis
- 1.1π Basic Commands
- 1.2π§΅ Metadata Extraction
- 2.π§© Embedded File Discovery
- 2.1π Binwalk β File Carving Tool
- 3.π¨ Image Steganography
- 3.1πΌ Visual Tricks
- 3.2π§ Bit-Level Tools
- 3.3π§° Extraction Tools
- 3.4πΌ Online Tools
- 4.π§ Audio Steganography
- 4.1π Useful Tools
- 5.π₯ Video Steganography
- 5.1π Frame & Audio Extraction
- 6.π PDF Stego
- 6.1π Text & Metadata
- 6.2π Crack Protected PDFs
- 7.π₯ Advanced Tricks & Scripts
- 7.1π Convert Binary to Image
- 7.2𧬠Invert Pixel Colors (Python)
- 8.π OSINT & Comparisons
- 9.π οΈ Tool Index (Summary)
Steganography is the art of concealing messages in plain sight β hiding data in files that appear normal. In Capture The Flag (CTF) contests, stego challenges often hide flags inside images, audio, videos, PDFs, or metadata.
π Step-by-Step File Analysis
π Basic Commands
file target.jpg strings target.jpg | head -n 50 xxd target.jpg | head hexdump -C target.jpg | head
Check the fileβs true type, readable strings, and hex patterns. You may discover plaintext flags, passwords, or data headers.
π§΅ Metadata Extraction
exiftool target.jpg
Extract EXIF comments, timestamps, GPS info, and hidden metadata.
Also try:
exiv2 target.jpg
For direct metadata manipulation or cleanup.
π§© Embedded File Discovery
π Binwalk β File Carving Tool
binwalk -Me target.jpg
Key Options:
-e
: Extract embedded files-M
: Recursive extraction-z
: Carve data blocks without extraction-R
: Raw hex pattern match (e.g.,\x1f\x8b
for gzip)-E
: Entropy scanning-W
: Hex diff mode
Use dd
if you manually need to extract embedded segments.
π¨ Image Steganography
πΌ Visual Tricks
Open image and observe β flag may be painted in.
Use GIMP: adjust brightness, contrast, curves, color levels.
Use ImageMagick to compare images:
compare original.png modified.png diff.png
π§ Bit-Level Tools
Tool | Usage |
---|---|
stegsolve | Bit-plane viewer (bit-level hidden info) |
zsteg | Bit analysis of PNG/BMP |
stegonline | Web-based image steg operations |
Steganabara | LSB amplifier & visualizer |
sigBits | Significant bits stego decoder |
pngcheck | Dump/analyze PNG chunks |
pngtools | Deep chunk-level PNG analysis |
Use stegsolve to identify QR codes, LSB data, or color-filtered patterns.
π§° Extraction Tools
Tool | Usage |
---|---|
steghide | Hide/extract in JPG, BMP, WAV |
stegseek | Fast brute-force for steghide |
stegcracker | Brute-force JPG stego files |
outguess | Stego in JPG/PPM files |
stegextract | Auto-detect hidden data |
jsteg | LSB-based JPEG stego |
stegpy | Simple Python LSB tool |
stegosaurus | Embed data into Python bytecode |
Snow/stegsnow | Whitespace stego tool |
Example:
steghide extract -sf secret.jpg stegseek secret.jpg rockyou.txt
πΌ Online Tools
AperiSolve β Multi-layer analyzer
Image ELA β Error level analysis (detects manipulations)
π§ Audio Steganography
π Useful Tools
Tool | Purpose |
---|---|
DeepSound | Hide/extract files in .wav audio |
sonic-visualiser | Visualize spectrograms, waveforms |
audacity | Waveform editing, reversal, decoding |
Decodes dial tones from audio | |
Snow / stegsnow | Whitespace stego in audio |
Use sonic-visualiser with linear/log scale spectrogram + contrast filters.
π₯ Video Steganography
π Frame & Audio Extraction
ffmpeg -i video.mp4 frame_%04d.png
Analyze individual frames using
zsteg
,stegsolve
.Open audio separately in Audacity for reverse/LSB tricks.
Tool:
hipshot β Convert video/photo series into long-exposure-style images to reveal stego data.
π PDF Stego
π Text & Metadata
pdfinfo file.pdf pdftotext file.pdf output.txt
π Crack Protected PDFs
pdf2john file.pdf > hash.txt john --wordlist=rockyou.txt hash.txt
π₯ Advanced Tricks & Scripts
π Convert Binary to Image
convert -depth 8 -size 300x300+0 gray:data.raw output.png
View strange binary blobs visually.
𧬠Invert Pixel Colors (Python)
import Imageif __name__ == '__main__': img = Image.open('input.png') in_pixels = list(img.getdata()) out_pixels = list()
for i in range(len(in_pixels)): r = in_pixels[i][0] g = in_pixels[i][1] b = in_pixels[i][2] out_pixels.append( (255-r, 255-g, 255-b) )
out_img = Image.new(img.mode, img.size) out_img.putdata(out_pixels) out_img.save("output_inverted.png", "PNG")
the image looks like itβs just a random noise we should make sure of it. We can, in fact, measure its randomness. Pixels of each color can appear in each place of the image with equal chance. If itβs false for some colors, we certainly want to look at them. Here is a script for that, and the results appears below:
$ php solve.php image.pngMAX disp: 1492.41; AVG: 92.82GAP: 351.61 Β± 200DONE.
π OSINT & Comparisons
TinEye: Reverse search
Use ImageMagick or diff-pixel tools for overlays
Compare layers in Adobe/GIMP if image has metadata for layer stacking
π οΈ Tool Index (Summary)
Tool | Category | Function |
---|---|---|
AperiSolve | Online | Layer inspection |
FotoForensics | Online | ELA and manipulation detection |
BPStegano | CLI | LSB encoding (Python3) |
Stegsolve | GUI (Java) | Bit-layer viewer |
Zsteg | CLI | PNG/BMP LSB decoding |
Steghide | CLI | Stego in image/audio |
Stegseek | CLI | Brute-force steghide |
Outguess | CLI | JPG/PPM stego |
Snow / Stegsnow | CLI | Whitespace stego |
jsteg | CLI | JPEG LSB |
sigBits | CLI | LSB decoder |
stegcracker | CLI | JPG bruteforce stego |
stegextract | CLI | Auto extract data |
ImageMagick | CLI | Compare, convert, XOR |
pngcheck | CLI | PNG chunk inspection |
pngtools | CLI | Advanced PNG analysis |
StegOnline | Web | Encode/Decode images |
Image Steganography | Web | JS-based LSB tool |
OpenStego | GUI | Random LSB |
DeepSound | GUI | Audio file steganography |
hipshot | CLI | Video β long exposure frame |
sonic-visualiser | GUI | Audio spectrum viewer |
DTMF Tools | Audio | Decode dial tones |
pdf2john | CLI | Crack PDF password |
Stegosaurus | Python | Embed in bytecode |
StegoVeritas | Python | Multi-stego toolkit |
Stegpy | Python | Basic LSB tool |
BPStegano | Python | LSB encoding (Python3) |
Steganabara | GUI | LSB amplifier & visualizer |
Magic Eye Solver | Web | Hidden info from images |
SmartDeblur | GUI | Deblur images |
Exiv2 | CLI | Image metadata manipulation |
Exif | CLI | Show EXIF info |
Stegbreak | CLI | Brute-force JPG stego |
Binwalk | CLI | Embedded file extraction |