diff options
author | lloyd <[email protected]> | 2010-03-05 06:47:02 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2010-03-05 06:47:02 +0000 |
commit | 1b68d7e53c4bc5e6b2938194b0f7eda78a72ce43 (patch) | |
tree | da1b0482d875a48fe95e133346aee4baabcbf7cb /src/pubkey/dsa | |
parent | d4ef447dc8b3b4f40f2ab250b1c364e2f74ccfa4 (diff) |
Remove the sign() operation from the public key objects, totally replaced
by using the ops.
Add real ECDSA test vectors (two found in ANSI X9.62)
Diffstat (limited to 'src/pubkey/dsa')
-rw-r--r-- | src/pubkey/dsa/dsa.cpp | 18 | ||||
-rw-r--r-- | src/pubkey/dsa/dsa.h | 3 |
2 files changed, 0 insertions, 21 deletions
diff --git a/src/pubkey/dsa/dsa.cpp b/src/pubkey/dsa/dsa.cpp index 403243a97..628841fba 100644 --- a/src/pubkey/dsa/dsa.cpp +++ b/src/pubkey/dsa/dsa.cpp @@ -66,24 +66,6 @@ DSA_PrivateKey::DSA_PrivateKey(const AlgorithmIdentifier& alg_id, } /* -* DSA Signature Operation -*/ -SecureVector<byte> DSA_PrivateKey::sign(const byte in[], u32bit length, - RandomNumberGenerator& rng) const - { - const BigInt& q = group_q(); - - rng.add_entropy(in, length); - - BigInt k; - do - k.randomize(rng, q.bits()); - while(k >= q); - - return core.sign(in, length, k); - } - -/* * Check Private DSA Parameters */ bool DSA_PrivateKey::check_key(RandomNumberGenerator& rng, bool strong) const diff --git a/src/pubkey/dsa/dsa.h b/src/pubkey/dsa/dsa.h index 444b3a825..e0aab1b52 100644 --- a/src/pubkey/dsa/dsa.h +++ b/src/pubkey/dsa/dsa.h @@ -63,9 +63,6 @@ class BOTAN_DLL DSA_PrivateKey : public DSA_PublicKey, const BigInt& private_key = 0); bool check_key(RandomNumberGenerator& rng, bool strong) const; - - SecureVector<byte> sign(const byte hash[], u32bit hash_len, - RandomNumberGenerator& rng) const; }; class BOTAN_DLL DSA_Signature_Operation : public PK_Ops::Signature_Operation |