mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2024-11-22 09:36:35 +03:00
Merge branch 'master' of github.com:sqlmapproject/sqlmap
This commit is contained in:
commit
18b596ea75
|
@ -1154,14 +1154,14 @@ def __setHTTPUserAgent():
|
|||
conf.httpHeaders.append(("User-Agent", conf.agent))
|
||||
|
||||
elif not conf.randomAgent:
|
||||
addDefaultUserAgent = True
|
||||
_ = True
|
||||
|
||||
for header, _ in conf.httpHeaders:
|
||||
if header == "User-Agent":
|
||||
addDefaultUserAgent = False
|
||||
_ = False
|
||||
break
|
||||
|
||||
if addDefaultUserAgent:
|
||||
if _:
|
||||
conf.httpHeaders.append(("User-Agent", __defaultHTTPUserAgent()))
|
||||
|
||||
else:
|
||||
|
|
|
@ -63,7 +63,7 @@ CHAR_INFERENCE_MARK = "%c"
|
|||
PRINTABLE_CHAR_REGEX = r"[^\x00-\x1f\x7e-\xff]"
|
||||
|
||||
# regular expression used for extracting results from google search
|
||||
GOOGLE_REGEX = r"url\?q=(http[^>]+)&sa=U&"
|
||||
GOOGLE_REGEX = r"url\?\w+=(http[^>]+)&(sa=U|rct=j)"
|
||||
|
||||
# regular expression used for extracting content from "textual" tags
|
||||
TEXT_TAG_REGEX = r"(?si)<(abbr|acronym|b|blockquote|br|center|cite|code|dt|em|font|h\d|i|li|p|pre|q|strong|sub|sup|td|th|title|tt|u)(?!\w).*?>(?P<result>[^<]+)"
|
||||
|
|
|
@ -46,7 +46,7 @@ class Google:
|
|||
HTTP addresses
|
||||
"""
|
||||
|
||||
retVal = re.findall(GOOGLE_REGEX, page, re.I | re.S)
|
||||
retVal = [match.group(1) for match in re.finditer(GOOGLE_REGEX, page, re.I | re.S)]
|
||||
|
||||
return retVal
|
||||
|
||||
|
|
|
@ -675,4 +675,3 @@ wizard = False
|
|||
# 6: Show also HTTP responses' page content
|
||||
# Default: 1
|
||||
verbose = 1
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user