aboutsummaryrefslogtreecommitdiffstats
path: root/src/pubkey
Commit message (Collapse)AuthorAgeFilesLines
* Remove IF_Scheme_PrivateKey::PKCS8_load_hooklloyd2010-03-046-35/+30
|
* New IF constructors, simplifies RSA/RWlloyd2010-03-046-72/+67
|
* Remove DH_PrivateKey::PKCS8_load_hooklloyd2010-03-042-15/+23
|
* Remove unnecessary virtual destructors from ECC key base typeslloyd2010-03-041-4/+0
| | | | (already have them, via Public_Key's virtual destructor)
* Fix GOST pubkey encoding when x.bytes() != y.bytes()lloyd2010-03-041-1/+1
|
* Fix exception textlloyd2010-03-041-1/+1
|
* Quite the hack, here.lloyd2010-03-043-1/+11
| | | | | | | | | | | | | | | | | GOST 34.10 public keys use a funky encoding. There is no standard for PKCS #8 format private keys, so the obvious choice is to act exactly the same as ECDSA/ECDH (following the rule of thumb that if you're going to make up a random non-standard thing, at least try to copy something that's standard for something else). However the public key encoding uses a weird scheme for encoding the OID in the algorithm identifier, which we don't want to use for the PKCS #8 encoding. Add a new function to Private_Key, pkcs8_algorithm_identifier, which by default just calls algorithm_identifier(). However GOST_3410_PrivateKey overrides it, and calls EC_PublicKey::algorithm_identifier(), basically skipping over the virtual function hierarchy, so it doesn't pick up the funky format from the public key's version of algorithm_identifier().
* Fix GOST 34.10 pubkey encodinglloyd2010-03-042-3/+13
|
* Fix loading ElGamal keyslloyd2010-03-041-6/+4
|
* Remove more load hookslloyd2010-03-047-17/+10
|
* Remove load hooks from ECC classes, unusedlloyd2010-03-043-21/+16
|
* Kill pkcs8_decoderlloyd2010-03-048-158/+0
|
* Add similar decoding constructors to the private keyslloyd2010-03-0416-82/+164
|
* Remove X509_Decoder. Fix GOST-34.10 DER constructor (was default to normal ECC)lloyd2010-03-0410-173/+24
|
* Add a new constructor to each public key algorithm (only the publiclloyd2010-03-0419-114/+193
| | | | | | | keys so far, private keys not changed) that takes an AlgorithmIdentifier and a MemoryRegion<byte>&. This performs the X.509 decoding. It is not possible anymore to create uninitialized PK objects.
* The code in pk_codecs was actually entirely tied to the code inlloyd2010-03-049-10/+6
| | | | | | pubkey; you literally could not compile any pubkey code without it. Move it up to the pubkey dir, it wasn't at all useful to have it in its own dir.
* Kill pkcs8_encoderlloyd2010-03-048-124/+4
|
* Add a pkcs8_private_key similiar to x509_subject_public_keylloyd2010-03-048-27/+49
|
* Add a new function to public key x509_subject_public_key which returnslloyd2010-03-0411-140/+34
| | | | | what x509_encoder()->key_bits() used to return. This is much simpler than using the explicit encoder objects. Remove X509_Encoder entirely.
* Add a new function to Public_Key, algorithm_identifier(), which justlloyd2010-03-047-16/+35
| | | | | returns the AlgorithmIdentifier representing this scheme (OID + domain params if any).
* Unused variable warning in catch statementlloyd2010-03-031-1/+1
|
* For PEM encoding ECC domain parameters I had been using the identifierlloyd2010-03-021-2/+2
| | | | | | | | "ECC DOMAIN PARAMETERS", because I couldn't find any other library that offered PEM encoding to be compatible with so I just picked something. Turns out OpenSSL does have PEM encoding of EC params (openssl ecparam), and uses "EC PARAMETERS". As good as anything else, and allows interop, so change to use that.
* Make two variants of OS2ECP, one taking pointer + length, and otherlloyd2010-03-021-3/+1
| | | | | (inlined) taking a MemoryRegion& that just forwards. This makes it possible to avoid an extra copy in ECDH::derive_key.
* Small cleanupslloyd2010-03-024-23/+21
|
* Add some simple constructors to the EC_ base key types to simplifylloyd2010-03-028-106/+78
| | | | the various implementations
* Remove extraneous includelloyd2010-03-021-4/+0
|
* Rename ECKAEG to ECDH. As far as I can tell they are the same algorithm,lloyd2010-03-023-31/+35
| | | | | I'm not sure where the old name came from though as literally the only hits for it on Google are botan-related.
* Kill ECKAEG_Oplloyd2010-03-027-235/+32
|
* Remove ECDSA_Op and its attendant bitslloyd2010-03-026-281/+45
|
* Remove auto_ptr from ECC key typeslloyd2010-03-0211-586/+136
|
* Remove a fairly useless member of EC_PublicKey that was only used forlloyd2010-03-026-94/+3
| | | | | | | handling ImplicitCA ECDSA keys in the CVC code. Currently dealt with in CVC by simply commenting out the calls - CVC is already pretty broken and I'd much rather have ECC sane and under control and CVC totally broken than ECC remaining in its current state.
* Set PEM constructor (taking a string) to default to "". In this case,lloyd2010-03-022-6/+12
| | | | don't initialize.
* Move all of the ECC domain parameter sets to policy.cpp, encoded as PEM,lloyd2010-03-023-437/+12
| | | | instead of weird custom format hard-coded in ec_dompar.cpp
* Add EC domain contructor eating PEM. Set OID in OID constructorlloyd2010-03-012-3/+17
|
* Add EC_Domain_Params::PEM_encodelloyd2010-03-013-31/+45
|
* Kill get_EC_Dom_Pars_by_oidlloyd2010-03-013-62/+49
|
* Clean up EC_Domain_Paramslloyd2010-03-016-184/+144
|
* Use a Modular_Reducer in ECDSA op for reductions mod the order of the grouplloyd2010-02-252-18/+9
|
* Move contents of gfpmath to numbertheory. Adjust dependencies.lloyd2010-02-255-6/+1
|
* Inline GFpElementlloyd2010-02-251-3/+1
|
* Remove point_{x,y,z} funcs, hide GFpElement entirelylloyd2010-02-251-2/+0
|
* CurveGFp: Inline, deleting source file. Store only a,b,p aslloyd2010-02-251-38/+41
| | | | | BigInts. Also reorder constructor args to p, a, b which seems more sensible to me.
* Convert PointGFp::get_affine_{x,y} to return just the BigInt valuelloyd2010-02-253-14/+16
|
* Convert 3-arg constructoor of PointGFp to take BigInts instead oflloyd2010-02-251-2/+1
| | | | | | GFpElements. Clean up OS2ECP
* Remove PointGFp::mult_this_securelloyd2010-02-245-19/+13
|
* Remove debug printlloyd2010-02-241-5/+0
|
* propagate from branch 'net.randombit.botan' (head ↵lloyd2010-02-2411-30/+24
|\ | | | | | | | | | | 84baf58b29f3aaaee34e2b873d0040be5a6c4368) to branch 'net.randombit.botan.gost_3410' (head 63cbe3e357c071d7960bfedc31101eff35895285)
| * Remove unused variable in ec_dompar. Add missing include to ecc_keylloyd2010-02-232-5/+4
| |
| * Remove catch clauses made redundant by inheritence changes in exception ↵lloyd2010-01-081-5/+0
| | | | | | | | hierarchy.
| * Clean up exceptions. Remove some unused ones like Config_Error. Makelloyd2010-01-054-6/+8
| | | | | | | | | | | | | | Invalid_Argument just a typedef for std::invalid_argument. Make Botan::Exception a typedef for std::runtime_error. Make Memory_Exhaustion a public exception, and use it in other places where memory allocations can fail.