Description
This issue is a reminder to update comments and code for P-256 and P-384 keygen/scalargen to comply with the latest FIPS 186-5 specification, as objected by @jadephilipoom in #19419 .
The current implementation follows the specifications in FIPS 186-4. The newer FIPS 186-5 specifies basically the same algorithm, with the major difference for P-384 being that the minimum size of seed is now only 384 bits, not 448. Essentially, the curve order for P-384 is so close to 2^384 that the probability of a random 384-bit number being larger than the modulus is less than 2^(-192), and is therefore not a problem for P-384's security.
P-256 needs to be updated as well, since it was written before FIPS 186-5 came out.