summaryrefslogtreecommitdiff
path: root/src/lib/screen.h
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2025-01-17 01:31:38 +0100
committerCarl Hetherington <cth@carlh.net>2025-01-22 14:34:25 +0100
commit5e10a6f047d12f1e2e3d0e2f8ee30f93897a2227 (patch)
treec3daccbbf2291d6330df2c2f6d99bf34fcb2e288 /src/lib/screen.h
parentc29ba2526337b486d4a3b1a1468513a22293bc87 (diff)
Allow KDMRecipient and hence Screen to convert certs to dcp::Certificate lazily.
This is pretty slow (as it runs the certificate through OpenSSL) and we don't need to do it for every certificate in a database when we load the database.
Diffstat (limited to 'src/lib/screen.h')
-rw-r--r--src/lib/screen.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/lib/screen.h b/src/lib/screen.h
index 89ebc3ab4..326bc9403 100644
--- a/src/lib/screen.h
+++ b/src/lib/screen.h
@@ -64,6 +64,17 @@ public:
, trusted_devices (trusted_devices_)
{}
+ Screen(
+ std::string const & name_,
+ std::string const & notes_,
+ boost::optional<std::string> recipient_,
+ boost::optional<std::string> recipient_file_,
+ std::vector<TrustedDevice> trusted_devices_
+ )
+ : KDMRecipient(name_, notes_, recipient_, recipient_file_)
+ , trusted_devices(trusted_devices_)
+ {}
+
std::vector<std::string> trusted_device_thumbprints () const;
std::vector<TrustedDevice> trusted_devices;
};