No description
Find a file
2026-07-07 00:28:29 +01:00
.gitignore initial commit 2026-07-07 00:20:55 +01:00
.python-version initial commit 2026-07-07 00:20:55 +01:00
decode.py initial commit 2026-07-07 00:20:55 +01:00
lunachocken_lying_flag.png initial commit 2026-07-07 00:20:55 +01:00
main.py initial commit 2026-07-07 00:20:55 +01:00
pyproject.toml initial commit 2026-07-07 00:20:55 +01:00
README.md Add a README.md 2026-07-07 00:28:29 +01:00
uv.lock initial commit 2026-07-07 00:20:55 +01:00

Packet Chaos

Scenario Desc

Find order in chaos, and you will find your way

Challenge Explanation

  • A Picture with flag is decoded (or any file really) and split into 70 width chunks per packet.
  • Noise is inserted via 5 packets per valid packet with the same packet length but random ascii text instead, you can not differentiate between noise and signal
  • The noisy packets have their checksum invalidated which is the way of realising how to figure out what to discard
  • The packets are completely out of order and shuffled, use the payload data: Index:Data where index is the order of the packet
  • Combine the packet data once sorted into a base64 string and decode it, save as binary to a file to get the picture

Characteristics

  • Difficulty: Medium?
  • Category: Network Forensics

Solution

  • Take the ctf.pcap into wireshark, filter for "ip.checksum.status == 1", exported specified packets with valid checksums
  • Use decode.py on the file
  • Voila

Generation

  • Inputs are variables at the top of the file

RANDOM_PACKETS = 5 # Random packets to add per file. e.g. 1:5 signal to noise ratio BODY_SIZE = 70 # Generated Body size for the packet payload OUTPUT_FOLDER = "pcap" PCAP_FILE = "ctf.pcap" IMAGE_FILE = "lunachocken_lying_flag.png" # My silly horsey but with the flag