aboutsummaryrefslogtreecommitdiffstats
path: root/src/pk_core.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Move what is left of the uncategorized library to 'core'. There is stilllloyd2008-09-291-300/+0
| | | | | a lot of public key stuff in here that needs to be extracted however, and probably 2-3 other modules worth of stuff to split off (engines, etc)
* Remove the Config class.lloyd2008-06-301-1/+0
| | | | | | | | In reality, Config was a singleton, with the only owner being the Library_State object. Theoretically one could create and use another Config instance, but in practice it was never done. Reflect the reality and inline the members and public functions of Config in Library_State, removing Config entirely.
* Remove load checking, as it requires an RNG (at least at the moment).lloyd2008-06-271-8/+14
| | | | | | | | | Probably some variation of it will be added back in later, at least to do basic checks like that primes are really odd (and we can do basic primality checks, etc, even with an RNG). Alternative: call check_key() manually on public keys you load with an RNG object.
* Split IF_Core constructor into two, one for public keys and one for private.lloyd2008-06-271-4/+11
| | | | Public version doesn't need an RNG argument.
* Pass a RandomNumberGenerator& to the PK_Core constructors and the variouslloyd2008-06-201-7/+6
| | | | public key object loading hooks.
* Remove random_integer() and replace it with a BigInt constructor taking alloyd2008-05-241-5/+9
| | | | RandomNumberGenerator reference. Update all callers.
* Pass an RNG reference to IF_Corelloyd2008-05-241-3/+3
|
* Previously random_integer and friends used the global PRNG object to getlloyd2008-05-241-3/+7
| | | | | | | | | | | | | random bits. Now they take a reference to a RandomNumberGenerator object. This was applied several times out, so now the constructors to private key objects also take a RandomNumberGenerator& argument. This is also true for a number of randomized algorithms (Miller-Rabin, for instance). You can get a reference to the global PRNG with global_state().prng_reference() This is a provisional thing: and warning: it is not thread safe! If this is a problem instead keep per-thread PRNGs and pass them were needed.
* Use existing reference to p in Elg_Core constructor for small code cleanuplloyd2008-04-121-2/+2
|
* Make the size of the random value used to blind the private keylloyd2008-04-121-15/+4
| | | | operations (to prevent timing attacks) a compile time constant.
* Remove Config::option_as_u32bit - the only advantage it had over callinglloyd2008-04-121-1/+2
| | | | | | | | | | | | | to_u32but on the return value from Config::option was that it passed it through parse_expr, which did some simple evaluation tricks so you could say 64*1024. That does not seem worth the cost in code, especially because most of the values so controlled are probably never changed. By making them compile time constants, additional optimizations are possible in the source as well as by the compiler. Remove the pkcs8_tries config option. Hardcode that value to 3 instead. I want to rewrite that code in the relatively near future and all that will (hopefully) go away.
* Change the copyrights in all files in the Botan tree to directly reflectlloyd2008-04-101-1/+1
| | | | | | 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)
* Mostly revert 2f4fd18182d5a75c40cd831e7ee3c314be5c57d6, only keep thelloyd2008-03-101-1/+1
| | | | | updated dates on files that have actually changed this year. This makes the diff across versions readable again.
* Mass update of the copyright date. Honestly I don't know why I bother,lloyd2008-02-141-1/+1
| | | | | | | 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.
* Bump copyright year to 2007lloyd2007-01-201-1/+1
|
* Access the global configuration through an object reference insteadlloyd2006-07-011-1/+3
| | | | | of stand-alone functions. Store the configuration in a distinct object, rather than just a map inside the library state.
* More config.h fixeslloyd2006-07-011-1/+1
|
* Initial checkin1.5.6lloyd2006-05-181-0/+289