CVE-2023-30581: mainModule.proto bypass experimental policy mechanism

Published Jun 20, 2023
·
Updated

A vulnerability has been discovered in Node.js, where the use of proto in process.mainModule.proto.require() can bypass the policy mechanism and require modules outside of the policy.json definition.

Other sources

Node.js could allow a remote attacker to bypass security restrictions, caused by the use of proto in process.mainModule.proto.require(). By sending a specially crafted request, an attacker could exploit this vulnerability to bypass experimental policy mechanism.

— IBM

The use of proto in process.mainModule.proto.require() can bypass the policy mechanism and require modules outside of the policy.json definition. This vulnerability affects all users using the experimental policy mechanism in all active release lines: v16, v18 and, v20.

Please note that at the time this CVE was issued, the policy is an experimental feature of Node.js

— MITRE

The use of proto in process.mainModule.proto.require() can bypass the policy mechanism and require modules outside of the policy.json definition.

Please note that at the time this CVE was issued, the policy is an experimental feature of Node.js.

— Node.Js

The use of proto in process.mainModule.proto.require() can bypass the policy mechanism and require modules outside of the policy.json definition.

References: https://nodejs.org/en/blog/vulnerability/june-2023-security-releases

— Red Hat

Affected Software

12 affected componentsFixes available
redhat/nodejs<18-9020020230717125503.rhel9
18-9020020230717125503.rhel9
redhat/nodejs<1:16.20.1-1.el9_2
1:16.20.1-1.el9_2
redhat/nodejs<1:16.20.2-1.el9_0
1:16.20.2-1.el9_0
IBM Planning Analytics<=2.0
Nodejs Node.js>=16.0.0<16.20.1
Nodejs Node.js>=18.0.0<18.16.1
Nodejs Node.js>=20.0.0<20.3.1
Node.js Node.js>=16.0.0<16.20.1, >=18.0.0<18.16.1, >=20.0.0<20.3.1
16.20.118.16.120.3.1
Node.js Node.js>=16.0.0<16.20.1
16.20.1
Node.js Node.js>=18.0.0<18.16.1
18.16.1
Node.js Node.js>=20.0.0<20.3.1
20.3.1
debian/nodejs
18.19.0+dfsg-6~deb12u118.13.0+dfsg1-1.1

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade redhat/nodejs to a version that resolves this vulnerability.

    Fixed in 18-9020020230717125503.rhel9
  2. Upgrade

    Upgrade redhat/nodejs to a version that resolves this vulnerability.

    Fixed in 1:16.20.1-1.el9_2
  3. Upgrade

    Upgrade redhat/nodejs to a version that resolves this vulnerability.

    Fixed in 1:16.20.2-1.el9_0
  4. Upgrade

    Upgrade to a fixed release to a version that resolves this vulnerability.

    Fixed in 16.20.1Fixed in 18.16.1Fixed in 20.3.1
  5. Upgrade

    Upgrade to a fixed release to a version that resolves this vulnerability.

    Fixed in 16.20.1
  6. Upgrade

    Upgrade to a fixed release to a version that resolves this vulnerability.

    Fixed in 18.16.1
  7. Upgrade

    Upgrade to a fixed release to a version that resolves this vulnerability.

    Fixed in 20.3.1
  8. Upgrade

    Upgrade debian/nodejs to a version that resolves this vulnerability.

    Fixed in 18.19.0+dfsg-6~deb12u1Fixed in 18.13.0+dfsg1-1.1

Event History

Jun 20, 2023
CVE Published
12:00 AM
Data Sourced
12:00 AM
RemedyDescriptionSeverityAffected Software
Data Sourced
via Node.js·02:30 PM
DescriptionSeverityAffected Software
Oct 9, 2023
Data Sourced
via Red Hat·10:26 AM
DescriptionSeverityAffected Software
Nov 22, 2023
CVE Published
via MITRE·11:28 PM
Dec 11, 2023
Updated
08:49 PM
Affected Software
Dec 21, 2023
Data Sourced
via IBM·12:00 AM
DescriptionSeverityAffected Software
Updated
via IBM·12:00 AM
Affected Software
Aug 2, 2024
Data Sourced
via MITRE·02:28 PM
Description
Jun 5, 2025
Data Sourced
via NVD·03:15 PM
DescriptionSeverityWeaknessAffected Software
Updated
via NVD·03:15 PM
SeverityAffected Software
Oct 10, 2025
Updated
via Red Hat·02:31 PM
Severity
Nov 3, 2025
Updated
via NVD·10:16 PM
Affected Software

Frequently Asked Questions

1

What is CVE-2023-30581?

CVE-2023-30581 is a vulnerability that allows the use of __proto__ to bypass the policy mechanism in Node.js.

2

What is the severity of CVE-2023-30581?

The severity of CVE-2023-30581 is high with a score of 7.5.

3

What software is affected by CVE-2023-30581?

Node.js versions 16, 18, and 20 are affected by CVE-2023-30581.

4

How can CVE-2023-30581 be exploited?

CVE-2023-30581 can be exploited by using __proto__ in process.mainModule.__proto__.require() to require modules outside of the policy.json definition.

5

How can I fix CVE-2023-30581?

To fix CVE-2023-30581, it is recommended to update to the latest version of Node.js or apply the appropriate patches provided by the vendor.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203