Vulnerability · Published Sep 26, 2023 · Assigned by GitHub_M

CVE-2023-43646Inefficient Regular Expression Complexity in get-func-name

High 8.6

In plain English

A high-severity uncontrolled resource consumption in get-func-name from chaijs. Proof-of-concept exploit code is public. The chance it is exploited in the next 30 days is estimated at 1.4% (higher than 72% of all known vulnerabilities). Ready-made attack tooling exists: public proof-of-concept code. Fixed versions are available - upgrade the affected package.

Severity (CVSS 3.1)8.6High
Exploit odds (30 days)1.4%top 27.7% of all CVEs
Exploited in the wildNo reportsCISA SSVC: poc
Attack tooling1Public PoC

Official description

get-func-name is a module to retrieve a function's name securely and consistently both in NodeJS and the browser. Versions prior to 2.0.1 are subject to a regular expression denial of service (redos) vulnerability which may lead to a denial of service when parsing malicious input. This vulnerability can be exploited when there is an imbalance in parentheses, which results in excessive backtracking and subsequently increases the CPU load and processing time significantly. This vulnerability can be triggered using the following input: '\t'.repeat(54773) + '\t/function/i'. This issue has been addressed in commit `f934b228b` which has been included in releases from 2.0.1. Users are advised to upgrade. There are no known workarounds for this vulnerability.

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
Debian:12node-get-func-nameno fix listedDEBIAN-CVE-2023-43646
Debian:13node-get-func-name2.0.2-1DEBIAN-CVE-2023-43646
Debian:14node-get-func-name2.0.2-1DEBIAN-CVE-2023-43646
Ubuntu:22.04:LTSnode-get-func-nameno fix listedUBUNTU-CVE-2023-43646
Ubuntu:24.04:LTSnode-get-func-nameno fix listedUBUNTU-CVE-2023-43646
Ubuntu:25.10node-get-func-nameno fix listedUBUNTU-CVE-2023-43646
Ubuntu:26.04:LTSnode-get-func-nameno fix listedUBUNTU-CVE-2023-43646
Ubuntu:26.10node-get-func-nameno fix listedUBUNTU-CVE-2023-43646
Ubuntu:22.04:LTSqt6-webengineno fix listedUBUNTU-CVE-2023-43646
Ubuntu:24.04:LTSqt6-webengineno fix listedUBUNTU-CVE-2023-43646
Ubuntu:25.10qt6-webengineno fix listedUBUNTU-CVE-2023-43646
Ubuntu:26.04:LTSqt6-webengineno fix listedUBUNTU-CVE-2023-43646
Ubuntu:26.10qt6-webengineno fix listedUBUNTU-CVE-2023-43646
npmget-func-name2.0.1GHSA-4q6p-r6v2-jvc5

Affected products (as reported)

VendorProductVersions
chaijs get-func-name < 2.0.1

Weakness: CWE-400, CWE-1333 · Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:N/I:N/A:H

References