Brian Smith
32cf372b32
Remove last, superfluous, stdlib.h dependency.
2019-02-02 16:08:12 -10:00
Brian Smith
c7f0eadf0f
Move ARM CPU feature caching from C to Rust.
...
Some of the targets in Rust's `cross` toolchains have old libc headers
that don't have sys/auxv.h, and we want to do this in Rust anyway.
Unfortunately, in the process of doing so, I found out that
`libc::getauxval()` isn't available in enough places either, so we skip
dealing with *that* too.
2019-01-28 14:33:31 -10:00
Brian Smith
3dfbe3bf6b
Do GCM CPU feature detection in Rust.
...
Rename some GCM assembly functions so that all functions that do the
same thing the same way have the same name, to make the dispatching
logic simpler.
Thread CPU feature caching witnesses through the GCM dispatching logic
to make feature detection less error-prone.
Start an internal Rust API for feature detection.
2019-01-28 14:33:31 -10:00
Brian Smith
f2aee63f78
Merge BoringSSL 5ecfb10: Modernize OPENSSL_COMPILE_ASSERT, part 2.
2019-01-03 17:12:28 -10:00
Brian Smith
1daee25818
Remove heap allocation & file I/O from crypto/cpu-arm-linux.c.
...
Require `getauxval`. Don't bother worrying about the very old,
now-EoL, devices with broken NEON.
2019-01-02 20:45:31 -10:00
Brian Smith
b989d3343d
Implement high-level AES-GCM logic to Rust.
2018-12-14 11:39:34 -10:00
Brian Smith
d6b194c72c
Remove unused declaration of BIGNUM.
2018-12-04 12:38:36 -10:00
Brian Smith
d05bdd5856
Merge BoringSSL 2745ef9: Also accept __ARM_NEON
2018-11-27 23:10:52 -10:00
Brian Smith
c6dccc7d00
Merge BoringSSL 749d187: Modernize OPENSSL_COMPILE_ASSERT.
2018-11-27 16:06:34 -10:00
Brian Smith
740032b9b7
Fix build with MSVC 2017 15.9.1.
2018-11-15 16:17:40 -10:00
Brian Smith
975a2c29f1
Remove unneeded __cplusplus ifdefs.
2018-11-15 16:17:39 -10:00
Adam Langley
e0e9d76047
Cherry-pick BoringSSL e77c27d: Automatically disable assembly with MSAN.
...
This should unbreak the build.
2018-11-14 16:24:32 -10:00
Brian Smith
cf15144757
Tighten the signature of GFp_memcmp and remove casting from it.
...
All callers are now comparing `uint8_t` arrays so upgrade its signature
to avoid the casting.
2018-05-18 13:32:50 -10:00
Brian Smith
b60250e47e
Remove bn.h.
2018-05-16 13:13:47 -10:00
Brian Smith
737e61df7d
Remove BIGNUM.
2018-05-16 11:47:28 -10:00
Brian Smith
6176ec7d79
Remove now-redundant AES function declarations.
2018-05-14 16:03:24 -10:00
Brian Smith
be238cff56
Merge BoringSSL b1e6a85: Change OPENSSL_cpuid_setup to reserve more extended feature space.
2018-05-11 10:53:57 -10:00
Brian Smith
4e69aa447a
Remove GFp_BN_copy().
2018-05-10 18:40:25 -10:00
Brian Smith
5eb53f5b19
Remove BIGNUM from GFp_BN_mod_exp_mont_consttime's signature.
2018-05-06 20:11:33 -10:00
Brian Smith
1c80ff727e
Remove prototype of already-removed GFp_BN_mod_mul_mont.
2018-05-06 19:22:05 -10:00
Brian Smith
e4034dded4
Use fixed-width ring elements (and modulus) in RSA signing.
...
Improve the constant-timedness of RSA.
2018-05-06 11:13:59 -10:00
Brian Smith
df505089ee
Remove non-Montgomery multiplication.
2018-05-05 08:49:14 -10:00
Brian Smith
065d243134
Remove GFp_BN_is_bit_set.
2018-05-05 08:26:23 -10:00
Brian Smith
082c79d5b8
Remove prototypes for already-removed functions.
2018-05-05 08:24:10 -10:00
Brian Smith
f3127d3625
Remove BIGNUM::flags and BN_FLG_STATIC_DATA.
...
These are no longer used.
2018-05-03 12:29:59 -10:00
Brian Smith
2be31b6b6a
Remove BN_FLG_MALLOCED.
...
The flag isn't needed.
2018-05-02 16:42:09 -10:00
Brian Smith
f116853105
Merge BoringSSL 32b59402: Don't leak the exponent bit width in BN_mod_exp_mont_consttime.
2018-05-01 12:44:21 -10:00
Brian Smith
9a63ee10d1
Merge BoringSSL 74b828f: Clarify the documentation for |BN_is_bit_set|.
2018-04-30 14:28:09 -10:00
Brian Smith
5fc6f9830f
Merge BoringSSL 4512b79: Run comment conversion script on include/
2018-04-29 19:46:16 -10:00
Brian Smith
4c01b3a7f1
Merge BoringSSL 808f832: Run the comment converter on libcrypto.
2018-04-29 10:59:44 -10:00
Brian Smith
cc9d3d792e
Merge BoringSSL 4d2e1a8: Add a note on architecture requirements.
...
Note that base.h has become disconnected from upstream so I had to
merge this manually.
2018-04-29 09:20:12 -10:00
Brian Smith
d0596794ee
Restore OPENSSL_UNUSED.
...
Now it is used by `OPENSSL_COMPILE_ASSERT`.
2018-04-29 09:09:39 -10:00
Brian Smith
c2c4dbbded
Take BoringSSL 7e9e06a: Use OPENSSL_UNUSED in OPENSSL_COMPILE_ASSERT.
2018-04-29 09:07:58 -10:00
Brian Smith
142968a115
s/CRYPTO_/GFp_/ to unbreak non-Intel builds.
2018-04-28 17:57:43 -10:00
Brian Smith
3589ba19fb
Merge BoringSSL 3b33f3e: Set static armcaps based on __ARM_FEATURE_CRYPTO.
2018-04-28 17:00:17 -10:00
Joe Ranweiler
ee84bc9b80
Use explicitly-sized integer type in C predicate.
...
I agree to license my contributions to each file under the terms given
at the top of each file I changed.
2017-05-16 12:17:13 -07:00
Brian Smith
60867f2642
Remove GFp/err.h and clean up leftover unused bits.
2017-04-27 16:06:22 -10:00
Brian Smith
c86906bc68
Remove GFp_BN_bin2bn().
2017-04-27 14:44:34 -10:00
Brian Smith
d18eb07d3f
Remove GFp_BN_set_word().
2017-04-26 17:24:44 -10:00
Brian Smith
3ee3b63ee0
Replace GFp_BN_is_one().
2017-04-26 17:24:43 -10:00
Brian Smith
68fa32053f
Replace GFp_BN_is_zero().
2017-04-26 17:24:42 -10:00
Brian Smith
c1ab3fe08f
Remove now-unused BIGNUM internal constants.
2017-04-26 17:24:42 -10:00
Brian Smith
08ec11041e
Replace GFp_BN_ucmp().
2017-04-26 17:24:41 -10:00
Brian Smith
aa6dcd5b55
Replace GFp_BN_usub().
2017-04-26 17:24:40 -10:00
Brian Smith
f2e5be3c00
Replace GFp_BN_uadd().
2017-04-26 17:17:52 -10:00
Brian Smith
8c1d54b353
Replace GFp_BN_mod_sub_quick().
2017-04-26 17:17:52 -10:00
Brian Smith
bff4a74a1f
Replace GFp_BN_mod_add_quick().
2017-04-26 17:12:28 -10:00
Brian Smith
94f73dfd5c
Replace GFp_BN_num_bits() with a simpler Rust equivalent.
2017-04-25 16:18:14 -10:00
Brian Smith
f4237ce57b
GFp_BN_mod_exp_mont_consttime: Have caller pass the exponent bit length.
...
This is a step towards doing the bit length calculation in Rust.
2017-04-25 16:18:13 -10:00
Brian Smith
b7e81ab569
RSA: Calculate RR in Rust.
2017-04-25 13:13:37 -10:00