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

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

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

订阅源联系隐私© 2026 Kitploit

工具目录

分类

查看所有分类
Loading categories
CVE-2024-0012 — PANW NGFW CVE-2024-0012 | Kitploit
工具/GitHubGitHub/greaselovely/cve-2024-0012
漏洞扫描器漏洞利用Web应用程序漏洞利用信息收集渗透测试学习与教育
GitHubgreaselovely/cve-2024-0012

CVE-2024-0012

PANW NGFW CVE-2024-0012

查看仓库
171年前尚未审核

最受欢迎

查看全部 →

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

探索所有工具

浏览我们的工具集合

查看所有工具 →
分享

Palo Alto PAN-OS CVE-2024-0012 漏洞检查器

此 Python 脚本用于检查 Palo Alto Networks PAN-OS 管理 Web 界面中是否存在严重的身份验证绕过漏洞,该漏洞编号为 CVE-2024-0012。此漏洞可使未经身份验证的攻击者获取管理员权限、篡改配置或利用其他权限提升漏洞。

功能

  • 自动化漏洞检查:向目标发送 HTTP GET 请求,并根据响应状态、标头以及特定于 Palo Alto PAN-OS 的内容标记来评估条件。
  • 改进的基于标记的验证:
    • 使用与 Palo Alto 相关的上下文标记(如 Zero Touch Provisioning 和 window.Pan)进行准确检测。
    • 通过结合标头和状态码验证内容来减少误报。
  • 交互式或命令行参数:
    • 使用 -t 指定单个目标,或使用 -f 指定目标文件。
    • 如果未提供任何参数,脚本将切换至交互模式,提示用户输入。
  • 摘要与详细输出:
    • 汇总所有目标的结果。
    • 可选地使用 -d 参数或在交互模式下通过用户提示显示存在漏洞目标的详细结果。
  • 可选解释:使用 -e 或 --explanation 打印关于 CVE-2024-0012 和 CVE-2024-9474 的详细、用户友好的描述。
  • 美化输出:使用 rich 库以清晰、易读的格式显示结果。
  • 错误处理:优雅地处理网络错误、无效响应和 SSL 验证问题。

依赖要求

  • Python 3.7 或更高版本
  • requests 库,用于 HTTP 请求
  • rich 库,用于样式化输出

安装

  1. 克隆仓库或下载脚本。
  2. 安装所需依赖:
    pip install -r requirements.txt
    

用法

基本用法

以交互方式检查单个目标:

python main.py

命令行参数

单个目标

指定单个 FQDN 或 IP:

python main.py -t 127.0.0.1

从文件指定多个目标

提供一个包含目标列表的文件(每行一个):

python main.py -f targets.txt

打印详细结果

使用 -d 或 --details 参数自动打印所有存在漏洞目标的详细结果:

python main.py -t 127.0.0.1 -d

打印解释

使用 -e 或 --explanation 参数打印关于 CVE-2024-0012 和 CVE-2024-9474 漏洞的详细解释:

python main.py -t 127.0.0.1 -d -e (or -de)

输出

存在漏洞的目标

[!] Target -appears- vulnerable!

┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
┃ Key                         ┃ Value                                                    ┃
┡━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┩
┃ URL                         ┃ https://127.0.0.1/php/ztp_gate.php/.js.map               ┃
┃ Status Code                 ┃ 200                                                      ┃
┃ Headers                     ┃ {"Date": "Wed, 20 Nov 2024 15:29:31 GMT", ...            ┃
┃ Markers Found               ┃ ...<title>Zero Touch Provisioning</title>...             ┃
┃                             ┃ ...window.Pan = window.Pan || {};...                     ┃
└─────────────────────────────┴──────────────────────────────────────────────────────────┘

不存在漏洞的目标

[+] Target does not appear to be vulnerable.
Message: No matching conditions met.

摘要表

扫描结束时,摘要表列出所有目标及其状态:

┏━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━┓
┃ Target                ┃ Status          ┃
┡━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━┩
┃ 127.0.0.1             ┃ Vulnerable      ┃
┃ example.com           ┃ Not Vulnerable  ┃
└───────────────────────┴─────────────────┘

解释

如果使用了 -e 或 --explanation 参数:

CVE-2024-0012 Explained

CVE-2024-0012 is an authentication bypass vulnerability. This means attackers can skip the login process and access sensitive parts of a system without needing a username or password. In Palo Alto Networks’ PAN-OS, this vulnerability allows attackers to trick the system by sending specially crafted HTTP GET requests. These requests include a header called `X-PAN-AUTHCHECK`, which tells the system whether or not authentication is required. If this header is set to `off`, the system mistakenly grants access to restricted areas without checking if the person is logged in.

This vulnerability can be exploited together with CVE-2024-9474, a privilege escalation vulnerability, to gain full root access to the device. Once attackers achieve root access, they can control the firewall, steal sensitive data, or disable security features.

If this vulnerability is confirmed, patch the affected system as soon as possible to prevent exploitation. Additionally, restrict access to the management interface by IP whitelisting or using a dedicated management network.

错误

[bold red]Error:[/bold red] HTTPSConnectionPool(host='127.0.0.1', port=443): Max retries exceeded with URL: /php/ztp_gate.php/.js.map (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x...>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed'))

备注

  • 交互式提示:如果未提供 --target 或 --file 参数,脚本将提示进行交互式输入。
  • SSL 警告:脚本会针对自签名证书禁用 SSL 警告。请在安全环境中谨慎使用。
  • 改进的验证:脚本专注于 Palo Alto 特定的标记,以减少误报并确保准确的结果。
  • 可选解释:-e 参数为需要更多上下文的用户提供漏洞的教育性概述。
  • 限制:此工具仅用于教育和授权的安全评估。针对您不拥有或不受您管理的系统进行未经授权的使用,可能违反法律或政策。

许可证

此脚本根据 MIT 许可证发布。有关详细信息,请参阅 LICENSE 文件。

免责声明

此脚本按“原样”提供,不附有任何形式的保证。使用风险自负。作者不对因使用此工具而造成的任何损害负责。

致谢

此脚本的灵感来自 watchTowr 团队的出色工作,他们为 CVE-2024-0012 编写的原始 Nuclei YAML 模板是此 Python 实现的基础。他们致力于识别和解决关键安全漏洞,持续为网络安全社区树立高标准。

下载工具