Exit 312-92 EC-Council Certified Secure Programmer v2 (ECSP)
Question 5 of 5
0% complete
Q5 Single choice

Malory is creating a webpage in PHP where users will have to logon to gain access to certain areas of the site.
Malory is concerned that malicious users might try to exploit her site, so she decides to use the following code to prevent some attacks. What is Malory trying to prevent here?

$username = addslashes($_POST["username"]);

$password = addslashes($_POST["password"]);

  • A

    SQL injection

  • B

    CSS attack

  • C

    Reflected mode XSS attack

  • D

    CSRF attack