nerdexam
CompTIA

CAS-003 · Question #159

select id, firstname, lastname from authors User input= firstname= Hack;man lastname=Johnson Which of the following types of attacks is the user attempting?

The correct answer is D. SQL injection. The code in the question is SQL code. The attack is a SQL injection attack. SQL injection is a code injection technique, used to attack data-driven applications, in which malicious SQL statements are inserted into an entry field for execution (e.g. to dump the database contents…

Enterprise Security Operations

Question

select id, firstname, lastname from authors User input= firstname= Hack;man lastname=Johnson Which of the following types of attacks is the user attempting?

Options

  • AXML injection
  • BCommand injection
  • CCross-site scripting
  • DSQL injection

How the community answered

(22 responses)
  • A
    5% (1)
  • B
    9% (2)
  • D
    86% (19)

Explanation

The code in the question is SQL code. The attack is a SQL injection attack. SQL injection is a code injection technique, used to attack data-driven applications, in which malicious SQL statements are inserted into an entry field for execution (e.g. to dump the database contents to the attacker). SQL injection must exploit a security vulnerability in an application's software, for example, when user input is either incorrectly filtered for string literal escape characters embedded in SQL statements or user input is not strongly typed and unexpectedly executed. SQL injection is mostly known as an attack vector for websites but can be used to attack any type of SQL database.

Topics

#SQL injection#web application attacks#input validation#attack identification

Community Discussion

No community discussion yet for this question.

Full CAS-003 Practice