Created
May 24, 2013 01:20
-
-
Save farukuzun/5640708 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from mechanize import Browser | |
url = "http://xss.progphp.com/" | |
forms = [] | |
br = Browser() | |
br.set_handle_robots(False) | |
br.addheaders = [('User-agent', 'Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.0.1) Gecko/2008071615 Fedora/3.0.1-1.fc9 Firefox/3.0.1')] | |
page = br.open(url) | |
for link in br.links(): | |
print link | |
try: | |
req = br.click_link(link) | |
br.open(req) | |
except: | |
pass | |
for form in br.forms(): | |
print form |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment