How does parameterized query help in preventing SQL Injection attacks?

  • It escapes special characters in user input
  • It encrypts SQL queries before execution
  • It restricts SQL queries to a predefined set
  • It validates SQL queries against a whitelist
A parameterized query helps prevent SQL Injection attacks by escaping special characters in user input. This ensures that user input is treated as data and not executable code. The other options do not accurately describe how parameterized queries work against SQL Injection.
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *