Which of the following methods is MOST effective in mitigating Cross-Site Scripting (XSS) vulnerabilities within HyperText Markup Language (HTML) websites?
A.
Use antivirus and endpoint protection on the server to secure the web-based application
B.
Place the web-based system in a defined Demilitarized Zone (DMZ)
C.
Use .NET framework with .aspx extension to provide a higher level of security to the web application so that the web server display can be locked down
D.
Not returning any HTML tags to the browser client
D. Not returning any HTML tags to the browser client.
Cross-Site Scripting (XSS) vulnerabilities occur when untrusted data is included in a web page and executed as code in a user's browser. By not returning any HTML tags to the browser client, you are effectively preventing any malicious code injection into the page. This approach, known as output encoding or input validation, helps ensure that user input is treated as plain text and not as executable code. It's a fundamental security practice to prevent XSS attacks.
The suggested answer D is correct
The most effective method for mitigating Cross-Site Scripting (XSS) vulnerabilities within HTML websites is option D - not returning any HTML tags to the browser client.
XSS exploits allow attackers to inject malicious client-side scripts. By not returning any HTML tags at all, you completely prevent the ability for attackers to inject active content that could execute scripts. This stops XSS at the root.
Antivirus (A) cannot catch all XSS payloads.
DMZs (B) only limit network access, not code injection.
.NET (C) helps but does not inherently prevent all XSS like removing HTML tags does.
By configuring the application to return no HTML tags, you guarantee malicious scripts have no entry point, shutting down potential XSS vectors altogether. This direct, foolproof approach makes it the most effective mitigation.
B. At work all web servers are in a DMZ, and this makes sense because the DMZ is separated from the rest of the infrastructure. The question talks about mitigation, even if someone runs a script since it's in the DMZ it won't go anywhere.
For the administrator of a website, defenses against XSS include
maintaining a patched web server, using web application firewalls,
operating a host-based intrusion detection system (HIDS), auditing
for suspicious activity, and, most important, performing server-side
input validation for length, malicious content, and metacharacter
filtering. As a web user, you can defend against XSS by keeping your
system patched, running antivirus software, and avoiding
nonmainstream websites. There are add-ons for some web browsers,
such as NoScript for Firefox and uBlock Origin for Chrome, that allow
only scripts of your choosing to be executed.
upvoted 1 times
...
Log in to ExamTopics
Sign in:
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
1460168
3 months, 3 weeks agogjimenezf
9 months, 3 weeks agoYesPlease
11 months agoSoleandheel
11 months, 1 week agoInclusiveSTEAM
1 year, 1 month agoVoxycs
1 year, 1 month agoHughJassole
1 year, 5 months agoTygrond87
1 year, 6 months agojackdryan
1 year, 6 months agoDelab202
1 year, 7 months ago