From 94f198e0be3b1069cb60758974f338465e041735 Mon Sep 17 00:00:00 2001 From: wangcundashang Date: Wed, 19 Jun 2024 11:36:59 +0800 Subject: [PATCH] chore: fix some comments Signed-off-by: wangcundashang --- src/lib.rs | 2 +- src/test.rs | 2 +- tests/aead_tests.rs | 2 +- tests/constant_time_tests.rs | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/lib.rs b/src/lib.rs index f501856bee..ff10953169 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -37,7 +37,7 @@ //! SecureRandom) on the esp-idf target. While the esp-idf //! target does have hardware RNG, it is beyond the scope of ring to //! ensure its configuration. This feature allows ring to build -//! on esp-idf despite the liklihood that RNG is not secure. +//! on esp-idf despite the likelihood that RNG is not secure. //! This feature only works with os = espidf targets. //! See //! std diff --git a/src/test.rs b/src/test.rs index fb62cff951..922ee30e7d 100644 --- a/src/test.rs +++ b/src/test.rs @@ -450,7 +450,7 @@ fn parse_test_case( let key = parts[0].trim(); let value = parts[1].trim(); - // Don't allow the value to be ommitted. An empty value can be + // Don't allow the value to be omitted. An empty value can be // represented as an empty quoted string. assert_ne!(value.len(), 0); diff --git a/tests/aead_tests.rs b/tests/aead_tests.rs index a55e3a7cd1..3cf1d7755b 100644 --- a/tests/aead_tests.rs +++ b/tests/aead_tests.rs @@ -207,7 +207,7 @@ fn test_open_in_place_seperate_tag( assert_eq!(&in_out[..tc.plaintext.len()], tc.plaintext); } - // Test that ciphertext range shifing works as expected. + // Test that ciphertext range shifting works as expected. { let range = in_out.len()..; in_out.extend_from_slice(tc.ciphertext); diff --git a/tests/constant_time_tests.rs b/tests/constant_time_tests.rs index 1f34f4ca42..952810156a 100644 --- a/tests/constant_time_tests.rs +++ b/tests/constant_time_tests.rs @@ -20,7 +20,7 @@ use wasm_bindgen_test::{wasm_bindgen_test as test, wasm_bindgen_test_configure}; #[cfg(all(target_arch = "wasm32", target_os = "unknown"))] wasm_bindgen_test_configure!(run_in_browser); -// This logic is loosly based on BoringSSL's `TEST(ConstantTimeTest, MemCmp)`. +// This logic is loosely based on BoringSSL's `TEST(ConstantTimeTest, MemCmp)`. #[test] fn test_verify_slices_are_equal() { let initial: [u8; 256] = rand::generate(&rand::SystemRandom::new()).unwrap().expose();