mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2024-11-23 01:56:36 +03:00
minor refactoring
This commit is contained in:
parent
accf4e6ce0
commit
c69b76776e
|
@ -83,18 +83,18 @@ def __setRequestParams():
|
||||||
if re.search(URI_INJECTABLE_REGEX, conf.url, re.I):
|
if re.search(URI_INJECTABLE_REGEX, conf.url, re.I):
|
||||||
conf.url = "%s%s" % (conf.url, URI_INJECTION_MARK_CHAR)
|
conf.url = "%s%s" % (conf.url, URI_INJECTION_MARK_CHAR)
|
||||||
|
|
||||||
if "*" in conf.url:
|
if URI_INJECTION_MARK_CHAR in conf.url:
|
||||||
conf.parameters[PLACE.URI] = conf.url
|
conf.parameters[PLACE.URI] = conf.url
|
||||||
conf.paramDict[PLACE.URI] = {}
|
conf.paramDict[PLACE.URI] = {}
|
||||||
parts = conf.url.split("*")
|
parts = conf.url.split(URI_INJECTION_MARK_CHAR)
|
||||||
for i in range(len(parts)-1):
|
for i in range(len(parts)-1):
|
||||||
result = str()
|
result = str()
|
||||||
for j in range(len(parts)):
|
for j in range(len(parts)):
|
||||||
result += parts[j]
|
result += parts[j]
|
||||||
if i == j:
|
if i == j:
|
||||||
result += "*"
|
result += URI_INJECTION_MARK_CHAR
|
||||||
conf.paramDict[PLACE.URI]["#%d*" % (i+1)] = result
|
conf.paramDict[PLACE.URI]["#%d%s" % (i+1, URI_INJECTION_MARK_CHAR)] = result
|
||||||
conf.url = conf.url.replace("*", str())
|
conf.url = conf.url.replace(URI_INJECTION_MARK_CHAR, str())
|
||||||
__testableParameters = True
|
__testableParameters = True
|
||||||
|
|
||||||
# Perform checks on Cookie parameters
|
# Perform checks on Cookie parameters
|
||||||
|
|
Loading…
Reference in New Issue
Block a user