CVE-2020-15168
JSON

2.6low

File size limit bypass in node-fetch

Severity
2.6low CVSS:3.1 by GitHub_M
Exploit likelihood
1.69% (higher than 77% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
GitHub_M
Also known as
GHSA-w7rc-rwvf-8q5r

Description

node-fetch before versions 2.6.1 and 3.0.0-beta.9 did not honor the size option after following a redirect, which means that when a content size was over the limit, a FetchError would never get thrown and the process would end without failure. For most people, this fix will have a little or no impact. However, if you are relying on node-fetch to gate files above a size, the impact could be significant, for example: If you don't double-check the size of the data after fetch() has completed, your JS thread could get tied up doing work on a large file (DoS) and/or cost you money in computing.

Affected

Product or packageVersionsReported by
node-fetch node-fetch<2.6.1, >3.0.0-beta.1, <3.0.0-beta.9CVE List
node-fetch (npm)from 2.0.0 before 2.6.1, from 3.0.0-beta.1 before 3.0.0-beta.9GitHub Advisory Database
node-fetch_project node-fetchbefore 2.6.1, 3.0.0NVD

All scores

GitHub_M2.6low CVSS:3.1CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:U/C:N/I:N/A:L
GitHub2.6low CVSS:3.1CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:U/C:N/I:N/A:L
NVD5.3medium CVSS:3.1CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L
NVD5.0medium CVSS:2.0AV:N/AC:L/Au:N/C:N/I:N/A:P

Classification

What each source says

CVE List

node-fetch before versions 2.6.1 and 3.0.0-beta.9 did not honor the size option after following a redirect, which means that when a content size was over the limit, a FetchError would never get thrown and the process would end without failure. For most people, this fix will have a little or no impact. However, if you are relying on node-fetch to gate files above a size, the impact could be significant, for example: If you don't double-check the size of the data after fetch() has completed, your JS thread could get tied up doing work on a large file (DoS) and/or cost you money in computing.

GitHub Advisory Database
Impact

Node Fetch did not honor the size option after following a redirect, which means that when a content size was over the limit, a FetchError would never get thrown and the process would end without failure.

For most people, this fix will have a little or no impact. However, if you are relying on node-fetch to gate files above a size, the impact could be significant, for example: If you don't double-check the size of the data after fetch() has completed, your JS thread could get tied up doing work on a large file (DoS) and/or cost you money in computing.

Patches

We released patched versions for both stable and beta channels:

  • For v2: 2.6.1
  • For v3: 3.0.0-beta.9
Workarounds

None, it is strongly recommended to update as soon as possible.

For more information

If you have any questions or comments about this advisory:

  • Open an issue in node-fetch
  • Contact one of the core maintainers.
NVD (es)

node-fetch versiones anteriores a 2.6.1 y a 3.0.0-beta.9 no respetaba la opción de tamaño después de seguir un redireccionamiento, lo que significa que cuando un tamaño de contenido superaba el límite, una FetchError nunca se iniciaba y el proceso terminaba sin fallos.&#xa0;Para la mayoría de las personas, esta solución tendrá un impacto mínimo o nulo.&#xa0;Sin embargo, si confía en node-fetch para bloquear archivos por encima de un tamaño, el impacto podría ser significativo, por ejemplo: si no verifica dos veces el tamaño de los datos después de que se haya completado la función fetch(), su hilo o subproceso JS podría atarse haciendo que en un archivo grande (DoS) y/o le cueste dinero en informática

References

Sources

SourceRecordLicence
CVE ListCVE-2020-15168 changed 2024-08-04CVE Terms of Use
GitHub Advisory DatabaseGHSA-w7rc-rwvf-8q5r changed 2026-07-08CC-BY-4.0
NVDCVE-2020-15168 changed 2026-06-17Public domain