libdcp
Public Member Functions | Private Member Functions | Private Attributes | Friends | List of all members
dcp::EncryptedKDM Class Reference

An encrypted KDM. More...

#include <encrypted_kdm.h>

Public Member Functions

 EncryptedKDM (std::string)
 
 EncryptedKDM (EncryptedKDM const &kdm)
 
EncryptedKDMoperator= (EncryptedKDM const &)
 
void as_xml (boost::filesystem::path file) const
 
std::string as_xml () const
 
std::vector< std::string > keys () const
 
std::string id () const
 
boost::optional< std::string > annotation_text () const
 
std::string content_title_text () const
 
std::string issue_date () const
 
std::string cpl_id () const
 
LocalTime not_valid_before () const
 
LocalTime not_valid_after () const
 
std::string recipient_x509_subject_name () const
 
CertificateChain signer_certificate_chain () const
 

Private Member Functions

 EncryptedKDM (std::shared_ptr< const CertificateChain > signer, Certificate recipient, std::vector< std::string > trusted_devices, std::string cpl_id, std::string cpl_content_title_text, boost::optional< std::string > annotation_text, LocalTime not_valid_before, LocalTime not_valid_after, Formulation formulation, bool disable_forensic_marking_picture, boost::optional< int > disable_forensic_marking_audio, std::vector< std::pair< std::string, std::string >> key_ids, std::vector< std::string > keys)
 

Private Attributes

data::EncryptedKDMData * _data = nullptr
 

Friends

class DecryptedKDM
 

Detailed Description

An encrypted KDM.

This is a KDM whose keys are encrypted using the target projector's private key. An EncryptedKDM object can be initialised from a KDM XML file, or created from a DecryptedKDM (using DecryptedKDM::encrypt).

Definition at line 75 of file encrypted_kdm.h.

Constructor & Destructor Documentation

◆ EncryptedKDM()

dcp::EncryptedKDM::EncryptedKDM ( std::shared_ptr< const CertificateChain signer,
Certificate  recipient,
std::vector< std::string >  trusted_devices,
std::string  cpl_id,
std::string  cpl_content_title_text,
boost::optional< std::string >  annotation_text,
LocalTime  not_valid_before,
LocalTime  not_valid_after,
Formulation  formulation,
bool  disable_forensic_marking_picture,
boost::optional< int >  disable_forensic_marking_audio,
std::vector< std::pair< std::string, std::string >>  key_ids,
std::vector< std::string >  keys 
)
private

Construct an EncryptedKDM from a set of details

Member Function Documentation

◆ as_xml() [1/2]

string EncryptedKDM::as_xml ( ) const
Returns
This KDM as XML

Definition at line 749 of file encrypted_kdm.cc.

◆ as_xml() [2/2]

void EncryptedKDM::as_xml ( boost::filesystem::path  file) const

Write this KDM as XML to a file.

Parameters
fileFile to write to.

Definition at line 733 of file encrypted_kdm.cc.

◆ keys()

vector< string > EncryptedKDM::keys ( ) const
Returns
The base64-encoded and encrypted keys that this KDM delivers. Note that the returned ‘keys’ contain more than just the asset decryption keys (also key id, CPL id etc.)

Definition at line 756 of file encrypted_kdm.cc.


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