312-49 · Question #358
Click on the Exhibit Button To test your website for vulnerabilities, you type in a Quotation mark (? for the username field. After you click Ok, you receive the following error message window: What…
The correct answer is B. SQL injection is possible. When a single quotation mark (') is entered into a login or input field and the application returns a database error (such as a SQL syntax error), it means the input is being passed directly to a SQL query without proper sanitization or parameterization. The quotation mark…
Question
Click on the Exhibit Button To test your website for vulnerabilities, you type in a Quotation mark (? for the username field. After you click Ok, you receive the following error message window: What can you infer from this error window?
Options
- ASQL injection is not possible
- BSQL injection is possible
- CThe user for line 3306 in the SQL database has a weak password
- DThe Quotation mark (? is a valid username
How the community answered
(52 responses)- A2% (1)
- B75% (39)
- C15% (8)
- D8% (4)
Explanation
When a single quotation mark (') is entered into a login or input field and the application returns a database error (such as a SQL syntax error), it means the input is being passed directly to a SQL query without proper sanitization or parameterization. The quotation mark breaks the SQL string syntax, causing the database to throw an error that is surfaced to the user. This behavior confirms that SQL injection is possible, because an attacker can craft malicious SQL statements that the database will execute.
Topics
Community Discussion
No community discussion yet for this question.