Nullcon Goa Hack IM 2025 CTF
Web Craphp: CRC Collision Challenge Walkthrough
Challenge
Initial Reconnaissance
The challenge presents a login form accessible through a web interface:
The source code, accessible via the ?source
parameter, reveals a PHP-based application:
|
|
Technical Analysis
The source code analysis reveals several critical components:
- Hardcoded password:
AdM1nP@assW0rd!
- Two hash functions:
- CRC16 (custom implementation)
- CRC8 (with lookup table)
- Input validation logic
Challenge Requirements
The flag retrieval requires a password input that meets the following criteria:
- Length must match
AdM1nP@assW0rd!
(15 characters) - Must NOT equal
AdM1nP@assW0rd!
- Must generate identical CRC16 hash
- Must generate identical CRC8 hash
Exploitation Strategy
The vulnerability stems from using CRC (Cyclic Redundancy Check) algorithms for password validation. These algorithms, designed for error detection rather than security, are susceptible to hash collisions.
Solution Approach
The exploitation utilizes character permutations of the original password. This method proves effective because:
- Maintains the required length constraint
- Utilizes the existing character set
- Exploits CRC’s sensitivity to character ordering
Solution Implementation
The following Go code systematically generates and tests permutations:
|
|
Execution Results
Running the solution program produces a valid collision:
Flag Retrieval
Submitting the generated collision string to the web form results in successful flag capture:
Security Recommendations
- Avoid non-cryptographic hash functions in security contexts
- Implement proper cryptographic hash functions
- Design robust authentication mechanisms
Web ZONEy: DNS Challenge Walkthrough
Challenge
Initial Reconnaissance
The challenge immediately indicates DNS involvement through:
- UDP service on port 5007 (non-standard DNS port)
- Domain name reference in “zoney.eno”
- Emphasis on “ZONE” in the name
Initial DNS Enumeration
Basic DNS enumeration on the service revealed a functioning DNS server:
|
|
Technical Analysis
DNS Record Discovery
MX record query revealed an additional subdomain:
|
|
NSEC Record Investigation
NSEC record query for the discovered subdomain exposed the flag location:
|
|
Solution Implementation
The solution path followed a logical DNS enumeration process:
- Initial zone reconnaissance
- Discovery of additional subdomains through MX records
- NSEC record query revealing hidden domains
- Flag retrieval from the exposed domain
Final flag retrieval command:
|
|