diff --git a/openssl/src/symm.rs b/openssl/src/symm.rs index 56338acd..b154d869 100644 --- a/openssl/src/symm.rs +++ b/openssl/src/symm.rs @@ -131,7 +131,7 @@ impl Cipher { } /// Requires OpenSSL 1.1.0 or newer. - #[cfg(any(ossl110))] + #[cfg(ossl110)] pub fn aes_128_ocb() -> Cipher { unsafe { Cipher(ffi::EVP_aes_128_ocb()) } } @@ -173,7 +173,7 @@ impl Cipher { } /// Requires OpenSSL 1.1.0 or newer. - #[cfg(any(ossl110))] + #[cfg(ossl110)] pub fn aes_192_ocb() -> Cipher { unsafe { Cipher(ffi::EVP_aes_192_ocb()) } } @@ -219,7 +219,7 @@ impl Cipher { } /// Requires OpenSSL 1.1.0 or newer. - #[cfg(any(ossl110))] + #[cfg(ossl110)] pub fn aes_256_ocb() -> Cipher { unsafe { Cipher(ffi::EVP_aes_256_ocb()) } } @@ -318,14 +318,14 @@ impl Cipher { } /// Determines whether the cipher is using OCB mode - #[cfg(any(ossl110))] + #[cfg(ossl110)] fn is_ocb(&self) -> bool { *self == Cipher::aes_128_ocb() || *self == Cipher::aes_192_ocb() || *self == Cipher::aes_256_ocb() } - #[cfg(not(any(ossl110)))] + #[cfg(not(ossl110))] const fn is_ocb(&self) -> bool { false } @@ -1425,7 +1425,7 @@ mod tests { } #[test] - #[cfg(any(ossl110))] + #[cfg(ossl110)] fn test_aes_128_ocb() { let key = "000102030405060708090a0b0c0d0e0f"; let aad = "0001020304050607"; @@ -1461,7 +1461,7 @@ mod tests { } #[test] - #[cfg(any(ossl110))] + #[cfg(ossl110)] fn test_aes_128_ocb_fail() { let key = "000102030405060708090a0b0c0d0e0f"; let aad = "0001020304050607";