Create your own Capture the Flags
Wanted to create a standalone CTF server to host offline.
HIGHLY RECOMMEND not using a special password, hashing has not been added yet.
Usernames and passwords are stored in /ctf/data/users.yaml
Tasks and flags are stored in /ctf/data/flags.yaml
Flag submissions are stored in /ctf/data/submissions.yaml
You can modify any of those files to reset users, flags and submissions.
pip install flask pyyaml
Git this repo
git clone https://github.com/bwithe/ctf
Start the webserver
cd ctf/app
python main.py
Build the image
docker build -t ctf .
Start the container
docker run -d -p 8000:8000 --name ctf --hostname ctf ctf-image
Pull python image
docker pull python:3.11-slim
Start the container
docker run -it --name ctf --hostname ctf -p 80:8000 <image> bash
Update and install dependencies
apt udapte
apt install wget nano git -y
pip install flask pyyaml
Git this repo
git clone https://github.com/bwithe/ctf
Start the webserver
cd ctf/app
python main.py