Commit Graph

22 Commits

Author SHA1 Message Date
29a14b39e6 Fix the bits() implementation, and add is_multiple_of() and gcd(). 2018-05-05 19:42:21 -07:00
c34629aa47 Add conversions for BigInt/BigUint. 2018-05-05 19:41:30 -07:00
bd0ddd848b A very slightly faster modexp. 2018-05-01 23:04:06 -07:00
296bb6ad90 Remove an unnecessary mut. 2018-05-01 22:28:59 -07:00
153d88237f Clean up (and make a lot more flexible) the code to translate to/from bytes. 2018-04-30 13:04:46 -07:00
baa70a6ce6 Starting to include RSA crypto. 2018-04-14 10:45:11 -07:00
b5a5cbdd98 Serialization routines. 2018-04-14 07:56:03 -07:00
4985426e74 Prospective prime support. 2018-04-14 07:16:50 -07:00
c45235473a Support modular inverses. 2018-04-14 07:05:57 -07:00
0d08f53d70 Make sure we print 0. 2018-04-14 06:59:49 -07:00
109e23789a Support fast modular exponentiation for when your base is roughly the same order of magnitude as the modulo. 2018-04-13 11:51:39 -04:00
551ebeac3b Fix some println!() leavings. 2018-04-13 11:06:42 -04:00
017392ff6c Fix the conversion functions, make sure we can do usize, too. 2018-04-13 10:57:22 -04:00
d98baa1381 Fix Barrett reduction. 2018-04-13 10:56:59 -04:00
330dabe017 Shift the gold testing infrastructure into its own module, and add the Haskell program I used to generate the tests. 2018-04-13 10:56:42 -04:00
675f8adc7e [BROKEN] Division seems to be broken? Might need better test vectors. 2018-04-05 18:02:03 -07:00
5868553c74 First whack at prime numbers and such. 2018-04-04 17:27:07 -07:00
ceb1e9eb58 Fix some shifting issues. 2018-04-04 17:26:49 -07:00
8a4693d30d Zero is a problem for me. 2018-04-04 17:57:11 -04:00
acda294bac Signed numbers! 2018-04-02 16:36:28 -04:00
7a8bb7b4fd Nevermind on the whole fixed size thing? 2018-03-23 22:11:09 -07:00
667e32694e Start including both signed and unsigned numbers, and starting building in Signed traits.
The latter seems much harder (and wordier) than it should be.
2018-03-11 17:46:22 -07:00