Skip to content

Commit

Permalink
doc: list how to get a TrustAnchor
Browse files Browse the repository at this point in the history
  • Loading branch information
jsha authored and cpu committed Dec 3, 2023
1 parent 3793627 commit 7ceb2f3
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,10 @@ impl fmt::Debug for PrivatePkcs8KeyDer<'_> {
/// root certificates. However, those certificates contain a lot more data than is needed for
/// verifying certificates. The [`TrustAnchor`] representation allows an application to store
/// just the essential elements of trust anchors.
///
/// The most common way to get one of these is to call [`rustls_webpki::anchor_from_trusted_cert()`].
///
/// [`rustls_webpki::anchor_from_trusted_cert()`]: https://docs.rs/rustls-webpki/latest/webpki/fn.anchor_from_trusted_cert.html
#[derive(Clone, Debug, PartialEq, Eq)]
pub struct TrustAnchor<'a> {
/// Value of the `subject` field of the trust anchor
Expand Down

0 comments on commit 7ceb2f3

Please sign in to comment.