nerdexam
Cisco

200-201 · Question #387

How is SQL injection prevented?

The correct answer is A. validate and sanitize user input. SQL injection is a type of injection attack where malicious SQL statements are inserted into an entry field for execution. The primary way to prevent SQL injection is by validating and sanitizing user input. This involves checking the input for malicious content and ensuring it…

Submitted by lukas.cz· Mar 6, 2026Security Concepts

Question

How is SQL injection prevented?

Options

  • Avalidate and sanitize user input
  • Baddress space layout randomization
  • Crun the web server as a nonprivileged user
  • Dhost profiling

How the community answered

(35 responses)
  • A
    91% (32)
  • B
    6% (2)
  • D
    3% (1)

Explanation

SQL injection is a type of injection attack where malicious SQL statements are inserted into an entry field for execution. The primary way to prevent SQL injection is by validating and sanitizing user input. This involves checking the input for malicious content and ensuring it adheres to expected patterns. Prepared statements (parameterized queries) are also highly effective, as they treat user input as data rather than executable code. Implementing these practices ensures that any input received from users does not manipulate SQL queries in a harmful way.

Topics

#SQL injection prevention#Input validation#Input sanitization

Community Discussion

No community discussion yet for this question.

Full 200-201 Practice