CCF
Loading...
Searching...
No Matches
Namespaces | Functions
ccf::cose::edit Namespace Reference

Namespaces

namespace  desc
 
namespace  pos
 

Functions

std::vector< uint8_t > set_unprotected_header (const std::span< const uint8_t > &cose_input, const desc::Type &descriptor)
 

Function Documentation

◆ set_unprotected_header()

std::vector< uint8_t > ccf::cose::edit::set_unprotected_header ( const std::span< const uint8_t > &  cose_input,
const desc::Type descriptor 
)

Set the unprotected header of a COSE_Sign1 message, according to a descriptor.

Useful to add a proof to a signature to turn it into a receipt, to add a receipt to a signed statement to turn it into a transparent statement, or simply to strip the unprotected header from a COSE Sign1.

Parameters
cose_inputThe COSE_Sign1 message to edit.
descriptorAn object describing whether and how to set the unprotected header.