Neil Horman
f42036822e
removing debug code from quic_impl
...
I had experimented with starting the ssl handshake during accept, and
forgot to remove it
Reviewed-by: Tomas Mraz <tomas@openssl.org>
Reviewed-by: Saša Nedvědický <sashan@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/26178 )
2025-02-17 11:27:33 -05:00
Neil Horman
d1c3bb2f74
Add tracking of receive credit for unvalidated connections
...
Reviewed-by: Tomas Mraz <tomas@openssl.org>
Reviewed-by: Saša Nedvědický <sashan@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/26178 )
2025-02-17 11:27:33 -05:00
Neil Horman
60762be09b
Add a public flag to disable address validation on listeners
...
Now that we have the infrastructure to skip address validation, add a
public flag to SSL_new_listener and SSL_new_listener_from to allow the
skipping of address validation on selected quic listener SSL objects
Reviewed-by: Saša Nedvědický <sashan@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/26114 )
2025-02-17 11:27:33 -05:00
sashan
41fe7a2b8e
SSL_inject_net_dgram() should return result of ossl_quic_demux_inject()
...
This got introduced by #595288251bb (QUIC APL: Ensure APL
functions use correct prologue)
Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/25659 )
2025-02-17 11:27:33 -05:00
Tomas Mraz
5031f1b196
Add quic_lock() calls for functions called from poll_translate_ssl_quic()
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Saša Nedvědický <sashan@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/25416 )
2025-02-17 11:27:33 -05:00
Hugo Landau
f2fff144d7
QUIC POLLING: Add support for polling listeners
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Saša Nedvědický <sashan@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/25416 )
2025-02-17 11:27:33 -05:00
Hugo Landau
643d149696
QUIC APL: Add support for registering blocking operations to support polling code
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Saša Nedvědický <sashan@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/25416 )
2025-02-17 11:27:33 -05:00
Matt Caswell
76af88a621
Use the reactor from ctx.obj for net read/write desired implementations
...
The ossl_quic_get_net_write_desired() and
ossl_quic_reactor_net_read_desired() implementations can be used by
listeners. But in that case there is no ctx.qc object present. Instead we
should use the reactor from ctx.obj which will work also for a listener.
Reviewed-by: Tomas Mraz <tomas@openssl.org>
Reviewed-by: Saša Nedvědický <sashan@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/25642 )
2025-02-17 11:27:33 -05:00
Matt Caswell
4af6bcd69c
Always tick the QUIC_ENGINE regardless of the state of a connection
...
Just because one connection has not started yet, it does not mean that
we should not tick the QUIC_ENGINE. There may be other connections that do
need ticking.
Reviewed-by: Saša Nedvědický <sashan@openssl.org>
Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/25452 )
2025-02-17 11:27:33 -05:00
Matt Caswell
3a75cf8d9c
Remove an obsolete comment
...
The comment is no longer accurance so it can be removed
Reviewed-by: Tomas Mraz <tomas@openssl.org>
Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/25457 )
2025-02-17 11:27:33 -05:00
Matt Caswell
ac69d0649a
Simplify the QUIC time override handling
...
Centralise the storage of the override in the QUIC_ENGINE rather than in
the QUIC_CONNECTION. We can now set the override on any type of QUIC SSL
object as needed.
Reviewed-by: Tomas Mraz <tomas@openssl.org>
Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/25457 )
2025-02-17 11:27:32 -05:00
Viktor Dukhovni
f23da50318
Handle a couple of NULL QUIC ctx.qc values
...
Now that we also QUIC server (listener) handles, we may have a NULL quic
connection (ctx.qc), and so need to either return early or handle the
NULL `qc` gracefully.
Reviewed-by: Sasa Nedvedicky <sashan@openssl.org>
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/25432 )
2025-02-17 11:27:32 -05:00
Alexandr Nedvedicky
73d7de128b
QUIC Concurrency API: Various minor fixes
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Neil Horman <nhorman@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24971 )
2025-02-17 11:27:32 -05:00
Hugo Landau
b93fb2d177
Assorted bugfixes
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Neil Horman <nhorman@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24971 )
2025-02-17 11:27:32 -05:00
Hugo Landau
2c9953bbd3
Minor fixes
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Neil Horman <nhorman@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24971 )
2025-02-17 11:27:32 -05:00
Hugo Landau
db590923c1
QUIC APL: Refine domain flag handling
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Neil Horman <nhorman@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24971 )
2025-02-17 11:27:32 -05:00
Hugo Landau
fa4a8e8871
QUIC REACTOR: Allow ticks to schedule notifications of other threads
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Neil Horman <nhorman@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24971 )
2025-02-17 11:27:32 -05:00
Hugo Landau
ae26f1eed6
QUIC APL: Default domain flags
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Neil Horman <nhorman@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24971 )
2025-02-17 11:27:32 -05:00
Hugo Landau
5a6898db3a
QUIC APL: Use domain flag to determine thread assisted mode
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Neil Horman <nhorman@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24971 )
2025-02-17 11:27:32 -05:00
Hugo Landau
50c7796267
QUIC APL: Add support for configuring domain flags
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Neil Horman <nhorman@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24971 )
2025-02-17 11:27:32 -05:00
Hugo Landau
f75b3d1db6
QUIC APL: Add QUIC Domain SSL Object: Implementation
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Neil Horman <nhorman@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24971 )
2025-02-17 11:27:32 -05:00
Hugo Landau
e6f062601b
Minor updates
...
Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24037 )
2025-02-17 11:27:32 -05:00
Hugo Landau
8b4b5048ee
Minor fixes and hardening
...
Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24037 )
2025-02-17 11:27:32 -05:00
Hugo Landau
e88f03f193
QUIC APL: Make QCTX comments clearer
...
Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24037 )
2025-02-17 11:27:32 -05:00
Hugo Landau
a55d8b8b71
QUIC APL: Connection acceptance is an I/O operation
...
Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24037 )
2025-02-17 11:27:32 -05:00
Hugo Landau
87d474660c
QUIC APL: Support SSL_inject_net_dgram for listeners
...
Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24037 )
2025-02-17 11:27:32 -05:00
Hugo Landau
2176e0467e
QUIC APL: When creating a default XSO, no further streams can arrive after connection terminastion
...
Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24037 )
2025-02-17 11:27:32 -05:00
Hugo Landau
05e0eae202
QUIC APL: Ensure incoming stream data can be drained after connection closure
...
Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24037 )
2025-02-17 11:27:32 -05:00
Hugo Landau
8a6bb6b639
QUIC APL: Revise SSL_pending and SSL_has_pending handling for s_client compat
...
Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24037 )
2025-02-17 11:27:32 -05:00
Hugo Landau
f1ade90a66
QUIC PORT: Ensure reactor waits for listening port correctly
...
Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24037 )
2025-02-17 11:27:32 -05:00
Hugo Landau
1e73a3ca9f
QUIC APL: Support blocking connection acceptance
...
Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24037 )
2025-02-17 11:27:32 -05:00
Hugo Landau
60c9ce78f5
QUIC APL: Unify event handling mode into QUIC_OBJ
...
Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24037 )
2025-02-17 11:27:32 -05:00
Hugo Landau
fdc13a9e4e
QUIC APL: Unify blocking mode handling for all object types
...
Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24037 )
2025-02-17 11:27:32 -05:00
Hugo Landau
38df4b1976
QUIC APL: Ensure APL functions use correct prologue
...
Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24037 )
2025-02-17 11:27:32 -05:00
Hugo Landau
67d43a7af5
QUIC APL: Make prologue function names more descriptive
...
Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24037 )
2025-02-17 11:27:32 -05:00
Hugo Landau
8110737e42
QUIC APL: Refactor API call prologue code
...
Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/24037 )
2025-02-17 11:27:32 -05:00
Hugo Landau
458018f3e6
Minor fix
...
Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/23995 )
2025-02-17 11:27:32 -05:00
Hugo Landau
bf8ce68c33
QUIC APL: Fix default stream creation on server side
...
Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/23995 )
2025-02-17 11:27:32 -05:00
Hugo Landau
2399678797
QUIC APL: Revise SSL_pending and SSL_has_pending handling for s_client compat
...
Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/23995 )
2025-02-17 11:27:32 -05:00
Hugo Landau
68537fceae
QUIC APL: Avoid having a mutex variable where not needed
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Neil Horman <nhorman@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/23334 )
2025-02-17 11:27:32 -05:00
Hugo Landau
477ff82236
Post-rebase fixes
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Neil Horman <nhorman@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/23334 )
2025-02-17 11:27:32 -05:00
Hugo Landau
c69ce7fcf1
QUIC APL: Fix bug around default XSO handling on server side
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Neil Horman <nhorman@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/23334 )
2025-02-17 11:27:32 -05:00
Hugo Landau
f4cfa1b9cc
QUIC APL: Fix refcounting for listeners
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Neil Horman <nhorman@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/23334 )
2025-02-17 11:27:32 -05:00
Hugo Landau
99e4a1e3ce
QUIC PORT: Allow QUIC_PORT to throw away incoming connections
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Neil Horman <nhorman@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/23334 )
2025-02-17 11:27:32 -05:00
Hugo Landau
88804f3181
QUIC APL: Fix server API bugs discovered during test
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Neil Horman <nhorman@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/23334 )
2025-02-17 11:27:32 -05:00
Hugo Landau
e3ba554d73
QUIC APL: Implement SSL_get0_listener
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Neil Horman <nhorman@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/23334 )
2025-02-17 11:27:32 -05:00
Hugo Landau
2e582648c5
QUIC APL: Free listeners correctly
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Neil Horman <nhorman@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/23334 )
2025-02-17 11:27:32 -05:00
Hugo Landau
882c77e93e
QUIC APL: Fix QUIC_TLS free order
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Neil Horman <nhorman@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/23334 )
2025-02-17 11:27:32 -05:00
Hugo Landau
d2ee7ceff0
Minor fix to BIO refcount handling
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Neil Horman <nhorman@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/23334 )
2025-02-17 11:27:32 -05:00
Hugo Landau
d1e81ca94c
Minor fixes
...
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Neil Horman <nhorman@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/23334 )
2025-02-17 11:27:32 -05:00