HAProxy returns HTTP/2 GOAWAY to clients after enabling an ACL using ssl_fc variables
Environment
HAProxy 2.4 fronting web services with HTTP/2 on the frontend and HTTP/1.1 backends. A recent config added a tcp-request content ACL that references ssl_fc_sni and ssl_fc_protocol to route traffic based on TLS attributes. Issue reproduces when many concurrent HTTP/2 streams are opened from browsers.
Symptoms
Browsers report broken HTTP/2 streams and intermittent 502/GOAWAY frames. HAProxy logs show abrupt connection termination with 'server sent GOAWAY' events. Short single-stream requests often succeed; long-lived or multiplexed streams fail more frequently.
Observations
Config uses tcp-request content rules with ssl_fc_* variables on an h2-enabled frontend. tcp-request content runs in TCP mode and may trigger early connection handling before HTTP/2 layer initialization. When ACLs reference SSL vars too early, HAProxy resets or re-negotiates, causing GOAWAY. Disabling the ACL stops GOAWAYs. No backend errors; problem localized to frontend behavior.
Already attempted
Moved the ACL into http-request rules on a separate frontend (requires terminating TLS earlier) — partially mitigated but broke TLS passthrough cases. Upgrading to HAProxy 2.6 not currently possible due to distro constraints.
Question
How to evaluate and fix the GOAWAYs while keeping SNI-based routing policy that sometimes needs tcp-level checks? Are there safe config changes in 2.4 to avoid breaking HTTP/2 multiplexing?
Verified community troubleshooting
The quickest safe test is to remove the tcp-request content ACL referencing ssl_fc_* — if GOAWAYs stop, the ACL is the culprit. Fix by moving SNI/TLS checks into the HTTP layer (http-request or use_backend with { req.ssl_sni }) on a TLS-terminating frontend, or perform SNI routing at bind-time so you don't alter a connection mid-handshake. For passthrough needs, avoid tcp-request content that touches ssl_fc_* while using HTTP/2. Verify by running an h2 load test and watch if GOAWAYs disappear. Roll back the config if client regressions occur.
Incident analysis
Most likely causes
Summary
Suggested Fixes
Continue troubleshooting
Related troubles
Matched from the title, description and tags
- Cloud Computing22% match
Kubernetes Ingress returns 404 only for external gRPC clients behind cloud load balancer
Open0 answers - Cloud Computing22% match
ALB returns 502 for gRPC over HTTP/2 after enabling TLS policy to TLS1.3-only
Open0 answers - Networking21% match
Linux source‑based routing causes intermittent IPv6 HTTPS failures for routed clients
Solved1 answer - Networking21% match
Dual‑WAN Edge Router Sends HTTPS Traffic Out Slower Link Despite Healthy Primary — Large TCP Transfers Stall
Open0 answers