minor fix

This commit is contained in:
Miroslav Stampar 2012-02-10 15:26:55 +00:00
parent e36e9de57e
commit 92590d0d59
2 changed files with 6 additions and 1 deletions

View File

@ -305,6 +305,9 @@ Truong Duc Luong <luongductruong@gmail.com>
Pavol Luptak <pavol.luptak@nethemba.com>
for reporting a bug when injecting on a POST data parameter
Till Maas <opensource@till.name>
for suggesting a minor feature
Michael Majchrowicz <mmajchrowicz@gmail.com>
for extensively beta-testing sqlmap on various MySQL DBMS
for providing really appreciated feedback

View File

@ -129,15 +129,17 @@ def __formatInjection(inj):
for stype, sdata in inj.data.items():
title = sdata.title
_ = sdata.vector
if stype == PAYLOAD.TECHNIQUE.UNION:
count = re.sub(r"\(.+\)", "", sdata.payload).count(",") + 1
title = re.sub(r"\d+ to \d+", str(count), title)
_ = agent.forgeInbandQuery("[QUERY]", _[0], _[1], _[2], _[3], _[4], _[5])
if count == 1:
title = title.replace("columns", "column")
data += " Type: %s\n" % PAYLOAD.SQLINJECTION[stype]
data += " Title: %s\n" % title
data += " Payload: %s\n" % (sdata.payload if stype != PAYLOAD.TECHNIQUE.TIME else sdata.payload.replace("[SLEEPTIME]", str(conf.timeSec)))
data += " Vector: %s\n" % sdata.vector if conf.verbose > 1 else "\n"
data += " Vector: %s\n\n" % _ if conf.verbose > 1 else "\n"
return data