CriticalCVE-2018-15133

    Laravel Deserialization of Untrusted Data Vulnerability (CVE-2018-15133)

    Published In CISA KEV since Sources: pwn.watch, CVE.org, OSV

    Share

    What is affected, what to do

    In Laravel Framework through 5.5.40 and 5.6.x through 5.6.29, remote code execution might occur as a result of an unserialize call on a potentially untrusted X-XSRF-TOKEN value. This involves the decrypt method in Illuminate/Encryption/Encrypter.php and PendingBroadcast in gadgetchains/Laravel/RCE/3/chain.php in phpggc.

    The vulnerability is being actively exploited; treat it as a priority. The available sources name no fixed version. Check the vendor guidance in the references below. Immediate actions, mitigation and detection rules are in the runbook below.

    Affected
    • Laravel Framework lte *..5.5.40
    • Laravel Framework lte 5.6.0..5.6.29

    Not sure whether and how you are affected? Ask a question about this vulnerability

    Metrics

    8.1

    Priority

    XIEM Effective CVSS: highest available CVSS rating from NVD and vendor data.

    Source: NVD, CVSS v3

    8.1

    CVSS v3

    Severity High on the scale from 0 to 10.

    Source: pwn.watch, CVE.org, OSV

    76.6 %

    EPSS score

    High — model estimates ≥ 50% chance of real-world exploitation within 30 days.

    Source: FIRST EPSS, percentile 99.54

    Show all metrics
    Severity
    Critical
    Priority (0–325)

    The priority score is a consolidated metric that condenses several individual signals into a single, action-guiding ranking: technical severity (CVSS), exploitation likelihood (EPSS), known-exploited status (KEV) and the context of the affected asset. The aim is to answer the only truly important question in vulnerability management: what first?

    Read in glossary
    219.77 Methodology
    Exploit maturity

    An exploit is code or a technique that specifically uses a concrete vulnerability to force unintended behaviour — such as executing code or escalating privileges. It is the tool that turns a theoretical flaw into a practical attack.

    Read in glossary
    actively exploited
    XIEM Effective CVSS

    XIEM® is the tiered managed-security operating model from NEOSEC and a registered trademark of NEOSEC GmbH. It extends classic SIEM — the central collection, normalisation and correlation of security-relevant events — with endpoint forensics, network visibility and deception technology, and consolidates them into three building tiers: Sentry, Orchestrate and Command.

    Read in glossary
    8.1 Methodology
    CVSS v3

    CVSS is the globally established, open standard for assessing the technical severity of a vulnerability on a scale from 0 to 10. It describes how easily a flaw can be exploited and what damage it can cause — but not how likely its actual exploitation is. CVSS and the complementary EPSS deliberately answer different questions.

    Read in glossary
    8.1
    EPSS score

    The EPSS score is the absolute model output for an individual vulnerability: the estimated probability of real-world exploitation within the next 30 days, expressed as a value between 0 and 1 (i.e. 0 % to 100 %). A score of 0.42 means „the model estimates a 42 % chance of real-world exploitation within 30 days“.

    Read in glossary
    76.6 %
    High — model estimates ≥ 50% chance of real-world exploitation within 30 days.
    EPSS percentile

    The EPSS percentile is the relative position of a vulnerability within all EPSS-scored CVEs, expressed as a value between 0 and 1. A percentile of 0.90 means „this CVE has a higher EPSS score than 90 % of all other scored CVEs“. Unlike the EPSS score, it is not a probability — but a positioning within a ranking.

    Read in glossary
    99.54
    Critical — this CVE ranks in the top fifth of all CVEs scored today (rank ≥ 80%).
    KEV status

    The KEV catalogue is a list maintained by the US authority CISA of vulnerabilities for which active exploitation in the wild has been confirmed. It answers not the question „how severe?“ but „is it already being attacked?“ — thereby sharply prioritising patching.

    Read in glossary
    Actively exploited
    Published
    In CISA KEV since

    The KEV catalogue is a list maintained by the US authority CISA of vulnerabilities for which active exploitation in the wild has been confirmed. It answers not the question „how severe?“ but „is it already being attacked?“ — thereby sharply prioritising patching.

    Read in glossary
    CISA assessment (SSVC)
    Exploitation: active · not automatable · Technical impact: total
    Source: CISA Vulnrichment, as of 17 January 2024
    CWE

    CWE is a catalogue of typical weakness types in software and hardware — such as flawed input validation, unsafe memory handling or poor authentication. Where a CVE names a concrete vulnerability in a concrete product, a CWE describes the underlying class of defect.

    Read in glossary
    CWE-502

    Response and mitigation

    Why act now?

    Prioritisation rationale

    The flaw is network-reachable without authentication. Its high attack complexity comes solely from the need to know APP_KEY. In practice that barrier falls routinely: automated campaigns mass-scan for exposed .env files and debug pages, harvest the key, and use public phpggc gadget chains to get straight to remote code execution. Exploitation likelihood is accordingly very high. Typical victims are internet-facing, poorly maintained legacy Laravel apps such as customer portals, internal tools and agency-built sites. Stolen cloud and mail credentials are then abused for spam, cryptomining and lateral movement. Treat this as critical for any internet-exposed Laravel 4.x/5.x instance, especially if .env was ever reachable. Internal instances with no evidence of key exposure can follow, but key rotation remains mandatory there too.

    1. Runbook step 1

      Immediate response (0-24 h)

      • Inventory: Find every Laravel deployment (composer show laravel/framework or parse composer.lock). Affected versions are up to and including 5.5.40, 5.6.0 through 5.6.29, and the 4.x line.
      • Patch: Upgrade to 5.6.30 or later. For 5.5, use a release after 5.5.40; check the vendor advisory for the exact version. The 4.x and 5.x branches are end-of-life, so schedule migration to a currently supported Laravel branch.
      • Rotate APP_KEY now (php artisan key:generate), regardless of patch status. Exploitation requires the key, and a leaked key keeps cookies and sessions forgeable even after the upgrade. Rotation invalidates all sessions, so give users a heads-up. Any data encrypted via encrypt() must first be decrypted with the old key and re-encrypted.
      • Check for key exposure: Is /.env, /.git/config or /storage/logs/laravel.log publicly reachable? Is APP_DEBUG=true set in production? Was .env committed to a repository, or is the app running a default or sample key? Treat any hit as an indicator of compromise.
      • If exploitation is suspected: Isolate the host and preserve evidence (webroot, logs, crontabs, /tmp). Rotate every secret held in .env: database, mail, cloud API keys and AWS credentials.
    2. Runbook step 2

      Mitigation layers

      • Web server config: Hard-deny dotfiles. For nginx: location ~ /\.(env|git) { deny all; return 404; }. For Apache: <FilesMatch "^\.">Require all denied</FilesMatch>. The DocumentRoot must point at public/ only.
      • WAF/IPS: Alert on or block oversized X-XSRF-TOKEN headers (over roughly 1–2 KB). Do the same for Base64 values that don't match Laravel's normal {"iv":…,"value":…,"mac":…} JSON structure. Rate-limit, then block, scanners probing /.env and /.git/.
      • PHP hardening: Set disable_functions = system,exec,shell_exec,passthru,proc_open,popen,pcntl_exec in php.ini where the application allows it. Restrict open_basedir to the project directory.
      • Segmentation and egress: Apply default-deny outbound rules on the web tier and allow only required destinations. This kills curl/wget payload staging and reverse shells.
      • Secrets management and least privilege: Load APP_KEY and other secrets from a secrets store (e.g. Vault or cloud KMS) rather than a plaintext .env in the webroot. Run PHP-FPM without write access to code directories.
      • File integrity: Set up FIM on public/, app/ and vendor/ to catch dropped webshells.
    3. Runbook step 3

      Detection rules

      • Process ancestry (EDR/Sysmon for Linux EID 1, auditd execve): Alert when php-fpm, php or apache2/httpd spawns a shell or download tool. Sigma shape: ParentImage|endswith: ['/php-fpm','/php','/apache2','/httpd'] AND Image|endswith: ['/sh','/bash','/curl','/wget','/nc','/python3'].
      • auditd: -a always,exit -F arch=b64 -S execve -F uid=33 -k web_exec (adjust to the uid of www-data). Any execution outside the expected binaries is an alert.
      • Web access logs: Requests for /.env, /.env.bak, /.git/config or /_ignition/ returning 200. SPL: index=web uri_path IN ("/.env*","/.git/*") status=200 | stats count by src_ip, host. A 200 on any of these means a likely key leak.
      • Application log: Bursts of DecryptException or "The MAC is invalid" in storage/logs/laravel.log point to attempts with a wrong key. If suspicious requests stop producing these errors, the attacker likely holds a valid key.
      • Network (Zeek/Suricata): Web servers connecting to unfamiliar external IPs shortly after POST requests carrying a large X-XSRF-TOKEN. Also watch for new long-lived outbound sessions from the web tier.

    Detection rules

    No NEOSEC detection rule is available for this vulnerability yet.

    Classification under NIS2 and CRA

    Rule-based classification from exploitation status and severity. It does not replace a case-by-case assessment.

    NIS2

    NIS2 is EU Directive (EU) 2022/2555 to raise the level of cybersecurity across the Union. It substantially broadens obligations compared with the first NIS directive: more sectors, mandatory risk management, staged reporting duties and personal accountability of senior management.

    Read in glossary
    Actively exploited: treat the vulnerability as a priority in vulnerability handling under Art. 21(2)(e) NIS2. If it is exploited in your environment, check the reporting obligation under Art. 23 (early warning within 24 hours).
    CRA

    The CRA is EU Regulation (EU) 2024/2847 setting horizontal cybersecurity requirements for „products with digital elements“ — from industrial controllers and software to connected consumer devices. For the first time manufacturers must ensure security across the entire product lifecycle, handle vulnerabilities and provide security updates.

    Read in glossary
    Since 11.09.2026, manufacturers of affected products with digital elements must report actively exploited vulnerabilities under Art. 14 CRA, with an early warning within 24 hours via ENISA's single reporting platform.
    ISO/IEC 27001

    ISO/IEC 27001 is the internationally leading standard for an information security management system (ISMS). It describes a risk-based, process-oriented framework to systematically plan, implement, review and improve information security.

    Read in glossary
    Control A.8.8, management of technical vulnerabilities: assess relevance to your systems, plan remediation and keep evidence.

    Description

    In Laravel Framework through 5.5.40 and 5.6.x through 5.6.29, remote code execution might occur as a result of an unserialize call on a potentially untrusted X-XSRF-TOKEN value. This involves the decrypt method in Illuminate/Encryption/Encrypter.php and PendingBroadcast in gadgetchains/Laravel/RCE/3/chain.php in phpggc. The attacker must know the application key, which normally would never occur, but could happen if the attacker previously had privileged access or successfully accomplished a previous attack.

    Source: pwn.watch, NVD (NIST), OSV (Open Source Vulnerabilities), cvelistv5, CISA KEV Catalog, CVE.org (MITRE)

    Affected products

    The following versions are affected. Older releases of the same product line are also vulnerable unless stated otherwise.

    Affected products
    Affected versionsFixed in
    laravellaravel
    • 5.6.0 – ≤ 5.6.29
    • ≤ 5.5.40
    • —
    • —
    packagistlaravel/framework
    • v5.6.23
    • v4.1.31
    • v5.5.17
    • v5.2.7
    • v5.3.5
    • v5.6.1
    • v5.1.31
    • v4.2.2
    • v5.1.29
    • v5.0.11
    • v5.5.26
    • v5.1.25
    • v4.1.21
    • v4.1.15
    • v5.3.2
    • v5.5.10
    • v5.2.28
    • v4.2.21
    • v5.1.8
    • v5.1.0
    • v4.2.0-BETA1
    • v4.0.6
    • v5.0.24
    • v5.0.14
    • v5.1.40
    • v5.1.13
    • v4.1.24
    • v5.3.11
    • v5.3.27
    • v4.1.26
    • v5.1.38
    • v5.4.7
    • v4.2.11
    • v5.5.3
    • v5.4.28
    • v5.0.33
    • v5.1.17
    • v5.2.20
    • v5.6.20
    • v5.5.18
    • v4.1.12
    • 5.0.30
    • 5.6.0
    • v5.1.18
    • v5.4.1
    • v5.5.27
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —
    • —

    Vendors and products

    Weakness classes (CWE)

    • CWE-502Deserialization of Untrusted Data

      Base

      The product deserializes untrusted data without sufficiently ensuring that the resulting data will be valid.

      Entry at MITRE CWE-502

    Public exploit references

    Publicly reported proof-of-concepts, exploit modules and detection templates for this vulnerability. NEOSEC links to the original sources only and does not provide any exploit code.

    Public exploit references
    CISA KEV CatalogCISA Known Exploited Vulnerability (opens in a new tab)cisa.govactively exploited
    GitHubkozmic/laravel-poc-CVE-2018-15133 (opens in a new tab)github.comPoC (publicly reported)reported, not verified—
    Packet StormPHP Laravel Framework Token Unserialize Remote Command Execution (opens in a new tab)packetstormsecurity.comPoC (publicly reported)reported, not verified—

    References & sources

    • NVD (NIST)NVD: CVE-2018-15133advisory, pwn-watch
    • github.comlaravel/framework/commit/d84cf988ed5d4661a4bf1fdcb08f5073835083…web
    • github.comkozmic/laravel-poc-CVE-2018-15133web
    • github.comlaravel/frameworkpackage
    • laravel.comLaravel advisory: CVE-2018-15133web, x_refsource_CONFIRM, Vendor advisory, pwn-watch
    • packetstormsecurity.comfiles/153641/PHP-Laravel-Framework-Token-Unserialize-Remote-Com…web, x_refsource_MISC, Exploit, Third-party advisory, Vulnerability database
    • cisa.govknown-exploited-vulnerabilities-catalog?field_cve=CVE-2018-15133government-resource, US government resource
    • pwn.watchpwn.watch: Laravel Deserialization of Untrusted Datapwn-watch
    • cisa.govCISA Known Exploited Vulnerabilities Catalogpwn-watch
    Embed badge

    Show the severity and KEV status of this vulnerability on your site – with a link back here. The image is updated hourly.

    Badge preview for CVE-2018-15133
    <a href="https://intel.neosec.eu/en/cve/CVE-2018-15133"><img src="https://intel.neosec.eu/badge/cve/CVE-2018-15133.svg?lang=en" alt="CVE-2018-15133 – NEOSEC Intel" height="20"></a>