19772 Commits

Author SHA1 Message Date
Sean Parkinson
d2afe9e5e0 Memory usage improvements
ECC: make private key field 'k' able to be smaller when ALT_ECC_SIZE is
defined.
WOLFSSL_SMALL_STACK_CACHE: allocate temps using new macros.
2023-05-04 10:26:57 +10:00
John Bland
6369b1e9ec
Merge pull request #6371 from dgarske/lowres
Fixes and improvements for building with low footprint
2023-05-03 19:33:53 -04:00
David Garske
714ec82e91
Merge pull request #6369 from rizlik/dh-async-fix
async fixes: dh and tests
2023-05-03 07:50:23 -07:00
JacobBarthelmeh
f05543c9e5
Merge pull request #6370 from SparkiDev/sp_int_copy_change
SP int: _sp_copy don't check a == b, change calls to _sp_copy
2023-05-03 08:30:55 -06:00
David Garske
4b90afa37b Provide way to disable ASN but have wc_RsaPublicKeyDecodeRaw, which doesn't need ASN.1 parsing. 2023-05-02 18:10:25 -07:00
David Garske
61dfbf5ef2 Fixes and improvements for building with low footprint. Fix for ASN template with RSA verify only (was missing mp_leading_bit). Fix to allow disabling DRBG with crypto callbacks enabled. Updated the wolfTPM user_settings.h template with low resource option. 2023-05-02 16:51:41 -07:00
Sean Parkinson
1a8f09d013
Merge pull request #6320 from JacobBarthelmeh/curl
smaller sized build with curl
2023-05-03 07:46:29 +10:00
Sean Parkinson
c3a8476b95 SP int: _sp_copy don't check a == b, change calls to _sp_copy
Simplify code to make it easier for software analysers.
Reduce work done by using _sp_copy instead of sp_copy where possible.
2023-05-03 07:44:28 +10:00
JacobBarthelmeh
11a77f7078
Merge pull request #6363 from dgarske/threadlocal
Add option to support disabling thread local storage
2023-05-02 15:12:13 -06:00
JacobBarthelmeh
58b996353b
Merge pull request #6266 from dgarske/zd15938_async_ecc
Fix for async ECC shared secret state
2023-05-02 12:01:31 -06:00
Marco Oliverio
a5a2316aa4 async: fix overwrite of keylen params between calls
The `kse->pubKeyLen` parameter is used as an input parameter to `DhGenKeyPair`
to provide the size of the `pubKey` buffer (the same size as the prime p). After
that, `kse->pubKeyLen` is used to check that the public key generated is of the
same length as the prime p. If this is not the case, the public key is
padded. If the key generation is asynchronous, then `TLSX_KeyShare_GenDhKey` may
be invoked twice. The second time, the `kse->pubKeyLen` value, updated
asynchronously by the async code, is overwritten with the prime size at the
beginning of the function. When this happens, a wrong public key value is used,
and the shared secret computed is incorrect.

