obfuscate/impls/
openmls_basic_credential.rs

1use std::fmt::Formatter;
2
3use hex::ToHex as _;
4use openmls_basic_credential::SignatureKeyPair;
5
6use crate::{Obfuscate, compute_hash};
7
8impl Obfuscate for SignatureKeyPair {
9    fn obfuscate(&self, f: &mut Formatter<'_>) -> core::fmt::Result {
10        f.debug_struct("SignatureKeyPair")
11            .field("signature_scheme", &self.signature_scheme())
12            .field("public", &self.public().encode_hex::<String>())
13            .field("private", &compute_hash(self.private()))
14            .finish()
15    }
16}