Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/env python2
- banner = """
- /$$$$$ /$$$ /$$ /$$
- |__ $$ /$$ $$ | $$ /$ | $$
- | $$ /$$$$$$ /$$$$$$ /$$$$$$/$$$$ | $$$ | $$ /$$$| $$ /$$$$$$
- | $$ /$$__ $$ /$$__ $$| $$_ $$_ $$ /$$ $$/$$ | $$/$$ $$ $$ /$$__ $$
- /$$ | $$| $$ \ $$| $$ \ $$| $$ \ $$ \ $$ | $$ $$_/ | $$$$_ $$$$| $$ \ $$
- | $$ | $$| $$ | $$| $$ | $$| $$ | $$ | $$ | $$\ $$ | $$$/ \ $$$| $$ | $$
- | $$$$$$/| $$$$$$/| $$$$$$/| $$ | $$ | $$ | $$$$/$$ | $$/ \ $$| $$$$$$$/
- \______/ \______/ \______/ |__/ |__/ |__/ \____/\_/ |__/ \__/| $$____/
- | $$
- | $$
- _ _
- | | | |
- ___| |__ ___ ___| | _____ _ __
- / __| '_ \ / _ \/ __| |/ / _ \ '__|
- | (__| | | | __/ (__| < __/ |
- \___|_| |_|\___|\___|_|\_\___|_|
- Coded By Matrix Coder & Psyco Miste
- """
- import re, urllib2
- print banner
- # found this code on stackoverflow.com/questions/19278877
- def unique(seq):
- seen = set()
- return [seen.add(x) or x for x in seq if x not in seen]
- def bing_all_grabber(s):
- lista = []
- page = 1
- while page <= 101:
- try:
- bing = "http://www.bing.com/search?q=ip%3A" + s + "+&count=50&first=" + str(page)
- openbing = urllib2.urlopen(bing)
- readbing = openbing.read()
- findwebs = re.findall('<h2><a href="(.*?)"', readbing)
- for i in range(len(findwebs)):
- allnoclean = findwebs[i]
- findall1 = re.findall('http://(.*?)/', allnoclean)
- for idx, item in enumerate(findall1):
- if 'www' not in item:
- findall1[idx] = 'http://www.' + item + '/'
- else:
- findall1[idx] = 'http://' + item + '/'
- lista.extend(findall1)
- page += 50
- except urllib2.URLError:
- pass
- final = unique(lista)
- return final
- def check_wordpress(sites) :
- wp = []
- for site in sites :
- try :
- if urllib2.urlopen(site+'wp-login.php').getcode() == 200 :
- wp.append(site)
- except :
- pass
- return wp
- def check_joomla(sites) :
- joomla = []
- for site in sites :
- try :
- if urllib2.urlopen(site+'administrator').getcode() == 200 :
- joomla.append(site)
- except :
- pass
- return joomla
- ip = raw_input('Enter IP >>> ')
- sites = bing_all_grabber(str(ip))
- wordpress = check_wordpress(sites)
- joomla = check_joomla(sites)
- for ss in wordpress :
- print ss
- print '[*] Found, ', len(wordpress), ' wordpress sites.'
- print '-'*30+'\n'
- for ss in joomla :
- print ss
- print '[*] Found, ', len(joomla), ' joomla sites.'
- print '\n'
Add Comment
Please, Sign In to add comment