markdown source
How to do steganography
---
title: How to do steganography
date: 2026-11-14
description: What actually worked in my attempts to hide files.
reading_time: 2
tags: steganography · software
published: true
---
This is my work to encode a file into an actual **playable FLAC file**, and it's simpler than you'd expect. The main tradeoff is the resulting size, but you can in fact encode a 2.8 KB file into a 292 KB FLAC file.
## Demo
Cut the FLAC Some Slack is my official demo:
* [GitHub Source Code](https://github.com/JustAnEric/ctfss)
* [Demo Site](https://ctfss.erikku.page)
*make sure not to upload anything sensitive!
## Main process
For this, I used allocations on every one of these frequencies, totalling about 40 frequencies 'in bandwidth' or working in tandem:
```python
[
500, 1000, 1500, 2000,
2500, 3000, 3500, 4000,
4500, 5000, 5500, 6000,
6500, 7000, 7500, 8000,
8500, 9000, 9500, 10000,
10500, 11000, 11500, 12000,
12500, 13000, 13500, 14000,
14500, 15000, 15500, 16000,
16500, 17000, 17500, 18000,
18500, 19000, 19500, 20000,
]
```
The decoder will scan all of these frequencies for an on or off bit for 1764 sample intervals (at a base sample rate of 44100, so `sr * 0.04`), and decode it into **40 bits** (because 40 frequencies) at a time. This means one sample in a file can account for more than one text/ASCII character.
The encoder will create these frequencies as described, place the magic header for `b"CTFSS"`, and give back the file.
You could technically go all the way up to a staggering 1.048575 MHz, unlocking way more frequency bands to store data past the human hearing range, but we (more me) like to keep our data hearable and it's just cooler that way... 😎
## Website
The website I made (at [https://ctfss.erikku.page](https://ctfss.erikku.page) primarily) uses an async decoder+encoder for the format to improve concurrency. It is hosted on the *chonk* server back at home!

This could be considered free compute* for your CTFSS files, especially after the RAM+CPU+GPU+SSD+HDD crises that's still ongoing...
## Plans for the future
* Introduce encryption along with all else!