Commit Graph

4902 Commits

Author SHA1 Message Date
Sean Parkinson
7345b2418b Merge pull request #3944 from guidovranken/zd12039
Account for sp_sqr failure in _sp_exptmod_nct
2021-04-12 11:03:38 +10:00
toddouska
b3177ffc17 Merge pull request #3945 from dgarske/ecc_nomalloc
Improve ECC with `WOLFSSL_NO_MALLOC`
2021-04-07 16:29:13 -07:00
toddouska
418e5b46d6 Merge pull request #3934 from SparkiDev/armv8-asm-sha256-fix
ARMv8 SHA-256: recalc data in SHA256 update
2021-04-07 16:22:27 -07:00
toddouska
86fe77d776 Merge pull request #3924 from dgarske/sp_math_all
Sp math all fixes
2021-04-07 16:21:58 -07:00
David Garske
786bbabbdc Improve ECC with WOLFSSL_NO_MALLOC
Tested with `./configure --enable-cryptonly --disable-examples --disable-rsa --disable-dh CFLAGS="-DWOLFSSL_NO_MALLOC -DBENCH_EMBEDDED" && make check`.
All ECC operations can work now with WOLFSSL_NO_MALLOC and variables will be on stack.
ZD 11829
2021-04-06 15:31:40 -07:00
Guido Vranken
52e6ff7c56 Account for sp_sqr failure in _sp_exptmod_nct
ZD 12039
2021-04-06 01:34:09 +02:00
David Garske
53d97d1961 Fix for DSA only case and missing sp_read_radix 2021-04-05 11:43:21 -07:00
David Garske
24d8e1b104 SP math all edge cases without RSA. 2021-04-05 11:31:55 -07:00
David Garske
eb37953061 Fix for WOLFSSL_SP_MATH_ALL typo. Plus a few other minor ones. 2021-04-05 11:31:55 -07:00
Jacob Barthelmeh
9a86f133c8 additional fixes for reports with test cases 2021-04-05 21:26:52 +07:00
Jacob Barthelmeh
71fea2bdd1 initialize hash size variable to 0 in the case that getting the digest size returns 0 2021-04-05 21:26:52 +07:00
Jacob Barthelmeh
39f34ef88b check return values 2021-04-05 21:26:52 +07:00
Jacob Barthelmeh
1c3ba77bee remove dead code path 2021-04-05 21:26:52 +07:00
Jacob Barthelmeh
4ead19e21f check return value of hash digest size 2021-04-05 21:26:22 +07:00
Jacob Barthelmeh
75abeebaf7 free memory in test case 2021-04-05 21:26:22 +07:00
Sean Parkinson
e3c86f8f77 ARMv8 SHA-256: recalc data in SHA256 update 2021-04-01 17:01:21 +10:00
Guido Vranken
2ecaa3c4c6 Use unsigned integers in mp_is_bit_set
ZD 12012
2021-04-01 00:57:06 +02:00
toddouska
95b91d8913 Merge pull request #3886 from DKubasekRA/fix/RA/v4.7.0-coverity
RA - Fixes for Coverity issues
2021-03-31 10:41:54 -07:00
toddouska
f7046ca12a Merge pull request #3906 from douzzer/AES-BAD_ALIGN_E-consistency
Adds optional AES CBC length checking
2021-03-30 16:01:29 -07:00
toddouska
4d1ad6acd6 Merge pull request #3885 from JacobBarthelmeh/StaticAnalysisTests
Static analysis fixes for items listed as high priority
2021-03-30 16:00:03 -07:00
Sean Parkinson
c3fcb2e95f Merge pull request #3923 from dgarske/armv8
ARMv8: do not compile code if module is disabled
2021-03-29 08:50:41 +10:00
David Garske
724a415d51 Fix ARMv8 to not compile code if module is disabled 2021-03-26 13:28:15 -07:00
Daniel Pouzzner
5d9ee97530 WOLFSSL_AES_CBC_LENGTH_CHECKS: add gated logic to aes.c wc_AesCbc{En,De}crypt() to return BAD_LENGTH_E when input length is not a multiple of AES_BLOCK_SIZE; add gated tests of new functionality in test_wc_AesCbcEncryptDecrypt(); fix first encrypt-decrypt-memcmp in test_wc_AesCbcEncryptDecrypt() to span all of test vector and extend test vector length to be block-multiple; add ungated logic in platform-specific wc_AesCbc{En,De}crypt() routines to return with early success when blocks == 0 (also mitigates buffer overrun on short (less-than-AES_BLOCK_SIZE) input); add BAD_LENGTH_E error code; update documentation. 2021-03-26 13:40:08 -05:00
David Garske
f201d65459 Merge pull request #3898 from elms/intime_rtos/crl_directory_fix
INTIME: add support for directory file search
2021-03-26 09:37:21 -07:00
toddouska
79fa71d600 Merge pull request #3882 from TakayukiMatsuo/tk11899
Return code differences in wolfSSL_EVP_PKEY_cmp et al.
2021-03-26 09:36:52 -07:00
toddouska
212be50a23 Merge pull request #3899 from SparkiDev/shake256_improve
SHA-3: Improve SHAKE256 change to support longer output
2021-03-26 09:35:52 -07:00
toddouska
bb7dce8b46 Merge pull request #3921 from SparkiDev/sp_modinv_win
SP MSVC: movslq -> movsxd
2021-03-26 09:34:15 -07:00
Sean Parkinson
1b832bf8fa SHA-3: Improve SHAKE256 change to support longer output
Added tests for 1 complete block output and longer from NIST's CAVP
tests vectors.
2021-03-26 14:59:12 +10:00
Sean Parkinson
a188ef251c SP MSVC: movslq -> movsl 2021-03-26 14:12:58 +10:00
Elms
4eb4cecff4 INTIME: whitespace fixup and zero context in wc_ReadDirFirst 2021-03-25 10:54:05 -07:00
David Garske
c9b5806575 Fix for ecc_mulmod_fast broken in PR #3868. The "t" needs 1 extra point for "rt". 2021-03-25 09:19:17 -07:00
Sean Parkinson
d8a81d0c0f SP C 32/64: fix corner cases around subtraction
Affected RSA PSS
2021-03-25 16:19:54 +10:00
David Garske
64555cdd11 Merge pull request #3907 from JacobBarthelmeh/CAAM 2021-03-24 18:47:47 -07:00
Sean Parkinson
08ea90ad94 Merge pull request #3905 from dgarske/sp_nb_sync
SP ECC: Fix for non-blocking test and synchronization of changes
2021-03-25 10:35:30 +10:00
JacobBarthelmeh
e074513d38 fix for memory management with mmap function calls 2021-03-25 01:32:37 +07:00
David Garske
a6851a44af Fix for ECC non-blocking test R/S values not zero padded causing occasstional wolfCrypt test failures with ./configure --enable-ecc=nonblock --enable-sp=yes,nonblock CFLAGS="-DWOLFSSL_PUBLIC_MP". 2021-03-23 17:32:36 -07:00
David Garske
a6e9e71fde Synchronization of SP ECC non-blocking code. Adds WOLFSSL_ECDSA_SET_K_ONE_LOOP support to SP ECC non-block. Removes double code in verify steps. Fixes verify result logic. Spelling error. 2021-03-23 17:30:56 -07:00
toddouska
14ef517b61 Merge pull request #3884 from SparkiDev/tfm_read_bin
TFM read_unsigned_bin: endian may not be defined
2021-03-23 14:47:18 -07:00
toddouska
d539dc59be Merge pull request #3903 from SparkiDev/sha2_arm
ARMv8 SHA256, SHA512: Add wc_Sha256Transform, wc_Sha512Transform
2021-03-23 14:46:45 -07:00
toddouska
1643bec05f Merge pull request #3862 from kaleb-himes/WIN32_WCE_PORTING
_WIN32_WCE port of wolfCrypt - OE12
2021-03-23 14:40:48 -07:00
toddouska
6134de6a22 Merge pull request #3855 from miyazakh/openssl_ext_r2
Compatibility layer API addition
2021-03-23 14:37:47 -07:00
Sean Parkinson
089ebf277f ARMv8 SHA256, SHA512: Add wc_Sha256Transform, wc_Sha512Transform 2021-03-23 12:53:06 +10:00
kaleb-himes
b3eb2e3ddd Implement peer review feedback
Fix items that were missed from peer review

