1337 Local CTF: BASIT — Apache Traversal → Encrypted ZIP → Nested Stego
BASIT
Challenge Context
BASIT was a network forensics challenge. The PCAP showed an attacker exploiting an internal Apache server and exfiltrating an encrypted archive.
Reconnaissance
The traffic identified:
attacker: 10.0.0.66victim: 10.0.0.10server: Apache/2.4.49 (Ubuntu)Apache 2.4.49 is vulnerable to path traversal via CVE-2021-41773 when misconfigured.
Attack Chain
Apache path traversal -> read /var/www/html/.env -> recover archive password -> download bocal.zip -> decrypt ZIP -> inspect PNG trailing data -> extract hidden ZIP -> recover flag from final image/textExploitation
The traversal used the classic encoded path:
/icons/.%2e/%2e%2e/%2e%2e/The attacker read sensitive files including:
/etc/passwd/etc/hostname/var/www/html/.env/var/www/html/.htpasswdThe .env exposed an archive secret. That password decrypted bocal.zip. Inside, bocal.png contained data after the PNG IEND marker: another hidden ZIP. Extracting that second layer led to the final flag.
Nested structure:
bocal.zip -> bocal.png -> data after IEND -> hidden ZIP -> staff.txt / staff.png -> flagFlag
leet{W1r3sh4rk_k1ws1_lh4dr4_1mz47a}Lesson Learned
Good PCAP forensics reconstructs the attacker’s path, not just the final artifact. Here the flag only made sense after following traversal, credential disclosure, archive extraction, and PNG stego layers.
Cover: Wallhaven yq8w5k.
Share Article
If this article helped you, please share it with others!