Similar reasoning can be applied to `kse->keyLen`
2023-05-02 16:34:15 +00:00
Marco Oliverio
3e4b95eb4b test: fix test AEAD limit server set fds as nonblock 2023-05-02 16:34:01 +00:00
JacobBarthelmeh
bdd45350c5
Merge pull request #6361 from bandi13/minorContainerUpdates
Minor container updates
2023-05-01 17:05:36 -06:00
David Garske
ceeda82906 Add option to support disabling thread local --disable-threadlocal. Useful for cross-compile situation where thread local storage is not desired. ZD 16062 2023-05-01 15:51:22 -07:00
JacobBarthelmeh
06d5897233
Merge pull request #6362 from dgarske/stm32_hash
Improved fix for STM32 hashing on U5
2023-05-01 16:30:57 -06:00
David Garske
72ffa743a0 Fix for async ECC shared secret. ZD 15938 2023-05-01 15:30:03 -07:00
JacobBarthelmeh
ef955c620f refactor evp.c to group all MD digest functions togther 2023-05-01 13:23:48 -07:00
David Garske
7576380635 Improved fix for STM32 hashing on U5 2023-05-01 13:13:00 -07:00
JacobBarthelmeh
c84abaf5b6
Merge pull request #6357 from kareem-wolfssl/gh6348
Fix wc_PeekErrorNodeLineData not unlocking error queue on error.
2023-05-01 13:59:35 -06:00
JacobBarthelmeh
45c8796f7c
Merge pull request #6355 from bandi13/minorBugfix
Should only move the index by the amount we wrote
2023-05-01 13:56:22 -06:00
Andras Fekete
931f665a9a Missing 'tcpdump' utility 2023-05-01 15:30:12 -04:00
Andras Fekete
00fa00f875 Changes to make it possible to use a different base container 2023-05-01 15:28:39 -04:00
JacobBarthelmeh
73b3f9c01a
Merge pull request #6356 from lealem47/init_values
Fix uninitialized variable compiler warning
2023-05-01 09:18:48 -06:00
Kareem
f6cdcfcf9f Fix wc_PeekErrorNodeLineData not unlocking error queue on error. 2023-04-28 16:35:49 -07:00
Lealem Amedie
99b4ee50ba Fix uninitialized variable compiler warning 2023-04-28 13:58:29 -06:00
Andras Fekete
1522155892 Should only move the index by the amount we wrote 2023-04-28 14:08:15 -04:00
David Garske
52a20fc2b5
Merge pull request #6328 from julek-wolfssl/zd/16000
Allow cert callback to override skipAddCA
2023-04-28 10:25:13 -07:00
Juliusz Sosinowicz
13f4e178e5
Zephyr misc fixes for TLS (#6353)
* zephyr wolfssl_tls_sock: fix project name

* zephyr tls_sock.c: don't include options.h when using user settings

* zephyr: define XSTAT_TYPE for use with XSTAT
2023-04-28 10:00:24 -07:00
JacobBarthelmeh
6b2aca1418
Merge pull request #6347 from SparkiDev/sp_int_armv6_clz
SP int ARMv6: clz not available, correct #if
2023-04-28 09:43:58 -06:00
Juliusz Sosinowicz
36ac816cd1
Merge pull request #6342 from TakayukiMatsuo/unittest 2023-04-28 10:06:04 +02:00
Sean Parkinson
f8559b745e
Merge pull request #6351 from douzzer/20230427-linuxkm-simd-fixes
20230427-linuxkm-simd-fixes
2023-04-28 11:20:20 +10:00
Sean Parkinson
e4bf1a7c0b
Merge pull request #6350 from kareem-wolfssl/zd15670
Fix PowerPC inline assembly on old GNU toolchain.
2023-04-28 11:19:42 +10:00
Daniel Pouzzner
448f1ec9e7 linuxkm: in {save,restore}_vector_registers_x86(), check if vector register file has already been saved and invalidated, and if so, inhibit the kernel_fpu_{begin,end}() wrap and instead just use preempt_{disable,enable}() wraps. 2023-04-27 17:48:32 -05:00
Daniel Pouzzner
8a89303b49 wolfcrypt/test/test.c: add TEST_FAIL() macro (counterpart to incumbent TEST_PASS()), by default same as incumbent functionality, but #ifdef TEST_ALWAYS_RUN_TO_END, print errors as they occur but continue to end. 2023-04-27 17:46:56 -05:00
Daniel Pouzzner
3f60fa8c3b configure.ac: escape backslashes when generating preprocessor directives for .build_params; delete backslashes and process parenthesized arguments correctly when generating options.h. 2023-04-27 17:38:29 -05:00
Hideki Miyazaki
dcd1428b7d
Merge pull request #6304 from TakayukiMatsuo/jpupdate
Update Japanese comments
2023-04-28 07:06:38 +09:00
Kareem
1172354664 Fix PowerPC inline assembly on old GNU as. It does not like an empty clobbered register line, so simply omit the line. 2023-04-27 14:54:51 -07:00
JacobBarthelmeh
7b52913451
Merge pull request #6345 from kareem-wolfssl/zd16035
Fix getting key size in stm32_ecc_sign_hash_ex.
2023-04-27 13:32:47 -06:00
JacobBarthelmeh
bbad64649b
Merge pull request #6340 from SparkiDev/minor_fixes_1
Minor fixes
2023-04-27 10:02:06 -06:00
TakayukiMatsuo
59472312a5 Fix example code in wolfSSL_get_chain_X509 2023-04-27 17:51:10 +09:00
Juliusz Sosinowicz
bf2c66a1cb Allow cert callback to override skipAddCA 2023-04-27 10:07:04 +02:00
TakayukiMatsuo
4c47934562 Fix issues in test_wolfSSL_dtls_fragments 2023-04-27 17:00:29 +09:00
Sean Parkinson
d901433999 SP int ARMv6: clz not available, correct #if
Checking for architecture less than 7 to use clz instruction when clz is
only guaranteed to be available in 7 or more. Reverse logic.
2023-04-27 09:41:31 +10:00
JacobBarthelmeh
ca4a17ebf6
Merge pull request #6339 from SparkiDev/asn_orig_ocsp_fix
ASN original, OCSP: fix maximum size calc to GetDateInfo
2023-04-26 16:36:55 -06:00
Kareem
e7e2713bba Fix getting key size in stm32_ecc_sign_hash_ex. 2023-04-26 15:00:59 -07:00
JacobBarthelmeh
ccb9bdd903
set dev ID with signature check (#6318)
* set dev ID with signature check

* refactor devId use and add API to set devId in WOLFSSL_CERT_MANAGER structure

* add api.c call to set devid with WOLFSSL_CERT_MANAGER

* resolving devID CRL issue and CM pointer

* add device find callback

* add simple test case
2023-04-26 11:19:00 -07:00
David Garske
3556b7adb7
Merge pull request #6338 from JacobBarthelmeh/certs
revert WOLFSSL_NO_ASN_STRICT macro guard
2023-04-26 11:16:04 -07:00
David Garske
b42d3566ab
Merge pull request #6336 from lealem47/useAfterFree
Remove XMEMSET after XFREE in sniffer.c
2023-04-26 10:50:00 -07:00
JacobBarthelmeh
32c6a66a4e
Merge pull request #6341 from douzzer/20230425-analyzer-coddling
20230425-analyzer-coddling
2023-04-26 11:22:23 -06:00
Chris Conlon
4526df6d78
Merge pull request #6199 from JacobBarthelmeh/PKCS7
add messageDigest attribute if adding any custom signed attributes
2023-04-26 09:23:22 -06:00