NCTF-2025-Web-Writeup

sqlmap-master 题目 1from fastapi import FastAPI, Request 2from fastapi.responses import FileResponse, StreamingResponse 3import subprocess 4 5app = FastAPI() 6 [email protected]("/") 8async def index(): 9 return FileResponse("index.html") 10 [email protected]("/run") 12async def run(request: Request): 13 data = await request.json() 14 url = data.get("url") 15 16 if not url: 17 return {"error": "URL is required"} 18 19 command = f'sqlmap -u {url} --batch --flush-session' 20 21 def generate(): 22 process = subprocess.Popen( 23 command.split(), 24 stdout=subprocess.PIPE, 25 stderr=subprocess.STDOUT, 26 shell=False 27 ) 28 29 while True: 30 output = process.stdout.readline() 31 if output == '' and process.poll() is not None: 32 break 33 if output: 34 yield output 35 36 return StreamingResponse(generate(), media_type="text/plain") 其实就是一个网页端的sqlmap 看一下sqlmap的使用文档 ...

2025-03-24 · 2 分钟 · Xrntkk

春秋云镜-Brute4Road-Writeup

参考文章 https://bowuchuling.github.io/posts/chunqiuBrute4Road.html https://h0ny.github.io/posts/Brute4Road-%E6%98%A5%E7%A7%8B%E4%BA%91%E5%A2%83 文章 - 浅谈约束委派攻击 - 先知社区 FLAG1 拿到靶机先用fscan扫一扫 ┌──────────────────────────────────────────────┐ │ ___ _ │ │ / _ \ ___ ___ _ __ __ _ ___| | __ │ │ / /_\/____/ __|/ __| '__/ _` |/ __| |/ / │ │ / /_\\_____\__ \ (__| | | (_| | (__| < │ │ \____/ |___/\___|_| \__,_|\___|_|\_\ │ └──────────────────────────────────────────────┘ Fscan Version: 2.0.0 [2025-03-17 14:12:55] [INFO] 暴力破解线程数: 1 [2025-03-17 14:12:55] [INFO] 开始信息扫描 [2025-03-17 14:12:55] [INFO] 最终有效主机数量: 1 [2025-03-17 14:12:55] [INFO] 开始主机扫描 [2025-03-17 14:12:55] [INFO] 有效端口数量: 233 [2025-03-17 14:12:55] [SUCCESS] 端口开放 39.98.114.207:80 [2025-03-17 14:12:55] [SUCCESS] 端口开放 39.98.114.207:22 [2025-03-17 14:12:55] [SUCCESS] 端口开放 39.98.114.207:6379 [2025-03-17 14:12:55] [SUCCESS] 端口开放 39.98.114.207:21 [2025-03-17 14:12:55] [SUCCESS] 服务识别 39.98.114.207:22 => [ssh] 版本:7.4 产品:OpenSSH 信息:protocol 2.0 Banner:[SSH-2.0-OpenSSH_7.4.] [2025-03-17 14:12:55] [SUCCESS] 服务识别 39.98.114.207:21 => [ftp] 版本:3.0.2 产品:vsftpd 系统:Unix Banner:[220 (vsFTPd 3.0.2).] [2025-03-17 14:13:00] [SUCCESS] 服务识别 39.98.114.207:80 => [http] 版本:1.20.1 产品:nginx [2025-03-17 14:13:00] [SUCCESS] 服务识别 39.98.114.207:6379 => [redis] 版本:5.0.12 产品:Redis key-value store [2025-03-17 14:13:06] [INFO] 存活端口数量: 4 [2025-03-17 14:13:06] [INFO] 开始漏洞扫描 [2025-03-17 14:13:06] [INFO] 加载的插件: ftp, redis, ssh, webpoc, webtitle [2025-03-17 14:13:06] [SUCCESS] 网站标题 http://39.98.114.207 状态码:200 长度:4833 标题:Welcome to CentOS [2025-03-17 14:13:07] [SUCCESS] 匿名登录成功! [2025-03-17 14:13:09] [SUCCESS] Redis 39.98.114.207:6379 发现未授权访问 文件位置:/usr/local/redis/db/dump.rdb [2025-03-17 14:13:13] [SUCCESS] Redis无密码连接成功: 39.98.114.207:6379 [2025-03-17 14:13:18] [SUCCESS] 扫描已完成: 5/5 发现redis不需要密码 ...

2025-03-17 · 9 分钟 · Xrntkk

TPCTF2025-Web-赛后复现Writeup

参考文章 https://blog.0xfff.team/posts/tpctf_2025_writeup/ https://z3n1th1.com/2025/03/tpctf2025-writeup/ TPCTF2025 Writeup - 星盟安全团队 baby layout 这是一道关于绕过DOMPurify库,进行xss cookie窃取的题目 DOMPurify 是一个专门用于清理 HTML 输入的 JavaScript 库,旨在防止跨站脚本 (XSS) 攻击。它通过过滤和净化用户提供的 HTML 内容,确保其安全地嵌入到网页中,避免恶意代码的执行。 ...

2025-03-15 · 5 分钟 · Xrntkk

春秋云镜-Initial-Writeup

参考文章 https://9anux.org/2024/08/01/%E6%98%A5%E7%A7%8B%E4%BA%91%E5%A2%83Initial%E8%AF%A6%E8%A7%A3/ 菜鸡第一个通关的靶场Orz FLAG1 fscan扫一下 ./fscan.exe -h 39.99.139.119 直接用thinkphpgui写马连蚁剑 先用vshell上线 读flag需要提权 peass-ng/PEASS-ng: PEASS - Privilege Escalation Awesome Scripts SUITE (with colors) ...

2025-03-12 · 2 分钟 · Xrntkk

春秋云镜-Tsclient-Writeup

Tsclient是一套难度为中等的靶场环境,完成该挑战可以帮助玩家了解内网渗透中的代理转发、内网扫描、信息收集、特权提升以及横向移动技术方法,加强对域环境核心认证机制的理解,以及掌握域环境渗透中一些有趣的技术要点。该靶场共有3个flag,分布于不同的靶机。 ...

2025-03-12 · 7 分钟 · Xrntkk

GHCTF-2025-Web-Writeup

战队名:我要打奥斯汀major 比赛排名:5 Web upload?SSTI! 读取文件中的内容并进行模板渲染,存在ssti 有waf 1def contains_dangerous_keywords(file_path): 2 dangerous_keywords = ['_', 'os', 'subclasses', '__builtins__', '__globals__','flag',] 3 4 with open(file_path, 'rb') as f: 5 file_content = str(f.read()) 6 7 for keyword in dangerous_keywords: 8 if keyword in file_content: 9 return True # 找到危险关键字,返回 True 简单绕一下 ...

2025-03-09 · 6 分钟 · Xrntkk

HGAME2025-Web-Writeup

Web week1 Level 24 Pacman 拿到环境 一个小游戏,猜测应该是js审计 查看index.js发现代码进行了混淆 可以用工具反混淆一下,增加一下可读性 https://tool.yuanrenxue.cn/decode_obfuscator 反混淆之后找到这个 ...

2025-02-20 · 9 分钟 · Xrntkk

CTFSHOW-SQL注入-Writeup

无过滤注入(对输出内容进行过滤) web171 $sql = "select username,password from user where username !='flag' and id = '".$_GET['id']."' limit 1;"; flag是存在于username为flag的用户的数据中,我们只需要通过 1' or 1=1 --+ 即可输出所有用户数据 web172 相比上一题,这题增加了过滤 ...

2025-01-22 · 35 分钟 · Xrntkk