CVE-2021-31358 in Juniper Junos OS Evolved
A command injection vulnerability in sftp command processing on Juniper Networks Junos OS Evolved allows an attacker with authenticated CLI access to be able to bypass configured access protections to execute arbitrary shell commands within the context of the current user. The vulnerability allows an attacker to bypass command authorization restrictions assigned to their specific user account and execute commands that are available to the privilege level for which the user is assigned. For example, a user that is in the super-user login class, but restricted to executing specific CLI commands could exploit the vulnerability to execute any other command available to an unrestricted admin user. This vulnerability does not increase the privilege level of the user, but rather bypasses any CLI command restrictions by allowing full access to the shell. This issue affects Juniper Networks Junos OS Evolved: All versions prior to 20.4R2-S2-EVO; 21.1 versions prior to 21.1R2-EVO; 21.2 versions prior to 21.2R1-S1-EVO, 21.2R2-EVO.
Affects 1 product from 1 vendor. Description from NVD and MITRE.
Requires local access, low complexity, low privileges required, no user interaction needed, impact contained to the vulnerable component, full confidentiality impact, full integrity impact, full availability impact.
Affected products and versions
| Vendor | Product | Affected versions |
|---|---|---|
| Juniper | Junos OS Evolved | 20.4 21.1 21.2 ≤ 20.3 |
Fix and vendor advisory
Vendor PSIRT: [email protected]
Exploitation
| CISA known-exploited | Not in the CISA KEV catalog |
|---|---|
| Public exploit | Not confirmed |
Record details
| CVE ID | CVE-2021-31358 |
|---|---|
| BreachSpider ID | BS-2021-GLOBAL-266926-H |
| CVSS vector | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H |
| Published | 2021-10-19 |
| Last modified | 2026-06-17 |
| Weakness (CWE) | |
| Source | NVD |
Check devices from your own code or AI agent: free 14-day trial
Page facts from NVD, MITRE, CISA and vendor advisories, record last modified 2026-06-17.