[CVE-2023-27530] Possible DoS Vulnerability in Multipart MIME parsing

There is a possible DoS vulnerability in the Multipart MIME parsing code in Rack. This vulnerability has been assigned the CVE identifier CVE-2023-27530.

Versions Affected: All. Not affected: None Fixed Versions: 3.0.4.2, 2.2.6.3, 2.1.4.3, 2.0.9.3

Impact

The Multipart MIME parsing code in Rack limits the number of file parts, but does not limit the total number of parts that can be uploaded. Carefully crafted requests can abuse this and cause multipart parsing to take longer than expected.

All users running an affected release should either upgrade or use one of the workarounds immediately.

Releases

The fixed releases are available at the normal locations.

Workarounds

A proxy can be configured to limit the POST body size which will mitigate this issue.

Patches

To aid users who aren’t able to upgrade immediately we have provided patches for the two supported release series. They are in git-am format and consist of a single changeset.

  • 3-0-multipart-dos.patch - Patch for the 3.0 series
  • 2-2-multipart-dos.patch - Patch for the 2.2 series
  • 2-1-multipart-dos.patch - Patch for the 2.1 series
  • 2-0-multipart-dos.patch - Patch for the 2.0 series

Credits

Thanks to @das7pad for reporting this!

2-1-multipart-dos.patch (7.3 KB) 2-2-multipart-dos.patch (7.3 KB) 3-0-multipart-dos.patch (7.8 KB) 2-0-multipart-dos.patch (7.3 KB)

1 Like