flynn / noise

Go implementation of the Noise Protocol Framework

Home Page:https://noiseprotocol.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Generated curve25519 private keys don't follow clamping ritual

mcginty opened this issue · comments

I noticed during testing that the curve25519 GenerateKeypair method uses direct data from the RNG without clamping as instructed in https://cr.yp.to/ecdh.html:

 secret[0] &= 248;
 secret[31] &= 127;
 secret[31] |= 64;