GHSA-5r27-rw8r-7967 · Severity: high · Ecosystem: npm — import-in-the-middle has unsanitized user controlled input in module generation
import-in-the-middle is a module loading interceptor specifically for ESM modules. The import-in-the-middle loader works by generating a wrapper module on the fly. The wrapper uses the module specifier to load the original module and add some wrapping code. Prior to version 1.4.2, it allows for remote code execution in cases where an application passes user-supplied input directly to the `import()` function. This vulnerability has been patched in import-in-the-middle version 1.4.2. Some workarounds are available. Do not pass any user-supplied input to `import()`. Instead, verify it against a set of allowed values. If using import-in-the-middle, directly or indirectly, and support for EcmaScript Modules is not needed, ensure that no options are set, either via command-line or the `NODE_OPTIONS` environment variable, that would enable loader hooks.
Conclusion & alert: CVE-2023-38704 is rated Moderate Risk (58.5/100): CVSS High severity, with medium exploitation likelihood (EPSS 0.80%). Mandatory action: Review affected assets and schedule remediation.
Risk is dynamic; we continuously reassess and refresh what is shown on this page as upstream context changes.
EPSS lead: Daily EPSS estimates relative likelihood of exploitation; percentile ranks this CVE among scored vulnerabilities (higher = more severe relative rank).
| # | Date | Old EPSS score | New EPSS score | Delta (New - Old) |
|---|---|---|---|---|
| 1 | 2026-06-03 | 0.75% | 0.80% | +0.05% |
| 2 | 2026-05-02 | 0.56% | 0.75% | +0.19% |
| 3 | 2025-11-21 | — | 0.56% | — |
Full EPSS history (16 records total)
CVSS metrics for this CVE.
| Base score | Version | Severity | Vector | Exploitability | Impact | Score source |
|---|---|---|---|---|---|---|
| 8.1 | 3.1 | HIGH |
|
2.2 | 5.3 | [email protected] |
| 9.8 | 3.1 | CRITICAL |
|
3.9 | 5.9 | [email protected] |
GHSA-5r27-rw8r-7967 · Severity: high · Ecosystem: npm — import-in-the-middle has unsanitized user controlled input in module generation
| Vendor | Product | Version | Raw CPE |
|---|---|---|---|
| datadoghq | import-in-the-middle | < 1.4.2 | cpe:2.3:a:datadoghq:import-in-the-middle:*:*:*:*:*:node.js:*:* |
| URL | Tags |
|---|---|
| https://github.com/DataDog/import-in-the-middle/commit/2531cdd9d1d73f9eaa87c16967f60cb276c1971b | Patch |
| https://github.com/DataDog/import-in-the-middle/security/advisories/GHSA-5r27-rw8r-7967 | Mitigation Third Party Advisory |