GPEN · Question #45
You enter the following URL on your Web browser: af../windows/system32/cmd.exe?/c+dir+c:\ What kind of attack are you performing?
The correct answer is D. Directory traversal. The URL uses dot-dot-slash sequences to navigate outside the web root and execute a system command, which is the defining characteristic of a directory traversal attack.
Question
You enter the following URL on your Web browser:
af../windows/system32/cmd.exe?/c+dir+c:\ What kind of attack are you performing?
Options
- ASession hijacking
- BReplay
- CURL obfuscating
- DDirectory traversal
How the community answered
(22 responses)- A14% (3)
- B5% (1)
- C5% (1)
- D77% (17)
Why each option
The URL uses dot-dot-slash sequences to navigate outside the web root and execute a system command, which is the defining characteristic of a directory traversal attack.
Session hijacking involves stealing or forging a valid session token to impersonate an authenticated user, which is unrelated to the file path manipulation shown.
A replay attack captures and retransmits legitimate network packets to authenticate or trigger actions, not to navigate file system paths.
URL obfuscation involves disguising a URL to hide its true destination (e.g., using hex encoding or misleading domains), not traversing the server file system.
A directory traversal attack (also called path traversal) uses sequences like '../' to move up the directory hierarchy beyond the intended web root, accessing restricted files or executables. The URL shown navigates to cmd.exe on the Windows system path and appends a command via the query string (?/c+dir+c:\), demonstrating classic traversal exploitation to execute arbitrary OS commands.
Concept tested: Directory traversal attack via URL path manipulation
Source: https://owasp.org/www-community/attacks/Path_Traversal
Topics
Community Discussion
No community discussion yet for this question.