What is the danger of Reflected Cross Site Scripting?
I understand the Reflected XSS is dangerous, because it's possible. But what practical attacks can be performed using Reflected XSS?
|
What is the danger of Reflected Cross Site Scripting? I understand the Reflected XSS is dangerous, because it's possible. But what practical attacks can be performed using Reflected XSS? |
||||
|
|
|
You can do a lot when you can inject code into a page. For example, you can
|
|||
|
|
|
From OWASP:
What this means is I can put malicious code as part of the query parameters (the part of the url after the ampersand or question mark. I can send out a malicious email, use bit.ly or similar, or combine with other attacks to get you to make a unintended request, which is not filtering for the XSS. In terms of attacks, Phishing is going to be the big one, get someone to trust my evil link. This type of attack can also be combined with CSRF or any of a number of attacks, any time and attacker can get another site to run their code, and you to run the page with javascript enabled, its going to be bad. Some links |
||||
|
|
|
The wikipedia article does it great justice:
Do you have any questions about it? The standard XSS defense work against it; e.g., sanitize untrusted user input; e.g., only let them insert a small subset of HTML (from a safe limited markup language) or pass through a good html sanitizer/purifier, don't use unsafe patterns in scripts (e.g., eval in javascript on user input), ideally use a browser with CSP and sandboxing, etc. |
||||
|
|
|
I recommend you take a look at BeEF - The Browser Exploitation Framework http://beefproject.com/ It's basically a tool for showing the dangers of XSS. By using a reflected or persistent XSS attack, beef hooks into the given web site, and allows the attacker control over the browser on the given page. BeEF integrates with Metasploit, which allows an attacker to send browser exploits etc. to the user's browser. You can steal data, steal sessions etc. There are some decent videos on there as well. Anything BeEF can do, attackers can also do. XSS can be pretty bad. |
|||
|
|