mirror of
https://github.com/sqlmapproject/sqlmap.git
synced 2026-02-05 21:16:34 +00:00
Minor patch
This commit is contained in:
@@ -160,6 +160,23 @@ def dirtyPatches():
|
||||
|
||||
logging._releaseLock = _releaseLock
|
||||
|
||||
from xml.etree import ElementTree as et
|
||||
if not getattr(et, "_patched", False):
|
||||
_real_parse = et.parse
|
||||
|
||||
def _safe_parse(source, parser=None):
|
||||
if parser is None:
|
||||
parser = et.XMLParser()
|
||||
if hasattr(parser, "parser"):
|
||||
def reject(*args): raise ValueError("XML entities are forbidden")
|
||||
parser.parser.EntityDeclHandler = reject
|
||||
parser.parser.UnparsedEntityDeclHandler = reject
|
||||
|
||||
return _real_parse(source, parser=parser)
|
||||
|
||||
et.parse = _safe_parse
|
||||
et._patched = True
|
||||
|
||||
def resolveCrossReferences():
|
||||
"""
|
||||
Place for cross-reference resolution
|
||||
|
||||
@@ -20,7 +20,7 @@ from lib.core.enums import OS
|
||||
from thirdparty import six
|
||||
|
||||
# sqlmap version (<major>.<minor>.<month>.<monthly commit>)
|
||||
VERSION = "1.10.2.1"
|
||||
VERSION = "1.10.2.2"
|
||||
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)
|
||||
|
||||
Reference in New Issue
Block a user