Certified Ethical Hacker (CEH v13) — Question 119
You're the security manager for a tech company that uses a database to store sensitive customer data. You have implemented countermeasures against SQL injection attacks. Recently, you noticed some suspicious activities and suspect an attacker is using SQL injection techniques. The attacker is believed to use different forms of payloads in his SQL queries. In the case of a successful SQL injection attack, which of the following payloads would have the most significant impact?
Answer options
- A. UNION SELECT NULL, NULL, NULL -- : This payload manipulates the UNION SQL operator, enabling the attacker to retrieve data from different database tables
- B. ' OR username LIKE '%': This payload uses the LIKE operator to search for a specific pattern in a column
- C. ' OR '1'='l: This payload manipulates the WHERE clause of an SQL statement, allowing the attacker to view unauthorized data
- D. ' OR 'a'='a; DROP TABLE members; --: This payload combines the manipulation of the WHERE clause with a destructive action, causing data loss
Correct answer: D
Explanation
Option D is the most impactful because it not only manipulates the WHERE clause but also includes a command to drop a table, leading to potential data loss. Options A, B, and C may allow unauthorized access or data retrieval, but they do not carry the same destructive potential as option D.