Question 4 of 10Pro Only
How does SQL injection work, and what are the best practices for preventing it?
Sample answer preview
SQL injection occurs when untrusted input is included in a SQL query without proper handling, allowing attackers to modify the query's logic. It remains one of the most dangerous and common vulnerabilities. Consider a login query built by concatenating user input.
parameterized queriesprepared statementsUNION attackinput validationleast privilegeORM