16 Commits

Author SHA1 Message Date
Jeffrey Walton
f5f63850f9
Use std namespace for memset, memcpy, memcmp (#1204) 2023-04-15 16:45:02 -04:00
Jeffrey Walton
5dfc7e1c27
Remove unneeded fail variable 2020-12-30 15:36:26 -05:00
Jeffrey Walton
09d4941874
Add additional ECP and EC2N self tests (GH #994) 2020-12-30 06:38:38 -05:00
Jeffrey Walton
c9ef9420e7
Fix ECP leakage in Add() and Double() (GH #869, PR #871)
This check-in provides the fix for leaks in ECP's Add() and Double(). The fixes were taken from Joost Renes, Craig Costello, and Lejla Batina's [Complete addition formulas for prime order elliptic curves](https://eprint.iacr.org/2015/1060.pdf).

The Pull Request includes two additional changes that were related to testing the primary fix. First, an `AuthenticatedKeyAgreementWithRolesValidate` interface was added. It allows us to test key agreement when roles are involved. Roles are "client", "server", "initiator", "recipient", etc.

Second, `SetGlobalSeed` was added to `test.cpp` to help with reproducible results. We had code in two different places that set the seed value for the random number generator. But it was sloppy and doing a poor job since results could not be reproduced under some circumstances.
2019-08-05 03:51:58 -04:00
Jeffrey Walton
b3eb4c6a69
Fix AuthenticatedKeyAgreementWithRolesValidate messages 2019-08-03 23:59:25 -04:00
Jeffrey Walton
5aac8506bd
Use recipient rather than responder in authenticated key agreement
The recipient may not respond (though they do in the case of these key agreement schemes)
2019-08-03 23:52:50 -04:00
Jeffrey Walton
2e6ccd7fb1
Fix authenticated key agreement domain parameter consistency test 2019-08-03 17:01:02 -04:00
Jeffrey Walton
7eeb954b23
Add AuthenticatedKeyAgreementValidateWithRoles free standing test function 2019-08-03 16:32:36 -04:00
Jeffrey Walton
2ffa70fbc6
Clear asserts under DEBUG builds 2019-07-06 15:57:08 -04:00
Andrew Wason
9c307ff4ba Use MAC::DIGESTSIZE in ECIES SymmetricEncrypt/SymmetricDecrypt
Fixes #856
2019-07-02 10:47:46 -04:00
Jeffrey Walton
d62674b561
Add ed25519 (GH #764, PR #767)
Add ed25519
2018-12-24 17:17:32 -05:00
Jeffrey Walton
9396dc46ec
Update comments 2018-07-30 15:58:44 -04:00
Jeffrey Walton
f290746a36
Remove Coverity worakaround StreamState
Use std::ostringstream instead. Eventually I'd like to see the output stream passed into the function of interest. It will avoid problems on some mobile OSes that don't have standard inputs and outputs.
2018-07-29 22:35:36 -04:00
Jeffrey Walton
0210e54310
Update comments 2018-07-29 20:34:29 -04:00
Jeffrey Walton
d51f701e06
Refactor validat5.cpp and validat6.cpp
Also see https://groups.google.com/forum/#\!topic/cryptopp-users/j_aQj6r-PoI
2018-07-29 20:30:19 -04:00
Jeffrey Walton
28fe1a6a4d
Split validat*.cpp source files
Also see https://groups.google.com/forum/#\!topic/cryptopp-users/j_aQj6r-PoI
2018-07-28 14:57:12 -04:00