openssl/ssl
Neil Horman c8127df04c Detect fin state of a QUIC stream for streams which are completely read
SSL_poll indicates that a stream which has had the fin bit set on it,
should generate SSL_POLL_EVENT_R events, so that applications can detect
stream completion via SSL_read_ex and SSL_get_error returning
SSL_ERROR_ZERO_RETURN.

However, the quic polling code misses on this, as a client that
completely reads a buffer after receipt has its underlying stream buffer
freed, loosing the fin status

We can however detect stream completion still, as a stream which has
been finalized, and had all its data read will be in the
QUIC_RSTREAM_STATE_DATA_READ state, iff the fin bit was set.

Fix it by checking in test_poll_event_r for that state, and generating a
SSL_POLL_EVENT_R if its found to be true, so as to stay in line with the
docs.

Fixes openssl/private#627

Reviewed-by: Tomas Mraz <tomas@openssl.org>
Reviewed-by: Sasa Nedvedicky <sashan@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/25399)
2024-09-13 15:05:29 -04:00
..
quic Detect fin state of a QUIC stream for streams which are completely read 2024-09-13 15:05:29 -04:00
record ssl: rework "e_os.h" inclusions 2024-09-05 17:02:51 +02:00
rio QUIC POLLING: Support no-quic builds 2024-02-10 11:37:14 +00:00
statem ssl: rework "e_os.h" inclusions 2024-09-05 17:02:51 +02:00
bio_ssl.c bio_ssl.c: Do not call SSL_shutdown if not inited 2024-06-25 16:06:17 +02:00
build.info Remove the event queue code 2024-08-07 19:48:26 +02:00
d1_lib.c ssl: rework "e_os.h" inclusions 2024-09-05 17:02:51 +02:00
d1_msg.c Copyright year updates 2023-09-07 09:59:15 +01:00
d1_srtp.c Copyright year updates 2024-04-09 13:43:26 +02:00
methods.c
pqueue.c
priority_queue.c Copyright year updates 2024-09-05 09:35:49 +02:00
s3_enc.c EVP_MD_size() updates 2024-08-29 10:29:53 +02:00
s3_lib.c ssl: rework "e_os.h" inclusions 2024-09-05 17:02:51 +02:00
s3_msg.c
ssl_asn1.c
ssl_cert_comp.c Copyright year updates 2024-09-05 09:35:49 +02:00
ssl_cert_table.h Make ssl_cert_info read-only 2023-11-27 07:51:33 +00:00
ssl_cert.c ssl: rework "e_os.h" inclusions 2024-09-05 17:02:51 +02:00
ssl_ciph.c EVP_MD_size() updates 2024-08-29 10:29:53 +02:00
ssl_conf.c ssl: rework "e_os.h" inclusions 2024-09-05 17:02:51 +02:00
ssl_err_legacy.c
ssl_err.c Check that a supported_versions extension is present in an HRR 2024-08-07 19:34:23 +02:00
ssl_init.c Copyright year updates 2024-09-05 09:35:49 +02:00
ssl_lib.c Cleanup of unused functions and macros in ssl_local.h 2024-09-10 20:43:16 +02:00
ssl_local.h Cleanup of unused functions and macros in ssl_local.h 2024-09-10 20:43:16 +02:00
ssl_mcnf.c Copyright year updates 2024-09-05 09:35:49 +02:00
ssl_rsa_legacy.c
ssl_rsa.c Copyright year updates 2023-09-07 09:59:15 +01:00
ssl_sess.c Incorporate review feedback 2024-06-21 07:57:56 -04:00
ssl_stat.c Copyright year updates 2024-09-05 09:35:49 +02:00
ssl_txt.c Copyright year updates 2024-09-05 09:35:49 +02:00
ssl_utst.c
sslerr.h QUIC APL: Implement optimised FIN API 2024-01-23 14:20:06 +00:00
t1_enc.c Copyright year updates 2024-04-09 13:43:26 +02:00
t1_lib.c adds TLS signature algorithms list feature 2024-08-13 11:48:54 +10:00
t1_trce.c IANA has assigned numbers for new TLS Supported Groups in ML-KEM 2024-09-13 14:09:34 +02:00
tls13_enc.c Copyright year updates 2024-09-05 09:35:49 +02:00
tls_depr.c
tls_srp.c