Go to file
2018-12-27 15:40:50 +01:00
demo explicit condition 2018-12-27 09:44:59 +01:00
doc Corrected 128 bit entry in bn_mp_prime_miller_rabin_rials.c and extended it slightly 2018-12-25 15:17:12 +01:00
etc fix format 2018-12-27 09:44:34 +01:00
logs update results when running the timing demo 2018-02-27 23:30:43 +01:00
mtest make astyle + some manual adjustments 2018-12-25 15:17:12 +01:00
tombc added libtommath-0.35 2010-07-15 17:25:53 +02:00
.gitattributes improve build 2018-04-11 23:35:43 +02:00
.gitignore more visual studio related items in .gitignore 2018-12-08 10:43:52 +01:00
.travis.yml also run test vs mtest with real random data 2017-10-19 12:01:58 +02:00
astylerc format with astyle (step 1) 2017-08-30 20:09:49 +02:00
bn_error.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_fast_mp_invmod.c bn_fast_mp_invmod fix related to #118 2018-09-22 16:37:03 +02:00
bn_fast_mp_montgomery_reduce.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_fast_s_mp_mul_digs.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_fast_s_mp_mul_high_digs.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_fast_s_mp_sqr.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_2expt.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_abs.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_add_d.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_add.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_addmod.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_and.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_clamp.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_clear_multi.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_clear.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_cmp_d.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_cmp_mag.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_cmp.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_cnt_lsb.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_complement.c explicit condition 2018-09-23 10:41:27 +02:00
bn_mp_copy.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_count_bits.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_div_2.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_div_2d.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_div_3.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_div_d.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_div.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_dr_is_modulus.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_dr_reduce.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_dr_setup.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_exch.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_export.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_expt_d_ex.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_expt_d.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_exptmod_fast.c another msvc warnings: 32-bit shift implicitly converted to 64 bits 2018-12-08 10:43:52 +01:00
bn_mp_exptmod.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_exteuclid.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_fread.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_fwrite.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_gcd.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_get_bit.c explicit condition 2018-12-26 09:08:05 +01:00
bn_mp_get_double.c explicit operator precedence 2018-11-28 10:53:57 +01:00
bn_mp_get_int.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_get_long_long.c add missing comments 2018-12-02 13:10:09 +01:00
bn_mp_get_long.c add missing comments 2018-12-02 13:10:09 +01:00
bn_mp_grow.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_import.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_init_copy.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_init_multi.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_init_set_int.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_init_set.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_init_size.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_init.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_invmod_slow.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_invmod.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_is_square.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_jacobi.c improve indentation 2018-12-26 09:08:12 +01:00
bn_mp_karatsuba_mul.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_karatsuba_sqr.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_kronecker.c improve indentation 2018-12-26 09:08:12 +01:00
bn_mp_lcm.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_lshd.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_mod_2d.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_mod_d.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_mod.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_montgomery_calc_normalization.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_montgomery_reduce.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_montgomery_setup.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_mul_2.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_mul_2d.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_mul_d.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_mul.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_mulmod.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_n_root_ex.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_n_root.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_neg.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_or.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_prime_fermat.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_prime_frobenius_underwood.c improve indentation 2018-12-26 09:08:12 +01:00
bn_mp_prime_is_divisible.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_prime_is_prime.c fix missing check of return value 2018-12-26 13:16:15 +01:00
bn_mp_prime_miller_rabin.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_prime_next_prime.c exchanged direct call to Miller-Rabin in mp_prime_next_prime with mp_prime_is_prime 2018-12-25 15:17:03 +01:00
bn_mp_prime_rabin_miller_trials.c Corrected 128 bit entry in bn_mp_prime_miller_rabin_rials.c and extended it slightly 2018-12-25 15:17:12 +01:00
bn_mp_prime_random_ex.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_prime_strong_lucas_selfridge.c improve indentation 2018-12-26 09:08:12 +01:00
bn_mp_radix_size.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_radix_smap.c const mp_s_rmap 2018-06-04 18:29:47 +02:00
bn_mp_rand.c auto-format 2018-09-23 21:37:58 +02:00
bn_mp_read_radix.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_read_signed_bin.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_read_unsigned_bin.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_reduce_2k_l.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_reduce_2k_setup_l.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_reduce_2k_setup.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_reduce_2k.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_reduce_is_2k_l.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_reduce_is_2k.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_reduce_setup.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_reduce.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_rshd.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_set_double.c commented additional preprocessor branch in bn_mp_set_double.c 2018-12-08 10:13:21 +01:00
bn_mp_set_int.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_set_long_long.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_set_long.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_set.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_shrink.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_signed_bin_size.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_sqr.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_sqrmod.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_sqrt.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_sqrtmod_prime.c add missing comments 2018-12-02 13:10:09 +01:00
bn_mp_sub_d.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_sub.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_submod.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_tc_and.c remove side effect inside parameter of macro MAX 2018-12-27 09:44:29 +01:00
bn_mp_tc_div_2d.c auto-format 2018-09-23 21:37:58 +02:00
bn_mp_tc_or.c remove side effect inside parameter of macro MAX 2018-12-27 09:44:29 +01:00
bn_mp_tc_xor.c remove side effect inside parameter of macro MAX 2018-12-27 09:44:29 +01:00
bn_mp_to_signed_bin_n.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_to_signed_bin.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_to_unsigned_bin_n.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_to_unsigned_bin.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_toom_mul.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_toom_sqr.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_toradix_n.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_toradix.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_unsigned_bin_size.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_xor.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_mp_zero.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_prime_tab.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_reverse.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_s_mp_add.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_s_mp_exptmod.c fix #131 - msvc warning: result of 32-bit shift implicitly converted to 64 bits 2018-12-08 10:43:52 +01:00
bn_s_mp_mul_digs.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_s_mp_mul_high_digs.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_s_mp_sqr.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bn_s_mp_sub.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
bncore.c Do not use installed headers for building 2018-05-02 21:43:17 +02:00
callgraph.txt Update makefiles etc. 2018-12-25 15:17:12 +01:00
changes.txt fix date in changes.txt 2017-08-29 22:51:01 +02:00
dep.pl remove trailing spaces 2018-12-02 13:13:48 +01:00
gen.pl sanitize some Perl scripts 2017-04-09 01:04:07 +02:00
helper.pl drop broken (not working) makefile.cygwin_dll 2018-12-02 18:28:59 +01:00
libtommath_VS2008.sln make libtommath_VS2008 better upgradable to the newer visual studio 2018-12-08 11:56:08 +01:00
libtommath_VS2008.vcproj Update makefiles etc. 2018-12-25 15:17:12 +01:00
libtommath.pc.in add pkg-config file for shared library 2017-05-09 14:25:11 +02:00
LICENSE after multiple objections of libtom users [1], we decided to change licensing 2011-01-19 10:21:45 +01:00
makefile Update makefiles etc. 2018-12-25 15:17:12 +01:00
makefile_include.mk fix cygwin build 2018-12-02 17:56:10 +01:00
makefile.mingw Update makefiles etc. 2018-12-25 15:17:12 +01:00
makefile.msvc Update makefiles etc. 2018-12-25 15:17:12 +01:00
makefile.shared Update makefiles etc. 2018-12-25 15:17:12 +01:00
makefile.unix Update makefiles etc. 2018-12-25 15:17:12 +01:00
pretty.build added libtommath-0.31 2010-07-15 17:25:45 +02:00
README.md update README.md 2018-04-11 23:35:43 +02:00
testme.sh In case of a timeout echo last line in logfile of last test before that logfile gets removed 2018-12-25 15:17:03 +01:00
tommath_class.h bugfix in bn_mp_kronecker.c, cleanup and formatting in div. files 2018-12-25 15:17:12 +01:00
tommath_private.h const mp_s_rmap 2018-06-04 18:29:47 +02:00
tommath_superclass.h add missing comments 2018-12-02 13:10:09 +01:00
tommath.h fixes for MP_8BIT and mx32, prefinal design 2018-12-25 15:17:12 +01:00
updatemakes.sh fixup updatemakes.sh 2018-12-02 21:18:10 +01:00

libtommath

This is the git repository for LibTomMath, a free open source portable number theoretic multiple-precision integer (MPI) library written entirely in C.

Build Status

master: Build Status

develop: Build Status

API/ABI changes: check here

Summary

The develop branch contains the in-development version. Stable releases are tagged.

Documentation is built from the LaTeX file bn.tex. There is also limited documentation in tommath.h. There is also a document, tommath.pdf, which describes the goals of the project and many of the algorithms used.

The project can be build by using make. Along with the usual make, make clean and make install, there are several other build targets, see the makefile for details. There are also makefiles for certain specific platforms.

Testing

Tests are located in demo/ and can be built in two flavors.

  • make test creates a test binary that is intended to be run against mtest. mtest can be built with make mtest and test execution is done like ./mtest/mtest | ./test. mtest is creating test vectors using an alternative MPI library and test is consuming these vectors to verify correct behavior of ltm
  • make test_standalone creates a stand-alone test binary that executes several test routines.