当前位置:网站首页>SQL injection Less42 (POST type stack injection)
SQL injection Less42 (POST type stack injection)
2022-07-31 22:52:00 【HUAWEI CLOUD】
Pre-knowledge: SQL Injection Less38 (Stacked Injection)
The page of this question is similar to secondary injection, but we can't register users, so we can't use secondary injection.
White box audit, view code
$username = mysqli_real_escape_string($con1, $_POST["login_user"]);$password = $_POST["login_password"];Only the username is escaped, but not the password, so the password is a breakthrough
Test the password with a passcode' or 1=1#
But why do we enter admin but log in as Dumb.
Because the SQL here is
SELECT * FROM users WHERE username='admin' and password='' or 1=1 #' And the priority of and is higher than or.So this statement is equivalent to
select * from users where 1Then the result is the entire users table.And Dumb is in the first row, so it is Dumb that is logged in.
Use password for stack injection
Enter the username at will
Password';drop table users;
https://blog.csdn.net/weixin_43901998/article/details/107566100
边栏推荐
- How to get useragent
- 面试突击69:TCP 可靠吗?为什么?
- [QNX Hypervisor 2.2用户手册]9.14 set
- SQL27 View user details of different age groups
- 高等代数_证明_任何矩阵都相似于一个上三角矩阵
- Drawing process of hand-drawn map of scenic spots
- Go mode tidy reports an error go warning “all” matched no packages
- Difference Between Stateless and Stateful
- Niuke.com brush questions (1)
- Binary tree non-recursive traversal
猜你喜欢
I don't know what to do with sync issues

Implementing a Simple Framework for Managing Object Information Using Reflection

Unity - LineRenderer show a line

Summary of the classic drawing method of histogram

21. Support Vector Machine - Introduction to Kernel Functions

Bionic caterpillar robot source code

flowable workflow all business concepts

【Acwing】第62场周赛 题解

手写一个简单的web服务器(B/S架构)

Go1.18 upgrade function - Fuzz test from scratch in Go language
随机推荐
Program processes and threads (concurrency and parallelism of threads) and basic creation and use of threads
One thing to say, is outsourcing company worth it?
信息学奥赛一本通 1941:【07NOIP普及组】Hanoi双塔问题 | 洛谷 P1096 [NOIP2007 普及组] Hanoi 双塔问题
linux view redis version command (linux view mysql version number)
Dry goods | 10 tips for MySQL add, delete, change query performance optimization
MySQL数据库‘反斜杠\’ ,‘单引号‘’,‘双引号“’,‘null’无法存储
HTC使用官方固件作为底包制作rom卡刷包教程
What is customer profile management?
How to get useragent
Daily practice——Randomly generate an integer between 1-100 and see how many times you can guess.Requirements: The number of guesses cannot exceed 7 times, and after each guess, it will prompt "bigger"
22年8月推广大使额外奖励规则
[QNX Hypervisor 2.2用户手册]9.15 suppress
How to debug TestCafe
Pytorch lstm time series prediction problem stepping on the pit "recommended collection"
TypeScript 的组件
How to identify fake reptiles?
Audio alignment using cross-correlation
[QNX Hypervisor 2.2 User Manual]9.16 system
Shell常用脚本:Nexus批量上传本地仓库增强版脚本(强烈推荐)
手写一个简单的web服务器(B/S架构)