Security Advisory

CVE-2025-21590: Junos OS Kernel Code Injection

Last updated:
  • CVE-2025-21590

CVE-2025-21590 is an isolation flaw in the Junos OS kernel: a local attacker with high privileges and access to the shell can inject arbitrary code and compromise the device. It is not reachable from the Junos CLI alone. Mandiant linked it to espionage backdoors on Juniper MX routers, and CISA KEV lists it. Juniper scores it 4.4 and NVD has no Primary score.

Vulnerability summary

CVSS base score

4.4

Medium severity

EPSS score (FIRST)

1.7%

Probability of exploitation in the wild in the next 30 days

CISA KEV catalog

Yes

Listed as known exploited

Published

Vulnerability ID: CVE-2025-21590 · Source: NVD (Juniper CNA Secondary score only, not NVD Primary)

Affected components

ComponentCPEVersion range
Juniper Networks Junos OS (all platforms)cpe:2.3:o:juniper:junos:*:*:*:*:*:*:*:*All versions before 21.2R3-S9; 21.4 before 21.4R3-S10; 22.2 before 22.2R3-S6; 22.4 before 22.4R3-S6; 23.2 before 23.2R2-S3; 23.4 before 23.4R2-S4; 24.2 before 24.2R1-S2, 24.2R2 (Juniper)
Juniper MX Series routers—Exploited on end-of-life MX routers (Mandiant); MX104 fix only in 21.2R3-S9 (Juniper)

What does this mean for affected devices?

Juniper's CVE record, published 2025-03-12, describes "an Improper Isolation or Compartmentalization vulnerability in the kernel of Juniper Networks Junos OS" that "allows a local attacker with high privileges to compromise the integrity of the device". It adds: "A local attacker with access to the shell is able to inject arbitrary code which can compromise an affected device. This issue is not exploitable from the Junos CLI." Juniper, the CNA, scores it CVSS v3.1 4.4 (CVSS:3.1/AV:L/AC:L/PR:H/UI:N/S:U/C:N/I:H/A:N) and CVSS v4.0 6.7, with CWE-653. As of 2026-11-25 NVD has added CPE configurations for Junos OS but no NVD Primary CVSS score; the CISA KEV listing is the reason to act (NVD, CVE record).

Which Junos OS releases fix it?

Juniper's solution lists 21.2R3-S9, 21.4R3-S10, 22.2R3-S6, 22.4R3-S6, 23.2R2-S3, 23.4R2-S4, 24.2R1-S2, 24.2R2 and 24.4R1, and all later releases. Juniper warns that "this issue is not fixed for all platforms" in those releases and gives platform-specific fixes. On SRX300 Series and on ACX500, ACX1000, ACX1100, ACX2100, ACX2200 and ACX4000 the fix is in 21.2R3-S9. On SRX300 Series it is also in 24.4R1. On MX104 it is only in 21.2R3-S9. For SRX550HM, EX4300 Series (except EX4300-48MP) and EX4600 (except EX4650), the record names later maintenance releases (22.2R3-S7 and 21.4R3-S11) that were unpublished when the record was written. Check JSA93446 for their current status. Until a fixed release is installed, Juniper strongly recommends "restricting shell access to trusted users only".

How was CVE-2025-21590 exploited?

Juniper's record states that "at least one instance of malicious exploitation has been reported to the Juniper SIRT". Mandiant's report of 2025-03-12 describes the China-nexus espionage group UNC3886 deploying TINYSHELL-based backdoors on Juniper MX routers in 2024. The group got in with legitimate credentials and used this technique to get around the Junos veriexec protection. Mandiant notes that the affected MX routers ran end-of-life hardware and software. It advises upgrading to Juniper's latest images and running the Juniper Malware Removal Tool (JMRT) Quick Scan and Integrity Check afterwards. CISA added the flaw to the KEV catalog on 2025-03-13 with the required action "Apply mitigations per vendor instructions, follow applicable BOD 22-01 guidance for cloud services, or discontinue use of the product if mitigations are unavailable." (due 2025-04-03; known ransomware campaign use: Unknown). It is still listed as of 2026-11-25 in catalog version 2026.11.24 (CISA KEV). FIRST EPSS gives 0.01749, the 78.32nd percentile, in the 2026-11-24 dataset (FIRST EPSS). A low CVSS and EPSS do not outweigh a KEV listing; see KEV and EPSS vulnerability prioritization. The attackers came in through management access, which CISA BOD 23-02 and internet-exposed management interfaces addresses. Older Juniper backdoor history: CVE-2015-7755 in ScreenOS.

How to fix this class of issueNo dedicated SoftWSP guide covers this weakness class; the fix is usually the vendor patch or firmware update referenced above. Our related guide explains how to plan and verify it: NIST SP 800-40 Rev. 4: enterprise patch management planning, explained.

