diff options
| author | jsing <> | 2025-09-08 12:56:17 +0000 |
|---|---|---|
| committer | jsing <> | 2025-09-08 12:56:17 +0000 |
| commit | edb41402990165c33fbbe4972a505d2b907f57b5 (patch) | |
| tree | daa72754af93ced1ffe1d8665b2a3c371ea95b64 /src/lib/libcrypto/arch | |
| parent | 0b23e36dfa750e5a98824fc469f69a27c5f25d3b (diff) | |
| download | openbsd-edb41402990165c33fbbe4972a505d2b907f57b5.tar.gz openbsd-edb41402990165c33fbbe4972a505d2b907f57b5.tar.bz2 openbsd-edb41402990165c33fbbe4972a505d2b907f57b5.zip | |
Allow generic AES implementation to be used as a fallback.
Rename the C based AES implementation to *_generic() and provide
*_internal() wrappers for these. This allows for architectures to provide
accelerated versions without having to also provide a fallback
implementation.
ok tb@
Diffstat (limited to 'src/lib/libcrypto/arch')
| -rw-r--r-- | src/lib/libcrypto/arch/amd64/crypto_arch.h | 7 | ||||
| -rw-r--r-- | src/lib/libcrypto/arch/i386/crypto_arch.h | 7 |
2 files changed, 12 insertions, 2 deletions
diff --git a/src/lib/libcrypto/arch/amd64/crypto_arch.h b/src/lib/libcrypto/arch/amd64/crypto_arch.h index a8f64cf235..9a179a571e 100644 --- a/src/lib/libcrypto/arch/amd64/crypto_arch.h +++ b/src/lib/libcrypto/arch/amd64/crypto_arch.h | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: crypto_arch.h,v 1.14 2025/08/14 15:11:01 jsing Exp $ */ | 1 | /* $OpenBSD: crypto_arch.h,v 1.15 2025/09/08 12:56:17 jsing Exp $ */ |
| 2 | /* | 2 | /* |
| 3 | * Copyright (c) 2024 Joel Sing <jsing@openbsd.org> | 3 | * Copyright (c) 2024 Joel Sing <jsing@openbsd.org> |
| 4 | * | 4 | * |
| @@ -33,6 +33,11 @@ extern uint64_t crypto_cpu_caps_amd64; | |||
| 33 | 33 | ||
| 34 | #ifndef OPENSSL_NO_ASM | 34 | #ifndef OPENSSL_NO_ASM |
| 35 | 35 | ||
| 36 | #define HAVE_AES_SET_ENCRYPT_KEY_GENERIC | ||
| 37 | #define HAVE_AES_SET_DECRYPT_KEY_GENERIC | ||
| 38 | #define HAVE_AES_ENCRYPT_GENERIC | ||
| 39 | #define HAVE_AES_DECRYPT_GENERIC | ||
| 40 | |||
| 36 | #define HAVE_AES_SET_ENCRYPT_KEY_INTERNAL | 41 | #define HAVE_AES_SET_ENCRYPT_KEY_INTERNAL |
| 37 | #define HAVE_AES_SET_DECRYPT_KEY_INTERNAL | 42 | #define HAVE_AES_SET_DECRYPT_KEY_INTERNAL |
| 38 | #define HAVE_AES_ENCRYPT_INTERNAL | 43 | #define HAVE_AES_ENCRYPT_INTERNAL |
diff --git a/src/lib/libcrypto/arch/i386/crypto_arch.h b/src/lib/libcrypto/arch/i386/crypto_arch.h index d2faa36e2e..522ed2788b 100644 --- a/src/lib/libcrypto/arch/i386/crypto_arch.h +++ b/src/lib/libcrypto/arch/i386/crypto_arch.h | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: crypto_arch.h,v 1.12 2025/07/22 09:18:02 jsing Exp $ */ | 1 | /* $OpenBSD: crypto_arch.h,v 1.13 2025/09/08 12:56:17 jsing Exp $ */ |
| 2 | /* | 2 | /* |
| 3 | * Copyright (c) 2024 Joel Sing <jsing@openbsd.org> | 3 | * Copyright (c) 2024 Joel Sing <jsing@openbsd.org> |
| 4 | * | 4 | * |
| @@ -32,6 +32,11 @@ extern uint64_t crypto_cpu_caps_i386; | |||
| 32 | 32 | ||
| 33 | #ifndef OPENSSL_NO_ASM | 33 | #ifndef OPENSSL_NO_ASM |
| 34 | 34 | ||
| 35 | #define HAVE_AES_SET_ENCRYPT_KEY_GENERIC | ||
| 36 | #define HAVE_AES_SET_DECRYPT_KEY_GENERIC | ||
| 37 | #define HAVE_AES_ENCRYPT_GENERIC | ||
| 38 | #define HAVE_AES_DECRYPT_GENERIC | ||
| 39 | |||
| 35 | #define HAVE_AES_SET_ENCRYPT_KEY_INTERNAL | 40 | #define HAVE_AES_SET_ENCRYPT_KEY_INTERNAL |
| 36 | #define HAVE_AES_SET_DECRYPT_KEY_INTERNAL | 41 | #define HAVE_AES_SET_DECRYPT_KEY_INTERNAL |
| 37 | #define HAVE_AES_ENCRYPT_INTERNAL | 42 | #define HAVE_AES_ENCRYPT_INTERNAL |
