Skip to content
Sharp

OWASP Vulnerabilities · interview question

Why is it risky to use string concatenation to build SQL queries?

Multiple choiceEasychapter-17-curatedpremiumowasp-vulnerabilitiessql-injection
Choose one answer
Answer and explanation

Correct answer

A. It allows SQL Injection attacks

Why

Using string concatenation for building SQL queries is risky because it opens the door to SQL Injection attacks, where attackers can manipulate the query by injecting malicious input.

Test yourself on OWASP Vulnerabilities

A free test with instant, explained results. No account needed.

Start free test
All OWASP Vulnerabilities questions →