Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Make high_bit and ctz actually const time | Jack Lloyd | 2018-12-22 | 1 | -3/+3 |
| | |||||
* | Promote ct_is_zero and expand_top_bit to bit_ops.h | Jack Lloyd | 2018-12-22 | 2 | -10/+21 |
| | |||||
* | Make ctz and high_bit faster and const-time-ish | Jack Lloyd | 2018-12-22 | 3 | -48/+51 |
| | | | | | | | They get compiled as const-time on x86-64 with GCC but I don't think this can be totally relied on. But it is anyway an improvement. And, faster, because we compute it recursively | ||||
* | Increase Travis cache size [ci skip] | Jack Lloyd | 2018-12-22 | 1 | -2/+2 |
| | | | | | With compression disabled, the cache is too small for builds that use debug info, and causes 100% miss rate. | ||||
* | Fix build with PGI [ci skip] | Jack Lloyd | 2018-12-22 | 1 | -5/+7 |
| | | | | I couldn't get anything to link with PGI, but at least it builds again. | ||||
* | Update news | Jack Lloyd | 2018-12-21 | 1 | -2/+2 |
| | |||||
* | Merge GH #1794 Improve const time logic in PKCS1v15 and OAEP decoding | Jack Lloyd | 2018-12-21 | 9 | -92/+171 |
|\ | |||||
| * | Use consistent logic for OAEP and PKCS1v15 decoding | Jack Lloyd | 2018-12-21 | 9 | -92/+171 |
| | | | | | | | | | | | | | | | | | | | | | | | | The decoding leaked some information about the delimiter index due to copying only exactly input_len - delim_idx bytes. I can't articulate a specific attack that would work here, but it is easy enough to fix this to run in const time instead, where all bytes are accessed regardless of the length of the padding. CT::copy_out is O(n^2) and thus terrible, but in practice it is only used with RSA decryption, and multiplication is also O(n^2) with the modulus size, so a few extra cycles here doesn't matter much. | ||||
* | | Merge GH #1793 Cleanup use of rotate.h header | Jack Lloyd | 2018-12-21 | 28 | -2/+30 |
|\ \ | |||||
| * | | Avoid including rotate.h in bswap.h | Jack Lloyd | 2018-12-21 | 28 | -2/+30 |
|/ / | | | | | | | | | | | | | It was only needed for one case which is easily hardcoded. Include rotate.h in all the source files that actually use rotr/rotl but implicitly picked it up via loadstor.h -> bswap.h -> rotate.h include chain. | ||||
* / | Stop compressing Travis ccache | Jack Lloyd | 2018-12-21 | 1 | -3/+1 |
|/ | | | | Since CPU is main bottleneck to the build, this is likely not helping. | ||||
* | Address a couple of Coverity false positives | Jack Lloyd | 2018-12-19 | 4 | -7/+62 |
| | | | | Add tests for is_power_of_2 | ||||
* | Correct affected version range for CVE-2018-20187 | Jack Lloyd | 2018-12-19 | 1 | -1/+1 |
| | | | | | | Using the Montgomery ladder for operator* was introduced in ca155a7e54, previous versions did something different, which was itself vulnerable to side channels, but not with the same issue as CVE-2018-20187. | ||||
* | Update news | Jack Lloyd | 2018-12-19 | 1 | -0/+4 |
| | |||||
* | Merge GH #1792 Avoid unblinded Montgomery ladder during ECC keygen | Jack Lloyd | 2018-12-19 | 3 | -11/+41 |
|\ | |||||
| * | Avoid using unblinded Montgomery ladder during ECC key generation | Jack Lloyd | 2018-12-18 | 3 | -11/+41 |
|/ | | | | | | | | | | | As doing so means that information about the high bits of the scalar can leak via timing since the loop bound depends on the length of the scalar. An attacker who has such information can perform a more efficient brute force attack (using Pollard's rho) than would be possible otherwise. Found by Ján Jančár (@J08nY) using ECTester (https://github.com/crocs-muni/ECTester) CVE-2018-20187 | ||||
* | Update roadmap [ci skip] | Jack Lloyd | 2018-12-18 | 2 | -56/+30 |
| | |||||
* | Test how long it takes to precompute base point multiples | Jack Lloyd | 2018-12-16 | 2 | -1/+21 |
| | |||||
* | Merge GH #1789 Improvements to const time lookups | Jack Lloyd | 2018-12-14 | 3 | -22/+26 |
|\ | |||||
| * | In PointGFp addition, prevent all_zeros from being shortcircuited | Jack Lloyd | 2018-12-14 | 1 | -4/+7 |
| | | | | | | | | | | | | This doesn't matter much but it causes confusing valgrind output when const-time checking since it distinguishes between the two possible conditional returns. | ||||
| * | Unroll const_time_lookup by 2 | Jack Lloyd | 2018-12-14 | 1 | -6/+10 |
| | | | | | | | | | | We know the lookup table is some power of 2, unrolling a bit allows more IPC | ||||
| * | Simplify the const time lookup in ECC scalar mul | Jack Lloyd | 2018-12-14 | 1 | -12/+9 |
|/ | | | | | Code is easier to understand and it may let the CPU interleave the loads and logical ops better. Slightly faster on my machine. | ||||
* | Update news | Jack Lloyd | 2018-12-14 | 1 | -1/+1 |
| | |||||
* | Merge GH #1788 Use 3-bit comb for ECC base point multiplies | Jack Lloyd | 2018-12-14 | 2 | -19/+36 |
|\ | |||||
| * | Use a 3-bit comb for ECC base point multiply | Jack Lloyd | 2018-12-13 | 2 | -19/+36 |
|/ | | | | Improves ECDSA signing by 15% | ||||
* | Another todo [ci skip] | Jack Lloyd | 2018-12-13 | 1 | -0/+1 |
| | |||||
* | More todos [ci skip] | Jack Lloyd | 2018-12-12 | 1 | -0/+2 |
| | |||||
* | Make this comment more clear [ci skip] | Jack Lloyd | 2018-12-12 | 1 | -1/+2 |
| | |||||
* | Some cleanups in x25519 | Jack Lloyd | 2018-12-10 | 1 | -53/+43 |
| | |||||
* | More todos | Jack Lloyd | 2018-12-10 | 1 | -1/+2 |
| | |||||
* | Fix more MSVC warnings | Jack Lloyd | 2018-12-10 | 4 | -8/+9 |
| | |||||
* | More todos [ci skip] | Jack Lloyd | 2018-12-10 | 1 | -0/+6 |
| | |||||
* | Merge GH #1769 Support TLS signature padding strings in PKCS11 mapping | Jack Lloyd | 2018-12-10 | 1 | -0/+10 |
|\ | |||||
| * | Remove EMSA1 encodings from p11 sign mechanisms map | Hannes Rantzsch | 2018-12-10 | 1 | -5/+0 |
| | | |||||
| * | Extend the SignMechanisms map for Signature_Scheme padding strings | Hannes Rantzsch | 2018-12-04 | 1 | -0/+15 |
| | | | | | | | | | | | | This addresses #730. The tls_sign_message callback was unable to handle emsa strings produced as padding strings for TLS::Signature_Scheme, due to inconsistent naming (mostly between EMSA3 and EMSA_PKCS1). | ||||
* | | Fix some MSVC warnings | Jack Lloyd | 2018-12-10 | 12 | -26/+35 |
| | | |||||
* | | Update news | Jack Lloyd | 2018-12-10 | 1 | -1/+3 |
| | | |||||
* | | Merge GH #1784 Add ECDSA pubkey recovery | Jack Lloyd | 2018-12-10 | 6 | -3/+236 |
|\ \ | |||||
| * | | Work around a problem when built with OpenSSL | Jack Lloyd | 2018-12-10 | 3 | -7/+10 |
| | | | | | | | | | | | | | | | | | | | | | It appears OpenSSL has a different interpretation from us of how the message representative is formed for P-521 when given a hash to sign that is larger than the group order; signatures generated by us do not verify with OpenSSL and vice versa. | ||||
| * | | Support recovering ECDSA public key from message/signature pair | Jack Lloyd | 2018-12-10 | 6 | -2/+232 |
|/ / | | | | | | | | | | | See http://www.secg.org/sec1-v2.pdf section 4.1.6 Closes #664 | ||||
* | | Fix pylint3 warning [ci skip] | Jack Lloyd | 2018-12-10 | 1 | -1/+1 |
| | | |||||
* | | More todos | Jack Lloyd | 2018-12-09 | 1 | -0/+2 |
| | | |||||
* | | Update news | Jack Lloyd | 2018-12-09 | 1 | -0/+2 |
| | | |||||
* | | Merge GH #1783 Add base58 encoding/decoding | Jack Lloyd | 2018-12-09 | 7 | -1/+454 |
|\ \ | |||||
| * | | Make ASan happy | Jack Lloyd | 2018-12-09 | 1 | -1/+1 |
| | | | |||||
| * | | Add base58 encoding/decoding | Jack Lloyd | 2018-12-09 | 7 | -1/+454 |
|/ / | |||||
* | | Todos [ci skip] | Jack Lloyd | 2018-12-09 | 1 | -2/+2 |
| | | |||||
* | | Merge GH #1782 Add an i386 build/test to CI | Jack Lloyd | 2018-12-09 | 3 | -4/+14 |
|\ \ | |||||
| * | | Add an i386 CI target to check on 32-bit asm | Jack Lloyd | 2018-12-09 | 3 | -4/+14 |
| | | | |||||
* | | | Remove Chi-square test on random_integer | Jack Lloyd | 2018-12-09 | 1 | -46/+0 |
|/ / | | | | | | | | | I'm not sure this test is that useful, which is not itself a big problem, but it is also flaky and occasionally fails, which is no good. |