mirror of
https://github.com/lgandx/Responder.git
synced 2025-07-14 00:53:01 -07:00
Case-insensitive content-type check
Was noticing that injection wasn't happening when the header was "Content-type" instead of the checked for "Content-Type". Headers could probably be put as .lower() from the beginning, but then again there might be header content that may break because of it.
This commit is contained in:
parent
2c9273eb2c
commit
094824bfd3
1 changed files with 1 additions and 1 deletions
|
@ -1498,7 +1498,7 @@ def InjectData(data):
|
||||||
return Gzip
|
return Gzip
|
||||||
else:
|
else:
|
||||||
return data
|
return data
|
||||||
if "Content-Type: text/html" in Headers:
|
if "content-type: text/html" in Headers.lower():
|
||||||
Len = ''.join(re.findall('(?<=Content-Length: )[^\r\n]*', Headers))
|
Len = ''.join(re.findall('(?<=Content-Length: )[^\r\n]*', Headers))
|
||||||
HasHTML = re.findall('(?<=<html)[^<]*', Content)
|
HasHTML = re.findall('(?<=<html)[^<]*', Content)
|
||||||
if HasHTML :
|
if HasHTML :
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue