Skip to content
KitploitKITPLOIT
ToolsExploitsBlog
Log in
Submit
ToolsExploitsBlog
Submit

Hacking, PenTest, and Cybersecurity Tools for Your Security Arsenal!

Kitploit is a directory of hacking, cybersecurity, and pentesting tools. Discover the latest project updates to find vulnerabilities, analyze systems, automate testing, and strengthen your security.

FeedsContactPrivacy© 2026 Kitploit

Tool Directory

Categories

View all categories
Loading categories
Tools/GitHubGitHub/razureink/cve-2024-0012_9474-panos_authbypass_reproduction
Authentication & AuthorizationPrivilege EscalationVulnerability AnalysisExploitationWeb Application ExploitationPenetration TestingRed TeamingPayload Development
GitHubrazureink/cve-2024-0012_9474-panos_authbypass_reproduction

cve-2024-0012_9474-panos_authbypass_reproduction

CVE Reproduction: cve-2024-0012_9474-panos_authbypass_reproduction

View Repository
333 months agoNot yet reviewed
Share

CVE-2024-0012 / CVE-2024-9474 — PAN-OS Authentication Bypass → Privilege Escalation Chain

CVEDescriptionCVSS
CVE-2024-0012PAN-OS Management Interface Authentication Bypass9.3
CVE-2024-9474PAN-OS Privilege Escalation6.9

When chained, these vulnerabilities allow unauthenticated remote code execution on the PAN-OS management web interface.

Both were actively exploited as zero-days in the wild under what has been tracked as Operation Lunar Peek. The research was initially disclosed by watchTowr.


Overview

The Palo Alto Networks PAN-OS management web interface is exposed to two critical flaws that, when combined, give an attacker full root-level access without any authentication:

  1. CVE-2024-0012 — Bypass authentication controls and reach authenticated endpoints as an unauthenticated remote attacker.
  2. CVE-2024-9474 — Once authenticated (even as a low-privilege user), escape the PHP session handler to write arbitrary files and escalate to root.

Technical Details

CVE-2024-0012 — Authentication Bypass

The management web interface improperly validates authentication for certain API and PHP endpoints. By manipulating HTTP request paths (e.g. path traversal or double-slash techniques), an attacker can reach restricted handlers that normally require a valid session. This effectively grants unauthenticated access to the PHPRESTAPI and other internal endpoints.

The root cause lies in the Nginx/Apache routing rules that fail to enforce session checks on specific URI patterns, allowing requests to bypass the authentication middleware.

CVE-2024-9474 — Privilege Escalation via PHP Session Write

Once authenticated (even as a read-only or low-privileged user), the vulnerability exists in the PHP session serialisation mechanism. The session.save_path is misconfigured, and the session filename is partially user-controlled. By crafting a session ID containing path-traversal sequences, an attacker can write a PHP session file to an arbitrary location (e.g. ../utils/webshell.php).

Because the web server runs as root, the written file inherits root ownership, giving the attacker a root-level webshell.


Affected Versions

PAN-OS VersionAffectedFixed In
10.2< 10.2.12-h210.2.12-h2
11.0< 11.0.6-h111.0.6-h1
11.1< 11.1.5-h111.1.5-h1
11.2< 11.2.4-h111.2.4-h1
11.3Not affected—
Cloud NGFWNot affected—

Exploitation Chain

Attacker (unauthenticated)
    │
    ├─ CVE-2024-0012 ─────────────────────────────┐
    │  Bypass auth via crafted URI                  │
    │  → Gain access to PHPRESTAPI endpoint         │
    │  → Create a low-privilege API key / session   │
    └──────────────────────────────────────────────┘
    │
    ├─ CVE-2024-9474 ─────────────────────────────┐
    │  Use obtained session/key                     │
    │  → Send crafted PHP session ID (path traversal)│
    │  → Write session file to webroot              │
    │  → File contains PHP code (webshell)          │
    └──────────────────────────────────────────────┘
    │
    ▼
RCE as root via webshell

Reproduction Steps

  1. Identify a vulnerable PAN-OS mgmt interface (port 443 by default).
  2. CVE-2024-0012 — Send a crafted HTTP request to an internal endpoint using path manipulation to bypass auth. Receive an authenticated session token or API key.
  3. CVE-2024-9474 — With the token, send a request to the session-handler endpoint with a malicious X-PAN- or cookie-based session ID containing ../ traversal to write a PHP payload to the web-accessible php/ directory.
  4. Access the written webshell at /php/<shell>.php to execute arbitrary commands as root.

PoC

See exploit.py in this directory for a working proof-of-concept that chains both CVEs.


Mitigation

  1. Upgrade PAN-OS to the hotfix versions listed in the affected-versions table.
  2. Restrict the management interface to trusted internal IPs only — never expose it to the internet.
  3. If the mgmt interface must be exposed, use a dedicated management VLAN or jump-box with strict ACLs.

References

  • watchTowr — Operation Lunar Peek
  • Palo Alto Networks Security Advisory — CVE-2024-0012
  • Palo Alto Networks Security Advisory — CVE-2024-9474
  • NVD — CVE-2024-0012
  • NVD — CVE-2024-9474
Download Tool

Most Popular

View all →

Discover the most used tools by our community.

  • 1

    OsintHunter

    letox4/osinthunter

    🎯 The ultimate OSINT toolkit: investigation graph, confidence scoring, alias families, map, timeline and reports. 49 modules, 400+ sites, no API keys required.

    936
  • 2

    ghostlock-app

    yukonga/ghostlock-app

    GhostLock One-Tap Execution App (CVE-2026-43499)

    555
  • 3

    redforge

    cybersecurity91/redforge

    Browser-side red team toolkit with 102 offline tools for recon, payload generation, credential attacks, crypto, encoding and engagement reporting.

    353
  • 4

    ARTEX

    baarai/artex

    LLM multi-agent autonomous penetration testing platform with planner/worker agents, asset and exploration graphs, MITM traffic recording, and vulnerability retesting.

    348
  • 5

    looking-glass

    anonghosty/looking-glass

    CSIRT platform that ingests Shadowserver reports into MongoDB and replays them as interactive maps, analysis, findings, advisories and executive dashboards.

    336
  • 6

    CyberStrikeAI

    ed1s0nz/cyberstrikeai

    The system of action for AI-native cybersecurity—where intent becomes governed execution, evidence becomes operational memory, and every operation improves the next.

    288

Explore all tools

Browse our collection of tools

View all tools →