aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/pubkey/dsa/dsa.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/pubkey/dsa/dsa.cpp')
-rw-r--r--src/lib/pubkey/dsa/dsa.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/lib/pubkey/dsa/dsa.cpp b/src/lib/pubkey/dsa/dsa.cpp
index f6c5989db..c419eec97 100644
--- a/src/lib/pubkey/dsa/dsa.cpp
+++ b/src/lib/pubkey/dsa/dsa.cpp
@@ -50,7 +50,7 @@ DSA_PrivateKey::DSA_PrivateKey(RandomNumberGenerator& rng,
}
DSA_PrivateKey::DSA_PrivateKey(const AlgorithmIdentifier& alg_id,
- const secure_vector<byte>& key_bits) :
+ const secure_vector<uint8_t>& key_bits) :
DL_Scheme_PrivateKey(alg_id, key_bits, DL_Group::ANSI_X9_57)
{
m_y = power_mod(group_g(), m_x, group_p());
@@ -90,7 +90,7 @@ class DSA_Signature_Operation : public PK_Ops::Signature_with_EMSA
size_t max_input_bits() const override { return m_q.bits(); }
- secure_vector<byte> raw_sign(const byte msg[], size_t msg_len,
+ secure_vector<uint8_t> raw_sign(const uint8_t msg[], size_t msg_len,
RandomNumberGenerator& rng) override;
private:
const BigInt& m_q;
@@ -100,8 +100,8 @@ class DSA_Signature_Operation : public PK_Ops::Signature_with_EMSA
std::string m_emsa;
};
-secure_vector<byte>
-DSA_Signature_Operation::raw_sign(const byte msg[], size_t msg_len,
+secure_vector<uint8_t>
+DSA_Signature_Operation::raw_sign(const uint8_t msg[], size_t msg_len,
RandomNumberGenerator& rng)
{
BigInt i(msg, msg_len);
@@ -154,8 +154,8 @@ class DSA_Verification_Operation : public PK_Ops::Verification_with_EMSA
bool with_recovery() const override { return false; }
- bool verify(const byte msg[], size_t msg_len,
- const byte sig[], size_t sig_len) override;
+ bool verify(const uint8_t msg[], size_t msg_len,
+ const uint8_t sig[], size_t sig_len) override;
private:
const BigInt& m_q;
const BigInt& m_y;
@@ -164,8 +164,8 @@ class DSA_Verification_Operation : public PK_Ops::Verification_with_EMSA
Modular_Reducer m_mod_p, m_mod_q;
};
-bool DSA_Verification_Operation::verify(const byte msg[], size_t msg_len,
- const byte sig[], size_t sig_len)
+bool DSA_Verification_Operation::verify(const uint8_t msg[], size_t msg_len,
+ const uint8_t sig[], size_t sig_len)
{
if(sig_len != 2*m_q.bytes() || msg_len > m_q.bytes())
return false;