finished import

This commit is contained in:
mamoniot 2023-03-09 12:12:03 -05:00
parent c8cb45128e
commit a507212276
No known key found for this signature in database
GPG key ID: ADCCDBBE0E3D3B3B
4 changed files with 3154 additions and 3136 deletions

View file

@ -3,9 +3,8 @@ use std::ptr;
use foreign_types::ForeignType;
use crate::cipher_ctx::CipherCtx;
use crate::{cipher_ctx::CipherCtx, ZEROES};
pub const ZEROES: [u8; 64] = [0_u8; 64];
/// AES-GMAC-SIV encryptor/decryptor.
pub struct AesGmacSiv {

File diff suppressed because it is too large Load diff

3131
crypto/src/aes_tests.rs Normal file

File diff suppressed because it is too large Load diff

View file

@ -4,7 +4,6 @@ mod cipher_ctx;
mod bn;
mod ec;
pub mod aes_gmac_siv;
pub mod secret;
pub mod random;
pub mod hash;
@ -16,7 +15,27 @@ pub mod salsa;
pub mod typestate;
pub mod x25519;
pub mod aes;
#[cfg(target_os = "macos")]
pub mod aes_fruity;
#[cfg(not(target_os = "macos"))]
pub mod aes_openssl;
#[cfg(target_os = "macos")]
pub use aes_fruity as aes;
#[cfg(not(target_os = "macos"))]
pub use aes_openssl as aes;
mod aes_tests;
#[cfg(target_os = "macos")]
pub mod aes_gmac_siv_fruity;
#[cfg(not(target_os = "macos"))]
pub mod aes_gmac_siv_openssl;
#[cfg(target_os = "macos")]
pub use aes_gmac_siv_fruity as aes_gmac_siv;
#[cfg(not(target_os = "macos"))]
pub use aes_gmac_siv_openssl as aes_gmac_siv;
/// This must be called before using any function from this library.
@ -38,3 +57,4 @@ pub fn secure_eq<A: AsRef<[u8]> + ?Sized, B: AsRef<[u8]> + ?Sized>(a: &A, b: &B)
false
}
}
pub const ZEROES: [u8; 64] = [0_u8; 64];