MySQL 26.10.0
Source Code Documentation
Key_hkdf_function Class Reference

Class to implement KDF method hkdf. More...

#include <my_kdf.h>

Inheritance diagram for Key_hkdf_function:
[legend]

Public Member Functions

 Key_hkdf_function (vector< string > *kdf_options)
 hkdf Constructor. More...
 
virtual ~Key_hkdf_function () override
 
int derive_key (const unsigned char *key, const unsigned int key_length, unsigned char *rkey, unsigned int key_size) override
 
int validate_options () override
 
- Public Member Functions inherited from Key_derivation_function
virtual ~Key_derivation_function ()
 

Private Attributes

string salt_
 
string info_
 

Additional Inherited Members

- Protected Attributes inherited from Key_derivation_function
vector< string > * kdf_options_ {nullptr}
 
bool options_valid_ {false}
 

Detailed Description

Class to implement KDF method hkdf.

Constructor & Destructor Documentation

◆ Key_hkdf_function()

Key_hkdf_function::Key_hkdf_function ( vector< string > *  kdf_options)

hkdf Constructor.

Parameters
kdf_optionsoptions

kdf_options has following KDF options:

  1. KDF function name
  2. KDF salt: The salt. Salts prevent attacks based on dictionaries of common passwords and attacks based on rainbow tables. It is a public value that can be safely stored along with the encryption key.
  3. KDF info: The context and application specific information.

◆ ~Key_hkdf_function()

virtual Key_hkdf_function::~Key_hkdf_function ( )
inlineoverridevirtual

Member Function Documentation

◆ derive_key()

int Key_hkdf_function::derive_key ( const unsigned char *  key,
const unsigned int  key_length,
unsigned char *  rkey,
unsigned int  key_size 
)
overridevirtual

◆ validate_options()

int Key_hkdf_function::validate_options ( )
overridevirtual

Member Data Documentation

◆ info_

string Key_hkdf_function::info_
private

◆ salt_

string Key_hkdf_function::salt_
private

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