CVE-2024-21892
nodejs: code injection and privilege escalation through Linux capabilities
Overview
Description
On Linux, Node.js ignores certain environment variables if those may have been set by an unprivileged user while the process is running with elevated privileges with the only exception of CAP_NET_BIND_SERVICE.
Due to a bug in the implementation of this exception, Node.js incorrectly applies this exception even when certain other capabilities have been set.
This allows unprivileged users to inject code that inherits the process's elevated privileges.
Source: OX vulnerability database
Severity
7.8 · HIGH
CVSS 3.1 base score, scored by NVD.
- Attack vector
- Local
- Attack complexity
- Low
- Privileges required
- Low
- User interaction
- None
- Scope
- Unchanged
- Confidentiality
- High
- Integrity
- High
- Availability
- High
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
Weakness: CWE-94, CWE-269
Affected packages · 2
Operating systems · 89 fixes
Azure Linux 1 release · 1 package
| Release | Package | Fixed in |
|---|---|---|
| 3.0 | nodejs | 0:20.14.0-1.azl3 |
Oracle Linux 2 releases · 4 packages
| Release | Package | Fixed in |
|---|---|---|
| 8 | npm | 1:10.2.4-1.20.11.1.1.module+el8.9.0+90250+089ba5e1 |
| 8 | nodejs +3 | 1:20.11.1-1.module+el8.9.0+90250+089ba5e1 |
| 8 | nodejs-packaging +1 | 2021.06-4.module+el8.9.0+90157+ed89dc20 |
| 8 | nodejs-nodemon | 3.0.1-1.module+el8.9.0+90157+ed89dc20 |
| 9 | npm | 1:10.2.4-1.20.11.1.1.module+el9.3.0+90254+3f4d3ee1 |
| 9 | nodejs +3 | 1:20.11.1-1.module+el9.3.0+90254+3f4d3ee1 |
2 more rows
Photon OS 2 releases · 1 package
| Release | Package | Fixed in |
|---|---|---|
| 4.0 | nodejs +1 | 18.19.1-1.ph4 |
| 5.0 | nodejs +1 | 20.11.1-1.ph5 |
Red Hat 4 releases · 4 packages
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| 8 (nodejs:18) | nodejs-packaging +1 | 0:2021.06-4.module+el8.7.0+15582+19c314fa | RHSA-2024:1880 |
| 8 (nodejs:18) | nodejs-packaging +1 | 0:2021.06-4.module+el8.9.0+21190+5ebd2c33 | RHSA-2024:1510 |
| 8 (nodejs:18) | nodejs-nodemon | 0:3.0.1-1.module+el8.8.0+19757+8ca87034 | RHSA-2024:1880 |
| 8 (nodejs:18) | nodejs-nodemon | 0:3.0.1-1.module+el8.9.0+21190+5ebd2c33 | RHSA-2024:1510 |
| 8 (nodejs:18) | npm | 1:10.2.4-1.18.19.1.1.module+el8.8.0+21592+14a8b93e | RHSA-2024:1880 |
| 8 (nodejs:18) | npm | 1:10.2.4-1.18.19.1.1.module+el8.9.0+21387+21356dec | RHSA-2024:1510 |
18 more rows
SUSE Linux Enterprise 2 releases · 2 packages
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| 15.4 | nodejs18 +3 | 18.19.1-150400.9.18.2 | SUSE-SU-2024:0730-1 |
| 15.5 | nodejs18 +3 | 18.19.1-150400.9.18.2 | SUSE-SU-2024:0730-1 |
| 15.5 | nodejs20 +3 | 20.11.1-150500.11.6.1 | SUSE-SU-2024:0643-1 |
alma 4 releases · 4 packages
| Release | Package | Fixed in |
|---|---|---|
| 8 (nodejs:18) | npm | 1:10.2.4-1.18.19.1.1.module_el8.9.0+3753+4de0891b |
| 8 (nodejs:18) | nodejs +3 | 1:18.19.1-1.module_el8.9.0+3753+4de0891b |
| 8 (nodejs:18) | nodejs-packaging +1 | 2021.06-4.module_el8.7.0+3343+ea2b7901 |
| 8 (nodejs:18) | nodejs-nodemon | 3.0.1-1.module_el8.8.0+3613+1ed8c91d |
| 8 (nodejs:20) | npm | 1:10.2.4-1.20.11.1.1.module_el8.9.0+3775+d8460d35 |
| 8 (nodejs:20) | nodejs +3 | 1:20.11.1-1.module_el8.9.0+3775+d8460d35 |
10 more rows
alpine 4 releases · 2 packages
| Release | Package | Fixed in |
|---|---|---|
| 3.22 | openjdk17 | 17.0.11_p9-r0 |
| 3.22 | openjdk21 | 21.0.3_p9-r0 |
| 3.23 | openjdk17 | 17.0.11_p9-r0 |
| 3.23 | openjdk21 | 21.0.3_p9-r0 |
| 3.24 | openjdk17 | 17.0.11_p9-r0 |
| 3.24 | openjdk21 | 21.0.3_p9-r0 |
2 more rows
amazon linux 1 release · 6 packages
| Release | Package | Fixed in |
|---|---|---|
| 2023 | nodejs20-npm | 1:10.2.4-1.20.11.1.1.amzn2023.0.1 |
| 2023 | nodejs +7 | 1:18.18.2-1.amzn2023.0.2 |
| 2023 | nodejs20 +7 | 1:20.11.1-1.amzn2023.0.1 |
| 2023 | nodejs-npm | 1:9.8.1-1.18.18.2.1.amzn2023.0.2 |
| 2023 | v8-10-2-devel | 3:10.2.154.26-1.18.18.2.1.amzn2023.0.2 |
| 2023 | v8-11-3-devel | 3:11.3.244.8-1.20.11.1.1.amzn2023.0.1 |
debian 3 releases · 1 package
| Release | Package | Fixed in |
|---|---|---|
| 12 | nodejs | 18.20.4+dfsg-1~deb12u1 |
| 13 | nodejs | 18.19.1+dfsg-1 |
| 14 | nodejs | 18.19.1+dfsg-1 |
echo 1 release · 1 package
| Release | Package | Fixed in |
|---|---|---|
| nodejs | 18.20.4+dfsg-1~deb12u1 |
openSUSE 1 release · 2 packages
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Tumbleweed | corepack20 +4 | 20.11.1-1.1 | openSUSE-SU-2024:13697-1 |
| Tumbleweed | corepack21 +4 | 21.6.2-1.1 | openSUSE-SU-2024:13698-1 |
rocky 3 releases · 4 packages
| Release | Package | Fixed in |
|---|---|---|
| 8 (nodejs:18) | npm | 1:10.2.4-1.18.19.1.1.module+el8.9.0+1768+6b454dc0 |
| 8 (nodejs:18) | nodejs +3 | 1:18.19.1-1.module+el8.9.0+1768+6b454dc0 |
| 8 (nodejs:18) | nodejs-packaging +1 | 2021.06-4.module+el8.7.0+1072+5b168780 |
| 8 (nodejs:18) | nodejs-nodemon | 3.0.1-1.module+el8.8.0+1459+02651ab6 |
| 8 (nodejs:20) | npm | 1:10.2.4-1.20.11.1.1.module+el8.9.0+1776+addd4aec |
| 8 (nodejs:20) | nodejs +3 | 1:20.11.1-1.module+el8.9.0+1776+addd4aec |
8 more rows
root.io debian 1 release · 1 package
| Release | Package | Fixed in |
|---|---|---|
| 12 | nodejs +1 | 18.20.4+dfsg-1~deb12u1 |
References
- www.openwall.com http://www.openwall.com/lists/oss-security/2024/03/11/1
- access.redhat.com https://access.redhat.com/errata/RHSA-2024:1687
- access.redhat.com https://access.redhat.com/errata/RHSA-2024:1688
- access.redhat.com https://access.redhat.com/security/cve/CVE-2024-21892
- bugzilla.redhat.com https://bugzilla.redhat.com/2264569
- bugzilla.redhat.com https://bugzilla.redhat.com/2264574
- bugzilla.redhat.com https://bugzilla.redhat.com/2264582
- bugzilla.redhat.com https://bugzilla.redhat.com/2265717
- bugzilla.redhat.com https://bugzilla.redhat.com/2265720
- bugzilla.redhat.com https://bugzilla.redhat.com/2265722
Show all 39 references
- bugzilla.redhat.com https://bugzilla.redhat.com/2265727
- bugzilla.redhat.com https://bugzilla.redhat.com/show_bug.cgi?id=2264569
- bugzilla.redhat.com https://bugzilla.redhat.com/show_bug.cgi?id=2264574
- bugzilla.redhat.com https://bugzilla.redhat.com/show_bug.cgi?id=2264582
- bugzilla.redhat.com https://bugzilla.redhat.com/show_bug.cgi?id=2265717
- bugzilla.redhat.com https://bugzilla.redhat.com/show_bug.cgi?id=2265720
- bugzilla.redhat.com https://bugzilla.redhat.com/show_bug.cgi?id=2265722
- bugzilla.redhat.com https://bugzilla.redhat.com/show_bug.cgi?id=2265727
- creativecommons.org https://creativecommons.org/licenses/by/4.0/
- cve.mitre.org https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2023-46809
- cve.mitre.org https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2024-21890
- cve.mitre.org https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2024-21891
- cve.mitre.org https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2024-21892
- cve.mitre.org https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2024-21896
- cve.mitre.org https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2024-22017
- cve.mitre.org https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2024-22019
- errata.almalinux.org https://errata.almalinux.org/9/ALSA-2024-1688.html
- errata.rockylinux.org https://errata.rockylinux.org/RLSA-2024:1687
- github.com https://github.com/nodejs/node/commit/10ecf400679e04eddab940721cad3f6c1d603b61
- github.com https://github.com/nodejs/node/commit/2a5a150772c6a41795314340c8697035a1b344b6
- github.com https://github.com/nodejs/node/commit/b43171c6f669b2223064343e2c8472582586f727
- github.com https://github.com/nodejs/node/commit/e6b4c105e0795fba8afb3f8e910c56ba9e60f4b5
- hackerone.com https://hackerone.com/reports/2237545
- linux.oracle.com https://linux.oracle.com/cve/CVE-2024-21892.html
- linux.oracle.com https://linux.oracle.com/errata/ELSA-2024-1688.html
- nvd.nist.gov https://nvd.nist.gov/vuln/detail/CVE-2024-21892
- security.netapp.com https://security.netapp.com/advisory/ntap-20240322-0003/
- www.cve.org https://www.cve.org/CVERecord?id=CVE-2024-21892
- www.oracle.com https://www.oracle.com/security-alerts/cpuapr2024.html
OX Radar and Response Center
Find threats in your stack.
OX Radar can check high-priority threats, like critical package CVEs, against your context.
Each incident is marked Detected or Not Detected with a remediation plan and proof all tracked in the Response Center.