mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2025-12-07 05:01:30 +00:00
Bug fix (-p Host didn't work, while -p host worked)
This commit is contained in:
@@ -327,7 +327,7 @@ def _setRequestParams():
|
|||||||
if httpHeader == HTTP_HEADER.USER_AGENT:
|
if httpHeader == HTTP_HEADER.USER_AGENT:
|
||||||
conf.parameters[PLACE.USER_AGENT] = urldecode(headerValue)
|
conf.parameters[PLACE.USER_AGENT] = urldecode(headerValue)
|
||||||
|
|
||||||
condition = any((not conf.testParameter, intersect(conf.testParameter, USER_AGENT_ALIASES)))
|
condition = any((not conf.testParameter, intersect(conf.testParameter, USER_AGENT_ALIASES, True)))
|
||||||
|
|
||||||
if condition:
|
if condition:
|
||||||
conf.paramDict[PLACE.USER_AGENT] = {PLACE.USER_AGENT: headerValue}
|
conf.paramDict[PLACE.USER_AGENT] = {PLACE.USER_AGENT: headerValue}
|
||||||
@@ -336,7 +336,7 @@ def _setRequestParams():
|
|||||||
elif httpHeader == HTTP_HEADER.REFERER:
|
elif httpHeader == HTTP_HEADER.REFERER:
|
||||||
conf.parameters[PLACE.REFERER] = urldecode(headerValue)
|
conf.parameters[PLACE.REFERER] = urldecode(headerValue)
|
||||||
|
|
||||||
condition = any((not conf.testParameter, intersect(conf.testParameter, REFERER_ALIASES)))
|
condition = any((not conf.testParameter, intersect(conf.testParameter, REFERER_ALIASES, True)))
|
||||||
|
|
||||||
if condition:
|
if condition:
|
||||||
conf.paramDict[PLACE.REFERER] = {PLACE.REFERER: headerValue}
|
conf.paramDict[PLACE.REFERER] = {PLACE.REFERER: headerValue}
|
||||||
@@ -345,7 +345,7 @@ def _setRequestParams():
|
|||||||
elif httpHeader == HTTP_HEADER.HOST:
|
elif httpHeader == HTTP_HEADER.HOST:
|
||||||
conf.parameters[PLACE.HOST] = urldecode(headerValue)
|
conf.parameters[PLACE.HOST] = urldecode(headerValue)
|
||||||
|
|
||||||
condition = any((not conf.testParameter, intersect(conf.testParameter, HOST_ALIASES)))
|
condition = any((not conf.testParameter, intersect(conf.testParameter, HOST_ALIASES, True)))
|
||||||
|
|
||||||
if condition:
|
if condition:
|
||||||
conf.paramDict[PLACE.HOST] = {PLACE.HOST: headerValue}
|
conf.paramDict[PLACE.HOST] = {PLACE.HOST: headerValue}
|
||||||
|
|||||||
Reference in New Issue
Block a user