Add cardholder_certificate()

This commit is contained in:
Heiko Schaefer 2022-05-24 14:37:18 +02:00
parent 14143ee182
commit 0885cb0ac9
No known key found for this signature in database
GPG key ID: 4A849A1904CCBD7D

View file

@ -271,6 +271,14 @@ impl<'a> Open<'a> {
self.opt.security_support_template() self.opt.security_support_template()
} }
/// Get cardholder certificate.
///
/// Call select_data() before calling this fn to select a particular
/// certificate (if the card supports multiple certificates).
pub fn cardholder_certificate(&mut self) -> Result<Vec<u8>, Error> {
self.opt.cardholder_certificate()
}
/// "GET NEXT DATA" for the DO cardholder certificate. /// "GET NEXT DATA" for the DO cardholder certificate.
/// ///
/// Cardholder certificate data for multiple slots can be read from the card by first calling /// Cardholder certificate data for multiple slots can be read from the card by first calling