refactor/feat: rewrite certs::fingerprint with generic data type…
…and allowing different bin2txt (getting ready for DANE)
This commit is contained in:
parent
6f91e705d3
commit
1fc73d0cab
6 changed files with 73 additions and 52 deletions
|
@ -1,6 +1,6 @@
|
|||
use tokio_gemini::{
|
||||
certs::{
|
||||
fingerprint::{generate_fingerprint, Algorithm},
|
||||
fingerprint::{self, CertFingerprint},
|
||||
SelfsignedCertVerifier,
|
||||
},
|
||||
Client, LibError,
|
||||
|
@ -47,7 +47,7 @@ impl SelfsignedCertVerifier for CertVerifier {
|
|||
eprintln!(
|
||||
"Host = {}\nFingerprint = {}",
|
||||
host,
|
||||
generate_fingerprint(cert, Algorithm::Sha512),
|
||||
CertFingerprint::<fingerprint::Sha256>::new(cert).base64(),
|
||||
);
|
||||
Ok(true)
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue