CVSROOT:        /cvs
Module name:    src
Changes by:     [email protected]    2026/06/08 06:08:08

Modified files:
        lib/libcrypto/ecdh: ecdh.c 

Log message:
Add a point at infinity check to ecdh_compute_key()

While we already check that the peer's public point is on the curve and
will reject the point at infinity when getting the affine coordinates,
doing this earlier avoids doing work with the private key in a clearly
invalid case.

Suggested by Lucca Hirschi et al.

[An EC_KEY_check_key() call was also suggested but this is a bit expensive
and punishes callers that do that or equivalent already (e.g. ssh)]

ok jsing kenjiro

Reply via email to