Remove dead code

Add ret capture of return from XVSNPRINTF
2021-03-22 11:55:16 -06:00
JacobBarthelmeh
b7ac12edb6 account for leading 0's with r and s during ECC verify 2021-03-22 18:16:21 +07:00
Sean Parkinson
24b67599c8 Merge pull request #3896 from strongX509/wolfssl-shake256
Full implementation of SHAKE256
2021-03-22 09:57:05 +10:00
TakayukiMatsuo
a1ff026670 Revert the change of wolfSSL_EVP_CHIPER_CTX_cleanup. 2021-03-21 00:14:57 +09:00
Elms
c3e6195da5 INTIME: add support for directory file search
Directory support allows CRL use with undefining `NO_WOLFSSL_DIR`

Also increase stack size to avoid page fault and add
`_USE_64BIT_TIME_T` to example project to pass ASN test
2021-03-20 00:53:02 -07:00
toddouska
a0a1406a43 Merge pull request #3894 from SparkiDev/eccsi_sakke_g++
ECCSI/SAKKE: fix for g++
2021-03-19 14:03:06 -07:00
Chris Conlon
19c321f165 Merge pull request #3891 from JacobBarthelmeh/PKCS7
adjust size when streaming with PKCS7 verify
2021-03-19 11:53:38 -06:00
David Garske
761bebc4a0 Merge pull request #3893 from SparkiDev/sp_dyn_stack
SP dyanmic stack: WOLFSSL_SP_NO_DYN_STACK disable use
2021-03-19 10:53:02 -07:00