libkeepass 0.2.0
KeePass key database importer/exporter library
Loading...
Searching...
No Matches
keepass::KdfRegistry Class Referencefinal

Process-wide registry for key-derivation functions. More...

#include <kdf_registry.hh>

Public Types

using Factory = std::function< SecureBuffer< 32 >(const Key &, const Database &, Key::SubKeyResolution)>
 Derives the transformed 32-byte key.
 

Public Member Functions

void Register (Database::Kdf kdf, Factory factory)
 Registers/overwrites the factory for a KDF id.
 
SecureBuffer< 32 > Transform (Database::Kdf kdf, const Key &key, const Database &db, Key::SubKeyResolution resolution) const
 Derives the transformed key, or throws UnsupportedFeatureError.
 
bool Contains (Database::Kdf kdf) const
 Returns whether a factory is registered for kdf.
 

Static Public Member Functions

static KdfRegistry & Instance ()
 Returns the process-wide registry.
 

Detailed Description

Process-wide registry for key-derivation functions.

Built-in AES-KDF/Argon2d/Argon2id factories are registered by the registry constructor. External implementations can be registered and are used by KdbxKdf::Transform for every KDBX import/export.


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