Lucene search

K
githubGitHub Advisory DatabaseGHSA-V2V2-HPH8-Q5XP
HistoryJan 08, 2024 - 3:22 p.m.

@fastify/reply-from JSON Content-Type parsing confusion

2024-01-0815:22:40
CWE-444
GitHub Advisory Database
github.com
6
fastify
content-type parsing
security bypass
reverse proxy
@fastify/reply-from
vulnerability detection

CVSS3

7.5

Attack Vector

NETWORK

Attack Complexity

LOW

Privileges Required

NONE

User Interaction

NONE

Scope

UNCHANGED

Confidentiality Impact

NONE

Integrity Impact

HIGH

Availability Impact

NONE

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N

AI Score

7.1

Confidence

Low

EPSS

0.001

Percentile

17.8%

Impact

The main repo of fastify use fast-content-type-parse to parse request Content-Type, which will trim after split.

The fastify-reply-from have not use this repo to unify the parse of Content-Type, which won’t trim.

As a result, a reverse proxy server built with @fastify/reply-from could misinterpret the incoming body by passing an header ContentType: application/json ; charset=utf-8. This can lead to bypass of security checks.

Patches

@fastify/reply-from v9.6.0 include the fix.

Workarounds

There are no known workarounds.

References

Hackerone Report: https://hackerone.com/reports/2295770.

Affected configurations

Vulners
Node
fastifyreply-fromRange<9.6.0
VendorProductVersionCPE
fastifyreply-from*cpe:2.3:a:fastify:reply-from:*:*:*:*:*:*:*:*

CVSS3

7.5

Attack Vector

NETWORK

Attack Complexity

LOW

Privileges Required

NONE

User Interaction

NONE

Scope

UNCHANGED

Confidentiality Impact

NONE

Integrity Impact

HIGH

Availability Impact

NONE

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N

AI Score

7.1

Confidence

Low

EPSS

0.001

Percentile

17.8%

Related for GHSA-V2V2-HPH8-Q5XP