diff options
Diffstat (limited to 'ssl/quic')
-rw-r--r-- | ssl/quic/quic_channel.c | 3 | ||||
-rw-r--r-- | ssl/quic/quic_impl.c | 1 | ||||
-rw-r--r-- | ssl/quic/quic_local.h | 84 | ||||
-rw-r--r-- | ssl/quic/quic_obj.c | 1 | ||||
-rw-r--r-- | ssl/quic/quic_port.c | 1 | ||||
-rw-r--r-- | ssl/quic/quic_tls.c | 1 | ||||
-rw-r--r-- | ssl/quic/quic_trace.c | 3 |
7 files changed, 18 insertions, 76 deletions
diff --git a/ssl/quic/quic_channel.c b/ssl/quic/quic_channel.c index 396cbe8461..7c9fa2f81a 100644 --- a/ssl/quic/quic_channel.c +++ b/ssl/quic/quic_channel.c @@ -9,12 +9,15 @@ #include <openssl/rand.h> #include <openssl/err.h> +#include "internal/ssl_unwrap.h" #include "internal/quic_channel.h" #include "internal/quic_error.h" #include "internal/quic_rx_depack.h" #include "internal/quic_lcidm.h" #include "internal/quic_srtm.h" #include "internal/qlog_event_helpers.h" +#include "internal/quic_txp.h" +#include "internal/quic_tls.h" #include "../ssl_local.h" #include "quic_channel_local.h" #include "quic_port_local.h" diff --git a/ssl/quic/quic_impl.c b/ssl/quic/quic_impl.c index c77230a19f..2043af1e95 100644 --- a/ssl/quic/quic_impl.c +++ b/ssl/quic/quic_impl.c @@ -12,6 +12,7 @@ #include <openssl/sslerr.h> #include <crypto/rand.h> #include "quic_local.h" +#include "internal/ssl_unwrap.h" #include "internal/quic_tls.h" #include "internal/quic_rx_depack.h" #include "internal/quic_error.h" diff --git a/ssl/quic/quic_local.h b/ssl/quic/quic_local.h index cada184482..0fcaf8a142 100644 --- a/ssl/quic/quic_local.h +++ b/ssl/quic/quic_local.h @@ -33,8 +33,8 @@ * state required by the libssl API personality. */ struct quic_xso_st { - /* SSL object common header. */ - struct ssl_st ssl; + /* QUIC_OBJ common header, including SSL object common header. */ + QUIC_OBJ obj; /* The connection this stream is associated with. Always non-NULL. */ QUIC_CONNECTION *conn; @@ -126,13 +126,13 @@ struct quic_xso_st { */ struct quic_conn_st { /* - * ssl_st is a common header for ordinary SSL objects, QUIC connection - * objects and QUIC stream objects, allowing objects of these different - * types to be disambiguated at runtime and providing some common fields. + * QUIC_OBJ is a common header for QUIC APL objects, allowing objects of + * these different types to be disambiguated at runtime and providing some + * common fields. * * Note: This must come first in the QUIC_CONNECTION structure. */ - struct ssl_st ssl; + QUIC_OBJ obj; SSL *tls; @@ -255,8 +255,8 @@ struct quic_conn_st { * layer for QLSO objects, wrapping the QUIC-native QUIC_PORT object. */ struct quic_listener_st { - /* Common header for SSL objects. */ - struct ssl_st ssl; + /* QUIC_OBJ common header, including SSL object common header. */ + QUIC_OBJ obj; }; /* Internal calls to the QUIC CSM which come from various places. */ @@ -276,77 +276,9 @@ void ossl_quic_conn_raise_protocol_error(QUIC_CONNECTION *qc, void ossl_quic_conn_on_remote_conn_close(QUIC_CONNECTION *qc, OSSL_QUIC_FRAME_CONN_CLOSE *f); -int ossl_quic_trace(int write_p, int version, int content_type, - const void *buf, size_t msglen, SSL *ssl, void *arg); - # define OSSL_QUIC_ANY_VERSION 0xFFFFF -# define IS_QUIC_METHOD(m) \ - ((m) == OSSL_QUIC_client_method() || \ - (m) == OSSL_QUIC_client_thread_method()) -# define IS_QUIC_CTX(ctx) IS_QUIC_METHOD((ctx)->method) - -# define QUIC_CONNECTION_FROM_SSL_int(ssl, c) \ - ((ssl) == NULL ? NULL \ - : ((ssl)->type == SSL_TYPE_QUIC_CONNECTION \ - ? (c QUIC_CONNECTION *)(ssl) \ - : NULL)) - -# define QUIC_XSO_FROM_SSL_int(ssl, c) \ - ((ssl) == NULL \ - ? NULL \ - : (((ssl)->type == SSL_TYPE_QUIC_XSO \ - ? (c QUIC_XSO *)(ssl) \ - : ((ssl)->type == SSL_TYPE_QUIC_CONNECTION \ - ? (c QUIC_XSO *)((QUIC_CONNECTION *)(ssl))->default_xso \ - : NULL)))) - -# define SSL_CONNECTION_FROM_QUIC_SSL_int(ssl, c) \ - ((ssl) == NULL ? NULL \ - : ((ssl)->type == SSL_TYPE_QUIC_CONNECTION \ - ? (c SSL_CONNECTION *)((c QUIC_CONNECTION *)(ssl))->tls \ - : NULL)) - -# define QUIC_LISTENER_FROM_SSL_int(ssl, c) \ - ((ssl) == NULL \ - ? NULL \ - : ((ssl)->type == SSL_TYPE_QUIC_LISTENER \ - ? (c QUIC_LISTENER *)(ssl) \ - : NULL)) - -# define IS_QUIC_CS(ssl) ((ssl) != NULL \ - && ((ssl)->type == SSL_TYPE_QUIC_CONNECTION \ - || (ssl)->type == SSL_TYPE_QUIC_XSO)) - -# define IS_QUIC(ssl) \ - ((ssl) != NULL && SSL_TYPE_IS_QUIC((ssl)->type)) -# else -# define QUIC_CONNECTION_FROM_SSL_int(ssl, c) NULL -# define QUIC_XSO_FROM_SSL_int(ssl, c) NULL -# define QUIC_LISTENER_FROM_SSL_int(ssl, c) NULL -# define SSL_CONNECTION_FROM_QUIC_SSL_int(ssl, c) NULL -# define IS_QUIC(ssl) 0 -# define IS_QUIC_CS(ssl) 0 -# define IS_QUIC_CTX(ctx) 0 -# define IS_QUIC_METHOD(m) 0 # endif -# define QUIC_CONNECTION_FROM_SSL(ssl) \ - QUIC_CONNECTION_FROM_SSL_int(ssl, SSL_CONNECTION_NO_CONST) -# define QUIC_CONNECTION_FROM_CONST_SSL(ssl) \ - QUIC_CONNECTION_FROM_SSL_int(ssl, const) -# define QUIC_XSO_FROM_SSL(ssl) \ - QUIC_XSO_FROM_SSL_int(ssl, SSL_CONNECTION_NO_CONST) -# define QUIC_XSO_FROM_CONST_SSL(ssl) \ - QUIC_XSO_FROM_SSL_int(ssl, const) -# define QUIC_LISTENER_FROM_SSL(ssl) \ - QUIC_LISTENER_FROM_SSL_int(ssl, SSL_CONNECTION_NO_CONST) -# define QUIC_LISTENER_FROM_CONST_SSL(ssl) \ - QUIC_LISTENER_FROM_SSL_int(ssl, const) -# define SSL_CONNECTION_FROM_QUIC_SSL(ssl) \ - SSL_CONNECTION_FROM_QUIC_SSL_int(ssl, SSL_CONNECTION_NO_CONST) -# define SSL_CONNECTION_FROM_CONST_QUIC_SSL(ssl) \ - SSL_CONNECTION_FROM_CONST_QUIC_SSL_int(ssl, const) - # define IMPLEMENT_quic_meth_func(version, func_name, q_accept, \ q_connect, enc_data) \ const SSL_METHOD *func_name(void) \ diff --git a/ssl/quic/quic_obj.c b/ssl/quic/quic_obj.c index 63261073d5..2981fd4fe8 100644 --- a/ssl/quic/quic_obj.c +++ b/ssl/quic/quic_obj.c @@ -9,6 +9,7 @@ #include "quic_obj_local.h" #include "quic_local.h" +#include "internal/ssl_unwrap.h" static int obj_update_cache(QUIC_OBJ *obj); diff --git a/ssl/quic/quic_port.c b/ssl/quic/quic_port.c index c8cdc66898..c26164c9c2 100644 --- a/ssl/quic/quic_port.c +++ b/ssl/quic/quic_port.c @@ -11,6 +11,7 @@ #include "internal/quic_channel.h" #include "internal/quic_lcidm.h" #include "internal/quic_srtm.h" +#include "internal/ssl_unwrap.h" #include "quic_port_local.h" #include "quic_channel_local.h" #include "quic_engine_local.h" diff --git a/ssl/quic/quic_tls.c b/ssl/quic/quic_tls.c index bd560c9a91..b2ad28e5d1 100644 --- a/ssl/quic/quic_tls.c +++ b/ssl/quic/quic_tls.c @@ -11,6 +11,7 @@ #include "internal/quic_tls.h" #include "../ssl_local.h" #include "internal/quic_error.h" +#include "internal/ssl_unwrap.h" #define QUIC_TLS_FATAL(rl, ad, err) \ do { \ diff --git a/ssl/quic/quic_trace.c b/ssl/quic/quic_trace.c index 5a6d79bf4b..34f9c001c6 100644 --- a/ssl/quic/quic_trace.c +++ b/ssl/quic/quic_trace.c @@ -9,7 +9,10 @@ #include <openssl/bio.h> #include "../ssl_local.h" +#include "internal/quic_trace.h" #include "internal/quic_wire_pkt.h" +#include "internal/quic_wire.h" +#include "internal/ssl_unwrap.h" static const char *packet_type(int type) { |