aboutsummaryrefslogtreecommitdiffstats
path: root/src/utils
Commit message (Collapse)AuthorAgeFilesLines
* Move std::vector operator^= to xor_buflloyd2013-03-151-0/+12
| | | | Some prep work for parallel encrypt
* Move assert.h from internal to very public (included in types.h)lloyd2013-03-135-8/+9
| | | | | | This reduces friction to writing an assert, so hopefully there will be more of them as a result. And we can use asserts in public headers now, very useful for templates.
* src/utils/semaphore.h was marked both public and internal, which brokelloyd2013-03-091-1/+0
| | | | | the amalgamation build. Add a check that warns if we do this again, and some more logging in the amalgamation generator.
* Set the release type (unreleased, released, snapshot) inlloyd2013-03-041-8/+11
| | | | | botan_version.py via the release script, and propagate it to version.cpp via build.h
* Add BOTAN_ASSERT_IMPLICATION macrolloyd2013-03-011-0/+13
|
* Add Threaded_Fork, which acts like a normal Fork filter except thatlloyd2013-02-023-1/+77
| | | | | | | | | | each subchain of filters will run in its own thread. Written and contributed by Joel Low. A thread on botan-devel contains the original patch and some discussion: http://lists.randombit.net/pipermail/botan-devel/2013-January/001699.html
* Move memory zeroing to a compiled function in a new source file. Castlloyd2012-11-123-11/+38
| | | | | | | | the pointer to volatile before writing to it. At least for various versions of GCC, Clang, and ICC on x86-64, this does cause the compiler to emit a simple byte-at-a-time loop, and at least in non-LTO builds the compiler won't optimize the call away. For dealing with LTO, probably would have to do some kind of complicated side-effect.
* Move to_u32bit to source file. Add map_remove_if helperlloyd2012-11-023-2/+19
|
* Add parens to BOTAN_ASSERT_EQUALS, otherwise low precedence ops couldlloyd2012-10-131-3/+3
| | | | cause problems.
* Build the return value of version_string at compile time instead of atlloyd2012-09-141-16/+17
| | | | runtime so it's easy to find in a binary with strings.
* This should be inlinelloyd2012-09-071-1/+1
|
* Add support for key material exportlloyd2012-09-071-0/+7
|
* Remove BigInt(NumberType type, size_t n) and replace it with a staticlloyd2012-08-011-1/+1
| | | | BigInt function power_of_2. (Power2 was the only available NumberType)
* Doxygen warning fixeslloyd2012-07-091-1/+2
|
* The messages for assertion checks were done both ways, both "assertionlloyd2012-07-091-3/+5
| | | | | | X is true" and "assertion X is false". Convert all of them to the form "assertion X is true" thus making it clear what it is that we are attempting to assert by testing the expression provided.
* Remove BOTAN_ASSERT_FUNCTION, use __func__ which is now standard in C++11lloyd2012-07-092-41/+35
|
* Add TLS::Session_Manager_Noop which just ignores all save requests.lloyd2012-06-293-3/+3
| | | | | | | Rename the sqlite module to sqlite3 as sometimes plain 'sqlite' is used to refer to sqlite2. Reduce the password check bits to 16 which is plenty.
* Add support (decoding only) for the CRL Distribution Point extension.lloyd2012-06-132-2/+19
|
* Allow x86-32 asm with clang. Compiles fine, though I cannot test as Illoyd2012-06-121-0/+1
| | | | only have a 64-bit libc++.
* Update what() signature on exception typeslloyd2012-06-121-1/+1
|
* Make a proper wrapper in util for SQLite3, update the TLS sessionlloyd2012-06-083-0/+220
| | | | manager to use it. Add --with-sqlite to configure.py
* Plain hex_decode now returns a std::vector, use hex_decode_locked tolloyd2012-05-261-1/+1
| | | | get a secure_vector.
* Properly align return values of mlock_allocator. Be more careful aboutlloyd2012-05-223-93/+0
| | | | | | | | | | | pointer checks as a sufficiently smart compiler might optimize way pointer comparisons otherwise. Avoid using an iterator value after we have released it from the map. Reduce the default buffer size to 1K to reduce pressure on mlock memory. Drop the old mlock wrapper code.
* Replace 0 and NULL pointer constants with nullptr. Also fix an oldlloyd2012-05-181-2/+2
| | | | style cast in secmem.h
* Fairly huge update that replaces the old secmem types with std::vectorlloyd2012-05-183-7/+39
| | | | | | using a custom allocator. Currently our allocator just does new/delete with a memset before deletion, and the mmap and mlock allocators have been removed.
* propagate from branch 'net.randombit.botan' (head ↵lloyd2012-05-181-1/+1
|\ | | | | | | | | | | 6332543aa5a8a4cc13662008ff9ac0f0016d9a4d) to branch 'net.randombit.botan.cxx11' (head 5517c9f8f6d1990f269afb94f569a97a80c5a5f4)
| * We were checking the wrong bit for rdrand support. Found using SDE'slloyd2012-05-101-1/+1
| | | | | | | | | | | | | | | | -ivb_rdrnd_cpuid option to toggle the bit off and on. Fortunately on Intel processors the bit we were actually checking is also enabled by Ivy Bridge. However it is also used on AMD Bulldozer processors to signal half-precision floating point support so we could false positive there.
* | propagate from branch 'net.randombit.botan.tls-state-machine' (head ↵lloyd2012-04-251-0/+3
|\ \ | | | | | | | | | | | | | | | a4741cd07f50a9e1b29b0dd97c6fb8697c038ade) to branch 'net.randombit.botan.cxx11' (head 116e5ff139c07000be431e07d3472cc8f3919b91)
| * | propagate from branch 'net.randombit.botan' (head ↵lloyd2012-04-201-0/+3
| |\| | | | | | | | | | | | | | | | 50fa70d871f837c3c3338fabf5fb45649669aabf) to branch 'net.randombit.botan.tls-state-machine' (head 2358daac57db0411e62da2ef5a484468cb9307b7)
| | * Avoid a few maintainer mode flag warnings. Remove -Weffc++ from thelloyd2012-04-201-0/+3
| | | | | | | | | | | | | | | list of maintainer mode flags. It produces some very useful warnings, but also a lot of noisy junk that I really don't care about.
* | | Don't need this function anymorelloyd2012-02-201-12/+0
| | |
* | | Remove get_nanoseconds_clock as we'll rely on std::chrono's highlloyd2012-02-203-66/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | resolution clock for this in C++11. Now that the only remaining function in time.h is calendar_point, rename the header to calendar.h. Hopefully that last use will go away once a TR2 datetime library becomes available. Use std::chrono inside the library benchmark code.
* | | Merge fixups. Add locking to default session manager. Use chrono liblloyd2012-02-201-0/+1
| | | | | | | | | | | | and unique_ptr.
* | | propagate from branch 'net.randombit.botan.tls-state-machine' (head ↵lloyd2012-02-2013-255/+69
|\ \ \ | |/ / |/| | | | | | | | | | | 0ceb9cde62a2b3614901ae85a53546d9fc641326) to branch 'net.randombit.botan.cxx11' (head 777e65950ef3706a82e5df20dcca7fcc999ca533)
| * | propagate from branch 'net.randombit.botan' (head ↵lloyd2011-12-182-5/+34
| |\| | | | | | | | | | | | | | | | 39f53266912f33dc48e942b1b865ddcd6af66d8d) to branch 'net.randombit.botan.cxx11' (head 0bf26cec09f71e75c547b4ec53365748c6d80d86)
| * | propagate from branch 'net.randombit.botan' (head ↵lloyd2011-11-101-0/+2
| |\ \ | | | | | | | | | | | | | | | | | | | | f13cb517b63aed4fcc4ad7013e5c905fae85796b) to branch 'net.randombit.botan.cxx11' (head e330c6b33c4583b342a129336d27ce03c9e4e287)
| * \ \ propagate from branch 'net.randombit.botan' (head ↵lloyd2011-07-1213-255/+69
| |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | 23a326fa36a31dd39347a8864e1f5740669a905e) to branch 'net.randombit.botan.cxx11' (head 9d3ac8dd45f7673c85dca41968e7750acc90bdff)
| | * | | long long is standard nowlloyd2011-06-171-9/+1
| | | | |
| | * | | Add string_join; inverse of split_on.lloyd2011-06-173-2/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Use auto in a few more places. Use GCC 4.6's range-for Delete rather than hide Algorithm copy constructor/assignment Move version to more or less randomly chosen 1.99 so there is no ambiguity about versions.
| | * | | propagate from branch 'net.randombit.botan' (head ↵lloyd2011-06-1712-245/+41
| | |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 5dc30d88afdeec4896b5065f9260e66d52b1a730) to branch 'net.randombit.botan.cxx11' (head 8d42792537db92fab3136f5696ee1eba3e73fa76)
| | | * \ \ propagate from branch 'net.randombit.botan' (head ↵lloyd2011-06-1312-245/+41
| | | |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 150bd11dd8090559ee1e83394b8283bf93a018de) to branch 'net.randombit.botan.c++0x' (head 7480693bb3f1e8a4e039a3e7ba3d9a7007f9730e)
| | | | * \ \ propagate from branch 'net.randombit.botan' (head ↵lloyd2011-02-1112-245/+41
| | | | |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 13a0d36dac3709f3cb88e830ed7f8cab9e7433ab) to branch 'net.randombit.botan.c++0x' (head 2221ad8796466e7e096645de77ba856a9c902d14)
| | | | | * \ \ propagate from branch 'net.randombit.botan' (head ↵lloyd2010-11-292-9/+19
| | | | | |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | fc8daa606ab7954eab48778d7236986747b719e4) to branch 'net.randombit.botan.c++0x' (head 2bf71b0a2e0e468d7eb3631e4ca284234f554729)
| | | | | * \ \ \ propagate from branch 'net.randombit.botan' (head ↵lloyd2010-11-0413-249/+44
| | | | | |\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 303b2518a80553214b1e5ab4d9b96ef54629cbc7) to branch 'net.randombit.botan.c++0x' (head d734eefabe4816be4dd3e3e6e7bb13b7ab5be148)
| | | | | | * \ \ \ propagate from branch 'net.randombit.botan' (head ↵lloyd2010-10-282-25/+25
| | | | | | |\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2841fb518e20d2fe0a374e4f6b08bdbb14d5d158) to branch 'net.randombit.botan.c++0x' (head 0b9275139d6346bd3aa28d63bf8b8a03851d853d)
| | | | | | * \ \ \ \ propagate from branch 'net.randombit.botan' (head ↵lloyd2010-10-132-7/+7
| | | | | | |\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | cba32f885eb7889a9711cbee120df42839deb9d0) to branch 'net.randombit.botan.c++0x' (head 7cb9cdfda0f3dedab24f1d3bc7e7ea9b22164234)
| | | | | | * \ \ \ \ \ propagate from branch 'net.randombit.botan' (head ↵lloyd2010-10-131-5/+8
| | | | | | |\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 6581b789d58717bc6acee5c6a248e2d44c636e40) to branch 'net.randombit.botan.c++0x' (head 227a989ae94da8f4379ea4b9b0fc0ee8dbdde0c7)
| | | | | | * | | | | | | Post-merge fixupslloyd2010-10-131-9/+2
| | | | | | | | | | | | |
| | | | | | * | | | | | | propagate from branch 'net.randombit.botan' (head ↵lloyd2010-10-1312-238/+34
| | | | | | |\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2898d79f992f27a328a3e41d34b46eb1052da0de) to branch 'net.randombit.botan.c++0x' (head 6cba76268fd69a73195760c021b7f881b8a6552c)
| | | | | | | * \ \ \ \ \ \ propagate from branch 'net.randombit.botan' (head ↵lloyd2010-09-072-2/+7
| | | | | | | |\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | fb78974f57bc3065d8537ebeb5210c86e74e9bb1) to branch 'net.randombit.botan.c++0x' (head dcb30c0029c7e44a75d0d8b859447a6c9df97cde)