Fix related to the #6149

This commit is contained in:
Miroslav Štampar
2026-10-20 10:07:33 +02:00
parent d57415479a
commit 9b0e262560
2 changed files with 12 additions and 5 deletions
+11 -4
View File
@@ -223,6 +223,9 @@ def _autoWafBypass(place, parameter, value):
return retVal
def _targetInfo():
return {"url": conf.url, "query": conf.parameters.get(PLACE.GET), "data": conf.parameters.get(PLACE.POST)}
def _showInjections():
if conf.wizard and kb.wizardMode:
kb.wizardMode = False
@@ -234,13 +237,12 @@ def _showInjections():
header = "sqlmap resumed the following injection point(s) from stored session"
if conf.api:
conf.dumper.string("", {"url": conf.url, "query": conf.parameters.get(PLACE.GET), "data": conf.parameters.get(PLACE.POST)}, content_type=CONTENT_TYPE.TARGET)
conf.dumper.string("", _targetInfo(), content_type=CONTENT_TYPE.TARGET)
conf.dumper.string("", kb.injections, content_type=CONTENT_TYPE.TECHNIQUES)
else:
# --report-json: capture the same TARGET/TECHNIQUES structures the API emits, without
# printing them (the human-readable injection points are rendered just below)
# --report-json: capture the same TECHNIQUES structure the API emits, without printing it (the
# human-readable injection points are rendered just below); TARGET is reported per target in start()
if conf.reportJson:
conf.dumper._reportData({"url": conf.url, "query": conf.parameters.get(PLACE.GET), "data": conf.parameters.get(PLACE.POST)}, CONTENT_TYPE.TARGET)
conf.dumper._reportData(kb.injections, CONTENT_TYPE.TECHNIQUES)
data = "".join(set(_formatInjection(_) for _ in kb.injections)).rstrip("\n")
@@ -522,6 +524,11 @@ def start():
setupTargetEnv()
# --report-json: every tested target gets its own group with its identity, also when nothing is found
# (otherwise its errors, e.g. connection failures, would have no group to land in)
if conf.reportJson:
conf.dumper._reportData(_targetInfo(), CONTENT_TYPE.TARGET)
if not any((conf.graphql,)) and not checkConnection(suppressOutput=conf.forms):
continue
+1 -1
View File
@@ -20,7 +20,7 @@ from lib.core.enums import OS
from thirdparty import six
# sqlmap version (<major>.<minor>.<month>.<monthly commit>)
VERSION = "1.10.10.13"
VERSION = "1.10.10.14"
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)