cisco / go-hpke

Implementation of draft-irtf-cfrg-hpke
BSD 2-Clause "Simplified" License
30 stars 15 forks source link

Fix test PSK encoding. Rename psk and pskID for clarity. #19

Closed chris-wood closed 4 years ago

rozbb commented 4 years ago

I inferred from the spec that psk is supposed to have length Nh. Is that not the case? If it is, then you need a PSK for HKDF-SHA384 and HKDF-SHA512

chris-wood commented 4 years ago

Is that not the case? If it is, then you need a PSK for HKDF-SHA384 and HKDF-SHA512

Nope -- the default PSK is zero(Nh) as that matches the HKDF spec. Any length PSK will do. That said, low entropy PSKs are... not good. There's a PR up against the spec that recommends a minimum length.

chris-wood commented 4 years ago

Applied in #21.