mirror of
https://github.com/PurpleI2P/i2pd
synced 2024-11-10 00:00:29 +03:00
use HKDF for NTCP2 key derivation data phase
This commit is contained in:
parent
599ec62bb0
commit
db84be2488
@ -450,7 +450,7 @@ namespace transport
|
||||
memcpy (h, m_Establisher->GetH (), 32);
|
||||
memcpy (h + 32, "siphash", 7);
|
||||
i2p::crypto::HKDF (master, h, 39, "", master, 32); // sip_master = HKDF(ask_master, h || "siphash")
|
||||
i2p::crypto::HKDF (master, nullptr, 0, "", k, 64); // sipkeys_ab, sipkeys_ba = HKDF(sip_master, zerolen)
|
||||
i2p::crypto::HKDF (master, nullptr, 0, "", k); // sipkeys_ab, sipkeys_ba = HKDF(sip_master, zerolen)
|
||||
memcpy (m_Sipkeysab, k, 32); memcpy (m_Sipkeysba, k + 32, 32);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user