Commit Graph

9499 Commits

Author SHA1 Message Date
Jacob Barthelmeh 213a2d0a7d reverse order that certificates are compared with private key when parsing PKCS12 2018-01-19 15:41:52 -07:00
dgarske 5d52466d6f Merge pull request #1326 from ejohnstown/rsa-test-fix
RSA Key Generation Test Fix
2018-01-18 15:01:55 -08:00
dgarske f61e56e5b6 Merge pull request #1312 from kojo1/mdk5
CMSIS pack 3.13.0
2018-01-18 14:48:37 -08:00
John Safranek 9654f19075 RSA Key Gen Test Fix
A recent change to the RSA key generation process is capping the number of attempts of finding a probable prime to a multiple of the prime's size, in FIPS builds. This means it might fail once in a while. (It could also fail for a couple other reasons but this is the most likely.) The API is changed to retry key generation until it succeeds. Non-FIPS builds keep trying until they find a prime.
2018-01-18 12:20:25 -08:00
Jacob Barthelmeh 377f5c304c update for async build and include for getenv 2018-01-18 09:05:21 -07:00
Takashi Kojo f79a3e9ddb Reverse ByteReversWOrd64 2018-01-18 07:10:55 +09:00
David Garske 1276d21d8e Added WOLFSSL_IGNORE_FILE_WARN option to ignore warning for .c files that do not need to be included. 2018-01-17 13:27:59 -08:00
Jacob Barthelmeh fa3ab4fd61 adjustment to RSA key size check 2018-01-17 11:34:27 -07:00
dgarske 57cbd5e53c Merge pull request #1322 from SparkiDev/poly1305_clang_fix
Fix clang using wrong registers in poly1305 AVX2 code
2018-01-17 08:30:33 -08:00
dgarske 2dc60b9e01 Merge pull request #1321 from SparkiDev/fe_init_small_fix
Fix fe_init implementation to appear for small Ed25519
2018-01-17 08:30:13 -08:00
Jacob Barthelmeh bf57da1914 static analysis fixes, free buffer return in test case, fips build 2018-01-17 09:28:25 -07:00
Sean Parkinson 4915a784ec Fix clang using wrong registers in poly1305 AVX2 code 2018-01-17 15:02:58 +10:00
Sean Parkinson c09d972012 Fix fe_init implementation to appear for small Ed25519 2018-01-17 11:34:22 +10:00
Takashi Kojo b3ab0a9c11 simplify visibility control 2018-01-16 14:59:50 -07:00
Takashi Kojo dce628ae8e Eliminate dup _InitHmac 2018-01-16 14:59:48 -07:00
Takashi Kojo 8f1fc8ad2e Error return value of checkPad 2018-01-16 14:51:44 -07:00
Go Hosohara a3ad8c5bae Implement DomainComponent in wolfSSL_X509_NAME_get_index_by_NID() and wolfSSL_X509_NAME_get_entry(). 2018-01-16 13:50:01 -07:00
Takashi Kojo 47bca28b1d Fix compatibility, inl == 0, EVP_CipherUpdate 2018-01-16 13:37:26 -07:00
Takashi Kojo 43ae3c9f59 ASN_PARSE_E in GetASNInt 2018-01-16 13:36:35 -07:00
Jacob Barthelmeh 39126cbb63 move variable declaration to top of function and silence compiler warning 2018-01-16 01:44:30 -07:00
Jacob Barthelmeh fcb1a10a3c upadte memory bio read and setting bios in ssl struct 2018-01-16 01:42:34 -07:00
Takashi Kojo d3f4845c55 EVP_PKEY_decrypt return value 2018-01-16 01:25:17 -07:00
Jacob Barthelmeh ca50d13149 update const type compatibility 2018-01-16 01:18:32 -07:00
Jacob Barthelmeh db3badb73a add GENERAL NAME stack functions and fix WOLFSSL_BIO free with files 2018-01-16 01:12:09 -07:00
Jacob Barthelmeh 6455801518 add TLSv1 method, getter function for cipher key length, and start stack functions 2018-01-16 00:58:33 -07:00
Jacob Barthelmeh 1d792b0b44 detect SHA256, SHA384, and SHA512 NID types when signing 2018-01-16 00:19:53 -07:00
Jacob Barthelmeh d1c05c1883 fix DER to internal private key function 2018-01-16 00:14:08 -07:00
Jacob Barthelmeh 18019f1bae evp key flags and add WOLFSSL_BUF_MEM struct to WOLFSSL_BIO 2018-01-15 23:34:13 -07:00
Sean Parkinson be1aba1f70 Improve performance of chacha20-poly1305 on AVX and AVX2.
Create an AVX2 version of the small block size chacha20 encryption code.
Only update the poly1305 once for the two lengths in chacha20-poly1305.
Poly1305 AVX2 uses AVX code to handle last bytes, store H whole.
Fix error codes in poly1305 test and add a longer data test case.
2018-01-16 13:45:36 +10:00
Takashi Kojo 8ae1b7823e ecc.c, logging.c: local value shadows global 2018-01-15 18:03:21 -07:00
Jacob Barthelmeh cda44c89ac account for different build options 2018-01-15 17:40:46 -07:00
Takashi Kojo c20bff79ad fix to fix EVP_CipherFinal stream cipher outlen 2018-01-15 16:19:57 -07:00
Jacob Barthelmeh 60b21ffa62 add compat functions; rand egd, rand file, bio_f_base64, bio pop, bio set flags, crypto set id callback, crypto set locking callback, evp pkey get1 RSA, PEM write bio RSA private key, set info callback and alter ERR GET REASON 2018-01-15 16:06:36 -07:00
Takashi Kojo 6fd949279d fix EVP_CipherFinal outlen for stream cipher 2018-01-15 13:48:31 -07:00
Chris Conlon 3415b05732 Merge pull request #1311 from ejohnstown/rsakeygen
RSA Key Generation (FIPS 186-4)
2018-01-15 13:26:44 -07:00
Jacob Barthelmeh 0c4f9c39c9 adjust AES-CFB location in code or --enable-armasm build and use wc_AesEncryptDirect function calls 2018-01-15 13:00:25 -07:00
Jacob Barthelmeh e9f3d7f898 add the function ERR remove state and test for it 2018-01-15 10:56:54 -07:00
toddouska 2e6f97621a Merge pull request #764 from JacobBarthelmeh/Compatibility-Layer-Part3
Compatibility layer part3
2018-01-13 09:57:14 -08:00
John Safranek 862e59f474 FIPS Update
1. White space changes. Converting tabs to spaces.
2. Add some comments explaining where a loop bound came from.
3. Added parameter checks to a function.
2018-01-12 15:37:22 -08:00
toddouska 0590f2493e Merge pull request #1314 from dgarske/cleanups
Minor fixes and cleanups for hash digest/block size
2018-01-12 13:00:53 -08:00
Jacob Barthelmeh df7917fcd9 add --enable-aescfb, add comments, include of stdio with snprintf 2018-01-12 11:05:43 -07:00
Sean Parkinson 3d6d80fe21 Improve AES-GCM code for Intel AVX1 and AVX2
Improve AES-GCM Intel performance by converting to pure inline ASM.
Improve AES-GCM Intel code algorithmically.
Split out platform specific code for AES-GCM encrypt and decrypt.
Move C implementation of AES-GCM to separate function to speed up Intel
ASM code.
Modified test to try all input byte sizes up to large benchmark size
when defined.
2018-01-12 10:51:32 +10:00
Chris Conlon e8179b29ff Merge pull request #1299 from JacobBarthelmeh/PKCS7
handle degenerate case with PKCS7
2018-01-11 16:56:39 -07:00
Jacob Barthelmeh 29ccc36fc2 refactor openssl test in test.c and update AES CFB compatibility function 2018-01-11 15:35:38 -07:00
Jacob Barthelmeh 953fc0d4a8 update CFB mode to handle partial AES block sizes 2018-01-11 15:28:56 -07:00
Jacob Barthelmeh c2a6c6c395 add CFB mode for AES 2018-01-11 15:23:15 -07:00
Jacob Barthelmeh 857bbe65b5 update OID check for domain component 2018-01-11 14:47:12 -07:00
Takashi Kojo e2a16190a6 add NID_domainComponent in X509_NAME_get_text_by_NID 2018-01-11 14:37:49 -07:00
Takashi Kojo 2fc494f66b add NID_domainComponent 2018-01-11 14:37:49 -07:00
Jacob Barthelmeh d2f1ced52f added x509 functions : x509 name cmp, i2d x509 name, i2d x509, x509 print 2018-01-11 14:04:03 -07:00