Drag steps to the numbered slots on the right, or tap a step then tap a slot.
CEH Scanning Networks and Enumeration Practice Question
Drag and drop the steps to perform a buffer overflow exploit in a controlled lab environment into the correct order.
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
Identify vulnerability, then find offset, then generate shellcode, then craft exploit, then execute
Identify vulnerability, find offset, generate shellcode, craft exploit, execute.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✓
Identify vulnerability, then find offset, then generate shellcode, then craft exploit, then execute
Why this is correct
This is the correct order because you must first know the vulnerability, then determine the offset to control EIP, then create the shellcode that fits within the buffer, then construct the full exploit payload, and finally execute it.
- ✗
Generate shellcode, then identify vulnerability, then find offset, then craft exploit, then execute
Why it's wrong here
This sequence is fundamentally flawed because shellcode generation is dependent on prior reconnaissance. An attacker must first identify a specific buffer overflow vulnerability, understand the target architecture, and determine critical constraints such as available buffer size, bad characters, and the exact return address overwrite location. Generating shellcode prematurely, without this context, would likely result in an incompatible or ineffective payload that cannot achieve arbitrary code execution.
- ✗
Identify vulnerability, then generate shellcode, then find offset, then craft exploit, then execute
Why it's wrong here
This is incorrect because generating shellcode before finding the offset may result in shellcode that is too large or does not align with the buffer structure. The offset is critical to know the exact location to overwrite EIP, which influences where shellcode can be placed.
- ✗
Find offset, then identify vulnerability, then generate shellcode, then craft exploit, then execute
Why it's wrong here
Attempting to find the offset before identifying a specific vulnerability is illogical and impractical. The "offset" refers to the precise number of bytes required to overwrite the Extended Instruction Pointer (EIP) or Return Instruction Pointer (RIP) on the stack, which is unique to a particular vulnerable buffer within a program. Without first identifying *which* buffer can be overflowed, there is no specific target or context to determine an offset, making this step impossible to execute effectively.
Go deeper
Related to this question
About these practice questions
One of 870 original CEH practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This CEH practice question is part of Courseiva's free EC-Council certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the CEH exam.