| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
Was already done in P-256 but not in P-{192,224,384}.
This is a cache-based side channel which would be good to address. It
seems like it would be very difficult to exploit even with perfect
recovery, but crazier things have worked.
|
|
|
|
| |
This is a tiny thing but it saves over 100K cycles for P-384 ECDSA
|
| |
|
| |
|
|
|
|
| |
Previously handled by the early exit
|
|
|
|
| |
Also avoid an early exit in P-521
|
|
|
|
|
| |
This is still vulnerable to a cache-based side channel since the
multiple chosen leaks the final carry.
|
|
|
|
| |
Avoid recalculating significant words which slows down reduction
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
It turned out 8 bit was very broken (failed to compile, due to
overload problems with functions taking uint8_t vs word).
16 bit words work aside from a test failure, but is really slow.
Practically speaking we are not in a position to support 16-bit CPUs
very well. And being able to assume sizeof(word) >= sizeof(uint32_t)
allows simplifying some code.
|
|
|
|
|
|
|
|
| |
If x was very small to start with x.size() might be under the
limb count which would cause the final addition to throw because
the destination array was smaller than the P-224 p being added.
Caught by Wycheproof ECDSA tests
|
| |
|
| |
|
|
|
|
| |
5-7% faster ECDSA
|
| |
|
|
|
|
| |
5-7% faster for ECDSA and ECDH
|
|
|
|
| |
Improves ECDSA and ECDH by 1% or so.
|
|
|
|
| |
Improves ECDSA by ~5% on Skylake
|
| |
|
|
|
|
| |
Use the BOTAN_MP_WORD_BITS consistently
|
|
|
|
|
|
|
| |
Introduced in c95b3967bf421, we failed to reduce if the result
was exactly 2**521 - 1
OSS-Fuzz 6635
|
|
|
|
| |
ECDSA/ECDH both about 25% faster
|
|
|
|
| |
Precompute the multiples of the prime and then subtract directly.
|
|
They were already somewhat entangled and future work will increase
that (eg by having PointGFp hold a pointer to EC_Group)
|