当前位置:网站首页>Judgment of database in SQL injection
Judgment of database in SQL injection
2022-07-31 05:52:00 【not used to having you】
Note: For technical discussion only, do not use for other purposes, all consequences have nothing to do with me.
Foreword: For penetration testing, we can use the corresponding statements and functions for penetration only if we know the database corresponding to the website.
Common databases:
Oracle, MySQL, SQL Server, Access, MSsql, Postgresql, mongodb, etc.
Oracle—Oracle Corporation—Commercial Large Databases
MySQL—Oracle Corporation (Acquisition)—— Open source small and medium databases
SQL SERVER—Microsoft Corporation—Commercial medium and large databases
Access—Microsoft Corporation—Commercial small databases
DB2—IBM Corporation—Commercial large databases
According to the port
Oracle: default port 1521
SQL Server: default port 1433
MySQL: default port 3306
The type corresponding to the backend language and database:
asp:sql server,Access
.net :sql server
php:PostgreSQL,Mysql
java:Oracle,Mysql
Website scripts, WEB service programs. Common combinations of database service programs include:
PHP+Apache+MYSQL
ASP+Microsoft IIS+ACCSECC
ASP+Microsoft IIS+mssql
ASPX+Microsoft IIS+Mssql
JSP+TOMCAT+Oracle(relatively rare)
Signature information of each database:
sql server: [email protected]@version –
Oracle:select banner from v$version
mysql:select @@version, version() –, length(user)>0 normal
postgresql:selectversion() –
For string handling
sql server : id=1 and 'a'+'b'='ab' –
mysql: id=1 and 'a'+'b'='ab' , 'ab'=concat('a','b')
oracle: id=1 and 'a'+'b'='a'||'b' ,'ab'=concat('a','b')
postgresql : id=1 and 'a'+'b'='a'||'b' ,'ab'=concat('a','b')
Special functions
len() and length() functions
length()/char_length(): for mysql database
len(): for sql sever database
lengthb()/length(): for useFor oracle database
length()/char_length(): for postgresql database
Special symbols, judgment of comments
Access: includes double hyphen (–), C style (/* . . . */)
MySQL: "#", means single-line comment, syntax "#comment content"
"-", means single-line comment, syntax "-- comment content"
"/**/", means multiple linesComment, syntax "/comment content/"
Oracle: "/**/", means multi-line comment, syntax "/comment content/"
"-", means single-line comment, syntax "-- comment content"
边栏推荐
- 阿里云中mysql数据库被攻击了,最终数据找回来了
- vulhub靶场学习日记xxe-lab
- 08 【生命周期 组件】
- If the account number or password is entered incorrectly for many times, the account will be banned.
- Getting to know regular expressions
- 变量的解构赋值
- 16 【打包上线 图片懒加载】
- Digital twins will be an important way to enter the "metaverse"
- 【云原生】原来2020.0.X版本开始的OpenFeign底层不再使用Ribbon了
- leetcode-每日一题873. 最长的斐波那契子序列的长度(哈希和二分)
猜你喜欢
随机推荐
Redis first meeting
数字孪生将成为进入“元宇宙”一项重要的途径
11 【定位】
MySQL压缩包方式安装,傻瓜式教学
三子棋讲解(C语言)
10 【高度塌陷与BFC】
leetcode-每日一题873. 最长的斐波那契子序列的长度(哈希和二分)
gin框架学习-Casbin入门指南(ACL、RBAC、域内RBAC模型)
Oracle数据库中的“limit”查询
SQL注入中数据库的判断
vulhub靶场学习日记SickOs1.2
leetcode-每日一题731. 我的日程安排表 II
Error: Cannot find module ‘D:\Application\nodejs\node_modules\npm\bin\npm-cli.js‘
wpf wrapPanel居中并从左到右排列
小白学爬虫——爬虫入门
Proteus 8 Professional安装教程
PHP中abstract(抽象)、final(最终)和static(静态)原理与用法
let和const命令
继承、Super,重写、抽象类、抽象方法 1(第七天)
Getting to know regular expressions







