First understand the next updatexml () function
Updatexml (Xml_document, xpath_string, New_value);
The first parameter: Xml_document is a string format, the name of the XML Document object, and the doc
The second argument: Xpath_string (a string in XPath format), you can find tutorials online If you don't know the XPath syntax.
Third parameter: new_value,string format, replacing found eligible data
Action: Change the value of a node in the document that matches the criteria
Change the value of xpath_string in Xml_document
And our injection statement is:
Updatexml (1,concat (0x7e, (SELECT @ @version), 0x7e), 1)
where the concat () function is linked to a string, and therefore does not conform to the xpath_string format, resulting in a format error, burst
Error 1105 (HY000): XPATH syntax error: ': [email protected] '
XPath format: http://www.cnblogs.com/Loofah/archive/2012/05/10/2494036.html
MYSQL updatexml Error Injection