Skip to content

Bump puma 6.6.0 -> 7.2.1 past Snyk High advisories#46

Merged
jpr5 merged 1 commit into
masterfrom
fix/puma-snyk-high
Jun 11, 2026
Merged

Bump puma 6.6.0 -> 7.2.1 past Snyk High advisories#46
jpr5 merged 1 commit into
masterfrom
fix/puma-snyk-high

Conversation

@jpr5

@jpr5 jpr5 commented Jun 11, 2026

Copy link
Copy Markdown
Owner

Summary

Bumps puma from 6.6.0 to 7.2.1 to clear two Snyk High advisories that cannot be auto-PR'd. Both are in puma's PROXY protocol v1 parser, only exploitable when the server is configured with set_remote_address proxy_protocol: :v1. We don't enable that, so we aren't directly exploitable — but the bump clears the scan.

Advisories resolved

Advisory CVE GHSA Snyk Severity Fix
User Impersonation via PROXY v1 spoofing on persistent connections CVE-2026-47737 GHSA-2vqw-3mp8-cgmx SNYK-RUBY-PUMA-17220028 High (CVSS 8.7, CWE-290) 7.2.1
Allocation of Resources Without Limits or Throttling — unbounded memory growth via PROXY v1 parser missing CRLF terminator CVE-2026-47736 GHSA-qpgp-93vx-g8v8 SNYK-RUBY-PUMA-17219754 High (CVSS 7.5, CWE-400/770) 7.2.1

Both are also fixed in 8.0.2 on the 8.x line. Pinned to ~> 7.2, >= 7.2.1 to minimize churn; the 8.x bump is deferred.

Version delta (6.6.0 -> 7.2.1)

Notable changes across the range:

  • 6.6.1 (Jul 2025) — rack.after_reply chain error handling, better HttpParserError messages.
  • 7.0.0 (Sep 2025) — major version, multiple breaking changes (see audit below). Fiber-per-request, rack.response_finished, custom logger.
  • 7.0.1 / 7.0.2 / 7.0.3 / 7.0.4 — backward-compat aliases, control CLI fixes, perf, SSL shutdown error handling, header whitespace stripping.
  • 7.1.0 (Oct 2025) — after_worker_shutdown hook, restores faster keepalive inline pipelining.
  • 7.2.0 (Jan 2026) — workers :auto, stats-only control server mode.
  • 7.2.1 (May 2026) — security fixes for the two advisories above.

Puma 7.0 breaking-change audit against this repo

Breaking change Status
Hook rename (e.g. on_worker_boot -> before_worker_boot) n/a — workers 0, no hooks defined
HTTP_VERSION no longer set for Rack > 3.1 not referenced in repo
ruby_engine removed from Runner not referenced
Default bind 0.0.0.0 -> :: (IPv6) we set port / bind explicitly
preload_app! default in clustered mode n/a — single mode (workers 0)
Response headers lowercased downstream of Sinatra/Rack, no app dependency on case
Min Ruby raised to 3.0 repo requires ruby '~> 3.2'

puma.rb config keys still supported: log_requests, workers, threads, raise_exception_on_sigterm, force_shutdown_after, port, bind, stdout_redirect.

Verification

  • bundle exec rspec512 examples, 0 failures (matches post-Fix XSS escaping flagged by Snyk Code #45 baseline)
  • Smoke boot: bundle exec puma -p 4567 -e test -> Puma version: 7.2.1 ("On The Corner"), curl http://localhost:4567/ returns HTTP 200 (49583 bytes)

Scope

Only Gemfile + Gemfile.lock. Adjacent dependabot/Snyk findings (if any) are deferred to follow-ups.

…VE-2026-47736

Both advisories are in puma's PROXY protocol v1 parser. We don't enable
set_remote_address proxy_protocol: :v1, so we aren't directly exploitable,
but the bump clears the Snyk scan.

Fixes:
- User Impersonation via PROXY v1 spoofing on persistent connections
  CVE-2026-47737 / GHSA-2vqw-3mp8-cgmx / SNYK-RUBY-PUMA-17220028
- Allocation of Resources Without Limits or Throttling (memory exhaustion
  via PROXY v1 parser, missing CRLF)
  CVE-2026-47736 / GHSA-qpgp-93vx-g8v8 / SNYK-RUBY-PUMA-17219754

Both fixed in puma 7.2.1 (and 8.0.2 on the 8.x line). Pinned to ~> 7.2,
>= 7.2.1 to take the minimum-churn line; deferred the puma 8.x bump.

Notable puma 7.0 breaking changes audited against this repo:
- on_worker_boot -> before_worker_boot rename: we don't use hooks (workers 0)
- HTTP_VERSION no longer set for Rack > 3.1: not referenced
- ruby_engine removed from Runner: not referenced
- Default bind 0.0.0.0 -> ::: we set port/bind explicitly
- preload_app! default in clustered: workers 0, single mode

Verified: bundle exec rspec -> 512 examples, 0 failures.
Smoke boot under test env returns HTTP 200 on /.
@jpr5 jpr5 merged commit 676ec7e into master Jun 11, 2026
2 checks passed
@jpr5 jpr5 deleted the fix/puma-snyk-high branch June 11, 2026 18:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant