boringssl/crypto/bn
Rob Sloan 45573cc04d Add Little-endian BIGNUM conversions
Towards an eventual goal of opaquifying BoringSSL structs, we want
our consumers -- in this case, Android's libcore -- to not directly
manipulate BigNums; and it would be convenient for them if we would
perform the appropriate gymnastics to interpret little-endian byte
streams.

It also seems a priori a bit strange to have only big-endian varieties
of BN byte-conversions.

This CL provides little-endian equivalents of BN_bn2bin_padded
and BN_bin2bn.

BUG=97
Change-Id: I0e92483286def86d9bd71a46d6a967a3be50f80b
Reviewed-on: https://boringssl-review.googlesource.com/12641
Reviewed-by: David Benjamin <davidben@google.com>
Commit-Queue: David Benjamin <davidben@google.com>
CQ-Verified: CQ bot account: commit-bot@chromium.org <commit-bot@chromium.org>
2017-01-06 18:20:09 +00:00
..
asm Remove RSAZ-512. 2016-12-14 22:12:50 +00:00
add.c Work around language and compiler bug in memcpy, etc. 2016-12-21 20:34:47 +00:00
bn_asn1.c
bn_test.cc Add Little-endian BIGNUM conversions 2017-01-06 18:20:09 +00:00
bn_tests.txt Remove RSAZ-512. 2016-12-14 22:12:50 +00:00
bn.c Work around language and compiler bug in memcpy, etc. 2016-12-21 20:34:47 +00:00
check_bn_tests.go
CMakeLists.txt Remove rsaz-x86_64.pl from CMake inputs. 2016-12-19 08:39:37 -08:00
cmp.c
convert.c Add Little-endian BIGNUM conversions 2017-01-06 18:20:09 +00:00
ctx.c Work around language and compiler bug in memcpy, etc. 2016-12-21 20:34:47 +00:00
div.c Remove the non-no_branch branch of BN_div. 2016-12-17 19:11:19 +00:00
exponentiation.c Work around language and compiler bug in memcpy, etc. 2016-12-21 20:34:47 +00:00
gcd.c Don't use BN_mod_inverse for inverses mod p in RSA keygen. 2017-01-04 13:56:11 +00:00
generic.c
internal.h Don't use BN_mod_inverse for inverses mod p in RSA keygen. 2017-01-04 13:56:11 +00:00
kronecker.c Fix BN_kronecker on unreachable BN_rshift error. 2016-12-12 21:40:20 +00:00
montgomery_inv.c Calculate Montgomery RR without division. 2016-12-16 17:41:01 +00:00
montgomery.c Work around language and compiler bug in memcpy, etc. 2016-12-21 20:34:47 +00:00
mul.c Work around language and compiler bug in memcpy, etc. 2016-12-21 20:34:47 +00:00
prime.c
random.c Work around language and compiler bug in memcpy, etc. 2016-12-21 20:34:47 +00:00
rsaz_exp.c Remove RSAZ-512. 2016-12-14 22:12:50 +00:00
rsaz_exp.h Remove RSAZ-512. 2016-12-14 22:12:50 +00:00
shift.c Work around language and compiler bug in memcpy, etc. 2016-12-21 20:34:47 +00:00
sqrt.c Check for BN_lshift failure in BN_sqrt. 2016-11-29 00:55:56 +00:00