2.3 Cross Site Scripting Flashcards

(7 cards)

1
Q

Cross Site Scripting

A

Abbreviation XSS. Cascading style sheets (CSS) are something else entirely.

Originally called cross site because of browser security flaws. Information from one site could be shared with another.

One of the most common web app vulnerabilities. Takes advantage of the trust a user has for a site. Complex and varied.

XSS commonly uses javascript. D

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Cross Site scripting attack

A
  1. Attacker sends a link containing a malicious script to a victim. 2. Victim clicks link and visits legitimate site. 3. Legitimate site loads in the victim’s browser. Malicious script is also executed. 4. Malicious script sends victims data (session cookies, etc.) to attacker.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Non- persistent (reflected) XSS attack.

A

Web site allows scripts to run in user input. Seach box is common source.

Attacker emails a link that takes advantage of this vulnerability. Runs a script that sends credentials/session IDs/ cookies to the attacker.

Script embedded in URL executes in the victim’s browser. As it came from the server.

Attacker uses credentials/session IDs/ cookies to steal victims’ information without their knowledge. Very sneaky.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Vulnerable XSS website (see video)

A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Persistent (stored) XSS attack

A

Attacker posts a message to a social network. Includes the malicious payload.

It’s now “persistent”. Everyone gets the payload.

No specific target. All viewers to the page.

For social networking this can spread quickly. Everyone who views the message can have it posted to their page. When someone else can view it and propagate it further.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Hacking a Subaru

A

June 2017, Aaron Guzman. Security researcher.

When authenticating with subarau, user gets a token. This token never expires (bad).

A valid token allowed any service request. Even adding your email address to someone’s else’s account. Now you have full access to someone’s else car.

Web front end included an XSS vulnerability. A user clicks a malicious link, and you have their token.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Protecting against XSS

A

Be careful when clicking untrusted links. Never blindly click in your email inbox. Never.

Consider disabling Javascript. Or control with an extension. This offers limited protection.

Keep your browser and applicants updated. Avoid the nasty browser vulnerabilities.

Validate input. Don’t allow users to add their own scripts to an input field.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly