SSP21-CPP
Classes | Static Public Member Functions | List of all members
ssp21::Chain Class Referencefinal

#include <ssp21/crypto/Chain.h>

Static Public Member Functions

static HandshakeError verify (const CertificateBody &anchor, const ICollection< CertificateEnvelope > &certificates, CertificateBody &result)
 
static HandshakeError verify_pair (const CertificateBody &parent, const CertificateEnvelope &child, CertificateBody &child_body)
 

Detailed Description

Operations for verifying certificate chains

Definition at line 17 of file Chain.h.

Member Function Documentation

◆ verify()

static HandshakeError ssp21::Chain::verify ( const CertificateBody anchor,
const ICollection< CertificateEnvelope > &  certificates,
CertificateBody result 
)
static

Verify a certificate chain

Parameters
anchorcertificate to verify against
certificatesChain of unparsed certificate envelopes
resultverified terminal certificate if return value is HandshakeError::none
Returns
Verification error or HandshakeError::none for success

◆ verify_pair()

static HandshakeError ssp21::Chain::verify_pair ( const CertificateBody parent,
const CertificateEnvelope child,
CertificateBody child_body 
)
static

Using the previously verified parent certifivate, verify the next untrusted child certificate

Parameters
parenttrusted parent certificate body
childcertificate to be verified
child_bodyif verification is successful, the fully parsed child certificate body is output in this parameter
Returns
An error condition. HandshakeError::none, if the verification was successful