CVE-2025-21598

Junos OS and Junos OS Evolved: When BGP traceoptions are configured, receipt of malformed BGP packets causes RPD to crash

8.2 high EPSS 0.72%

Published 9 Jan 2025 Updated 9 Jan 2025 CNA: juniper

Check your servers for CVE-2025-21598

The Vulnpocalypse collector sends the package list of each Linux server and of its container images once a day. Vulnpocalypse shows every server where CVE-2025-21598 affects rpd, with the command that installs the fix. The free plan covers one server and one domain and does not need a credit card.

Check my servers

Description

An Out-of-bounds Read vulnerability in Juniper Networks Junos OS and Junos OS Evolved's routing protocol daemon (rpd) allows an unauthenticated, network-based attacker to send malformed BGP packets to a device configured with packet receive trace options enabled to crash rpd. This issue affects:

Junos OS:

* from 21.2R3-S8 before 21.2R3-S9,  * from 21.4R3-S7 before 21.4R3-S9,  * from 22.2R3-S4 before 22.2R3-S5,  * from 22.3R3-S2 before 22.3R3-S4,  * from 22.4R3 before 22.4R3-S5,  * from 23.2R2 before 23.2R2-S2,  * from 23.4R1 before 23.4R2-S1,  * from 24.2R1 before 24.2R1-S1, 24.2R2.

Junos OS Evolved: * from 21.4R3-S7-EVO before 21.4R3-S9-EVO,  * from 22.2R3-S4-EVO before 22.2R3-S5-EVO,  * from 22.3R3-S2-EVO before 22.3R3-S4-EVO,  * from 22.4R3-EVO before 22.4R3-S5-EVO,  * from 23.2R2-EVO before 23.2R2-S2-EVO,  * from 23.4R1-EVO before 23.4R2-S1-EVO,  * from 24.2R1-EVO before 24.2R1-S2-EVO, 24.2R2-EVO.

This issue requires a BGP session to be established.

This issue can propagate and multiply through multiple ASes until reaching vulnerable devices.

This issue affects iBGP and eBGP.

This issue affects IPv4 and IPv6.

An indicator of compromise may be the presence of malformed update messages in a neighboring AS which is unaffected by this issue:

For example, by issuing the command on the neighboring device:  show log messages

Reviewing for similar messages from devices within proximity to each other may indicate this malformed packet is propagating:   rpd[<pid>]: Received malformed update from <IP address> (External AS <AS#>) and   rpd[<pid>]: Malformed Attribute

Severity (CVSS)

8.2 high CVSS 4.0 from juniper (CNA)
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:L/AU:Y/R:A/V:C/RE:M/U:Amber
Attack vector
network: an attacker can reach the vulnerable part over the network, often from the internet
Attack complexity
low: an attack works without special conditions
Attack requirements
present: an attack works only when the target is in a certain state or configuration
Privileges required
none: the attacker does not need an account
User interaction
none: nobody has to click or open anything
Impact on the vulnerable system
confidentiality none, integrity none, availability high: what an attacker can read, change or stop in the vulnerable component
Impact on other systems
confidentiality none, integrity none, availability low: what an attacker can read, change or stop beyond it
7.5 high CVSS 3.1 from juniper (CNA)
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Attack vector
network: an attacker can reach the vulnerable part over the network, often from the internet
Attack complexity
low: an attack works without special conditions
Privileges required
none: the attacker does not need an account
User interaction
none: nobody has to click or open anything
Scope
unchanged: the damage stays inside the vulnerable component
Impact
confidentiality none, integrity none, availability high: what an attacker can read (confidentiality), change (integrity) or stop (availability)

Exploitation

EPSS 0.72%: the probability of exploitation activity in the next 30 days, from the EPSS model of FIRST. The score is higher than 55.0% of all scored CVEs. Scores of 1 Dec 2026.

The assessment of CISA (SSVC, 9 Jan 2025):

Exploitation
none: CISA did not find evidence of exploitation or a public proof of concept
Automatable
yes: an attacker can automate the attack across many targets
Technical impact
partial: limited control or limited data

Weakness

Affected products

As the CNA lists them.

ProductVersions
Junos OS
package RPD
affected from 21.2R3-S8, before 21.2R3-S9
affected from 21.4R3-S7, before 21.4R3-S9
affected from 22.2R3-S4, before 22.2R3-S5
affected from 22.3R3-S2, before 22.3R3-S4
affected from 22.4R3, before 22.4R3-S5
affected from 23.2R2, before 23.2R2-S2
affected from 23.4R1, before 23.4R2-S1
affected from 24.2R1, before 24.2R1-S1, 24.2R2
Other versions: unaffected
Junos OS Evolved
affected from 21.4R3-S7-EVO, before 21.4R3-S9-EVO
affected from 22.2R3-S4-EVO, before 22.2R3-S5-EVO
affected from 22.3R3-S2-EVO, before 22.3R3-S4-EVO
affected from 22.4R3-EVO, before 22.4R3-S5-EVO
affected from 23.2R2-EVO, before 23.2R2-S2-EVO
affected from 23.4R1-EVO, before 23.4R2-S1-EVO
affected from 24.2R1-EVO, before 24.2R1-S2-EVO, 24.2R2-EVO
Other versions: unaffected

Is my server affected?

Find the installed version of rpd and compare it with the fixed version of your distribution. Distributions often fix a CVE in a package version of their own, so the version number of the upstream project can mislead.

Debian, Ubuntu

dpkg -l | grep -i rpd
# packages whose changelog names the CVE (fixed in the installed version)
zgrep -l CVE-2025-21598 /usr/share/doc/*/changelog.Debian.gz
# Ubuntu
pro fix CVE-2025-21598

RHEL, Rocky, Alma, Fedora

rpm -q rpd
# lists the advisory while the fix is not installed
dnf updateinfo list --cve CVE-2025-21598

Alpine

apk list --installed | grep -i rpd

With Trivy, on the host and for a container image. When a package is affected, it prints the installed and the fixed version:

trivy rootfs --scanners vuln / | grep CVE-2025-21598
trivy image --scanners vuln IMAGE | grep CVE-2025-21598

Vulnpocalypse makes this comparison every day for the package lists of your servers and container images, including language packages (npm, PyPI, Go, Maven and others), and sends the command that installs the fix. Start free with one server and one domain or read how to install the collector.

References

Advisories

Other references

Source: the record CVE-2025-21598 of the CVE List (CVE Program), CVE Terms of Use; the CISA KEV catalog and the CISA ADP container; EPSS of FIRST; the CWE catalog of MITRE, CWE Terms of Use. The text of the record is shown as published. Data sources and licences.