This repository was imported from https://github.com/smadi0x86/Cool-CTFd <3
CoolCTFd is a combination of CTFd and CTFd-Whale plugin that is meant to address the issue of the old CTFd-whale plugin version and make it compatible with CTFd.
This project was created for the sole purpose of helping the CTFd community to have a better experience with CTFd-Whale plugin as it was a tedious process to get it working.
CTFd-Whale is a plugin for CTFd that allows you to run challenges as standalone containers. It provides a way to deploy challenges in Docker containers, making it easier to manage and isolate challenges. For more information, please refer to the CTFd-Whale GitHub Repository.
- Run challenges in isolated Docker containers
- Support for both standalone and multi-container challenges
- Automatic container lifecycle management
- Integration with frp for challenge access
- Support for both single-server and multi-server deployments
This repository contains everything you need to run CTFd with CTFd-Whale. Simply clone this repository and follow the deployment guides:
git clone https://github.com/Cyber-Security-Club-HTU/CTF-Setup CTFd
cd CTFd
Then follow either the basic or advanced deployment guide.
The basic deployment runs CTFd and all challenges on a single server. This is suitable for smaller CTFs or testing environments.
See BASIC_DEPLOYMENT.md for detailed instructions.
The advanced deployment separates CTFd and challenges across multiple servers. This is suitable for production environments or larger CTFs.
See ADVANCED_DEPLOYMENT.md for detailed instructions.
See NETWORK_DOCS.md for detailed instructions.
CTFd and CTFd-Whale are already included in this repository. There's no need to clone them separately when following the deployment guides.
When deploying CTFd on your server, please make sure to harden your server as well.
Check out Hardening Folder for more information.
- API URL:
unix:///var/run/docker.sock
(single server) orhttps://target_server_ip:2376
(multi-server) - Credentials: Leave empty for local Docker or path to client certificates for remote Docker
- Swarm Nodes:
linux-1
(or your node label) - Use SSL: Unchecked for local Docker, checked for remote Docker
- Auto Connect Network:
ctfd_frp_containers
(single server) orchallenges
(multi-server) - Dns Setting:
1.1.1.1
- Auto Connect Containers: Leave empty
- Multi-Container Network Subnet:
174.1.0.0/16
- Multi-Container Network Subnet New Prefix:
24
- Router type:
frp
- API URL:
http://frpc:7400
- Http Domain Suffix:
your-domain.com
- External Http Port:
8001
- Direct IP Address:
your-domain.com
- Direct Minimum Port:
10000
- Direct Maximum Port:
10100
- Frpc config template:
[common]
token = your_token
server_addr = frps
server_port = 7987
admin_addr = 0.0.0.0
admin_port = 7400
Check TROUBLESHOOT.md for more information.
Contributions are welcome! Please feel free to submit a Pull Request.
This project is licensed under Apache License 2.0. See the LICENSE file for details.