openssl / openssl/openssl

SSL_do_handshake return value is confusing when 0-RTT is enabled via QUIC TLS API

Open
#27,650 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

branch: 3.5 branch: 3.6 branch: master triaged: bug
Dominant language
C
Stars
30.8k
Forks
11.5k
Avg merge
10m
Merged PRs (30d)
1

Description

version: 3.5

When the server enables 0-RTT by using SSL_set_quic_tls_early_data_enabled, SSL_do_handshake will return 1 before receiving the Client Finished during the initial handshake

Related PR, Some results tested by @pluknet

Library / case SSL_do_handshake SSL_in_init SSL_is_init_finished
OpenSSL 3.5 / initial / CH 1 0 0
OpenSSL 3.5 / initial / CF 1 0 1
OpenSSL 3.5 / 0-RTT / CH -1 1 0
OpenSSL 3.5 / 0-RTT / CF 1 0 1

https://github.com/openssl/openssl/blob/1d3fdab1ecf5062bcecad10ff1497b0bb4501571/ssl/statem/statem_srvr.c#L838-L862

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with ssl/statem/statem_srvr.c at the linked lines and compare the listed OpenSSL 3.5 handshake states for initial and 0-RTT flows. Review the related nginx PR and existing SSL_do_handshake tests, then determine the intended return-value contract and add coverage showing the expected behavior before considering an implementation change.

Written by the indexing model from the issue text.

Assessment

Tech stack
c
Domain
cryptography, networking, security
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.