Commit Graph

17590 Commits

Author SHA1 Message Date
Chris Conlon
350ff552c4 Merge pull request #5351 from kojo1/renesas-csp 2022-07-14 16:10:34 -06:00
David Garske
e3c65d86d6 Merge pull request #5360 from LinuxJedi/se050-sign-fix-b
Missed a small part of my original SE050 sign fix
2022-07-14 06:39:11 -07:00
Andrew Hutchings
3f390efb24 Missed a small part of my original SE050 sign fix
Empty keyId handling now exists so we shouldn't return `BAD_FUNC_ARG`.
2022-07-14 07:47:33 +01:00
Andrew Hutchings
c211b90aab Merge pull request #5357 from dgarske/se050_fixes
Fixes for SE050 ED25519 private key loading and Curve25519/ECC handle leak
2022-07-14 07:14:54 +01:00
Andrew Hutchings
5098cdcd76 Merge pull request #5356 from dgarske/asn_rfc8410
Fixes for ED25519/ED448 private key with public key export (RFC8410)
2022-07-14 07:11:03 +01:00
Sean Parkinson
b69af856de Ed ASN template: change for IMPLICIT public key in private key
Fix KATs in test.c to match new expected format.
2022-07-14 10:19:43 +10:00
David Garske
2d5bc72c9b Fixes for ED25519/ED448 private key with public key export (RFC8410). Added length only support. 2022-07-13 16:17:08 -07:00
David Garske
586ae71dac Fixes for SE050 ECC and Curve25519 with TLS. 2022-07-13 10:50:10 -07:00
David Garske
a2b7b44163 Merge pull request #5342 from Uriah-wolfSSL/dtls_for_win
Example DTLS v1.3 build settings for Windows Visual Studio
2022-07-13 09:27:46 -07:00
David Garske
065991bab5 Merge pull request #5348 from douzzer/20220707-attend-return-values
20220707-attend-return-values
2022-07-13 08:50:29 -07:00
Takashi Kojo
69bf0345c4 Renesas cs+ project. Remove depreciated algorithms 2022-07-13 10:24:44 +09:00
Daniel Pouzzner
dc231dc099 peer review: add explanatory comment for printf() macro in test.c; rearrange test.h to avoid awkward forward declaration and add some topical grouping. 2022-07-12 18:19:52 -05:00
Uriah-wolfSSL
a4e452ec6a New file for adding needed configuration options to enable DTLS including DTLS version 1.3. This is an example file to be used for testing, eval, demos, etc. 2022-07-12 15:53:21 -05:00
Uriah-wolfSSL
357ace8408 * Updated README.txt w/ how to use user_settings_dtls.h.
* Added dtls13.c to build project files.
* Added user_settiings.dtls.h to include.am.
2022-07-12 15:53:21 -05:00
Daniel Pouzzner
b64949d564 wolfcrypt/benchmark/benchmark.c: fix gating for #include <errno.h>, and add #include <unistd.h> for _exit(). 2022-07-11 23:15:43 -05:00
Daniel Pouzzner
ccc5952369 global fixup to check or explicitly ignore return values from failable library/system calls that weren't already being checked;
add wolfCrypt error codes IO_FAILED_E "Input/output failure" and SYSLIB_FAILED_E "System/library call failed";

tests/api.c and tests/unit.c: flush stdout for error message in Fail() macro, add fflush(stdout) after printf()s, print success message at end of unit_test(), and send several error messages to stderr instead of stdout;

wolfcrypt/test/test.c: add fallthrough macro definition of printf() that pairs it with fflush(stdout);

unit.h: in definition of macro AssertPtr(), add PRAGMA_GCC("GCC diagnostic ignored \"-Wpedantic\"");

