Skip to content

body-parser (npm)

Node.js body parsing middleware

Advisories
11
Latest version
2.4.0
Released Oct 22, 2026
License
MIT
OpenSSF Scorecard
7.4 / 10

How to fix

Upgrading to 2.4.0 or later clears every advisory below that has a fix.

Upgrade commands
npm
npm install body-parser@2.4.0
yarn
yarn add body-parser@2.4.0
pnpm
pnpm add body-parser@2.4.0

Known vulnerabilities

AdvisorySeverityAffectedFixed in
GHSA-27r3-jxmh-p828
body-parser vulnerable to Denial of Service via trailing bytes after a compressed request body
High
EPSS 0.39%
>= 2.0.0, < 2.4.0
2.4.0
GHSA-27r3-jxmh-p828
body-parser vulnerable to Denial of Service via trailing bytes after a compressed request body
High
EPSS 0.39%
< 1.20.9
1.20.9
GHSA-27r3-jxmh-p828
body-parser vulnerable to Denial of Service via trailing bytes after a compressed request body
High
EPSS 0.39%
>= 2.0.0, < 2.4.0
2.4.0
GHSA-27r3-jxmh-p828
body-parser vulnerable to Denial of Service via trailing bytes after a compressed request body
High
EPSS 0.39%
< 1.20.9
1.20.9
GHSA-v422-hmwv-36x6
body-parser vulnerable to denial of service when invalid limit value silently disables size enforcement
Medium
EPSS 0.41%
< 1.20.6
1.20.6
GHSA-v422-hmwv-36x6
body-parser vulnerable to denial of service when invalid limit value silently disables size enforcement
Medium
EPSS 0.41%
>= 2.0.0, < 2.3.0
2.3.0
GHSA-v422-hmwv-36x6
body-parser vulnerable to denial of service when invalid limit value silently disables size enforcement
Medium
EPSS 0.41%
< 1.20.6
1.20.6
GHSA-v422-hmwv-36x6
body-parser vulnerable to denial of service when invalid limit value silently disables size enforcement
Medium
EPSS 0.41%
>= 2.0.0, < 2.3.0
2.3.0
GHSA-wqch-xfxh-vrr4
body-parser is vulnerable to denial of service when url encoding is used
Medium
EPSS 0.39%
>= 2.2.0, < 2.2.1
2.2.1
GHSA-wqch-xfxh-vrr4
body-parser is vulnerable to denial of service when url encoding is used
Medium
EPSS 0.39%
>= 2.2.0, < 2.2.1
2.2.1
GHSA-qwcr-r2fm-qrc7
body-parser vulnerable to denial of service when url encoding is enabled
High
EPSS 0.82%
< 1.20.3
1.20.3

Source: git+https://github.com/expressjs/body-parser.git

Is this in your code?

MergeHarbor checks every repository's dependencies against this database, ranks what matters by exploitability and reachability, routes it to the owning team and opens the fix pull request.

Check your repos with MergeHarbor