- boost::filesystem::path p = dcp::make_certificate_chain (openssl_path ());
- _decryption_certificate = dcp::Certificate (dcp::file_to_string (p / "leaf.signed.pem"));
- _decryption_private_key = dcp::file_to_string (p / "leaf.key");
- boost::filesystem::remove_all (p);
+ dcp::CertificateChain c (openssl_path ());
+ _decryption_certificate = c.leaf ();
+ _decryption_private_key = c.key().get ();