diff --git a/openssl/src/aes.rs b/openssl/src/aes.rs index a4af8d4500a9642bce099e6ac08160dae83185bb..7790885d853ff925eceb66103dd9224931a524a6 100644 --- a/openssl/src/aes.rs +++ b/openssl/src/aes.rs @@ -121,14 +121,14 @@ impl AesKey { /// Performs AES IGE encryption or decryption /// /// AES IGE (Infinite Garble Extension) is a form of AES block cipher utilized in -/// OpenSSL. Infinite Garble referes to propogating forward errors. IGE, like other -/// block ciphers implemented for AES requires an initalization vector. The IGE mode +/// OpenSSL. Infinite Garble refers to propagating forward errors. IGE, like other +/// block ciphers implemented for AES requires an initialization vector. The IGE mode /// allows a stream of blocks to be encrypted or decrypted without having the entire /// plaintext available. For more information, visit [AES IGE Encryption]. /// -/// This block cipher uses 16 byte blocks. The rust implmentation will panic -/// if the input or output does not meet this 16-byte boundry. Attention must -/// be made in this low level implementation to pad the value to the 128-bit boundry. +/// This block cipher uses 16 byte blocks. The rust implementation will panic +/// if the input or output does not meet this 16-byte boundary. Attention must +/// be made in this low level implementation to pad the value to the 128-bit boundary. /// /// [AES IGE Encryption]: http://www.links.org/files/openssl-ige.pdf /// diff --git a/openssl/src/asn1.rs b/openssl/src/asn1.rs index d1323116a5725c15b0cd94658ea8be5ec42d79fc..9c066c556c05d52324c41058b70217964954b7a8 100644 --- a/openssl/src/asn1.rs +++ b/openssl/src/asn1.rs @@ -53,7 +53,7 @@ foreign_type_and_impl_send_sync! { /// example outside the year range of 1950-2049. /// /// [ASN1_GENERALIZEDTIME_set] documentation from OpenSSL provides - /// further details of implmentation. Note: these docs are from the master + /// further details of implementation. Note: these docs are from the master /// branch as documentation on the 1.1.0 branch did not include this page. /// /// [ASN1_GENERALIZEDTIME_set]: https://www.openssl.org/docs/manmaster/man3/ASN1_GENERALIZEDTIME_set.html diff --git a/openssl/src/bn.rs b/openssl/src/bn.rs index 9639593b9252d45cf9c16ae297b59b12cfdd6777..6738ee177ccb696eacba3623dbc0313331378560 100644 --- a/openssl/src/bn.rs +++ b/openssl/src/bn.rs @@ -120,7 +120,7 @@ foreign_type_and_impl_send_sync! { /// with [`new`]. Perform standard mathematics on large numbers using /// methods from [`Dref`] /// - /// OpenSSL documenation at [`BN_new`]. + /// OpenSSL documentation at [`BN_new`]. /// /// [`new`]: struct.BigNum.html#method.new /// [`Dref`]: struct.BigNum.html#deref-methods diff --git a/openssl/src/cms.rs b/openssl/src/cms.rs index c228c16d9a67452e3882d5c574b539e6471405f6..5ef23eeace7a40cf9d99e3a5684352f1a084c6e8 100644 --- a/openssl/src/cms.rs +++ b/openssl/src/cms.rs @@ -1,6 +1,6 @@ //! SMIME implementation using CMS //! -//! CMS (PKCS#7) is an encyption standard. It allows signing and encrypting data using +//! CMS (PKCS#7) is an encryption standard. It allows signing and encrypting data using //! X.509 certificates. The OpenSSL implementation of CMS is used in email encryption //! generated from a `Vec` of bytes. This `Vec` follows the smime protocol standards. //! Data accepted by this module will be smime type `enveloped-data`. @@ -56,7 +56,7 @@ foreign_type_and_impl_send_sync! { /// CMS supports nesting various types of data, including signatures, certificates, /// encrypted data, smime messages (encrypted email), and data digest. The ContentInfo /// content type is the encapsulation of all those content types. [`RFC 5652`] describes - /// CMS and OpenSSL follows this RFC's implmentation. + /// CMS and OpenSSL follows this RFC's implementation. /// /// [`RFC 5652`]: https://tools.ietf.org/html/rfc5652#page-6 pub struct CmsContentInfo; diff --git a/openssl/src/dsa.rs b/openssl/src/dsa.rs index 691d09ecaf547678665afb2ef7a4a327632f1a30..7a8799139bdc20e5d0948695ee1515394aec504f 100644 --- a/openssl/src/dsa.rs +++ b/openssl/src/dsa.rs @@ -1,7 +1,7 @@ //! Digital Signatures //! //! DSA ensures a message originated from a known sender, and was not modified. -//! DSA uses asymetrical keys and an algorithm to output a signature of the message +//! DSA uses asymmetrical keys and an algorithm to output a signature of the message //! using the private key that can be validated with the public key but not be generated //! without the private key. @@ -31,7 +31,7 @@ generic_foreign_type_and_impl_send_sync! { /// * `q`: DSA sub-prime parameter /// * `g`: DSA base parameter /// - /// These values are used to calculate a pair of asymetrical keys used for + /// These values are used to calculate a pair of asymmetrical keys used for /// signing. /// /// OpenSSL documentation at [`DSA_new`] diff --git a/openssl/src/ec.rs b/openssl/src/ec.rs index 8f202b4f43f2675e7bdebf9d2608c52f272edde2..9e7ad86001a8977e22cb805932c145e7415837cd 100644 --- a/openssl/src/ec.rs +++ b/openssl/src/ec.rs @@ -102,7 +102,7 @@ foreign_type_and_impl_send_sync! { /// Prime fields use the formula `y^2 mod p = x^3 + ax + b mod p`. Binary /// fields use the formula `y^2 + xy = x^3 + ax^2 + b`. Named curves have /// assured security. To prevent accidental vulnerabilities, they should - /// be prefered. + /// be preferred. /// /// [wiki]: https://wiki.openssl.org/index.php/Command_Line_Elliptic_Curve_Operations /// [`Nid`]: ../nid/index.html @@ -742,7 +742,7 @@ where /// Checks the key for validity. /// - /// OpenSSL documenation at [`EC_KEY_check_key`] + /// OpenSSL documentation at [`EC_KEY_check_key`] /// /// [`EC_KEY_check_key`]: https://www.openssl.org/docs/man1.1.0/crypto/EC_KEY_check_key.html pub fn check_key(&self) -> Result<(), ErrorStack> { @@ -768,7 +768,7 @@ impl EcKey { /// It will not have an associated public or private key. This kind of key is primarily useful /// to be provided to the `set_tmp_ecdh` methods on `Ssl` and `SslContextBuilder`. /// - /// OpenSSL documenation at [`EC_KEY_new_by_curve_name`] + /// OpenSSL documentation at [`EC_KEY_new_by_curve_name`] /// /// [`EC_KEY_new_by_curve_name`]: https://www.openssl.org/docs/man1.1.0/crypto/EC_KEY_new_by_curve_name.html pub fn from_curve_name(nid: Nid) -> Result, ErrorStack> { diff --git a/openssl/src/memcmp.rs b/openssl/src/memcmp.rs index 97b36302ab356c237dd517a80e1d6c3877dc2df9..e7e7b50e0722eca08ff5487894fc4d46425f91d7 100644 --- a/openssl/src/memcmp.rs +++ b/openssl/src/memcmp.rs @@ -12,7 +12,7 @@ //! //! # Examples //! -//! To perform a constant-time comparision of two arrays of the same length but different +//! To perform a constant-time comparison of two arrays of the same length but different //! values: //! //! ``` @@ -43,7 +43,7 @@ use libc::size_t; /// /// # Examples /// -/// To perform a constant-time comparision of two arrays of the same length but different +/// To perform a constant-time comparison of two arrays of the same length but different /// values: /// /// ``` diff --git a/openssl/src/sha.rs b/openssl/src/sha.rs index 11a2297090cd1c007076cdab69923a611ac3c659..2709ef919a09880d182879a9fa35a429a5015cb7 100644 --- a/openssl/src/sha.rs +++ b/openssl/src/sha.rs @@ -3,7 +3,7 @@ //! SHA, or Secure Hash Algorithms, are a family of cryptographic hashing algorithms published by //! the National Institute of Standards and Technology (NIST). Hash algorithms such as those in //! the SHA family are used to map data of an arbitrary size to a fixed-size string of bytes. -//! As cryptographic hashing algorithms, these mappings have the property of being irreversable. +//! As cryptographic hashing algorithms, these mappings have the property of being irreversible. //! This property makes hash algorithms like these excellent for uses such as verifying the //! contents of a file- if you know the hash you expect beforehand, then you can verify that the //! data you have is correct if it hashes to the same value. @@ -25,7 +25,7 @@ //! println!("Hashed \"Hello, world\" to {}", hex::encode(hash)); //! ``` //! -//! On the other hand, if you already have access to all of the data you woud like to hash, you +//! On the other hand, if you already have access to all of the data you would like to hash, you //! may prefer to use the slightly simpler method of simply calling the hash function corresponding //! to the algorithm you want to use. //! diff --git a/openssl/src/ssl/mod.rs b/openssl/src/ssl/mod.rs index 36951a83a3c4b692dd2ad42a1aa938e6741266ec..2e734ec7a797171b2fac0ccd68099e8e8720aede 100644 --- a/openssl/src/ssl/mod.rs +++ b/openssl/src/ssl/mod.rs @@ -368,7 +368,7 @@ unsafe impl Sync for SslMethod {} unsafe impl Send for SslMethod {} bitflags! { - /// Options controling the behavior of certificate verification. + /// Options controlling the behavior of certificate verification. pub struct SslVerifyMode: i32 { /// Verifies that the peer's certificate is trusted. /// @@ -3309,7 +3309,7 @@ impl SslRef { /// Returns the random field of the client's hello message. /// - /// This can only be used inside of the client hello callback. Otherwise, `None` is returend. + /// This can only be used inside of the client hello callback. Otherwise, `None` is returned. /// /// Requires OpenSSL 1.1.1 or newer. /// @@ -3331,7 +3331,7 @@ impl SslRef { /// Returns the session ID field of the client's hello message. /// - /// This can only be used inside of the client hello callback. Otherwise, `None` is returend. + /// This can only be used inside of the client hello callback. Otherwise, `None` is returned. /// /// Requires OpenSSL 1.1.1 or newer. /// @@ -3353,7 +3353,7 @@ impl SslRef { /// Returns the ciphers field of the client's hello message. /// - /// This can only be used inside of the client hello callback. Otherwise, `None` is returend. + /// This can only be used inside of the client hello callback. Otherwise, `None` is returned. /// /// Requires OpenSSL 1.1.1 or newer. /// @@ -3375,7 +3375,7 @@ impl SslRef { /// Returns the compression methods field of the client's hello message. /// - /// This can only be used inside of the client hello callback. Otherwise, `None` is returend. + /// This can only be used inside of the client hello callback. Otherwise, `None` is returned. /// /// Requires OpenSSL 1.1.1 or newer. /// @@ -3678,7 +3678,7 @@ impl SslStream { /// /// [`SSL_read`]: https://www.openssl.org/docs/manmaster/man3/SSL_read.html pub fn ssl_read(&mut self, buf: &mut [u8]) -> Result { - // The intepretation of the return code here is a little odd with a + // The interpretation of the return code here is a little odd with a // zero-length write. OpenSSL will likely correctly report back to us // that it read zero bytes, but zero is also the sentinel for "error". // To avoid that confusion short-circuit that logic and return quickly diff --git a/openssl/src/symm.rs b/openssl/src/symm.rs index 0414c9a869ea55fe05a4b432e846f18f6906785b..a63e9066abe91c44232f0bc0ed11fbe6c2d52c31 100644 --- a/openssl/src/symm.rs +++ b/openssl/src/symm.rs @@ -426,7 +426,7 @@ unsafe impl Sync for Crypter {} unsafe impl Send for Crypter {} impl Crypter { - /// Creates a new `Crypter`. The initialisation vector, `iv`, is not necesarry for certain + /// Creates a new `Crypter`. The initialisation vector, `iv`, is not necessary for certain /// types of `Cipher`. /// /// # Panics @@ -681,7 +681,7 @@ impl Drop for Crypter { /// Encrypts data in one go, and returns the encrypted data. /// /// Data is encrypted using the specified cipher type `t` in encrypt mode with the specified `key` -/// and initailization vector `iv`. Padding is enabled. +/// and initialization vector `iv`. Padding is enabled. /// /// This is a convenient interface to `Crypter` to encrypt all data in one go. To encrypt a stream /// of data increamentally , use `Crypter` instead. @@ -720,7 +720,7 @@ pub fn encrypt( /// Decrypts data in one go, and returns the decrypted data. /// /// Data is decrypted using the specified cipher type `t` in decrypt mode with the specified `key` -/// and initailization vector `iv`. Padding is enabled. +/// and initialization vector `iv`. Padding is enabled. /// /// This is a convenient interface to `Crypter` to decrypt all data in one go. To decrypt a stream /// of data increamentally , use `Crypter` instead.