From: Carl Hetherington Date: Mon, 8 Jan 2024 11:54:00 +0000 (+0100) Subject: Make public_key_digest() testable. X-Git-Tag: v1.8.93~4 X-Git-Url: https://git.carlh.net/gitweb/?a=commitdiff_plain;h=815c7b9f870de727d76eb7641d924ed0831e14ec;hp=b666e62173fc3272baf12692ca298be0b24ca66f;p=libdcp.git Make public_key_digest() testable. --- diff --git a/src/certificate_chain.cc b/src/certificate_chain.cc index 6748d73c..5afe8a27 100644 --- a/src/certificate_chain.cc +++ b/src/certificate_chain.cc @@ -124,8 +124,8 @@ command (string cmd) * @param openssl openssl binary name (or full path if openssl is not on the system path). * @return SHA1 digest of corresponding public key, with escaped / characters. */ -static string -public_key_digest (boost::filesystem::path private_key, boost::filesystem::path openssl) +string +dcp::public_key_digest(boost::filesystem::path private_key, boost::filesystem::path openssl) { boost::filesystem::path public_name = private_key.string() + ".public"; diff --git a/src/certificate_chain.h b/src/certificate_chain.h index 5d94b74b..aabe9f00 100644 --- a/src/certificate_chain.h +++ b/src/certificate_chain.h @@ -190,6 +190,9 @@ private: }; +std::string public_key_digest(boost::filesystem::path private_key, boost::filesystem::path openssl); + + }