Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Support bcrypt 2b and 2y | Jack Lloyd | 2018-06-29 | 3 | -12/+47 |
| | | | | | | | Continue to default to 2a since older versions don't know about 2b. Both 2b and 2y are identical to our implementation of 2a since we never implemented the relevant bugs which necessitated the new formats. | ||||
* | Fix handling of SHA instructions in tests | Jack Lloyd | 2018-06-29 | 4 | -2/+6 |
| | |||||
* | Check arguments to BigInt::random_integer | Jack Lloyd | 2018-06-29 | 2 | -2/+5 |
| | |||||
* | Fix Coverity false positive | Jack Lloyd | 2018-06-29 | 1 | -0/+2 |
| | | | | It thinks a divide by zero can happen here | ||||
* | Fix file descriptor leak in tls_server | Jack Lloyd | 2018-06-29 | 1 | -0/+2 |
| | | | | Coverity find | ||||
* | Fix some -Wshadow warnings | Jack Lloyd | 2018-06-29 | 2 | -6/+5 |
| | |||||
* | Add `botan has_command` | Jack Lloyd | 2018-06-29 | 1 | -0/+42 |
| | | | | Allows scripts to check if a subcommand is available | ||||
* | Fix CLI tests when OpenSSL is enabled | Jack Lloyd | 2018-06-29 | 1 | -1/+1 |
| | |||||
* | More CLI tests | Jack Lloyd | 2018-06-29 | 1 | -5/+66 |
| | |||||
* | Fix error - testing input file instead of output file | Jack Lloyd | 2018-06-29 | 1 | -1/+1 |
| | |||||
* | More cli tests, and a lint fix | Jack Lloyd | 2018-06-28 | 1 | -3/+4 |
| | |||||
* | Add --max-clients= option to tls_server CLI | Jack Lloyd | 2018-06-28 | 2 | -3/+10 |
| | | | | | | | Killing the process seems to result in the coverage info being lost. I think because gcov writes during an exit handler which ends up not running if we SIGTERM | ||||
* | Allow setting extended key usage when generating PKCS10 | Jack Lloyd | 2018-06-28 | 1 | -1/+6 |
| | |||||
* | Move reduction mod q to DL_Group | Jack Lloyd | 2018-06-28 | 4 | -31/+118 |
| | | | | | Avoids computing Barrett params many times and gives option for more optimizations in future. | ||||
* | Lint fixes | Jack Lloyd | 2018-06-28 | 1 | -7/+4 |
| | |||||
* | More CLI tests | Jack Lloyd | 2018-06-28 | 2 | -4/+97 |
| | |||||
* | Expose reduction mod p in CurveGFp | Jack Lloyd | 2018-06-28 | 3 | -16/+28 |
| | | | | This is slightly slower for Brainpool, but NIST curves are 5% faster. | ||||
* | Better document security status of included hashes | Jack Lloyd | 2018-06-28 | 1 | -9/+14 |
| | |||||
* | Add --no-fsname option to hash cli | Jack Lloyd | 2018-06-28 | 1 | -2/+8 |
| | |||||
* | Put warning about 64-bit ciphers in a warning block | Jack Lloyd | 2018-06-28 | 1 | -5/+7 |
| | |||||
* | Correct computing of discriminant in EC_Group::verify_group | Jack Lloyd | 2018-06-27 | 2 | -16/+36 |
| | | | | It was checking 4*a+27*b instead of 4*a^3 + 27*b^2 | ||||
* | Prohibit empty nonces with GCM | Jack Lloyd | 2018-06-27 | 3 | -5/+13 |
| | | | | | This is mostly harmless but not allowed by the specification. See for example SP800-38D section 5.2.1.1 | ||||
* | Add todo [ci skip] | Jack Lloyd | 2018-06-27 | 1 | -0/+1 |
| | |||||
* | Avoid useless multiplication in Montgomery exponentiation | Jack Lloyd | 2018-06-26 | 3 | -22/+39 |
| | | | | | | | | | | | | When beginning the loop we initialized a value to one (in Montgomery form) then multiply it by the first element looked up based on the exponent. But this will always (after Montgomery multiplication) be exactly the value we looked up in the table. So just assign it directly and avoid the redundant operation. Improves RSA verification by 5% or so since the number of multiplications is so small in that case saving even 1 in useful. For other operations there is no measurable improvement. | ||||
* | Add a warning about win32 stats making antivirus unhappy [ci skip] | Jack Lloyd | 2018-06-25 | 1 | -0/+4 |
| | | | | GH #1614 | ||||
* | Fix error in 1024-bit polynomial double | Jack Lloyd | 2018-06-25 | 2 | -2/+7 |
| | | | | | No big problem since we don't even support 1024-bit ciphers atm (though I suppose someone might have used Lion for this) | ||||
* | Merge GH #1616 Use ASCII versions of Win32 filesystem calls | Jack Lloyd | 2018-06-25 | 1 | -3/+3 |
|\ | |||||
| * | Use ASCII specific function calls for Windows API calls | Jack Lloyd | 2018-06-25 | 1 | -3/+3 |
|/ | | | | Fixes #1615 | ||||
* | Test all multiplication variants in ECC scalar mult test | Jack Lloyd | 2018-06-25 | 1 | -4/+15 |
| | |||||
* | Document preconditions of BigInt::mod_add/mod_sub | Jack Lloyd | 2018-06-23 | 1 | -0/+2 |
| | |||||
* | Minor optimization for Montgomery exponentiation | Jack Lloyd | 2018-06-23 | 3 | -17/+26 |
| | | | | | | | | | The loop started off by squaring the result value, but at that point it is always one (or the Montgomery representation thereof). Avoiding those squarings does not leak any information about the exponent, because we haven't even looked at the exponent at that point. Improves RSA verify performance by about 5%, everything else ~1% speedup | ||||
* | Fix typo [ci skip] | Jack Lloyd | 2018-06-22 | 1 | -1/+1 |
| | |||||
* | Some fiddling with RSA private operation | Jack Lloyd | 2018-06-22 | 1 | -18/+29 |
| | | | | | Spawning the thread off as quickly as possible helps perf slighty, especially with larger modulus. | ||||
* | Improve documentation of the AES T-table situation [ci skip] | Jack Lloyd | 2018-06-22 | 1 | -8/+26 |
| | |||||
* | Document what we do in GCM a bit better [ci skip] | Jack Lloyd | 2018-06-21 | 1 | -2/+5 |
| | |||||
* | Remove outdated comment [ci skip] | Jack Lloyd | 2018-06-21 | 1 | -2/+0 |
| | |||||
* | Avoid needless alloc and copy | Jack Lloyd | 2018-06-21 | 2 | -7/+11 |
| | |||||
* | Fix a header comment and inline PointGFp::add/add_affine | Jack Lloyd | 2018-06-21 | 2 | -26/+23 |
| | |||||
* | Attempt to verify decoded ECC groups are using prime fields | Jack Lloyd | 2018-06-20 | 2 | -5/+57 |
| | | | | | | | Otherwise ressol (part of point decompression) can end up in very long loop. OSS-Fuzz 9011 | ||||
* | Add todo | Jack Lloyd | 2018-06-20 | 1 | -0/+1 |
| | | | | GH #1612 | ||||
* | Avoid an unncecessary malloc | Jack Lloyd | 2018-06-20 | 1 | -1/+1 |
| | |||||
* | Use masked table lookups for variable point scalar mult | Jack Lloyd | 2018-06-20 | 2 | -16/+36 |
| | |||||
* | Changes to allow masked lookups for variable point mult | Jack Lloyd | 2018-06-20 | 8 | -146/+174 |
| | |||||
* | Fix SM2 encryption tests | Jack Lloyd | 2018-06-20 | 1 | -3/+4 |
| | | | | Broken in 5f26125d | ||||
* | Update side channel doc | Jack Lloyd | 2018-06-20 | 1 | -9/+25 |
| | |||||
* | Remove build time toggle for ECC coordinate masking | Jack Lloyd | 2018-06-20 | 3 | -23/+16 |
| | | | | | | | | | This is not a decision we should leave to end users. And always use a random mask equal in size to the underlying field. It was never quite clear if 80 bits was sufficient or not. But taking a random field element is clearly the best possible situation, and has very little additional cost. | ||||
* | Perform ECC mult starting from top bit of the exponent | Jack Lloyd | 2018-06-20 | 1 | -17/+16 |
| | | | | | | | Since we know the top bit is 1, then R will always be a point other than point at infinity after the very first addition regardless of the scalar or mask, so then coordinate randomization is guaranteed to work. | ||||
* | Avoid a small timing channel in Barrett reduction | Jack Lloyd | 2018-06-20 | 2 | -25/+31 |
| | | | | No known exploit for this but no point taking chances. | ||||
* | More cli tests | Jack Lloyd | 2018-06-19 | 1 | -0/+27 |
| | |||||
* | Ensure that trying to add points from different groups fails. | Jack Lloyd | 2018-06-19 | 3 | -13/+35 |
| | | | | Producing garbage instead is asking for trouble. |