diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/lib/kdf/kdf1_iso18033/kdf1_iso18033.cpp | 4 | ||||
-rw-r--r-- | src/lib/kdf/kdf1_iso18033/kdf1_iso18033.h | 3 |
2 files changed, 5 insertions, 2 deletions
diff --git a/src/lib/kdf/kdf1_iso18033/kdf1_iso18033.cpp b/src/lib/kdf/kdf1_iso18033/kdf1_iso18033.cpp index 3ff717993..b40fe55cc 100644 --- a/src/lib/kdf/kdf1_iso18033/kdf1_iso18033.cpp +++ b/src/lib/kdf/kdf1_iso18033/kdf1_iso18033.cpp @@ -11,7 +11,8 @@ namespace Botan { size_t KDF1_18033::kdf(byte key[], size_t key_len, const byte secret[], size_t secret_len, - const byte salt[], size_t salt_len) const + const byte salt[], size_t salt_len, + const byte label[], size_t label_len) const { u32bit counter = 0; secure_vector<byte> h; @@ -21,6 +22,7 @@ size_t KDF1_18033::kdf(byte key[], size_t key_len, { m_hash->update(secret, secret_len); m_hash->update_be(counter++); + m_hash->update(label, label_len); m_hash->update(salt, salt_len); m_hash->final(h); diff --git a/src/lib/kdf/kdf1_iso18033/kdf1_iso18033.h b/src/lib/kdf/kdf1_iso18033/kdf1_iso18033.h index 6ec7ead8e..d6ce851ae 100644 --- a/src/lib/kdf/kdf1_iso18033/kdf1_iso18033.h +++ b/src/lib/kdf/kdf1_iso18033/kdf1_iso18033.h @@ -25,7 +25,8 @@ class BOTAN_DLL KDF1_18033 : public KDF size_t kdf(byte key[], size_t key_len, const byte secret[], size_t secret_len, - const byte salt[], size_t salt_len) const override; + const byte salt[], size_t salt_len, + const byte label[], size_t label_len) const override; KDF1_18033(HashFunction* h) : m_hash(h) {} private: |