Skip to content

Commit

Permalink
pkcs1+pkcs8+sec1+spki: fix typos (#1340)
Browse files Browse the repository at this point in the history
  • Loading branch information
shuja73 authored Feb 3, 2024
1 parent e6ef734 commit f299a42
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions pkcs1/src/traits.rs
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ pub trait EncodeRsaPrivateKey {
Ok(self.to_pkcs1_der()?.write_der_file(path)?)
}

/// Write ASN.1 DER-encoded PKCS#1 private key to the given path.
/// Write ASN.1 PEM-encoded PKCS#1 private key to the given path.
#[cfg(all(feature = "pem", feature = "std"))]
fn write_pkcs1_pem_file(&self, path: impl AsRef<Path>, line_ending: LineEnding) -> Result<()> {
let doc = self.to_pkcs1_der()?;
Expand All @@ -146,7 +146,7 @@ pub trait EncodeRsaPublicKey {
Ok(self.to_pkcs1_der()?.write_der_file(path)?)
}

/// Write ASN.1 DER-encoded public key to the given path.
/// Write ASN.1 PEM-encoded public key to the given path.
#[cfg(all(feature = "pem", feature = "std"))]
fn write_pkcs1_pem_file(&self, path: impl AsRef<Path>, line_ending: LineEnding) -> Result<()> {
let doc = self.to_pkcs1_der()?;
Expand Down
2 changes: 1 addition & 1 deletion pkcs8/src/traits.rs
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ pub trait EncodePrivateKey {
Ok(self.to_pkcs8_der()?.write_der_file(path)?)
}

/// Write ASN.1 DER-encoded PKCS#8 private key to the given path
/// Write ASN.1 PEM-encoded PKCS#8 private key to the given path
#[cfg(all(feature = "pem", feature = "std"))]
fn write_pkcs8_pem_file(&self, path: impl AsRef<Path>, line_ending: LineEnding) -> Result<()> {
let doc = self.to_pkcs8_der()?;
Expand Down
2 changes: 1 addition & 1 deletion sec1/src/traits.rs
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ pub trait EncodeEcPrivateKey {
Ok(self.to_sec1_der()?.write_der_file(path)?)
}

/// Write ASN.1 DER-encoded SEC1 private key to the given path.
/// Write ASN.1 PEM-encoded SEC1 private key to the given path.
#[cfg(all(feature = "pem", feature = "std"))]
fn write_sec1_pem_file(&self, path: impl AsRef<Path>, line_ending: LineEnding) -> Result<()> {
let doc = self.to_sec1_der()?;
Expand Down
2 changes: 1 addition & 1 deletion spki/src/traits.rs
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ pub trait EncodePublicKey {
Ok(self.to_public_key_der()?.write_der_file(path)?)
}

/// Write ASN.1 DER-encoded public key to the given path
/// Write ASN.1 PEM-encoded public key to the given path
#[cfg(all(feature = "pem", feature = "std"))]
fn write_public_key_pem_file(
&self,
Expand Down

0 comments on commit f299a42

Please sign in to comment.