# CVE-2020-36632: hughsk flat index.js unflatten prototype pollution

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** MEDIUM 6.3
- **CVSS:** 6.3 (v3.1, CNA) `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:L`
- **CVSS metrics:** Attack vector: Network; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: Low; Integrity impact: Low; Availability impact: Low
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Remote, login needed
- **EPSS:** 1.20% (percentile 68, 2026-11-26)
- **CWE:** CWE-1321
- **Aliases:** GHSA-2j2x-2gpw-g8fm
- **Published:** 2022-12-25T19:37:16.959Z
- **Modified:** 2026-06-17T03:15:51.030Z

## Who should check

- Projects that depend on npm package flat (\< 1.6.2)
- Anyone running hughsk flat 5.0

## Description

A vulnerability, which was classified as critical, was found in hughsk flat up to 5.0.0. This affects the function unflatten of the file index.js. The manipulation leads to improperly controlled modification of object prototype attributes ('prototype pollution'). It is possible to initiate the attack remotely. Upgrading to version 5.0.1 is able to address this issue. The name of the patch is 20ef0ef55dfa028caddaedbcb33efbdb04d18e13. It is recommended to upgrade the affected component. The identifier VDB-216777 was assigned to this vulnerability.

## Affected and fixed versions

- npm `flat`: affected \< 1.6.2; fixed 1.6.2, 2.0.2, 3.0.1, 4.0.2, 5.0.1 (osv)
- hughsk flat: 5.0 (cvelist)

## Mitigation

- Upgrade flat to one of 1.6.2, 2.0.2, 3.0.1, 4.0.2, 5.0.1 (or later in the same release line).

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2020-36632. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2020-36632.md
Affected: flat < 1.6.2
Fixed in: 1.6.2, 2.0.2, 3.0.1, 4.0.2, 5.0.1

Steps:
1. Search this machine and project for flat (npm), hughsk flat: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2020-36632 being exploited?

There is no confirmed exploitation: CVE-2020-36632 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 1.20% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2020-36632?

Medium: CVSS 6.3 (v3.1, scored by CNA). Remote, login needed.

### Which versions are affected by CVE-2020-36632?

flat \< 1.6.2.

### Is there a fix for CVE-2020-36632?

Yes. Fixed in 1.6.2, 2.0.2, 3.0.1, 4.0.2, 5.0.1. Upgrade flat to one of 1.6.2, 2.0.2, 3.0.1, 4.0.2, 5.0.1 (or later in the same release line).

### How do I check if I'm affected by CVE-2020-36632?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- vendor: <https://nvd.nist.gov/vuln/detail/CVE-2020-36632>
- patch: <https://github.com/hughsk/flat/pull/106>
- patch: <https://github.com/hughsk/flat/commit/20ef0ef55dfa028caddaedbcb33efbdb04d18e13>
- patch: <https://github.com/hughsk/flat/releases/tag/5.0.1>
- article: <https://vuldb.com/?id.216777>
- other: <https://vuldb.com/?ctiid.216777>
- other: <https://github.com/hughsk/flat/issues/105>
- other: <https://github.com/hughsk/flat>
- other: <https://github.com/hughsk/flat/compare/3.0.0...3.0.1>
- other: <https://github.com/hughsk/flat/compare/4.1.0...4.1.1>
- other: <https://github.com/hughsk/flat/compare/v1.6.0...1.6.2>
- other: <https://github.com/hughsk/flat/compare/v2.0.1...2.0.2>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2020-36632>
- OSV: CC-BY 4.0 <https://osv.dev/vulnerability/GHSA-2j2x-2gpw-g8fm> (license: <https://creativecommons.org/licenses/by/4.0/>)

HTML: <https://flawdb.com/CVE-2020-36632> · JSON: <https://flawdb.com/api/v1/entries/CVE-2020-36632>
