mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2024-11-22 01:26:42 +03:00
Minor patch for colorization (multiple quoted strings in same line)
This commit is contained in:
parent
9e00202823
commit
75a64245c5
|
@ -19,7 +19,7 @@ from lib.core.enums import DBMS_DIRECTORY_NAME
|
|||
from lib.core.enums import OS
|
||||
|
||||
# sqlmap version (<major>.<minor>.<month>.<monthly commit>)
|
||||
VERSION = "1.2.8.3"
|
||||
VERSION = "1.2.8.4"
|
||||
TYPE = "dev" if VERSION.count('.') > 2 and VERSION.split('.')[-1] != '0' else "stable"
|
||||
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)
|
||||
|
|
20
thirdparty/ansistrm/ansistrm.py
vendored
20
thirdparty/ansistrm/ansistrm.py
vendored
|
@ -181,16 +181,16 @@ class ColorizingStreamHandler(logging.StreamHandler):
|
|||
reset = self.reset
|
||||
message = message.replace(counter, ''.join((self.csi, str(self.color_map["yellow"] + 30), 'm', counter, reset)), 1)
|
||||
|
||||
match = re.search(r"'([^']+)'", message) # single-quoted
|
||||
if level != "PAYLOAD" and match:
|
||||
string = match.group(1)
|
||||
if not message.endswith(self.reset):
|
||||
reset = self.reset
|
||||
elif self.bold in message: # bold
|
||||
reset = self.reset + self.bold
|
||||
else:
|
||||
reset = self.reset
|
||||
message = message.replace(string, ''.join((self.csi, str(self.color_map["white"] + 30), 'm', string, reset)), 1)
|
||||
if level != "PAYLOAD":
|
||||
for match in re.finditer(r"'([^']+)'", message): # single-quoted
|
||||
string = match.group(1)
|
||||
if not message.endswith(self.reset):
|
||||
reset = self.reset
|
||||
elif self.bold in message: # bold
|
||||
reset = self.reset + self.bold
|
||||
else:
|
||||
reset = self.reset
|
||||
message = message.replace(string, ''.join((self.csi, str(self.color_map["white"] + 30), 'm', string, reset)), 1)
|
||||
else:
|
||||
message = ''.join((self.csi, ';'.join(params), 'm', message, self.reset))
|
||||
|
||||
|
|
|
@ -48,7 +48,7 @@ c8c386d644d57c659d74542f5f57f632 lib/core/patch.py
|
|||
0c3eef46bdbf87e29a3f95f90240d192 lib/core/replication.py
|
||||
a7db43859b61569b601b97f187dd31c5 lib/core/revision.py
|
||||
fcb74fcc9577523524659ec49e2e964b lib/core/session.py
|
||||
a56c2a90533ae494cd72e817d84a6c46 lib/core/settings.py
|
||||
9253fffb810752d130525dde8668c06a lib/core/settings.py
|
||||
dd68a9d02fccb4fa1428b20e15b0db5d lib/core/shell.py
|
||||
a7edc9250d13af36ac0108f259859c19 lib/core/subprocessng.py
|
||||
12bed9603b6fba3e5ffda11d584bc449 lib/core/target.py
|
||||
|
@ -285,7 +285,7 @@ f2b9eac52d346315f5705f71beeda791 tamper/varnish.py
|
|||
0e40966a51d1eb5d42a2159d2015a8a4 tamper/versionedkeywords.py
|
||||
0fba004bf1be6edbefbda89f23f4e518 tamper/versionedmorekeywords.py
|
||||
de532c4e3160039335010c499129d54f tamper/xforwardedfor.py
|
||||
b25b47ddeeb62e5857fd5ad17fd454b5 thirdparty/ansistrm/ansistrm.py
|
||||
3f6a3d322a4629d5bbd93f43ff8e59cc thirdparty/ansistrm/ansistrm.py
|
||||
d41d8cd98f00b204e9800998ecf8427e thirdparty/ansistrm/__init__.py
|
||||
8e775c25bc9e84891ad6fcb4f0005c23 thirdparty/beautifulsoup/beautifulsoup.py
|
||||
cb2e1fe7c404dff41a2ae9132828f532 thirdparty/beautifulsoup/__init__.py
|
||||
|
@ -467,7 +467,7 @@ d48c971769c6131e35bd52d2315a8d58 xml/banner/servlet-engine.xml
|
|||
d989813ee377252bca2103cea524c06b xml/banner/sharepoint.xml
|
||||
350605448f049cd982554123a75f11e1 xml/banner/x-aspnet-version.xml
|
||||
817078783e1edaa492773d3b34d8eef0 xml/banner/x-powered-by.xml
|
||||
201b8bb7888f500294a9831bb47ce7a7 xml/boundaries.xml
|
||||
6debc049a8049b890ca109a731c60782 xml/boundaries.xml
|
||||
0d0d4bd0e06c99dd8eb4f92acc25caf3 xml/errors.xml
|
||||
a279656ea3fcb85c727249b02f828383 xml/livetests.xml
|
||||
3318571fac8df058f19ea85780606643 xml/payloads/boolean_blind.xml
|
||||
|
|
Loading…
Reference in New Issue
Block a user