XSS Manual
XSS Manual
keralacyberforce.in
Introduction
Cross Site Scripting or XSS vulnerabilities have been reported and exploited since 1990s. XSS got
listed as the top 2nd Vulnerability in the OWASP 2010 Web application Vulnerabilities list.
Cross-site scripting (XSS) is a type of security vulnerability typically found in web applications
which allows the attackers to inject client-side script into web pages viewed by other users. The
execution of the injected code takes place at client side. A cross site scripting vulnerability can
be used by the attacker to bypass the Same Origin Policy (SOP). In the past, the potentials of
XSS vulnerability were not known. XSS was mainly used for stealing cookies and for temporary
or permanent defacements and was not considered as high risk vulnerability. But later XSS
tunneling and Payload delivering showed us the potential of XSS Vulnerability. Most of the large
websites like Google, Facebook, Twitter, Microsoft, and Amazon etc. even now suffers from XSS
bugs. That’s a brief introduction about XSS.
Client side code injection: A hacker can inject malicious codes and execute them at client side.
DOS: A hacker can perform DOS against a remote server or against the client itself.
Cookie Stealing: A hacker can obtain the session cookies or tokens of a victim.
Malware Spreading: A hacker can spread malwares with a website which is vulnerable to XSS.
Phishing: A hacker can embed or redirect to a fake page of the website to get the login
credentials of the victim.
Xenotix XSS Exploit Framework is a penetration testing tool to detect and exploit XSS
vulnerabilities in Web Applications. This tool can inject codes into a webpage which are
It is having an inbuilt XSS payload list of above 350+ XSS payloads. It includes HTML5
compactable XSS injection payloads. Most of the XSS filters are implemented using String
Replace filter, htmlentities filter and htmlspecialcharacters filter. Most of these weakly designed
filters can be bypassed by specific XSS payloads present in the inbuilt payload list.
The above chart shows the number of XSS Payloads in different XSS Scanning tools available in
market. So it’s clear that Xenotix XSS Exploit Framework got the world’s second largest XSS
Payload list.
Ajin Abraham Kerala Cyber Force
Learn | Contribute | Share
XSS Key logger
The tool includes an inbuilt victim side Key logger which is implemented using JavaScript and
PHP. PHP is served with the help of a portable PHP server named QuickPHP by Zach Saw. A
JavaScript file is injected into the web application vulnerable to XSS and is presented to the
victim. The script captures the keystrokes made by the victim and send to a PHP file which
further write down the logs into a text file.
Java Drive-by download can be implemented with Xenotix XSS Exploit Framework. It allows the
attacker to download and run a malicious executable file on the victim’s system without his
knowledge and permission. You have to specify the URL for the malicious executable and then
embed the drive-by implemented webpage into a XSS vulnerable page and serve your victim.
When the victim view the injected page, the java applet client.jar will access the command
Ajin Abraham Kerala Cyber Force
Learn | Contribute | Share
prompt and with the help of echo command, write down some scripts to a Visual basic script
file named winconfig.vbs in the temp directory(%temp%) and then the cmd.exe will start
winconfig.vbs. The winconfig.vbs will download the malicious executable specified by you in the
URL to temp directory and rename it as update.exe and finally it will execute update.exe. The
downloading and executing of the malicious executable happened without the knowledge and
permission of the victim.
The tool is having an automatic test mode based on a time interval. You have to specify the
time interval according to the time taken by a webpage to load which depends on your
bandwidth. It will test all the payloads one by one after the specified time interval. With this
feature automated XSS testing can be done. You don’t have to check all the 350+ payloads
manually.
XSS Encoder
The inbuilt Encoder will allow encoding into different forms to bypass various filters and Web
Application Firewalls. The encoder supports Base64 Encoding, URL Encoding, HEX Encoding,
HTML Characters Conversion, Character Code Conversion and IP to Dword, Hex and Octal
conversions.
For testing against XSS in Xenotix XSS Exploit Framework you should specify the protocol, which
is http or https. Then give the website URL other than the suspected variable in the field after
Conclusion
XSS in popular website is a high security threat. Xenotix XSS Exploit Framework can be used by
Security Analysts to perform Penetration test on Web Applications against XSS vulnerability.
Google Vulnerability Reward Program, Facebook Bounty etc. are there. So go for XSS hunting
and grab your bounty.
References
Papers
Our Favorite XSS Filters/IDS and how to Attack Them - Eduardo Vela and David Lindsay.
Blackbox Reversing of XSS Filters - Alexander Sotirov.
Advanced Cross-Site-Scripting with Real-time Remote Attacker Control - Anton Rager
Bypass XSS filters - k3nz0
XSS for Fun and Profit - Lord Epsylon
Bypassing Web Application Firewalls (WAFs) - Ing. Pavol Lupták
Abusing Internet Explorer 8’s XSS Filters –Eduardo Vela Nava, David Lindsay
Websites