sp_int.c: refactor several lingering instances of "if (0) { ... }" code pattern to #if 0 ... #endif.
2022-07-11 22:28:09 -05:00
David Garske
e30899b676 Merge pull request #5334 from LinuxJedi/se050-fixes
Fixes to SE050 port
2022-07-11 16:15:08 -07:00
JacobBarthelmeh
22c3a1fc6f Merge pull request #5346 from dgarske/async_rel_v5.4.0
Async release v5.4.0 patches
2022-07-11 17:11:06 -06:00
David Garske
34c576d2a7 Fixes for possible NULL dereference for heap hint in pk.c Fix typo in api.c test for dynamic type. 2022-07-11 14:41:11 -07:00
David Garske
57aac1c50b Merge pull request #5345 from JacobBarthelmeh/release
Release version 5.4.0
v5.4.0-stable
2022-07-11 11:10:10 -07:00
JacobBarthelmeh
a48129eb99 update README for release 2022-07-11 07:28:15 -07:00
JacobBarthelmeh
032d59b077 adjust sizeof type for getsockopt argument 2022-07-11 07:10:11 -07:00
JacobBarthelmeh
86662bca2f update library version to 5.4.0 2022-07-08 16:04:26 -07:00
JacobBarthelmeh
7379e377ab cast for g++ warning 2022-07-08 15:11:29 -07:00
JacobBarthelmeh
983b9fc5fb Merge pull request #5343 from dgarske/ecc_oid_coding
Fixes for ECC OID encoding/decoding
2022-07-08 15:38:47 -06:00
David Garske
4892435004 Fix for wc_ecc_get_curve_id_from_oid with combinations of HAVE_OID_ENCODING and HAVE_OID_DECODING. Fix in SetCurve for unused outSz with HAVE_OID_ENCODING. 2022-07-08 13:00:09 -07:00
JacobBarthelmeh
66aed8193a Merge pull request #5341 from dgarske/various_20220708
Various fixes and cleanups
2022-07-08 13:56:51 -06:00
David Garske
56325143f1 Merge pull request #5340 from anhu/micrium_alt_ecc_size
Gate ALT_ECC_SIZE on NO_MALLOC and STATIC_MEMORY since they conflict.
2022-07-08 09:53:07 -07:00
David Garske
720030b5a9 Improvements to error handling for AddSessionToClientCache. 2022-07-08 09:06:51 -07:00
David Garske
03a32250da Fix for KCAPI HMAC forcing use of software for HKDF. 2022-07-08 09:06:30 -07:00
David Garske
3d124c093e Fix PK function name in log. Remove the ECC logging (spams benchmark with --enable-debug). 2022-07-08 09:06:08 -07:00
David Garske
905f71d80d Fix with macro redefinition error if building with NO_WOLFSSL_ALLOC_ALIGN. 2022-07-08 09:05:29 -07:00
JacobBarthelmeh
f7595cc77d Merge pull request #5338 from julek-wolfssl/tcp-sendto
sendto can't specify addr on a TCP socket
2022-07-08 09:39:39 -06:00
Anthony Hu
2d6b6d62b2 Gate ALT_ECC_SIZE on NO_MALLOC and STATIC_MEMORY since they conflict. 2022-07-08 10:52:01 -04:00
David Garske
a2b75e313a Merge pull request #5339 from douzzer/20220708-DUW_TEST-bugprone-macro-parentheses
tests/api.c: fix bugprone-macro-parentheses in DUW_TEST().
2022-07-08 07:46:20 -07:00
Daniel Pouzzner
48d3cf593e tests/api.c: fix bugprone-macro-parentheses in DUW_TEST(). 2022-07-08 07:57:29 -05:00
Juliusz Sosinowicz
251642a44a sendto can't specify addr on a TCP socket
From the man page
       If  sendto()  is used on a connection-mode (SOCK_STREAM, SOCK_SEQPACKET) socket, the arguments dest_addr and
       addrlen are ignored (and the error EISCONN may be returned when they are not NULL  and  0),  and  the  error
       ENOTCONN  is  returned  when the socket was not actually connected.
2022-07-08 12:14:23 +02:00
David Garske
58cb91602d Merge pull request #5337 from douzzer/20220707-DtlsUpdateWindowGTSeq-overshift
20220707-DtlsUpdateWindowGTSeq-overshift
2022-07-07 21:53:26 -07:00
David Garske
c9e9a421e9 Merge pull request #5336 from SparkiDev/aes_ctr_opt
AES-CTR: improve performance when multiple blocks
2022-07-07 21:51:08 -07:00
Daniel Pouzzner
91438c1087 wolfssl/wolfcrypt/settings.h: refactor Math Library Selection for clarity, and to include WOLFSSL_SP_MATH as an available math back end. 2022-07-07 21:02:16 -05:00
David Garske
49d292ec4f Merge pull request #5335 from SparkiDev/ecc_imp_exp_fix
ECC import and export fixes
2022-07-07 17:52:20 -07:00
Daniel Pouzzner
b952c2f777 src/internal.c: add codepath in _DtlsUpdateWindowGTSeq() to avoid a word32 overshift. 2022-07-07 19:36:20 -05:00
Sean Parkinson
2bfac42d65 AES-CTR: improve performance when multiple blocks
When in and out aren't the same pointer, for multiples of block size
input:
  - generate the counters into the output buffer
  - encrypt output buffer
  - XOR in the input
Faster than encrypting a block at a time.
2022-07-08 09:56:20 +10:00
Sean Parkinson
70b9833e98 ECC import and export fixes
On raw import, don't import ordinates that are larger than the curve
size.
On export of compressed point, don't export ordinate if it is larger
than the curve size.
2022-07-08 08:54:53 +10:00
David Garske
4e1e1e922a Merge pull request #5278 from ejohnstown/dtls-seq
Refactor DTLS Window Update (Fix #5211)
2022-07-07 10:22:21 -07:00
Chris Conlon
5e453ad932 Merge pull request #5323 from SparkiDev/sha512_arm32_asm_align 2022-07-07 09:47:37 -06:00
Juliusz Sosinowicz
e295328436 Fix window handling around word32 boundary 2022-07-07 17:37:10 +02:00
Andrew Hutchings
34d897e433 Fixes to SE050 port
This fixes the following things:

* Memory leaks in SE050 SHA messages
* Add key to SE050 for ECC sign hash function
* Remove circular include
* Correct prototype for `se050_hash_final`
* A few defined check fixes
2022-07-07 16:11:54 +01:00
David Garske
a771baf551 Merge pull request #5332 from SparkiDev/memusage_fix_2
SP math: fix configure.ac to allow its use
2022-07-07 07:40:13 -07:00
David Garske
738d79c5d5 Merge pull request #5330 from SparkiDev/aesni_no_sse4
AESNI: fix configure to use minimal compiler flags
2022-07-06 20:44:40 -07:00