Implement TLS 1.3-like handshake manually

This commit is contained in:
Vitaliy Filippov
2026-05-19 17:19:47 +03:00
parent 72d1447eec
commit f2585bcd02
12 changed files with 1086 additions and 78 deletions
+1 -9
View File
@@ -240,6 +240,7 @@ void osd_messenger_t::parse_config(const json11::Json & config)
this->use_proto_checksums = config["proto_checksums"].string_value() == "full" ? MSGR_CSUM_FULL : MSGR_CSUM_PAYLOAD;
else
this->use_proto_checksums = 0;
gcm_enabled = true;
if (!osd_num)
{
tls_cert = config["tls_cert"].string_value();
@@ -253,15 +254,6 @@ void osd_messenger_t::parse_config(const json11::Json & config)
osd_tls_ca = config["osd_tls_ca"].string_value();
client_tls_ca = config["client_tls_ca"].string_value();
}
test_osd_aes_key.resize(32);
if (fromhexstr(config["test_osd_aes_key"].string_value(), 32, (uint8_t*)test_osd_aes_key.data()) != 32)
test_osd_aes_key.clear();
else
{
#ifdef WITH_ISAL_CRYPTO
isal_aes_gcm_pre_256(test_osd_aes_key.data(), &test_osd_aes_key_isal);
#endif
}
if (!osd_num)
this->iothread_count = (uint32_t)config["client_iothread_count"].uint64_value();
else