summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Move aes_core.c to the primary Makefile.jsing2024-03-2912-32/+12
| | | | This is now built on all platforms.
* Consolidate idea into a single C file.jsing2024-03-295-357/+287
|
* Remove unused n2ln, l2nn, n2l and l2n macros.jsing2024-03-291-44/+1
|
* Make X509_VERIFY_PARAM_set1_policies() less badtb2024-03-291-22/+34
| | | | | | | | | | | If any OBJ_dup() fails along the way, a partially copied policy stack would remain on the params object. This makes no sense. Implement and use an sk_ASN1_OBJECT_deep_copy(), that copies the full stack or else returns NULL. Remove unnecessary NULL check and streamline some other logic. ok jsing
* Clean up X509_VERIFY_PARAM_add0_policy()tb2024-03-291-6/+5
| | | | | | Streamline some checks and use more idiomatic sk_push() error check ok jsing
* Always use C functions for AES_set_{encrypt,decrypt}_key().jsing2024-03-299-57/+100
| | | | | | | | Always include aes_core.c and provide AES_set_{encrypt,decrypt}_key() via C functions, which then either use a C implementation or call the assembly implementation. ok tb@
* Retire mime_debug()tb2024-03-291-5/+1
| | | | discussed with jsing
* Improve error checking in i2d_ASN1_bio_stream()tb2024-03-291-23/+24
| | | | | | | | | | The streaming BIO API is full of missing error checks. This diff reverts the logic so that the single call to ASN1_item_i2d_bio() is error checked (it has the usual 1/0 return values), unindents the bulk of the code and propagates the SMIME_crlf_copy() return value (alos 1/0) to be the actual error. ok jsing
* Consolidate whirlpool into a single C file.jsing2024-03-294-284/+229
| | | | | | | Buy a vowel at the same time, since we're no longer limited to 8.3 file names. Discussed with tb@
* Remove now unused assembly implementations of whirlpool.jsing2024-03-292-978/+0
|
* Hide symbols in Blowfishjoshua2024-03-293-1/+51
| | | | ok jsing tb
* Move wp_block.c to the primary Makefile.jsing2024-03-2912-35/+12
| | | | This is now built on all platforms.
* Remove CMS special now that we do not depend on pem.h being included first.jsing2024-03-291-2/+1
|
* Stop playing #ifdef HEADER_PEM_H games in cms.h.jsing2024-03-291-3/+4
| | | | | | | | Rather than making prototypes appear and disappear depending on whether or not you've included pem.h before cms.h, just include pem.h from cms.h itself. ok joshua@ tb@
* Stop using pem2.h.jsing2024-03-292-4/+3
| | | | | | | | Somewhere in the past 25 years, the circular dependency between err and pem went away. Stop pulling in pem2.h and just use pem.h directly (pem2.h can probably be removed at some point, but that remains for another day). ok joshua@ tb@
* Hide symbols in DESjoshua2024-03-2922-20/+157
| | | | ok jsing beck
* Rename AES_cbc_encrypt to aes_cbc_encrypt_internal for the SEH handlers.jsing2024-03-291-4/+4
| | | | Should fix windows build.
* Stop building whirlpool assembly on amd64 and i386.jsing2024-03-292-6/+3
| | | | | | | This is a legacy algorithm and the assembly is only marginally faster than the C code. Discussed with beck@ and tb@
* Fix indenttb2024-03-291-2/+2
|
* Apply style(9) hammer.jsing2024-03-291-118/+117
| | | | | The code is still a horrific mess, but at least the braces are in the right place...
* Hide symbols in RIPEMDjoshua2024-03-283-1/+45
| | | | ok beck jsing
* Merge aes_cbc.c into aes.c now that aes_cbc.c is used on all platforms.jsing2024-03-2814-102/+43
|
* Make AES_cbc_encrypt() always be a C function.jsing2024-03-285-17/+32
| | | | | | | | Rename the assembly generated functions from AES_cbc_encrypt() to aes_cbc_encrypt_internal(). Always include aes_cbc.c and change it to use defines that are similar to those used in BN. ok tb@
* Use static inline for rc4_set_key_internal().jsing2024-03-281-2/+2
|
* Remove unused SM3_Transform()jsing2024-03-281-9/+1
| | | | Along with the misnamed SM3_transform() prototype.
* Rename SM3_block_data_order() and make static.jsing2024-03-281-9/+8
|
* Remove md32_common.h since it is now (finally) unused.jsing2024-03-281-309/+0
|
* Rework loads and stores for sm3.jsing2024-03-281-61/+57
| | | | | | | Replace loads with crypto_load_be32toh() or be32toh(). Use crypto_store_htobe32() or htobe32() for stores. ok tb@
* Remove .init section that calls OPENSSL_cpuid_setup on i386.jsing2024-03-281-4/+0
| | | | | OPENSSL_cpuid_setup() is already called from OPENSSL_crypto_init(), hence we do not need or want automatic initialisation on library load.
* Remove .init section that calls OPENSSL_cpuid_setup on amd64.jsing2024-03-281-10/+0
| | | | | | | OPENSSL_cpuid_setup() is already called from OPENSSL_crypto_init(), hence we do not need or want automatic initialisation on library load. ok tb@
* Rework loads and stores in ripemd.jsing2024-03-281-74/+53
| | | | | | | Replace loads with crypto_load_le32toh() or le32toh(). Use crypto_store_htole32() or htole32() for stores. ok joshua@ tb@
* Remove OPENSSL_UNISTD definetb2024-03-2813-39/+0
|
* Expand ROTATE macro to crypto_rol_u32().jsing2024-03-281-8/+10
|
* Include stdint.h since we use uint*_t types.jsing2024-03-281-1/+2
|
* Inline initial hash values.jsing2024-03-281-18/+11
|
* Remove no unnecessary do { } while (0);jsing2024-03-281-3/+1
|
* Inline HASH_MAKE_STRING.jsing2024-03-281-17/+20
| | | | No change to generated assembly.
* Expand HASH_* defines.jsing2024-03-281-26/+28
| | | | No change in generated assembly.
* Hide symbols in RC4joshua2024-03-283-1/+36
| | | | ok jsing tb beck
* Reorder functions.jsing2024-03-281-116/+115
| | | | No functional change.
* Tidy includes.jsing2024-03-281-5/+5
|
* Inline functions from md32_common.h.jsing2024-03-281-1/+101
| | | | No change in generated assembly.
* Load in the top of the loop, as we do for other hash implementations.jsing2024-03-282-20/+20
|
* Remove now unnecessary do { } while (0);jsing2024-03-281-3/+1
|
* Inline HASH_MAKE_STRING.jsing2024-03-281-14/+14
| | | | No change in generated assembly.
* Expand ROTATE macro to crypto_rol_u32().jsing2024-03-281-11/+16
|
* Demacro sha1.jsing2024-03-281-164/+252
| | | | | | | | | Replace macros with static inline functions and use names that follow the spec more closely. Unlike SHA256/SHA512, the functions and constants do not align with the number of words loaded, which means we cannot easily loop and just end up just unrolling everything. ok joshua@ tb@
* Inline initial hash values.jsing2024-03-281-12/+8
|
* Clean up various defines and prototypes.jsing2024-03-281-28/+2
| | | | | No assembly implementations remain, hence we can clean the mess up and replace it with a single static void function.
* Use TLS_ERROR_INVALID_ARGUMENT for "too large" and "too small" errorsjoshua2024-03-282-8/+9
| | | | ok beck tb