EC-Council
312-92 · Question #29
What is the following shellcode trying to accomplish? int main(void) { mkdir("A"); chdir("A"); chroot("..//..//..//..//..//..//..//..//"); system("/bin/sh")
The correct answer is B. Break out of "chroot jail". See the full explanation below for the reasoning.
Question
What is the following shellcode trying to accomplish? int main(void) { mkdir("A"); chdir("A"); chroot("..//..//..//..//..//..//..//..//"); system("/bin/sh")
Options
- ACorrupt the Linux kernel
- BBreak out of "chroot jail"
- CTraverse to the /bin/sh directory
- DCreate a buffer overflow
How the community answered
(41 responses)- A7% (3)
- B71% (29)
- C17% (7)
- D5% (2)
Community Discussion
No community discussion yet for this question.