uthenticode  2.0.1-19005f0
Public Member Functions | List of all members
uthenticode::SignedData Class Reference

#include <uthenticode.h>

Public Member Functions

 SignedData (std::vector< std::uint8_t > cert_buf)
 
 SignedData (SignedData &&s) noexcept
 
 SignedData (const SignedData &)=delete
 
 ~SignedData ()
 
bool verify_signature () const
 
Checksum get_checksum () const
 
std::vector< Certificateget_signers () const
 
std::vector< Certificateget_certificates () const
 
std::optional< SignedDataget_nested_signed_data () const
 
std::vector< std::uint8_t > const & get_raw_data () const
 

Detailed Description

Encapsulates an Authenticode PKCS#7 SignedData blob.

Constructor & Destructor Documentation

◆ SignedData() [1/3]

uthenticode::SignedData::SignedData ( std::vector< std::uint8_t >  cert_buf)

Create a SignedData from the given raw buffer.

Exceptions
FormatErrorif the buffer is not a Authenticode PKCS#7 SignedData

◆ SignedData() [2/3]

uthenticode::SignedData::SignedData ( SignedData &&  s)
noexcept

◆ SignedData() [3/3]

uthenticode::SignedData::SignedData ( const SignedData )
delete

◆ ~SignedData()

uthenticode::SignedData::~SignedData ( )

Member Function Documentation

◆ get_certificates()

std::vector< Certificate > uthenticode::SignedData::get_certificates ( ) const

Returns the list of verification certificates in this SignedData.

Returns
a list of Certificate instances

◆ get_checksum()

Checksum uthenticode::SignedData::get_checksum ( ) const

Returns the kind of checksum in this SignedData and its contents.

Returns
a Checksum tuple

◆ get_nested_signed_data()

std::optional< SignedData > uthenticode::SignedData::get_nested_signed_data ( ) const
Returns
a new SignedData for any nested signature within this SignedData, or std::nullopt if this SignedData has no nested signature.

◆ get_raw_data()

std::vector< std::uint8_t > const & uthenticode::SignedData::get_raw_data ( ) const
Returns
a const-reference to the certificate buffer.

◆ get_signers()

std::vector< Certificate > uthenticode::SignedData::get_signers ( ) const

Returns the list of signer certificates in this SignedData.

Returns
a list of Certificate instances

◆ verify_signature()

bool uthenticode::SignedData::verify_signature ( ) const

Verifies the Authenticode signature.

Returns
true if valid, false otherwise

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