Evidence

  • NVD: Analyzed; Improper Isolation or Compartmentalization in the kernel of Junos OS, local attacker with high privileges and shell access can inject arbitrary code, not exploitable from the Junos CLI; affected all versions before 21.2R3-S9, 21.4 before 21.4R3-S10, 22.2 before 22.2R3-S6, 22.4 before 22.4R3-S6, 23.2 before 23.2R2-S3, 23.4 before 23.4R2-S4, 24.2 before 24.2R1-S2/24.2R2; Juniper Secondary CVSS v4.0 6.7 and CVSS v3.1 4.4 AV:L/AC:L/PR:H/UI:N/S:U/C:N/I:H/A:N; no NVD Primary score; CWE-653; CPE junos; published 2025-03-12; read 2026-11-25. — NVD
  • CVE record (CNA Juniper, advisory JSA93446): fixed releases 21.2R3-S9, 21.4R3-S10, 22.2R3-S6, 22.4R3-S6, 23.2R2-S3, 23.4R2-S4, 24.2R1-S2, 24.2R2 and 24.4R1 and all subsequent releases; not fixed for all platforms: SRX300 Series 21.2R3-S9, 23.4R2-S5 (marked future), 24.4R1; SRX550HM 22.2R3-S7 (future); EX4300 Series 21.4R3-S11 (future, except EX4300-48MP); EX4600 21.4R3-S11 (future, except EX4650); ACX1000/1100/2100/2200/4000/ACX500 21.2R3-S9; MX104 21.2R3-S9; workaround restrict shell access to trusted users only; 'At least one instance of malicious exploitation has been reported to the Juniper SIRT.' — CVE.org (Juniper CNA record)
  • Juniper 2025-03 Out-of-Cycle Security Bulletin JSA93446, 'Junos OS: A local attacker with shell access can execute arbitrary code', named in the CVE record and KEV entry (portal page is script-rendered; its fix and workaround text is carried in Juniper's CVE record). — Juniper Networks
  • Mandiant (Google Cloud blog), 2025-03-12: UNC3886 deployed TINYSHELL-based backdoors on Juniper MX routers found mid-2024; affected MX routers ran end-of-life hardware and software; process-injection technique to circumvent veriexec tracked as CVE-2025-21590 (JSA93446); initial access via legitimate credentials from a terminal server; recommends upgrading to latest Juniper images and running JMRT Quick Scan and Integrity Check after upgrade. — Mandiant / Google Cloud
  • KEV catalog 2026.11.24: Juniper Junos OS Improper Isolation or Compartmentalization, dateAdded 2025-03-13, due 2025-04-03, required action 'Apply mitigations per vendor instructions, follow applicable BOD 22-01 guidance for cloud services, or discontinue use of the product if mitigations are unavailable.', knownRansomwareCampaignUse Unknown, CWE-653; checked 2026-11-25. — CISA KEV
  • EPSS 0.01749, percentile 0.78317, dataset 2026-11-24, read 2026-11-25. — FIRST EPSS

Related advisories

Sources

  1. NVD
  2. CVE.org record CVE-2025-21590 (CNA: Juniper Networks)
  3. Juniper JSA93446: A local attacker with shell access can execute arbitrary code
  4. Mandiant: China-nexus espionage actor UNC3886 targets Juniper routers
  5. CISA KEV
  6. FIRST EPSS

Frequently asked questions

Which Juniper devices are affected by CVE-2025-21590?

Junos OS on all platforms before 21.2R3-S9, and the 21.4, 22.2, 22.4, 23.2, 23.4 and 24.2 trains before their fixed releases. Some platforms (SRX300, SRX550HM, EX4300, EX4600, ACX, MX104) have their own fix releases. Exploitation was seen on end-of-life MX routers (per Juniper's CVE record and Mandiant).

Can CVE-2025-21590 be exploited remotely?

Not directly. The attacker needs high privileges and access to the Junos shell; the flaw is not exploitable from the Junos CLI. In the reported attacks the group first logged in with legitimate credentials from a terminal server (per Juniper and Mandiant).

What should I do about CVE-2025-21590?

Upgrade to 21.2R3-S9, 21.4R3-S10, 22.2R3-S6, 22.4R3-S6, 23.2R2-S3, 23.4R2-S4, 24.2R1-S2, 24.2R2 and 24.4R1 or later, or to the platform-specific release Juniper names. Until then restrict shell access to trusted users. Mandiant also advises running the JMRT Quick Scan and Integrity Check after upgrading (per Juniper JSA93446 and Mandiant).

Why does NVD show no score for CVE-2025-21590?

As of 2026-11-25 NVD shows only Juniper's CNA scores, CVSS v3.1 4.4 and CVSS v4.0 6.7, and no NVD Primary score, although it has added CPE data. The page qualifies through the CISA KEV listing of 2025-03-13 (per NVD and CISA KEV).