From db74456212cd28ed0ea430e9647f6cd4ea98628c Mon Sep 17 00:00:00 2001 From: soffensive Date: Thu, 5 Feb 2026 19:00:35 +0100 Subject: [PATCH] Add hint to change XML encoding behavior in case of unsuccessful attempt --- lib/controller/controller.py | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/lib/controller/controller.py b/lib/controller/controller.py index 1770e751c5..d2a0fe1aa5 100644 --- a/lib/controller/controller.py +++ b/lib/controller/controller.py @@ -56,6 +56,7 @@ from lib.core.enums import NOTE from lib.core.enums import PAYLOAD from lib.core.enums import PLACE +from lib.core.enums import POST_HINT from lib.core.exception import SqlmapBaseException from lib.core.exception import SqlmapConnectionException from lib.core.exception import SqlmapNoneDataException @@ -711,6 +712,16 @@ def start(): if not conf.randomAgent: errMsg += " and/or switch '--random-agent'" + if kb.postHint in (POST_HINT.SOAP, POST_HINT.XML): + if conf.skipXmlEncode: + errMsg += ". Also, you can try to rerun by omitting the " + errMsg += "option '--skip-xmlencode' as the target may " + errMsg += "require proper XML encoding of payload data" + else: + errMsg += ". Also, you can try to rerun by providing the " + errMsg += "option '--skip-xmlencode' as the target may " + errMsg += "not require XML encoding of payload data" + raise SqlmapNotVulnerableException(errMsg.rstrip('.')) else: # Flush the flag