Subscribe free
Morning Merge Security · Friday, December 4, 20264 min read

Rack multipart DoS hits Rails; Mongoose leaks hidden fields

Also: DOMPurify template bypass, Laravel validation, Tailscale and Cloudflare go PQ

Today is mostly a lockfile check: Rack, Mongoose, DOMPurify and Laravel all have patched versions for bugs that attacker-supplied input can reach. Start with Rack, then Mongoose.

The main thing

A green magnifying lens shows a parcel covered in hundreds of tags on a sorting rack, beside a long row of library shelves with a rolling ladder.

Rack's multipart parser searches the load path for every unknown charset (CVE-2026-142592, rated high). Any app that parses multipart bodies through Rack::Request#POST or #params is exposed in its default configuration, no login needed.

In a default Rails app, a POST to any path works, even one with no route, because Rack::MethodOverride parses the body before routing.

The weird part is where the time goes. For every charset parameter on a part, Rack calls Encoding.find. If Ruby doesn't know the name, it tries to load an encoding library by that name, which means searching every directory on $LOAD_PATH before it gives up.

Rack catches the error and falls back to binary. It doesn't remember the miss, and it doesn't cap how many charset parameters a part can carry. So each ;charset=x costs 10 bytes to send and a full load-path search to parse.

Per the advisory, one part with 4000 unknown charsets (64 KB) takes about 1.7 s to parse in a mid-sized Bundler app. A 1 MB request with 16 such parts takes 27–40 s, and four concurrent 1 MB requests through Puma delayed an unrelated health check by over 10 s.

The cost grows with the number of gems in your bundle, so the bigger the app, the cheaper it is to stall. The existing part limit doesn't help: it counts parts, not parameters.

What to do: Rack 3.0, 3.1 and 3.2 are affected. Upgrade to 3.1.24 or 3.2.9, which only call Encoding.find for names in Encoding.name_list. Rack 2.2 isn't affected by the denial of service.

If you can't deploy today, limit multipart request size at your reverse proxy, which the advisory lists as a mitigation alongside the upgrade.

Patch check

A green magnifying lens shows a filing cabinet drawer sliding open with a folder inside.

Mongoose's sanitizeProjection can be talked out of hiding fields (CVE-2026-142596, rated high). Since 8.5.0, sanitizeProjection is supposed to stop an untrusted projection from returning select: false fields like password hashes and reset tokens. Projections such as '-name +password' got around it, and { name: { $concat: ['$password'] } } returns the hash under another field's name.

Nested exclusions, $elemMatch and discriminator filters also leak on queries that don't use the option at all. Fixed in 8.24.10 and 9.12.2. If any endpoint lets a client choose fields, do this one first.

DOMPurify's SAFE_FOR_TEMPLATES is undone by a nested form (CVE-2026-144292, rated high). With SAFE_FOR_TEMPLATES: true, DOMPurify 3.4.18 returns markup with no {{ in it that becomes a live {{…}} expression once it's assigned to innerHTML. A nested <form> splits the braces into separate text nodes, and the browser's second parse drops the inner form tag and joins them.

The reporter got code execution through Vue 3 in-DOM templates and AngularJS 1.8.3. Upgrade to 3.5.0. It only bites if a template engine compiles the sanitized output, which is the setup this option exists for.

Laravel's numeric validation can exhaust memory (CVE-2026-142610, rated high). multiple_of, plus gt, gte, lt and lte when they compare against another numeric field, expand input with arbitrary-precision math and no exponent bound. A number in scientific notation with an extreme exponent burns CPU and memory. Fixed in laravel/framework 12.74.0 and 13.44.1. Until you deploy, bound the field and bail first: bail|numeric|min:0|max:100|multiple_of:2.

Two more worth a lookup:

Post-quantum gets dates

A newly cut green key sits under a magnifying lens on a key-cutting machine, with a ring of older keys hanging on a pegboard behind it.

Government post-quantum guidance is turning into roadmaps. Only one item here changes what you run today.

Tailscale v1.106 adds a hybrid post-quantum handshake. When both devices run 1.106 or later, the tunnel adds an ephemeral ML-KEM-768 key agreement to the standard WireGuard handshake, so an attacker recording traffic would have to break both. If either side is older, it falls back to plain WireGuard. That fallback is the catch: you're only covered between updated pairs, so roll the client out everywhere.

Cloudflare says it will be fully post-quantum in 2027, pulled forward from 2029. It cites its own risk analysis and the joint NSA, CISA and Office of the National Cyber Director statement. Cloudflare says 73% of browser-generated connections to it are already post-quantum encrypted.

Mozilla is accelerating its transition and says it understands there has been "a substantial advance in classical cryptanalysis of at least one widely deployed public-key cryptosystem." Classical, as in no quantum computer required. Mozilla's working assumption is an "immediate but narrow threat" to high-value targets. It says 52% of Firefox-initiated TLS handshakes are already post-quantum protected.

Latacora's updated right answers are the checklist to forward. Know where TLS terminates, enable the X25519MLKEM768 group for TLS 1.3 and verify a client negotiates it, and check what your CDN negotiates with your origin, not only with browsers. For signatures, start with the verifiers that are hardest to update: firmware, software updates and private certificate authorities.

Bump Rack and Mongoose today, then spend an hour finding out where your TLS actually terminates.

← All Morning Merge Security issues

Get this in your inbox every morning.

Free. Five minutes. Unsubscribe in one click.

Subscribe free →