Compile latest ngtcp2 crypto lib

This commit is contained in:
Tatsuhiro Tsujikawa 2020-05-23 09:29:03 +09:00
parent 3c676d0836
commit af691e07e9
1 changed files with 4 additions and 4 deletions

View File

@ -52,8 +52,8 @@ int recv_crypto_data(ngtcp2_conn *conn, ngtcp2_crypto_level crypto_level,
int Client::quic_recv_crypto_data(ngtcp2_crypto_level crypto_level, int Client::quic_recv_crypto_data(ngtcp2_crypto_level crypto_level,
const uint8_t *data, size_t datalen) { const uint8_t *data, size_t datalen) {
return ngtcp2_crypto_read_write_crypto_data(quic.conn, ssl, crypto_level, return ngtcp2_crypto_read_write_crypto_data(quic.conn, crypto_level, data,
data, datalen); datalen);
} }
namespace { namespace {
@ -426,7 +426,7 @@ void Client::quic_close_connection() {
int Client::quic_on_key(ngtcp2_crypto_level level, const uint8_t *rx_secret, int Client::quic_on_key(ngtcp2_crypto_level level, const uint8_t *rx_secret,
const uint8_t *tx_secret, size_t secretlen) { const uint8_t *tx_secret, size_t secretlen) {
if (ngtcp2_crypto_derive_and_install_rx_key(quic.conn, ssl, nullptr, nullptr, if (ngtcp2_crypto_derive_and_install_rx_key(quic.conn, nullptr, nullptr,
nullptr, level, rx_secret, nullptr, level, rx_secret,
secretlen) != 0) { secretlen) != 0) {
std::cerr << "ngtcp2_crypto_derive_and_install_rx_key() failed" std::cerr << "ngtcp2_crypto_derive_and_install_rx_key() failed"
@ -434,7 +434,7 @@ int Client::quic_on_key(ngtcp2_crypto_level level, const uint8_t *rx_secret,
return -1; return -1;
} }
if (ngtcp2_crypto_derive_and_install_tx_key(quic.conn, ssl, nullptr, nullptr, if (ngtcp2_crypto_derive_and_install_tx_key(quic.conn, nullptr, nullptr,
nullptr, level, tx_secret, nullptr, level, tx_secret,
secretlen) != 0) { secretlen) != 0) {
std::cerr << "ngtcp2_crypto_derive_and_install_tx_key() failed" std::cerr << "ngtcp2_crypto_derive_and_install_tx_key() failed"