mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2026-11-20 23:23:21 +00:00
Fix for --safe-url carrying injected cookie payload and --safe-req getting target's GET parameters
This commit is contained in:
parent
3ab05cade0
commit
057e614500
2 changed files with 4 additions and 3 deletions
|
|
@ -19,7 +19,7 @@ from lib.core.enums import OS
|
|||
from thirdparty import six
|
||||
|
||||
# sqlmap version (<major>.<minor>.<month>.<monthly commit>)
|
||||
VERSION = "1.10.11.42"
|
||||
VERSION = "1.10.11.43"
|
||||
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)
|
||||
|
|
|
|||
|
|
@ -1695,10 +1695,11 @@ class Connect(object):
|
|||
if (conf.safeFreq or 0) > 0 and not buildOnly:
|
||||
kb.queryCounter += 1
|
||||
if kb.queryCounter % conf.safeFreq == 0:
|
||||
# Note: "safe" visit must not carry the payload (e.g. in case of Cookie injection)
|
||||
if conf.safeUrl:
|
||||
Connect.getPage(url=conf.safeUrl, post=conf.safePost, cookie=cookie, direct=True, silent=True, ua=ua, referer=referer, host=host)
|
||||
Connect.getPage(url=conf.safeUrl, post=conf.safePost, cookie=conf.parameters.get(PLACE.COOKIE) if place == PLACE.COOKIE else cookie, direct=True, silent=True, ua=ua, referer=referer, host=host)
|
||||
elif kb.safeReq:
|
||||
Connect.getPage(url=kb.safeReq.url, post=kb.safeReq.post, method=kb.safeReq.method, auxHeaders=kb.safeReq.headers)
|
||||
Connect.getPage(url=kb.safeReq.url, post=kb.safeReq.post, method=kb.safeReq.method, auxHeaders=kb.safeReq.headers, direct=True)
|
||||
|
||||
# When the timeless oracle is engaged (by action() at the start of extraction, so the heavy vector
|
||||
# is in place before any payload is built), a boolean comparison is answered by relative HTTP/2
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue