aboutsummaryrefslogtreecommitdiffstats
path: root/modules
Commit message (Collapse)AuthorAgeFilesLines
...
* Cleaner flags: define MAP_NOSYNC to zero ifndef, always use itlloyd2008-08-271-5/+5
|
* Include mp_asm.h in mp_asmi.h in both of the assembly modules, forlloyd2008-07-192-2/+2
| | | | consistency with the C++ headers.
* If MAP_NOSYNC is defined, pass it as a flag to mmap. Apparently onlloyd2008-07-171-1/+7
| | | | | | | | | | | | FreeBSD, by default the VM will sync dirty pages periodically, even if the pages do not need to be reclaimed. Since in this case the contents of the map will contain sensitive information, try to avoid that. The FreeBSD 7.0 man page for mmap also warns that severe file fragmentation can result from using MAP_NOSYNC with sparse files, which we are currently using. It recommends instead explicitly writing out zero bytes. Since typically the full range of pages in the file will be eventually accessed and modified, this doesn't seem like a problem.
* Use NULL instead of 0 for execl terminatorlloyd2008-07-131-1/+1
|
* Remove unnecessary inclusion of botan/config.h in several moduleslloyd2008-06-305-5/+0
|
* The change in rev f6d0cb6f9569d228ed6a11d021c3f57f55220bde was actuallylloyd2008-06-261-4/+4
| | | | | | | | | | | completely wrong, and it is rather disturbing I made that mistake. The poll() function will gather up to the number of bytes passed as its argument; it will do this by opening up files and reading up to 1024 bytes from each one. So we might open between 256 and 256*1024 files, depending on the sizes of them (ignoring empty files, which count for zero bytes). (Idea: also include the name of the file in the output? Is that useful?) Move the read_buf out of the loop to minimize allocator thrashing.
* ew_ftw was reading up to 32 Mb for a fast poll and 256 Mb for a slow poll.lloyd2008-06-221-2/+2
| | | | That seems excessive. Reduce to 32 Kb and 256 Kb (resp).
* New, much cleaner (and thread safe) implementation of es_ftWlloyd2008-06-172-59/+97
|
* Remove unneeded inclusion of <fstream>lloyd2008-06-161-1/+0
|
* Move the declaration of the RandomNumberGenerator base class from base.hlloyd2008-06-103-3/+3
| | | | to rng.h (eventually base.h will be split up entirely and go away)
* propagate from branch 'net.randombit.botan' (head ↵lloyd2008-04-171-2/+0
|\ | | | | | | | | | | 85596a0b1fbee6696261d36def7dad742375f7d9) to branch 'net.randombit.botan.remove-libstate' (head faf75eec422a3eb6108748315724fb6ac217dede)
| * propagate from branch 'net.randombit.botan' (head ↵lloyd2008-04-121-2/+0
| |\ | | | | | | | | | | | | | | | bcae6a19d8d96ebde33c832c76a130ea02bc923a) to branch 'net.randombit.botan.remove-libstate' (head f640991b6e433a264f5d22a08338cfc9c24c82da)
| | * propagate from branch 'net.randombit.botan' (head ↵lloyd2008-04-101-2/+0
| | |\ | | | | | | | | | | | | | | | | | | | | 6afe2db1f710f75bc27e189bb8bdb23613ce1ca3) to branch 'net.randombit.botan.remove-libstate' (head e40f0dbdfd847024c30fa0092c2acefc19a550b8)
| | | * In Botan, the Timer base class provides access to a high-resolutionlloyd2008-04-071-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | timer with an unspecified update rate and epoch. It is only used inside the entropy sources to provide some timing-dependent randomness. However, it is easier and basically 'as good' to treat the timers as entropy sources in their own right and feed their output directly into an entropy pool. This commit removes Library_State::system_clock and all calls to that function.
* | | | Drop eng_aep module (the hardware AEP engine). I still have a card (and driverlloyd2008-04-148-815/+0
|/ / / | | | | | | | | | | | | sources, etc), but drivers for x86-64/2.6 are not in evidence these days. To test this I would probably have to get a 32-bit machine running ~RH9/2.4 kernel...
* | | Make the memory allocator's chunk size a compile time constant, via alloyd2008-04-121-1/+0
| | | | | | | | | | | | new build.h macro BOTAN_MEM_POOL_CHUNK_SIZE
* | | Fix some relatively minor linker namespace pollution issueslloyd2008-04-114-33/+29
|/ /
* | Remove severa global configuration variables related to entropy gathering,lloyd2008-04-108-35/+18
| | | | | | | | instead passing those values as arguments.
* | Remove the config option rng/ms_capi_prov_type - the CryptoAPI entropylloyd2008-04-101-8/+3
| | | | | | | | | | source will default to using the PROV_RSA_FULL provider if an empty string is passed to the constructor.
* | Fix some completely bogus code in zlib.cpp that was causing compilation ↵lloyd2008-04-101-8/+8
| | | | | | | | | | | | failures. Seemingly from a bad merge around Christmas?
* | Change the copyrights in all files in the Botan tree to directly reflectlloyd2008-04-1082-83/+96
|/ | | | | | the actual copyright holders. For rationale, see my post to botan-devel on April 9, subject 'Changing license to directly reflect contributors' (http://www.randombit.net/pipermail/botan-devel/2008-April/000527.html)
* Wrap lineslloyd2008-03-141-1/+2
|
* Update mp_asm64 module to use new signatures for word_madd{2,3} functions1.7.4lloyd2008-03-101-6/+6
|
* Mostly revert 2f4fd18182d5a75c40cd831e7ee3c314be5c57d6, only keep thelloyd2008-03-1076-76/+76
| | | | | updated dates on files that have actually changed this year. This makes the diff across versions readable again.
* Add a version of bit_ops.h with bswapl/bswapq statements. The xor_buflloyd2008-03-092-0/+91
| | | | | | | | takes advantage of unaligned reads/writes being legal for some extra performance, but should be rewritten to use SSE2 and non-termporal writes. Most of the functions in bit_ops.cpp are implemented by x86-64, just not easily accessible from C++
* Avoid closing an invalid file descriptor, even though it is basicallylloyd2008-03-091-1/+1
| | | | harmless, to avoid a valgrind warning
* Alter bigint_madd2 and bigint_madd3 to take only 3 (4, resp) arguments,lloyd2008-03-092-12/+12
| | | | | | | with the last one being both one of the input values and the output carry register, since almost always they were in fact the same variable. Also update the x86 and x86-64 modules.
* Mass update of the copyright date. Honestly I don't know why I bother,lloyd2008-02-1481-81/+81
| | | | | | | but might as well keep it up to date. And it's easier to do it once with a 'perl -pi' command than to update each file over time. Apologies to anyone looking at diffs.
* Fix compilation with GCC 3.2 - it doesn't like the :: namespace specificationlloyd2008-02-122-2/+2
| | | | for struct stat
* Mark es_dev as only running on Unix/Unix-like systems. Patch from Joel Low.lloyd2008-01-311-0/+16
| | | | | | | Has not been tested on all of the systems listed, and on many of them it won't be relevant anyway since /dev/random and company only exist on some of them (Linux, BSDs, recent Solaris, and it looks like recent AIX and HP-UX as well).
* Qualify (some) calls to functions in the global namespace using anlloyd2007-12-249-80/+78
| | | | | | explicit :: (it is unfortunate that there is no good way to detect all of such calls in an automated manner). Also use new-style casts in parts of the zlib code.
* Add a new module, es_dev, that will replace es_file. Instead of using C++lloyd2007-11-173-0/+153
| | | | | iostreams, it uses unbuffered Unix I/O syscalls and is careful to avoid blocking for more than short amounts of time.
* Revert the change that renamed append() to push_back(). As pointed outlloyd2007-11-151-1/+1
| | | | | | by Joel Low on the mailing list, the STL container types have only a single version of push_back(), along with variations of insert() for handling range-based appending.
* Rename MemoryRegion::append to push_backlloyd2007-11-141-1/+1
| | | | Change all callers in the library and self-test code.
* Remove amd64 support from the mp_asm64 module. Use mp_amd64 instead.lloyd2007-11-112-10/+1
|
* Change the syntax from load_on: to load_on (since that way configure.pl canlloyd2007-10-2227-28/+40
| | | | | | | | | | | use the generic variable reading routines). Instead of hardcoding the module sets (historically, 'unix', 'beos', and 'win32') into the script, have each module specify which group(s) (if any) it should be considered a member of in its modinfo.txt file. Add a new module set compression which contains (currently) the zlib and bzip2 modules.
* Remove several uses of old style C casts in favor of C++98's static_cast and lloyd2007-10-192-3/+3
| | | | reinterpret_cast
* Fix the alg_ia32 module code WRT the recent changes to loadstor.h not beinglloyd2007-10-194-4/+4
| | | | included by bit_ops.h
* bit_ops.h no longer includes loadstor.hlloyd2007-10-191-1/+1
| | | | | | | | | Where loadstor.h was needed but only implicitly included via bit_ops.h, include it directly Add endian reversal functions to bit_ops.h Remove some unneeded includes in big_ops2.cpp and a few other files.
* Don't hard code any directories to search for programs into es_unix.lloyd2007-10-191-6/+1
| | | | | | | All are now specified through the config. The new default is just /bin, /sbin, /usr/bin, and /usr/sbin. Formerly /usr/ucb, /usr/etc, and /etc were also searched. If you want this behavior again you have to explicitly set the rng/unix_path configuration setting.
* Add stats of '/', '/tmp', '.', and '..' to the es_unix fast poll.lloyd2007-10-191-1/+12
| | | | Use u32bit instead of uint32_t
* New implementation of fast polling in es_unix. Instead of executinglloyd2007-10-192-41/+44
| | | | | | programs, the fast poll will just call a handful of simple Unix/POSIX functions like getpid, getuid, getrusage, etc. Identifying further useful sources would probably be helpful.
* Update the copyright notice to include 2007lloyd2007-09-132-2/+2
|
* Avoid some C-style casts in the moduleslloyd2007-07-234-4/+4
|
* Add QueryPerformanceCounter to the Win32 fast entropy poll, as it can'tlloyd2007-05-181-0/+4
| | | | hurt and might help. From Yves Jerschow.
* propagate from branch 'net.randombit.botan.stable' (head ↵lloyd2007-04-011-0/+1
|\ | | | | | | | | | | 63c067b5454498ee48466101aedb54613615a983) to branch 'net.randombit.botan' (head 2444e9d08f77852cf2df58c34ca38145c2f416ba)
| * Need to include stdlib.h for exit() call, reported through the Debianlloyd2007-04-011-0/+1
| | | | | | | | folks (I think this was also required under QNX, actually).
* | Check in an initial assembler implementation of SHA-1 for x86-64 systems.lloyd2007-03-124-9/+321
| | | | | | | | | | It is not amazingly optimized, about 5% faster than what GCC 4.1.1 does on my Core2 with the normal C++ code, but it's a start.
* | Insert a note so the toolchain knows that we are not using an executablelloyd2007-03-121-0/+4
| | | | | | | | | | | | | | | | | | stack. At least SuSE and Gentoo are using a patch for this in their trees, probably others are as well. I still have not had a chance to check the portability aspects of this, especially on Solaris (the only ELF-based x86/amd64 operating system that I know of that does not use the GNU toolchain).
* | Provide a more flexible mechanism for specifying which modules are loaded.lloyd2007-03-1227-18/+58
| | | | | | | | | | | | | | | | | | | | | | | | | | Now three classes are defined: 'request', 'auto', and 'asm_ok'. The 'auto' class is loaded automatically if the platform support matches up with what we are building for (this is the former default). The 'request' mode means it is only loaded if specifically requested by name. The 'asm_ok' module is marked for all modules that use any assembler (including inline assembler). This normally functions like 'auto', unless --debug is passed to configure, in which case it is treated as 'request'. Modules which do not specify a load behavior are given a default of 'request'.