quic: update to quicly version 0.1.5
Type: improvement Change-Id: I7c9c91a9c4d3ac2499e42eedda0a5d395bdf5912 Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
This commit is contained in:

committed by
Florin Coras

parent
56265b9f55
commit
a2bc88bb69
@ -18,7 +18,7 @@ if(NOT OPENSSL_FOUND)
|
||||
endif()
|
||||
|
||||
unset(QUIC_LINK_LIBRARIES)
|
||||
set(EXPECTED_QUICLY_VERSION "0.1.4-vpp")
|
||||
set(EXPECTED_QUICLY_VERSION "0.1.5-vpp")
|
||||
|
||||
vpp_find_path(QUICLY_INCLUDE_DIR NAMES quicly.h)
|
||||
vpp_find_path(PICOTLS_INCLUDE_DIR NAMES picotls.h)
|
||||
|
@ -250,7 +250,6 @@ quic_init_crypto_context (crypto_context_t * crctx, quic_ctx_t * ctx)
|
||||
ptls_ctx->cipher_suites = qm->quic_ciphers[ctx->crypto_engine];
|
||||
ptls_ctx->certificates.list = NULL;
|
||||
ptls_ctx->certificates.count = 0;
|
||||
ptls_ctx->esni = NULL;
|
||||
ptls_ctx->on_client_hello = NULL;
|
||||
ptls_ctx->emit_certificate = NULL;
|
||||
ptls_ctx->sign_certificate = NULL;
|
||||
@ -718,7 +717,6 @@ quic_send_packets (quic_ctx_t * ctx)
|
||||
session_t *udp_session;
|
||||
quicly_conn_t *conn;
|
||||
size_t num_packets, i, max_packets;
|
||||
quicly_address_t dest, src;
|
||||
u32 n_sent = 0;
|
||||
int err = 0;
|
||||
|
||||
@ -744,17 +742,16 @@ quic_send_packets (quic_ctx_t * ctx)
|
||||
break;
|
||||
|
||||
num_packets = max_packets;
|
||||
if ((err = quicly_send (conn, &dest, &src, packets, &num_packets, buf,
|
||||
sizeof (buf))))
|
||||
if ((err = quicly_send (conn, &ctx->rmt_ip, &ctx->lcl_ip, packets,
|
||||
&num_packets, buf, sizeof (buf))))
|
||||
goto quicly_error;
|
||||
|
||||
for (i = 0; i != num_packets; ++i)
|
||||
{
|
||||
|
||||
if ((err =
|
||||
quic_send_datagram (udp_session, &packets[i], &dest, &src)))
|
||||
goto quicly_error;
|
||||
|
||||
if ((err = quic_send_datagram (udp_session, &packets[i],
|
||||
&ctx->rmt_ip, &ctx->lcl_ip)))
|
||||
goto quicly_error;
|
||||
}
|
||||
n_sent += num_packets;
|
||||
}
|
||||
@ -1848,10 +1845,10 @@ quic_udp_session_connected_callback (u32 quic_app_index, u32 ctx_index,
|
||||
quic_build_sockaddr (sa, &salen, &tc->rmt_ip, tc->rmt_port, tc->is_ip4);
|
||||
|
||||
quicly_ctx = quic_get_quicly_ctx_from_ctx (ctx);
|
||||
ret = quicly_connect (&ctx->conn, quicly_ctx, (char *) ctx->srv_hostname,
|
||||
sa, NULL, &quic_main.wrk_ctx[thread_index].next_cid,
|
||||
ret = quicly_connect (&ctx->conn, quicly_ctx, (char *) ctx->srv_hostname, sa,
|
||||
NULL, &quic_main.wrk_ctx[thread_index].next_cid,
|
||||
ptls_iovec_init (NULL, 0), &quic_main.hs_properties,
|
||||
NULL);
|
||||
NULL, NULL);
|
||||
++quic_main.wrk_ctx[thread_index].next_cid.master_id;
|
||||
/* Save context handle in quicly connection */
|
||||
quic_store_conn_ctx (ctx->conn, ctx);
|
||||
@ -2103,10 +2100,9 @@ quic_accept_connection (quic_rx_packet_ctx_t * pctx)
|
||||
}
|
||||
|
||||
quicly_ctx = quic_get_quicly_ctx_from_ctx (ctx);
|
||||
if ((rv = quicly_accept (&conn, quicly_ctx, NULL, &pctx->sa,
|
||||
&pctx->packet, NULL,
|
||||
&quic_main.wrk_ctx[pctx->thread_index].next_cid,
|
||||
NULL)))
|
||||
if ((rv = quicly_accept (
|
||||
&conn, quicly_ctx, NULL, &pctx->sa, &pctx->packet, NULL,
|
||||
&quic_main.wrk_ctx[pctx->thread_index].next_cid, NULL, NULL)))
|
||||
{
|
||||
/* Invalid packet, pass */
|
||||
assert (conn == NULL);
|
||||
@ -2192,12 +2188,8 @@ quic_reset_connection (u64 udp_session_handle, quic_rx_packet_ctx_t * pctx)
|
||||
packet.iov_len = payload_len;
|
||||
packet.iov_base = payload;
|
||||
|
||||
struct _st_quicly_conn_public_t *conn =
|
||||
(struct _st_quicly_conn_public_t *) qctx->conn;
|
||||
|
||||
udp_session = session_get_from_handle (udp_session_handle);
|
||||
rv = quic_send_datagram (udp_session, &packet, &conn->remote.address,
|
||||
&conn->local.address);
|
||||
rv = quic_send_datagram (udp_session, &packet, &qctx->rmt_ip, &qctx->lcl_ip);
|
||||
quic_set_udp_tx_evt (udp_session);
|
||||
return rv;
|
||||
}
|
||||
|
@ -179,6 +179,8 @@ typedef struct quic_ctx_
|
||||
ptls_aead_context_t *aead_ctx;
|
||||
} ingress_keys;
|
||||
int key_phase_ingress;
|
||||
quicly_address_t rmt_ip;
|
||||
quicly_address_t lcl_ip;
|
||||
|
||||
} quic_ctx_t;
|
||||
|
||||
|
@ -10,7 +10,7 @@ endif()
|
||||
# it's reasonable to make this check to avoid breaking
|
||||
# existing builds when upgrading the quicly/picotls
|
||||
# versions
|
||||
set(EXPECTED_QUICLY_VERSION "0.1.4-vpp")
|
||||
set(EXPECTED_QUICLY_VERSION "0.1.5-vpp")
|
||||
|
||||
|
||||
vpp_find_path(QUICLY_INCLUDE_DIR NAMES quicly.h)
|
||||
|
Reference in New Issue
Block a user