Botan  2.7.0
Crypto and TLS for C++11
Public Member Functions | Protected Member Functions | List of all members
Botan::PK_Ops::Key_Agreement_with_KDF Class Referenceabstract

#include <pk_ops_impl.h>

Inheritance diagram for Botan::PK_Ops::Key_Agreement_with_KDF:

Public Member Functions

secure_vector< uint8_t > agree (size_t key_len, const uint8_t other_key[], size_t other_key_len, const uint8_t salt[], size_t salt_len) override

Protected Member Functions

 Key_Agreement_with_KDF (const std::string &kdf)
 ~Key_Agreement_with_KDF ()=default

Detailed Description

Definition at line 172 of file pk_ops_impl.h.

Constructor & Destructor Documentation

◆ Key_Agreement_with_KDF()

Botan::PK_Ops::Key_Agreement_with_KDF::Key_Agreement_with_KDF ( const std::string &  kdf)

Definition at line 50 of file pk_ops.cpp.

References Botan::get_kdf().

51  {
52  if(kdf != "Raw")
53  m_kdf.reset(get_kdf(kdf));
54  }
KDF * get_kdf(const std::string &algo_spec)
Definition: kdf.cpp:237

◆ ~Key_Agreement_with_KDF()

Botan::PK_Ops::Key_Agreement_with_KDF::~Key_Agreement_with_KDF ( )

Member Function Documentation

◆ agree()

secure_vector< uint8_t > Botan::PK_Ops::Key_Agreement_with_KDF::agree ( size_t  key_len,
const uint8_t  other_key[],
size_t  other_key_len,
const uint8_t  salt[],
size_t  salt_len 

Implements Botan::PK_Ops::Key_Agreement.

Definition at line 56 of file pk_ops.cpp.

References salt_len.

59  {
60  secure_vector<uint8_t> z = raw_agree(w, w_len);
61  if(m_kdf)
62  return m_kdf->derive_key(key_len, z, salt, salt_len);
63  return z;
64  }
size_t salt_len
Definition: x509_obj.cpp:26

The documentation for this class was generated from the following files: