Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 8649021

Browse files
committed
Adding support for Drizzle (MySQL fork)
1 parent 9d6c931 commit 8649021

4 files changed

Lines changed: 5 additions & 2 deletions

File tree

lib/core/agent.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -388,7 +388,7 @@ def adjustLateValues(self, payload):
388388
for _ in set(re.findall(r"\[RANDSTR(?:\d+)?\]", payload, re.I)):
389389
payload = payload.replace(_, randomStr())
390390

391-
if hashDBRetrieve(HASHDB_KEYS.DBMS_FORK) in (FORK.MEMSQL, FORK.TIDB):
391+
if hashDBRetrieve(HASHDB_KEYS.DBMS_FORK) in (FORK.MEMSQL, FORK.TIDB, FORK.DRIZZLE):
392392
payload = re.sub(r"(?i)\bORD\(", "ASCII(", payload)
393393
payload = re.sub(r"(?i)\bMID\(", "SUBSTR(", payload)
394394
payload = re.sub(r"(?i)\bNCHAR\b", "CHAR", payload)

lib/core/enums.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,7 @@ class FORK(object):
8787
TIDB = "TiDB"
8888
REDSHIFT = "Amazon Redshift"
8989
GREENPLUM = "Greenplum"
90+
DRIZZLE = "Drizzle"
9091

9192
class CUSTOM_LOGGING(object):
9293
PAYLOAD = 9

lib/core/settings.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
from thirdparty.six import unichr as _unichr
1919

2020
# sqlmap version (<major>.<minor>.<month>.<monthly commit>)
21-
VERSION = "1.4.2.8"
21+
VERSION = "1.4.2.9"
2222
TYPE = "dev" if VERSION.count('.') > 2 and VERSION.split('.')[-1] != '0' else "stable"
2323
TYPE_COLORS = {"dev": 33, "stable": 90, "pip": 34}
2424
VERSION_STRING = "sqlmap/%s#%s" % ('.'.join(VERSION.split('.')[:-1]) if VERSION.count('.') > 2 and VERSION.split('.')[-1] == '0' else VERSION, TYPE)

plugins/dbms/mysql/fingerprint.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,8 @@ def getFingerprint(self):
9292
fork = FORK.MARIADB
9393
elif inject.checkBooleanExpression("VERSION() LIKE '%TiDB%'"):
9494
fork = FORK.TIDB
95+
elif inject.checkBooleanExpression("@@VERSION_COMMENT LIKE '%drizzle%'"):
96+
fork = FORK.DRIZZLE
9597
elif inject.checkBooleanExpression("@@VERSION_COMMENT LIKE '%Percona%'"):
9698
fork = FORK.PERCONA
9799
else:

0 commit comments

Comments
 (0)