Skip to content

dev-760/CTF

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🚩 CTF — Capture The Flag

A beginner-friendly CTF environment built for WSL.
Ubuntu runs the backend. Kali runs the menu. You just hack.


🧠 How It Works

┌─────────────┐        SSH        ┌──────────────────┐
│  Kali WSL   │ ◄───────────────► │   Ubuntu WSL     │
│  ctf menu   │   silent backend  │   challenges     │
│  ctf score  │                   │   flag checker   │
│  ctf flag{} │                   │   SSH server     │
└─────────────┘                   └──────────────────┘

The ctf command runs on Kali.
All challenges and data live on Ubuntu.
You will use SSH to interact with the challenges, and the ctf tool to submit your findings.


📦 Requirements

  • Windows with WSL2
  • Ubuntu distro (WSL)
  • Kali distro (WSL)
  • sudo access on both

⚡ Setup

1️⃣ On Ubuntu WSL

sudo bash install.sh

This will:

  • Install required tools
  • Set up 8 challenges under /opt/ctf/
  • Create the ctfplayer SSH user
  • Start the SSH server
  • Print your Ubuntu IP at the end

2️⃣ On Kali WSL

sudo bash kali_ctf_setup.sh <ubuntu-ip>

This will:

  • Install sshpass
  • Test the connection to Ubuntu
  • Install the ctf command globally on Kali

🎮 Playing

The ctf command lets you view descriptions and submit flags, but the actual hacking requires an SSH shell to Ubuntu.

1. The Dashboard (Kali)

Run this from Kali to view descriptions and submit flags:

ctf              # launch menu, pick a challenge
ctf flag{...}    # submit a flag
ctf score        # view your scoreboard

2. The Sandbox (Ubuntu)

Run this from Kali (or anywhere) to jump into the actual challenge environment. You will need to use Linux commands to explore /opt/ctf/challenges.

ssh ctfplayer@<ubuntu-ip>  # Password: ctf2024!

🗂️ Challenges

# Name Category Difficulty
01 Hidden in Plain Sight MISC Easy
02 Caesar's Last Words CRYPTO Easy
03 What Lies Beneath FORENSICS Easy-Medium
04 Strings Attached BINARY Easy
05 The Linux Labyrinth MISC Easy-Medium
06 XOR Marks the Spot CRYPTO Medium
07 Log Whisperer FORENSICS Easy
08 Permission Denied MISC Hard

🛠️ Tools You Might Need on Kali

base64    strings    file    xxd
unzip     grep       find    python3

📁 Repo Structure

ctf/
├── install.sh          ← run on Ubuntu WSL
├── kali_ctf_setup.sh   ← run on Kali WSL
└── README.md

👤 Author

dev-760 (https://github.com/dev-760)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors