MCPcopy Index your code
hub / github.com/sqlmapproject/sqlmap / parseXmlFile

Function parseXmlFile

lib/core/common.py:2409–2421  ·  view source on GitHub ↗

Parses XML file by a given handler

(xmlFile, handler)

Source from the content-addressed store, hash-verified

2407 kb.prependFlag = False
2408
2409def parseXmlFile(xmlFile, handler):
2410 """
2411 Parses XML file by a given handler
2412 """
2413
2414 try:
2415 with contextlib.closing(io.StringIO(readCachedFileContent(xmlFile))) as stream:
2416 parse(stream, handler)
2417 except (SAXParseException, UnicodeError) as ex:
2418 errMsg = "something appears to be wrong with "
2419 errMsg += "the file '%s' ('%s'). Please make " % (xmlFile, getSafeExString(ex))
2420 errMsg += "sure that you haven't made any changes to it"
2421 raise SqlmapInstallationException(errMsg)
2422
2423def getSQLSnippet(dbms, sfile, **variables):
2424 """

Callers 3

headersParserFunction · 0.90
bannerParserFunction · 0.90
htmlParserFunction · 0.90

Calls 3

readCachedFileContentFunction · 0.85
getSafeExStringFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…