Skip to content

Commit

Permalink
add comment
Browse files Browse the repository at this point in the history
  • Loading branch information
squell authored and davidv1992 committed Nov 30, 2023
1 parent ab4b778 commit cca8f02
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions ntp-proto/src/tls_utils.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,12 @@
/// The intent of this ClientCertVerifier is that it accepts any connections that are either
/// a.) not presenting a client certificicate
/// b.) are presenting a well-formed, but otherwise not checked (against a trust root) client certificate
///
/// This is because RusTLS apparently doesn't accept every kind of self-signed certificate.
///
/// The only goal of this ClientCertVerifier is to achieve that, if a client presents a TLS certificate,
/// this certificate shows up in the .peer_certificates() for that connection.
pub struct AllowAnyAnonymousOrCertificateBearingClient;

use rustls::{server::ClientCertVerified, Certificate};
Expand Down

0 comments on commit cca8f02

Please sign in to comment.