mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2025-02-16 19:40:37 +03:00
Minor patch
This commit is contained in:
parent
7accba4cf9
commit
c19a283434
|
@ -254,7 +254,14 @@ def decodePage(page, contentEncoding, contentType):
|
|||
|
||||
# e.g. ’…™
|
||||
if "&#" in page:
|
||||
page = re.sub(r"&#(\d+);", lambda _: unichr(int(_.group(1))), page)
|
||||
def _(match):
|
||||
retVal = match.group(0)
|
||||
try:
|
||||
retVal = unichr(int(match.group(1)))
|
||||
except ValueError:
|
||||
pass
|
||||
return retVal
|
||||
page = re.sub(r"&#(\d+);", _, page)
|
||||
|
||||
# e.g. ζ
|
||||
page = re.sub(r"&([^;]+);", lambda _: unichr(htmlEntities[_.group(1)]) if htmlEntities.get(_.group(1), 0) > 255 else _.group(0), page)
|
||||
|
|
Loading…
Reference in New Issue
Block a user