Back to Labs
Security Advisory

CVE-2023-36845

About

A PHP External Variable Modification vulnerability in J-Web of Juniper Networks Junos OS on EX Series

and SRX Series

allows an unauthenticated, network-based attacker to remotely execute code.

Using a crafted request which sets the variable PHPRC an attacker is able to modify the PHP execution environment allowing the injection und execution of code.

This issue affects Juniper Networks Junos OS on EX Series

and

SRX Series:

* All versions prior to

20.4R3-S9;
* 21.1 versions 21.1R1 and later;
* 21.2 versions prior to 21.2R3-S7;
* 21.3 versions prior to 21.3R3-S5;
* 21.4 versions prior to 21.4R3-S5;
* 22.1 versions

prior to

22.1R3-S4;
* 22.2 versions

prior to

22.2R3-S2;
* 22.3 versions

prior to

22.3R2-S2, 22.3R3-S1;
* 22.4 versions

prior to

22.4R2-S1, 22.4R3;
* 23.2 versions prior to 23.2R1-S1, 23.2R2.

Weakness (CWE):CWE-473

Rainforest analyst review

This is a PHP external-variable-modification flaw in the J-Web management interface of Juniper's Junos OS on EX and SRX series devices. J-Web runs on PHP, and a crafted request lets an unauthenticated attacker set the PHPRC environment variable, which controls where PHP looks for its configuration. By pointing PHP at attacker-influenced configuration, the request alters the execution environment enough to inject and run code, converting a management-interface request into remote code execution on the device.

EX switches and SRX firewalls are core network infrastructure, and SRX units in particular are security devices frequently placed at the network edge with J-Web enabled for administration. A code-execution flaw on a firewall is worst-case, because that device sees and controls the traffic it is meant to protect, and public exploit chains for the Junos J-Web bugs appeared rapidly after disclosure and drew active scanning. Apply Juniper's fixed Junos releases for the specific train, and as interim hardening disable J-Web or restrict it to a management network. Given how fast weaponization followed, verify no unauthorized configuration changes or unexpected processes on exposed devices.

References

Related CVEs

No related CVEs.

Frequently asked questions

What is CVE-2023-36845?

A PHP External Variable Modification vulnerability in J-Web of Juniper Networks Junos OS on EX Series and SRX Series allows an unauthenticated, network-based attacker to remotely execute code. Using a crafted request which sets the variable PHPRC an attacker is able to modify the PHP execution environment allowing the injection und execution of code.

How severe is CVE-2023-36845?

CVE-2023-36845 carries a CVSS 3.1 base score of 9.8, rated critical. On the Rainforest Risk Index — which weighs the severity alongside how easy the flaw is to reach and how broad its impact is — it scores 99 out of 100, in the critical band.

How is CVE-2023-36845 exploited?

According to the CVSS vector (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H): attack vector Network, attack complexity Low, privileges required None, user interaction None. Impact on confidentiality High, integrity High and availability High.

Which products are affected by CVE-2023-36845?

Public advisories list the following as affected: junos, srx100, srx110, srx1400, srx1500, srx210, +23. Check the references on this page for the exact versions each vendor confirms.

How do I fix CVE-2023-36845?

Apply the fix the vendor published — the references on this page link to the primary advisories and patches. When patching can't happen right away, reduce the exposure of the affected component and watch it for exploitation attempts. Rainforest customers see this vulnerability correlated to their own assets and prioritized by real exposure, not by score alone.

Empower Your Security Strategy with Rainforest

Discover vulnerabilities early, prioritize critical threats, and protect what truly matters. Rainforest streamlines your security operations, saving you time and reducing costs, so you can focus on what drives your business forward.

Share this:LinkedInX Email