mirror of
https://github.com/ZeroTier/ZeroTierOne
synced 2025-08-22 14:23:59 -07:00
Merge branch 'tetanus-noise-xk' of github.com:/zerotier/ZeroTierOne into tetanus-noise-xk
This commit is contained in:
commit
5d3536325e
1 changed files with 1 additions and 1 deletions
|
@ -1240,7 +1240,7 @@ fn hmac_sha384_2(key: &[u8], a: &[u8], b: &[u8]) -> [u8; 48] {
|
|||
/// Cryptographically this isn't meaningfully different from HMAC(key, [label]) but this is how NIST rolls.
|
||||
fn kbkdf<const OUTPUT_BYTES: usize, const LABEL: u8>(key: &[u8]) -> Secret<OUTPUT_BYTES> {
|
||||
//These are the values we have assigned to the 5 variables involved in https://csrc.nist.gov/publications/detail/sp/800-108/final:
|
||||
// K_in = key, [i]_2 = 0x01, Label = 'Z'||'T'||label, Context = 0x00, L = 0x0200
|
||||
// K_in = key, i = 0x01, Label = 'Z'||'T'||label, Context = 0x00, L = (OUTPUT_BYTES * 8)
|
||||
Secret::<OUTPUT_BYTES>::from_bytes(
|
||||
&hmac_sha512(
|
||||
key,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue