aboutsummaryrefslogtreecommitdiffstats
path: root/src/math
Commit message (Collapse)AuthorAgeFilesLines
* propagate from branch 'net.randombit.botan' (head ↵lloyd2009-11-027-51/+44
|\ | | | | | | | | | | 2773c2310e8c0a51975987a2dd6c5824c8d43882) to branch 'net.randombit.botan.c++0x' (head f13cf5d7e89706c882604299b508f356c20aae3a)
| * propagate from branch 'net.randombit.botan' (head ↵lloyd2009-10-137-51/+44
| |\ | | | | | | | | | | | | | | | 139d6957d20f0b1202e0eacc63cb011588faffde) to branch 'net.randombit.botan.c++0x' (head c16676fa6c393bc3f46a044755ce525a013380a6)
| | * propagate from branch 'net.randombit.botan' (head ↵lloyd2009-09-172-2/+2
| | |\ | | | | | | | | | | | | | | | | | | | | 92e05ab242e4b6998d685961c53700534a673bce) to branch 'net.randombit.botan.c++0x' (head 27ce37b971ec5cb1f80a9a95b13d5a951b96653b)
| | * \ propagate from branch 'net.randombit.botan' (head ↵lloyd2009-09-087-51/+44
| | |\ \ | | | | | | | | | | | | | | | | | | | | | | | | | 5cadcc57872bef55226579df57349fe09a93d1f5) to branch 'net.randombit.botan.c++0x' (head d1747f0394aa4442e5b32b9102b830e1a86f0e5a)
| | | * \ propagate from branch 'net.randombit.botan' (head ↵lloyd2009-07-216-31/+36
| | | |\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 95eb8083f5884531e5ca0667388f8a6fb6d05c41) to branch 'net.randombit.botan.c++0x' (head 56e105e678540c8bcafa4d0198c19a9489fbf8d1)
| | | * \ \ propagate from branch 'net.randombit.botan' (head ↵lloyd2009-07-157-51/+44
| | | |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 5438defd358f82e876917a8bd6d735305ecb0a8e) to branch 'net.randombit.botan.c++0x' (head cbdb2fd418557add29a536f7bdb6e78db16f725c)
| | | | * \ \ propagate from branch 'net.randombit.botan' (head ↵lloyd2009-07-031-1/+1
| | | | |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | d6d32791adfa878b6fc0dd3a5b65a665b7bbb549) to branch 'net.randombit.botan.c++0x' (head 54deb0e078aab8cd91c8fd8819d1e6668fc762da)
| | | | * \ \ \ propagate from branch 'net.randombit.botan' (head ↵lloyd2009-06-047-51/+44
| | | | |\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 6a746ccf1e957dba703e65372050a7bd4d6b117d) to branch 'net.randombit.botan.c++0x' (head f54bb7b391eb3b71f380a68ddd460debdc31545d)
| | | | | * | | | Use C++0x std::shared_ptr<> instead of TR1'slloyd2009-04-016-50/+43
| | | | | | | | |
| | | | | * | | | Replace the (deprecated) auto_ptr with unique_ptr.lloyd2009-04-011-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This was mostly a s/auto_ptr/unique_ptr/, except in the CVC code and one function in ECDSA, which relied on auto_ptr's move semantics (ugh) and had to be modified in various ways.
* | | | | | | | | Remove the 'realname' attribute on all modules and cc/cpu/os info files.lloyd2009-10-2913-26/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Pretty much useless and unused, except for listing the module names in build.h and the short versions totally suffice for that.
* | | | | | | | | Also enable x86 asm word_addlloyd2009-10-151-8/+0
| | | | | | | | |
* | | | | | | | | Enable x86-64 asm word_addlloyd2009-10-151-8/+0
| | | | | | | | |
* | | | | | | | | Avoid using word_add() in gfp_element.cpp, actually more complex than necessary,lloyd2009-10-151-1/+3
|/ / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | and was tickling a bug in the asm versions because of the constant 0.
* | | | | | | | Oops, removed assert.h from gfp_element.cpp which uses assert :(lloyd2009-10-071-0/+1
| | | | | | | |
* | | | | | | | Add 'Distributed under...' text to files missing it. Some format cleanupslloyd2009-10-076-84/+79
| |_|_|_|_|_|/ |/| | | | | |
* | | | | | | Split up util.h into 3 fileslloyd2009-09-172-2/+2
|/ / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - rounding.h (round_up, round_down) - workfactor.h (dl_work_factor) - timer.h (system_time) And update all users of the previous util.h
* | | | | | Add 'Distributed under the terms of the Botan license' notices to the .Slloyd2009-08-113-12/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | files. Were missed by the automated script that added them to the cpp/h files, it appears.
* | | | | | Add support for Dragonfly BSD (a fork of FreeBSD).lloyd2009-07-253-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | Contributed by Patrick Georgi
* | | | | | Fix bigint_2word_mul - it tried to use MP_WORD_BITS which was not visiblelloyd2009-07-231-1/+1
| |_|_|_|/ |/| | | | | | | | | | | | | | | | | | | in this header, instead use the macro version BOTAN_MP_WORD_BITS. Only affected 64-bit SPARC builds.
* | | | | Fix various auto generated dependencies that were wronglloyd2009-07-177-22/+5
| | | | |
* | | | | Move some files around to break up dependencies between directorieslloyd2009-07-161-0/+1
| | | | |
* | | | | Add a script that reads the output of print_deps.py and rewriteslloyd2009-07-159-29/+50
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | the info.txt files with the right module dependencies. Apply it across the codebase.
* | | | | New module load_on directive 'never', to mark known-buggy codelloyd2009-07-152-2/+2
|/ / / /
* | | | Fix nonce generation of Miller-Rabin testlloyd2009-07-121-1/+1
| | | |
* | | | Remove unnecessary includes of <iostream>; either delete entirely as notlloyd2009-07-115-4/+4
| | | | | | | | | | | | | | | | needed, or replace with <iosfwd> or <ostream> where necessary.
* | | | Fix generating primes between 4 and 7 bits. The problem was that whenlloyd2009-07-111-17/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | verify mode is not set, by default the Miller-Rabin bases are chosen from the small primes. Generally speaking these make good test bases. However if the prime to be generated is very small, we will choose a base which is out of range. If the i'th prime is too big to be a base, then just choose a random integer of the appropriate size instead.
* | | | Devai Tamas pointed out on the mailing list that random_prime with bitslloyd2009-07-101-3/+3
| |_|/ |/| | | | | | | | | | | | | | set to 2, 3, or 4 was not returning a random prime due to reducing the rng output modulo 1 instead of mod 2 in choosing which prime of that size to return. Oops.
* | | Only load mulop_amd64 on request (currently broken code)lloyd2009-07-021-1/+1
|/ /
* / One more s/engine.h/pk_engine.h/lloyd2009-05-131-1/+1
|/
* Thomas Moschny passed along a request from the Fedora packagers which camelloyd2009-03-3051-946/+1044
| | | | | | | | | | | | | | | up during the Fedora submission review, that each source file include some text about the license. One handy Perl script later and each file now has the line Distributed under the terms of the Botan license after the copyright notices. While I was in there modifying every file anyway, I also stripped out the remainder of the block comments (lots of astericks before and after the text); this is stylistic thing I picked up when I was first learning C++ but in retrospect it is not a good style as the structure makes it harder to modify comments (with the result that comments become fewer, shorter and are less likely to be updated, which are not good things).
* Remove print statements in PointGFp::check_invariants which were triggeredlloyd2008-11-171-19/+0
| | | | | | | when the test failed. I had added them for debugging something long ago. What I thought was an InSiTo ECC test failure was actually a sucessful test, it was making sure an Illegal_Point would be thrown in the conditions tested. So, all seems OK.
* Wrap at 80 columnslloyd2008-11-111-1/+2
|
* Bubble up use of global algo factory out of DSA parameter gen to DL_Grouplloyd2008-11-112-4/+8
|
* Remove lookup.h use from DLIES, PK key agreement, DSA param gen, get_enc.cpplloyd2008-11-111-2/+6
|
* Mention existence of O(n^1.5) squaring algorithmlloyd2008-11-101-0/+3
|
* Reformat for shorter lineslloyd2008-11-071-1/+4
|
* Wrap lines to 80 columnslloyd2008-10-281-4/+5
|
* Move EntropySource base class to new entropy_src.h (which allows the ↵lloyd2008-10-261-0/+1
| | | | | | implementations to decouple from knowing about RandomNumberGenerator).
* Remove prohibition against generating DSA parameter set with a 224 bit q,lloyd2008-10-261-4/+0
| | | | since SHA-224 is now implemented.
* Clean up VC++ ia32 asm a bit, use new defs of word3_muladd* from generic ↵lloyd2008-10-151-49/+28
| | | | mp_asmi.h
* Fix include of mp_asm.h in mp_ia32_msvc/mp_asmi.h (used quotes instead of ↵lloyd2008-10-151-1/+1
| | | | brackets)
* Add trailing H__ to some header guards. Line wrap long comment.lloyd2008-10-134-25/+27
|
* Add Doxygen comments to bigint.h (from InSiTo)lloyd2008-10-131-51/+397
|
* Add a new switch to configure.pl --with-tr1-implementation whichlloyd2008-10-121-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | accepts options 'boost' and 'system'. Now GF(p) math (and indirectly, ECDSA) will be enabled if --with-tr1=boost or --with-tr1=system is passed at build time to enable a shared_ptr implementation. Modules can now specify that they require TR1, in which case they will only be autoloaded if a TR1 implementation was set (they can choose which one to use by checking the feature macros from build.h) The gfpmath module was set to load only on request. That has changed to load automatically (but will only do so if a TR1 impl is set as described above). CVC has also been marked as requiring TR1. (ECDSA/ECDH are not, since they do not use tr1 shared_ptr directly) Update and cleanup help output. Do not print the list of modules in --help anymore (too long); you can still get the list (in an easier to parse format) --module-info. Reorganize the help text so the more useful options are described closer to the top. Fix the --with-endian and --with-unaligned-mem options: they were being accepted but ignored.
* Rename the TR1 choice macros to BOTAN_USE_STD_TR1 and BOTAN_USE_BOOST_TR1.lloyd2008-10-121-3/+3
| | | | | | | | If neither is defined when build.h is included, choose Boost. Reorganize build.h so it is easier to find things, in particular move all of the interesting toggles to the top of the file and all of the long lists of modules and feature test macros to the end.
* Return const references instead of copies in GFpModulus where possiblelloyd2008-10-121-4/+4
|
* Modify CurveGFp::get_{a,b} to return a const reference instead of a copylloyd2008-10-122-5/+5
|
* Enable throwing of Illegal_Point in check_invariantslloyd2008-10-111-2/+2
|
* Disable the implementation of word_add in mp_ia32 for the same reasonlloyd2008-10-111-0/+8
| | | | | as the version in mp_amd64. Presumably they both need the same constraint added for them to work correclty.