Signet Forge 0.1.0
C++20 Parquet library with AI-native extensions
DEMO
Loading...
Searching...
No Matches
signet::forge::crypto::IKmsClient Class Referenceabstract

Abstract KMS client interface for DEK/KEK key wrapping. More...

#include <key_metadata.hpp>

Inheritance diagram for signet::forge::crypto::IKmsClient:
signet::forge::crypto::HsmClientStub

Public Member Functions

virtual ~IKmsClient ()=default
 
virtual expected< std::vector< uint8_t > > wrap_key (const std::vector< uint8_t > &dek, const std::string &master_key_id) const =0
 Wrap (encrypt) a DEK under the KEK identified by master_key_id.
 
virtual expected< std::vector< uint8_t > > unwrap_key (const std::vector< uint8_t > &wrapped_dek, const std::string &master_key_id) const =0
 Unwrap (decrypt) a wrapped DEK using the KEK identified by master_key_id.
 

Detailed Description

Abstract KMS client interface for DEK/KEK key wrapping.

Subclass this to integrate with a specific KMS provider. The interface is intentionally minimal — only wrap and unwrap.

Definition at line 97 of file key_metadata.hpp.

Constructor & Destructor Documentation

◆ ~IKmsClient()

virtual signet::forge::crypto::IKmsClient::~IKmsClient ( )
virtualdefault

Member Function Documentation

◆ unwrap_key()

virtual expected< std::vector< uint8_t > > signet::forge::crypto::IKmsClient::unwrap_key ( const std::vector< uint8_t > &  wrapped_dek,
const std::string &  master_key_id 
) const
pure virtual

Unwrap (decrypt) a wrapped DEK using the KEK identified by master_key_id.

Parameters
wrapped_dekWrapped DEK bytes (as returned by wrap_key).
master_key_idKMS identifier for the Key Encryption Key (KEK).
Returns
Unwrapped (plaintext) DEK bytes, or error on KMS failure / auth failure.

Implemented in signet::forge::crypto::HsmClientStub.

◆ wrap_key()

virtual expected< std::vector< uint8_t > > signet::forge::crypto::IKmsClient::wrap_key ( const std::vector< uint8_t > &  dek,
const std::string &  master_key_id 
) const
pure virtual

Wrap (encrypt) a DEK under the KEK identified by master_key_id.

Parameters
dekRaw Data Encryption Key bytes (typically 32 bytes for AES-256).
master_key_idKMS identifier for the Key Encryption Key (KEK).
Returns
Wrapped (encrypted) DEK bytes, or error on KMS failure.

Implemented in signet::forge::crypto::HsmClientStub.


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