caddy icon indicating copy to clipboard operation
caddy copied to clipboard

server protocol h3 h2 leads to ssl errors

Open N4CH723HR3R opened this issue 11 months ago • 2 comments

Issue Details

when setting

      servers {
        protocols h3 h2
      }

i get ssl errors on all browsers and in openssl itself

user@host$ openssl s_client server:443

Connecting to $IP
CONNECTED(00000003)
4057F98EA87F0000:error:0A000126:SSL routines::unexpected eof while reading:ssl/record/rec_layer_s3.c:696:
---
no peer certificate available
---
No client certificate CA names sent
Negotiated TLS1.3 group: <NULL>
---
SSL handshake has read 0 bytes and written 1547 bytes
Verification: OK
---
New, (NONE), Cipher is (NONE)
Protocol: TLSv1.3
This TLS version forbids renegotiation.
Compression: NONE
Expansion: NONE
No ALPN negotiated
Early data was not sent
Verify return code: 0 (ok)
---
4057F98EA87F0000:error:0A000197:SSL routines:SSL_shutdown:shutdown while in init:ssl/ssl_lib.c:2834:

Assistance Disclosure

AI not used

If AI was used, describe the extent to which it was used.

No response

N4CH723HR3R avatar Dec 19 '25 07:12 N4CH723HR3R

The openssl s_client output here is not enough on its own to show a bug.

If you configure only h3 h2, then h1 is disabled so a client that does not negotiate ALPN has no usable protocol over TCP. In the output above, the important line is:

No ALPN negotiated

So the first thing to check is whether this still reproduces when ALPN is explicitly requested, for example with openssl s_client -alpn h2 -connect server:443.

If browsers are still failing as well, then we need a minimal full repro:

  • the exact Caddyfile
  • exact browser error text
  • Caddy debug logs
  • whether it still fails with only h2 enabled and h3 removed

At the moment this looks like it may just be the expected consequence of disabling h1 but the browser part needs more detail to tell whether there is a real bug beyond that.

steadytao avatar Apr 14 '26 19:04 steadytao

I'll close this for now as there's not enough detail, but we can reopen if more info is provided.

francislavoie avatar Apr 14 '26 20:04 francislavoie