MySQL 8.3.0
Source Code Documentation
Pbkdf2 Class Reference

Key Derivation Function for PBKDF2. More...

#include <kdf_pbkdf2.h>

Public Types

enum class  Type { Sha_256 , Sha_512 }

Static Public Member Functions

static std::vector< uint8_t > salt ()
static std::vector< uint8_t > derive (Type type, unsigned long rounds, const std::vector< uint8_t > &salt, const std::string &key)

Detailed Description

Key Derivation Function for PBKDF2.

See: RFC 2898

while PBKDF2 support several hash-functions, only the most commonly used, secure variants are exposed:

  • SHA256
  • SHA512

while the insecure ones are not offered:

  • SHA1

Other HMACs of ( may be added:

  • SHA224
  • SHA384
  • SHA512-224
  • SHA512-256

Member Enumeration Documentation

◆ Type

enum class Pbkdf2::Type

Member Function Documentation

◆ derive()

std::vector< uint8_t > Pbkdf2::derive ( Pbkdf2::Type  type,
unsigned long  rounds,
const std::vector< uint8_t > &  salt,
const std::string &  key 

◆ salt()

std::vector< uint8_t > Pbkdf2::salt ( )

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