mirror of
https://github.com/byt3bl33d3r/MITMf.git
synced 2025-07-07 05:22:15 -07:00
Fix returning data, check mime to avoid heavy chardet process we are not interested in other mimes.
This commit is contained in:
parent
2490b87f43
commit
f8293c38c9
1 changed files with 4 additions and 1 deletions
|
@ -64,7 +64,10 @@ class Inject(Plugin):
|
||||||
try:
|
try:
|
||||||
mime = response.headers['Content-Type']
|
mime = response.headers['Content-Type']
|
||||||
except KeyError:
|
except KeyError:
|
||||||
return
|
return {'response': response, 'request':request, 'data': data}
|
||||||
|
|
||||||
|
if "text/html" not in mime:
|
||||||
|
return {'response': response, 'request':request, 'data': data}
|
||||||
|
|
||||||
if "charset" in mime:
|
if "charset" in mime:
|
||||||
match = re.search('charset=(.*)', mime)
|
match = re.search('charset=(.*)', mime)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue