mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2024-11-25 19:13:48 +03:00
Patch related to #4527 (drei)
This commit is contained in:
parent
779b352f6b
commit
f84ec1072b
|
@ -18,7 +18,7 @@ from lib.core.enums import OS
|
||||||
from thirdparty.six import unichr as _unichr
|
from thirdparty.six import unichr as _unichr
|
||||||
|
|
||||||
# sqlmap version (<major>.<minor>.<month>.<monthly commit>)
|
# sqlmap version (<major>.<minor>.<month>.<monthly commit>)
|
||||||
VERSION = "1.5.1.11"
|
VERSION = "1.5.1.12"
|
||||||
TYPE = "dev" if VERSION.count('.') > 2 and VERSION.split('.')[-1] != '0' else "stable"
|
TYPE = "dev" if VERSION.count('.') > 2 and VERSION.split('.')[-1] != '0' else "stable"
|
||||||
TYPE_COLORS = {"dev": 33, "stable": 90, "pip": 34}
|
TYPE_COLORS = {"dev": 33, "stable": 90, "pip": 34}
|
||||||
VERSION_STRING = "sqlmap/%s#%s" % ('.'.join(VERSION.split('.')[:-1]) if VERSION.count('.') > 2 and VERSION.split('.')[-1] == '0' else VERSION, TYPE)
|
VERSION_STRING = "sqlmap/%s#%s" % ('.'.join(VERSION.split('.')[:-1]) if VERSION.count('.') > 2 and VERSION.split('.')[-1] == '0' else VERSION, TYPE)
|
||||||
|
|
|
@ -303,7 +303,7 @@ def decodePage(page, contentEncoding, contentType, percentDecode=True):
|
||||||
|
|
||||||
page = data.read()
|
page = data.read()
|
||||||
except Exception as ex:
|
except Exception as ex:
|
||||||
if "<html" not in page: # in some cases, invalid "Content-Encoding" appears for plain HTML (should be ignored)
|
if b"<html" not in page: # in some cases, invalid "Content-Encoding" appears for plain HTML (should be ignored)
|
||||||
errMsg = "detected invalid data for declared content "
|
errMsg = "detected invalid data for declared content "
|
||||||
errMsg += "encoding '%s' ('%s')" % (contentEncoding, getSafeExString(ex))
|
errMsg += "encoding '%s' ('%s')" % (contentEncoding, getSafeExString(ex))
|
||||||
singleTimeLogMessage(errMsg, logging.ERROR)
|
singleTimeLogMessage(errMsg, logging.ERROR)
|
||||||
|
|
|
@ -241,7 +241,7 @@ class Connect(object):
|
||||||
if len(part) == MAX_CONNECTION_READ_SIZE:
|
if len(part) == MAX_CONNECTION_READ_SIZE:
|
||||||
warnMsg = "large response detected. This could take a while"
|
warnMsg = "large response detected. This could take a while"
|
||||||
singleTimeWarnMessage(warnMsg)
|
singleTimeWarnMessage(warnMsg)
|
||||||
part = re.sub(r"(?si)%s.+?%s" % (kb.chars.stop, kb.chars.start), "%s%s%s" % (kb.chars.stop, LARGE_READ_TRIM_MARKER, kb.chars.start), part)
|
part = re.sub(getBytes(r"(?si)%s.+?%s" % (kb.chars.stop, kb.chars.start)), getBytes("%s%s%s" % (kb.chars.stop, LARGE_READ_TRIM_MARKER, kb.chars.start)), part)
|
||||||
retVal += part
|
retVal += part
|
||||||
else:
|
else:
|
||||||
retVal += part
|
retVal += part
|
||||||
|
|
Loading…
Reference in New Issue
Block a user