Certified Ethical Hacker (CEH v12) — Question 240

An ethical hacker is testing a web application of a financial firm. During the test, a 'Contact Us' form's input field is found to lack proper user input validation, indicating a potential Cross-Site Scripting (XSS) vulnerability. However, the application has a stringent Content Security Policy (CSP) disallowing inline scripts and scripts from external domains but permitting scripts from its own domain. What would be the hacker's next step to confirm the XSS vulnerability?

Answer options

Correct answer: A

Explanation

The correct answer is A because the application's CSP allows scripts from its own domain, which means the ethical hacker can use a domain-hosted script to test the XSS vulnerability. Options B and D are not viable due to the CSP restrictions, and option C is ineffective since the CSP disallows inline scripts.