Compare commits

...

2555 Commits

Author SHA1 Message Date
f1e2165c59 Merge pull request #5638 from JacobBarthelmeh/release 2022-09-27 14:21:19 -07:00
eb5076bb89 update changelog for release 5.5.1 2022-09-27 13:40:00 -06:00
ffe052e845 Merge pull request #5634 from douzzer/20220926-fixes
20220926-fixes
2022-09-27 11:49:20 -06:00
dde5ef558b Merge pull request #5633 from SparkiDev/sp_mod_fix
SP int all: sp_mod
2022-09-27 10:23:03 -06:00
cc03e3fdab wolfcrypt/src/misc.c ByteReverseWords(): mollify MSVC re C4311. 2022-09-27 10:05:07 -05:00
cfe0278d35 wolfcrypt/src/misc.c ByteReverseWords(): fix misaligned word accesses under armv7a-asm. 2022-09-27 02:02:31 -05:00
1ffe4275ae fix whitespace 2022-09-26 23:32:59 -05:00
34fd412fd6 SP int all: sp_mod
sp_mod wasn't checking return of sp_init_size.
Add _sp_init_size change and change calls.
2022-09-27 10:05:13 +10:00
8617de86c1 Merge pull request #5632 from JacobBarthelmeh/Testing
Misc. testing items
2022-09-27 08:25:18 +10:00
1e348eb7bd sanity check on return value 2022-09-26 10:40:41 -07:00
cc4e8df56d cast to fix warning in test case 2022-09-26 10:13:06 -07:00
9d9fa0132e Merge pull request #5622 from lealem47/sniffer_sequence
Fix for sniffer to decode out of order packets
2022-09-26 07:53:00 -07:00
b4077d80c9 Merge pull request #5620 from JacobBarthelmeh/Certs
fix for return value of x509 print
2022-09-25 19:32:52 -07:00
b1a69f6469 Merge pull request #5630 from dgarske/deos_cleanups
Support for DEOS RTEMS and minor build fixes
2022-09-26 09:06:49 +10:00
55a0f6d97b Support for RTEMS in the DEOS user_settings.h template and time. Fix for bio.c and OPENSSL_EXTRA which needs XATOI. Fix for SP math ECC with 384-bit and 521-bit curves enabled. 2022-09-25 10:41:05 -07:00
f80fb7f1aa Merge pull request #5625 from dgarske/esp32_cleanups
Fixes for various build configurations
2022-09-23 20:46:44 -05:00
221fd275fd Fixes for building without SHAKE. 2022-09-23 14:50:16 -07:00
2421727b1c Merge pull request #5441 from kareem-wolfssl/quietShutdown
Make wolfSSL quiet_shutdown functions available when using OPENSSL_EXTRA_X509_SMALL.
2022-09-23 14:40:29 -07:00
606f58a851 Spelling and whitespace cleanups. 2022-09-23 13:58:58 -07:00
b42631c721 Fix for ESP32 wolfcrypt_test entry point. 2022-09-23 13:58:49 -07:00
792eac9484 Fixes for building the API unit test without filesystem NO_FILESYSTEM. 2022-09-23 13:58:17 -07:00
7a69415e79 Fix for possible memory leak on failure in RSA/DH public key decode with heap based math. 2022-09-23 13:53:16 -07:00
c29e602ea5 Fix for building with WOLFSSL_ASN_TEMPLATE and IGNORE_NAME_CONSTRAINTS. 2022-09-23 13:52:55 -07:00
7970d5d794 Merge pull request #5152 from SparkiDev/armv7a_neon_asm
ARM ASM: ARMv7a with NEON instructions
2022-09-23 08:46:03 -07:00
62670d9263 Merge pull request #5619 from kaleb-himes/AZURE-fix2
Fix undesirable kyber dependencies when not building kyber (#2)
2022-09-22 19:55:50 -07:00
1b9656f72d ARM ASM: add fpu directive to assembly files 2022-09-23 12:31:39 +10:00
aa1a95e70b Merge pull request #5621 from tmael/sp_1024_sakke
Wrap 1024 single precision math with WOLFCRYPT_HAVE_SAKKE
2022-09-23 08:52:05 +10:00
a322e09150 Fix for sniffer to decode out of order packets 2022-09-22 15:12:51 -07:00
7805ffeee0 Fix enable-sp=1024 2022-09-22 14:03:40 -07:00
f113e92495 Merge pull request #5612 from kareem-wolfssl/base16Ending
Update Base16_Encode so the ending null terminator is optional.
2022-09-22 13:24:19 -07:00
938ab16907 Also address assembly file 2022-09-22 14:15:46 -06:00
39815a53fa fix for return value of x509 print 2022-09-22 14:09:50 -06:00
77676537f6 Fix undesirable kyber dependencies when not building kyber (#2) 2022-09-22 10:43:03 -06:00
7ca9e4f084 Merge pull request #5616 from julek-wolfssl/dtls13.test-proxy-path
dtls13.test: Allow setting UDP_PROXY_PATH in env
2022-09-22 09:15:32 -07:00
13555bebcd Merge pull request #5617 from kaleb-himes/FIX-AZURE-TEST
Fix undesirable kyber dependencies when not building kyber
2022-09-22 09:04:35 -07:00
f271bef7b5 Merge pull request #5618 from lealem47/dc
Fix for incorrect DN NID and confusion with DC
2022-09-21 15:00:25 -07:00
216d4afaad Merge pull request #5611 from tim-weller-wolfssl/zd14815-updates
Updates to remove build warnings and test/example code update to avoid memory leak
2022-09-21 14:33:37 -07:00
f177d9364a Fix for incorrect DN NID and confusion with DC 2022-09-21 13:11:12 -07:00
62766b0758 Updates to remove warnings and build issues found with IAR tools. Update test function / example to avoid memory leak. Update to pass error codes along rather than mask them at lower levels.
Make logic to avoid masking return error conditionally compiled based on STSAFE configuration

Update logic at second crypto-callback location to return error code rather than mask it
2022-09-21 14:16:49 -05:00
913bbc8f79 Merge pull request #5613 from kareem-wolfssl/staticEccFix
Fix bad casts in wc_EccPublicKeyDecode when using WOLFSSL_ECC_CURVE_STATIC with custom curves.
2022-09-21 11:38:06 -07:00
38d4df0c0f Merge pull request #5610 from kareem-wolfssl/v5Fips
Restore v5-dev/v5-ready configure options.
2022-09-21 12:56:27 -05:00
680182cab5 Merge pull request #5614 from rizlik/oobread
Fix: parsing oob read in dtls1.3
2022-09-21 10:08:32 -07:00
d672f10f7e Fix undesirable kyber dependencies when not building kyber 2022-09-21 09:58:38 -06:00
2bf583aa57 Merge pull request #5526 from miyazakh/qt_jenkins_fix
Fix qt nightly test failure
2022-09-21 09:38:45 -06:00
f9b2ef47c9 dtls13.test: Allow setting UDP_PROXY_PATH in env 2022-09-21 16:49:53 +02:00
400d3c6963 dtls13: Dtls13ParseUnifiedRecordLayer: add overflow check 2022-09-21 16:01:35 +02:00
804081e7c2 fix: GetDtls13RecordHeader:requires correct minimum size 2022-09-21 16:01:35 +02:00
a36604079b Merge pull request #5609 from philljj/master
Fixes DTLS 1.3 client use-after-free error
2022-09-21 06:38:09 -07:00
2578f2c8f2 ARMv8 32 Inline ASM: fixes
Force parameters to use specific registers.
Shift/rotate amount must have '#' prepended.
2022-09-21 10:45:50 +10:00
ca392fb200 ARM32 ASM Inline: fix SHA-256 inline asm to compile 2022-09-21 09:58:16 +10:00
c6bd297bd2 Fix bad casts in wc_EccPublicKeyDecode when using WOLFSSL_ECC_CURVE_STATIC with custom curves. 2022-09-20 15:37:12 -07:00
c146fcf581 Update Base16_Encode so the ending null terminator is optional. 2022-09-20 14:44:01 -07:00
76afcc1da4 Restore v5-dev/v5-ready configure options as customers are currently using them. 2022-09-20 14:26:15 -07:00
90c9363af8 Merge pull request #5538 from satoshiyamaguchi/trial5
Add wolfSSL_EVP_PKEY_new_CMAC_key to OpenSSL compatible API
2022-09-20 13:01:52 -07:00
427383233d Fix formatting, add check to not support plain HTTP requests in DTLS 2022-09-20 14:41:11 -05:00
624aca80dc Merge pull request #5606 from julek-wolfssl/zd14813-cont
0 len sz is allowed
2022-09-20 09:49:17 -07:00
8336dbf366 Fixes DTLS 1.3 client use-after-free error 2022-09-20 09:17:08 -05:00
c6ea68a118 Fix two not freed WOLFSSL_CMAC_CTX. 2022-09-20 23:10:22 +09:00
43715d1bb5 Merge pull request #5607 from haydenroche5/140_3_version_fixes
Clean up some FIPS versioning logic in configure.ac and WIN10 user_settings.h.
2022-09-19 20:48:25 -06:00
d212974d5e Clean up some FIPS versioning logic in configure.ac and WIN10 user_settings.h.
configure.ac: Get rid of v5-RC8, v5-RC9, v5-RC10, v5-RC11, v5-ready, and v5-dev.
v5-ready is now just ready and v5-dev just dev.
IDE/WIN10/user_settings.h: Make the FIPS blocks define HAVE_FIPS. Change WCv5.0
block to WCv5.0-RC12. Change FIPS Ready block to use HAVE_FIPS_VERSION_MINOR 3
instead of HAVE_FIPS_VERSION_MINOR 2.
2022-09-19 15:26:06 -07:00
73dbc873bd Merge pull request #5586 from julek-wolfssl/dtls-misc-security
Add missing minor security checks
2022-09-19 09:47:00 -07:00
cf3d9df443 Merge pull request #5605 from julek-wolfssl/gitignore
Add async and fips test folders to gitignore
2022-09-19 09:36:06 -07:00
0b81a584cc Merge pull request #5604 from SparkiDev/mp_init_size_fizes_2
SP int: mp_init_size fixes when SP_WORD_SIZE == 8
2022-09-19 06:50:26 -07:00
8ca4a6086e 0 len sz is allowed
In async mode, we always store all handshake messages before processing them. The server hello done message has a length of 0 but we still need to store it to process it.
2022-09-19 14:00:13 +02:00
9eac8bf5a9 Add async and fips test folders to gitignore 2022-09-19 11:42:45 +02:00
23e9cf2dc1 Test AEAD limits only without WOLFSSL_TLS13_IGNORE_AEAD_LIMITS 2022-09-19 10:30:29 +02:00
dd32f30306 Merge pull request #5601 from douzzer/20220917-fixes
20220917-fixes
2022-09-19 13:50:25 +10:00
e7dba670d6 SP int: mp_init_size fix for sp_mont_norm
sp_mont_norm should check wrong parameter when determining whether the
calculation values will fit.
2022-09-19 10:04:30 +10:00
02e51953fd SP int: mp_init_size fixes when SP_WORD_SIZE == 8
Setting an integer may have a value larger than one word being set.
Check size of SP int in this case.
2022-09-19 09:26:47 +10:00
e43a7843b6 Merge pull request #5603 from kaleb-himes/scripts-update
Address Issue pointed out in (now deleted) comment on an old merge
2022-09-19 09:06:39 +10:00
9a193a3e02 Address Issue pointed out in (now deleted) comment on an old merge 2022-09-18 08:45:18 -06:00
001592a8a3 fix qt nightly test 2022-09-18 13:56:55 +09:00
ac0d7f4d84 src/internal.c:
in DtlsMsgNew(), iff WOLFSSL_ASYNC_CRYPT, allow sz==0 allocation, to fix infinite loop in ProcessReplyEx() around DoDtlsHandShakeMsg();

in DtlsMsgAssembleCompleteMessage() restore fix from 0603031362 for pointerOutOfBounds (undefined behavior) construct;

in ProcessReplyEx(), in WOLFSSL_DTLS13 case ack, check and propagate error from DoDtls13Ack() (fix from @guidovranken).
2022-09-17 13:02:51 -05:00
0fc80f5f85 wolfcrypt/src/sp_int.c: catch and propagate errors from sp_init_size() in sp_invmod() and sp_gcd() to fix clang-analyzer-core.UndefinedBinaryOperatorResult. 2022-09-17 12:55:48 -05:00
02cc7bf82e fix whitespace/linelength/indentation. 2022-09-17 12:53:37 -05:00
64f2a0cafe Extend wolfSSL_EVP_PKEY_free for freing EVP_PKEY of CMAC.
Fix EVP_PKEY not freed in unit test (test_wolfSSL_EVP_PKEY_new_CMAC_key).
2022-09-17 14:44:45 +09:00
e6bd6a94a0 Merge pull request #5521 from TakayukiMatsuo/clientverify 2022-09-16 16:55:38 -06:00
7a728c0c48 Merge pull request #5569 from SparkiDev/kyber
Kyber: Add option to build Kyber API
2022-09-16 14:56:02 -06:00
c6f6086b15 Merge pull request #5576 from julek-wolfssl/dtls-windows
Fix build errors and warnings for MSVC with DTLS 1.3
2022-09-16 11:11:46 -06:00
b780ad6da0 Merge pull request #5594 from julek-wolfssl/zd14813
Do not allow 0 size DtlsMsg
2022-09-16 10:21:54 -06:00
43b16f67b9 Merge pull request #5596 from SparkiDev/mac_m1_arm_sha256_fix
Aarch64 SHA-256 Mac M1 fix
2022-09-16 09:13:23 -07:00
24d0112d2c Merge pull request #5581 from SparkiDev/sp_int_size_fix
SP int: mp_init_size() fix
2022-09-16 08:29:06 -07:00
a948c78ac7 addressed review comments. remove Qt case guard 2022-09-16 21:25:42 +09:00
9ef10b5435 Check return of DtlsMsgCreateFragBucket() 2022-09-16 12:13:12 +02:00
bf4be901e4 Add prototypes for w64wrapper functions 2022-09-16 11:28:29 +02:00
4b3718543e Aarch64 SHA-256 Mac M1 fix
Inline assembly is told K when finished is not important but K is
changing. Take a local copy of K and mark as a changing value.
2022-09-16 13:20:48 +10:00
7062ed0a2c ChaCha ARM 32-bit: get debug working
r7 is needed for debug.
Needed to use stack explicitly rather than let compiler use r7.
2022-09-16 11:29:30 +10:00
e52730d008 SP int: mp_init_size() and check size fixes
Check size passed to mp_init_size() 1..SP_INT_DIGITS.
More checks of parameters to SP int functions to ensure result is big
enough to hold value calculated.
2022-09-16 10:13:33 +10:00
a98cda3516 fix qsscertificate test failure 2022-09-16 07:48:05 +09:00
523c16130d Merge pull request #5579 from douzzer/20220911-fixes-re-multi-test
20220911-fixes-re-multi-test
2022-09-16 08:29:41 +10:00
d18a654f74 wolfcrypt/src/sp_int.c: address peer review around _sp_zero(), sp_init(), and sp_init_size(), re sp_int_minimal. 2022-09-15 14:33:45 -05:00
5d2610c96d wolfssl/wolfcrypt/sp_int.h and wolfcrypt/src/sp_int.c: add struct sp_int_minimal, with same structure as struct sp_int but only one digit, to allow error-free access to sp_ints allocated with ALLOC_SP_INT() with fewer than SP_INT_DIGITS digits, and use the new type in _sp_zero() and sp_init_size() to eliminate -Werror=array-bounds on _sp_zero() under gcc-13. 2022-09-15 13:16:27 -05:00
23b16c09d7 linuxkm/Makefile: add support for $KBUILD_EXTRA_FLAGS. 2022-09-15 13:16:27 -05:00
2a96d62e43 Merge pull request #5573 from embhorn/zd14802
Add WOLFSSL_ATECC_TFLXTLS for Atmel port
2022-09-15 08:59:40 -07:00
4b3f6ada8a Do not allow 0 size DtlsMsg 2022-09-15 16:18:24 +02:00
1941fb2b35 Keep a separate drop counter for each epoch 2022-09-15 15:49:05 +02:00
67473bac28 Code review fixes
- Mark old epochs as invalid so we don't attempt to decrypt with them
- Return a non-zero value if possible in unit tests
- Move Dtls13CheckAEADFailLimit to dtls13.c
- Reset state in processreply
2022-09-15 14:39:33 +02:00
63ba2f7b8f TLS 1.3: Check maximum records encrypted with one key set 2022-09-15 12:17:46 +02:00
4e9106c355 Enforce maximum amount of failed decryptions in DTLS 1.3 2022-09-15 12:17:46 +02:00
c7de58ebaf Add code to fallback to S/W if TSIP cannot handle 2022-09-15 11:16:37 +09:00
ad39e8f77d Kyber: fix OQS memory leak 2022-09-15 09:18:47 +10:00
37adf0ff06 Merge pull request #5592 from douzzer/20220914-fix-quic-test-default-build
20220914-fix-quic-test-default-build
2022-09-14 14:15:46 -06:00
f21b021bb6 Merge pull request #5590 from SparkiDev/tlsx_symbol_fix
TLSX: function not used
2022-09-14 09:10:56 -06:00
8b641df116 Merge pull request #5588 from SparkiDev/tls13_cs_fixes
TLSv1.3 cipher suites: fixes
2022-09-14 09:06:31 -06:00
eef67478e9 tests/quic.c: gate QuicConversation_fail() definition to avoid -Wunused-function. 2022-09-14 09:46:07 -05:00
17df33cef8 Fix TLS 1.3 testsuite for wolfssl64.sln solution 2022-09-14 11:39:27 +02:00
e8d5cf9662 TLSX: function not used 2022-09-14 09:52:26 +10:00
79d85f6c13 TLS cipher suite: improvements
wolfSSL_clear: check return from InitSSL_Suites() call.
TLS13: check ClientHello cipher suite length is even.
Silently remove duplicate cipher suites from user input.
Add tests of duplicate cipher suite removal.
2022-09-14 09:26:00 +10:00
3cafde2519 Merge pull request #5589 from SparkiDev/sp_mac_m1_asm
SP; Mac M1 failure fix
2022-09-13 16:35:57 -06:00
fa8c158f3c Merge pull request #5587 from tim-weller-wolfssl/dev-win-build-fips-update
Remove FIPS preprocessor defines from Windows build options
2022-09-13 13:47:51 -07:00
12ec2272d6 Merge pull request #5585 from icing/groups-key-share
wolfSSL_set1_curves_list(), wolfSSL_CTX_set1_curves_list() improvements.
2022-09-13 10:36:25 -06:00
1a0073b558 Add WOLFSSL_ATECC_TFLXTLS for Atmel port 2022-09-13 11:04:58 -05:00
7f2659bb9b add test-tls13-pq-2.conf to include.am 2022-09-13 10:51:07 -04:00
62c415fd50 Kyber: fixes
Don't define WOLFSSL_HAVE_KYBER unless configured.
Only compile code in ext_kyber.c when WOLFSSL_HAVE_KYBER defined.
Include config.h and settings in ext_kyber.c. This allowed
HAVE_VISIBILITY to be defined.
Cleanup kyber.h.
2022-09-13 10:07:28 -04:00
bcf4dbe697 Changes inspired by Feedback from Sean.
Define WOLFSSL_HAVE_KYBER when HAVE_LIBOQS is defined.
Fix some misleading debug output.
Fix benchmarking logic.
2022-09-13 10:07:28 -04:00
a2635be9e6 wolfCrypt support for external Kyber implementations (liboqs and pqm4) 2022-09-13 10:07:28 -04:00
8c1e2c52e7 Kyber: Add option to build Kyber API
wolfSSL Kyber implementation not included.
Added tests and benchmarking.
2022-09-13 10:07:27 -04:00
531f125925 Fix build without TLS13. 2022-09-13 11:18:27 +02:00
bebb686217 Fixes for different build scenarios:
- fix the type cast in SMALL_STACK builds
- only use new behviour when wolfSSL_set_groups() is available
2022-09-13 11:10:59 +02:00
112fc540bb Fix build errors and warnings for MSVC with DTLS 1.3 2022-09-13 10:13:44 +02:00
5e945f94b4 TLSv1.3 cipher suites: fixes
Handle multiple instances of the same cipher suite being in the server's
list.
Fix client order negotiation of cipher suite when doing pre-shared keys.
2022-09-13 17:25:11 +10:00
38418b31f1 Merge pull request #5197 from JacobBarthelmeh/OCSP
RSA-PSS with OCSP and add simple OCSP response der verify test case
2022-09-13 15:10:00 +10:00
99d60a0781 SP; Mac M1 failure fix
Give the compiler a hint that mask needs special attention.
2022-09-13 13:54:06 +10:00
e867f0d312 Merge pull request #5574 from haydenroche5/ecc_nb_tls
Add support for non-blocking ECDHE/ECDSA in TLS/DTLS layer.
2022-09-12 16:24:00 -06:00
ba12d72e7a Remove FIPS preprocessor defines from Windows build command-line options (values specified via user_settings.h) 2022-09-12 15:54:36 -05:00
2eee35ef8f Merge pull request #5582 from SparkiDev/small_stack_cache_fix
Small Stack Cache: make work again
2022-09-12 09:53:10 -06:00
ba5aeb3501 Merge pull request #5583 from SparkiDev/psk_only_tls_fix
PSK only TLS: fix ENCRYPT_LEN
2022-09-12 09:26:28 -06:00
be72549388 Merge pull request #5584 from SparkiDev/tls13_midbox_fix
TLS 1.3 Middle-Box compat: fix missing brace
2022-09-12 09:15:10 -06:00
c6c4134542 wolfSSL_set1_curves_list(), wolfSSL_CTX_set1_curves_list() improvements.
- Use wolfSSL API wolfSSL_set_groups() and wolfSSL_CTX_set_groups()
  to configure curves list
- This sets ssl->groups and ctx->groups accordingly and makes
  TLSX_KEY_SHARE generation respect the selection and precedence.
- Add tests in quic to assert the order of selections.
2022-09-12 14:31:58 +02:00
375b9c1a59 TLS 1.3 Middle-Box compat: fix missing brace 2022-09-12 13:11:49 +10:00
005f77180b PSK only TLS: fix ENCRYPT_LEN
Allow no PK algorithms and TLS to build and test.
Use PSK cipher suite with GCM if AES-CBC not available.
2022-09-12 11:21:01 +10:00
e0a47ca6c1 Small Stack Cache: make work again
Fix Small Stack Cache option so that it works with various options
including ALT_ECC_SIZE.
Allow ALT_ECC_SIZE when SP math all or SP math is compiled in.
2022-09-12 10:52:34 +10:00
2c4c7ba6da ARM v7a ASM: 128-bit registers not supported
Cortex-A5 - Cortex-A9 only support 64-bit wide NEON.
Remove use of WOLFSSL_ARM_ARCH_NO_VREV.
Use WOLFSSL_ARM_ARCH_NEON_64BIT to indicate to use 64-bit NEON registers
and not 128-bit NEON registers.
2022-09-12 10:00:18 +10:00
fa6bc79f8b Merge pull request #5578 from douzzer/20220909-fixes
20220909-fixes
2022-09-09 16:37:35 -06:00
460b6f1ecc Merge pull request #5577 from tmael/vx_entropy
Improves entropy with VxWorks
2022-09-09 15:51:24 -06:00
6c71777ca6 no verify on renewing ocsp response 2022-09-09 13:58:43 -07:00
0603031362 fix whitespace in wolfssl/wolfcrypt/settings.h;
fix bugprone-macro-parentheses in wolfssl/ssl.h;

fix pointerOutOfBounds and declaration-after-statement in src/internal.c DtlsMsgAssembleCompleteMessage().
2022-09-09 15:25:06 -05:00
82781043c4 Add entropy to VxWorks 2022-09-09 12:44:56 -07:00
757a18ab7e Merge pull request #5496 from SKlimaRA/SKlimaRA/SetCipherListBytes
Support for setting cipher list with bytes
2022-09-09 13:42:51 -06:00
23ba1e7e98 Minor cleanups. Gate these API's on OPENSSL_EXTRA or WOLFSSL_SET_CIPHER_BYTES to keep code size reduced. 2022-09-09 10:49:49 -07:00
6526ffc5f8 Merge pull request #5567 from haydenroche5/hmac_sha1_fix
Fix HMAC compat layer function for SHA-1.
2022-09-09 09:45:21 -06:00
3bd91c6ab8 wolfcrypt/src/pkcs7.c: revert 57a7430b6a, which broke SCEP use case, and redo using a simple stack variable initialization approach. 2022-09-09 10:09:14 -05:00
7418ddcae6 Refactor nofail tests into test_wolfSSL_client_server_nofail 2022-09-09 16:04:30 +02:00
0a1332c4df Additional checks for secure renegotiation 2022-09-09 15:33:27 +02:00
f7c31dbf64 Merge pull request #5575 from SparkiDev/sp_int_no_64
SP int: default to 16 bit word size when NO_64BIT defined
2022-09-08 18:30:30 -07:00
0db0032b31 ARM32 ASM: vrev not always available
Provide alternative assembly instructions to vrev when
WOLFSSL_ARM_ARCH_NO_VREV is defined.
2022-09-09 10:19:17 +10:00
3b8f3a0897 SP int: default to 16 bit word size when NO_64BIT defined 2022-09-09 08:33:30 +10:00
14a521ca25 Make --enable-asynccrypt-sw imply --enable-asynccrypt.
Simplifies configuration.
2022-09-08 15:23:22 -07:00
200ca9db4b Merge pull request #5572 from tim-weller-wolfssl/zd14615-config-updates
Configuration consistency fixes for RSA keys and way to force disable of private keys
2022-09-08 13:19:11 -06:00
226a8b676d Add support for non-blocking ECDHE/ECDSA in TLS/DTLS layer.
This requires the async code.
2022-09-08 11:34:59 -07:00
e49efbc101 Merge pull request #5544 from haydenroche5/async_sw
Migrate async names from "test" to "software."
2022-09-08 10:18:26 -07:00
f49d84e17a fix typo and pipe ocsp response creation to /dev/null 2022-09-08 09:02:31 -07:00
52653c654d Merge pull request #5571 from julek-wolfssl/sk-cmp-param-fix
Set correct types in wolfSSL_sk_*_new functions
2022-09-08 08:47:20 -07:00
7c153a49ec Merge pull request #5570 from SparkiDev/sp_noasm
SP: config option to force no asm
2022-09-08 07:49:24 -07:00
64376d4d9e Merge pull request #5555 from julek-wolfssl/dtls-fragment-buckets
Don't over-allocate memory for DTLS fragments
2022-09-08 07:46:04 -07:00
1b90d4fad2 Configuration consistency fixes and addition of new config option to disable private key
Add way to disable private keys in wolfcrypt (settings). Make RSA integer usage match structure configuration.
2022-09-08 09:36:18 -05:00
28af88788a Set correct types in wolfSSL_sk_*_new functions
- Use WOLF_SK_COMPARE_CB() to generate the correct types instead of using void* for the callback parameters.
- Remove WOLFSSL_STACK.comp entirely since it is not used anywhere. Ignore input parameters that used to set this member.
2022-09-08 11:55:32 +02:00
81321fc10e SP: config option to force no asm
Added to configure.ac the option to specify SP to be built with ASM as
x64 defaults to with asm.
2022-09-08 16:20:15 +10:00
4deae6dcc6 Remove duplicate defines for EVP_get_cipherbyname and EVP_get_digestbyname. 2022-09-07 16:32:25 -07:00
9d6e157fc5 add asn template version 2022-09-07 16:15:19 -07:00
4066568315 Merge pull request #5564 from douzzer/20220907-fixes
20220907-fixes
2022-09-07 16:03:37 -07:00
5dc1732036 Fix define name
WOLFSSL_ARMASM_NO_CRYPTO -> WOLFSSL_ARMASM_NO_HW_CRYPTO
2022-09-08 08:39:00 +10:00
18450eb94b Fix HMAC compat layer function for SHA-1.
This function would only accept the string "SHA" for SHA-1-based HMAC, but it
should also accept "SHA1." This is similar to how wolfSSL_EVP_get_digestbyname
allows both "SHA" and "SHA1." We didn't have a test for this in api.c. I added
one, and it failed before my fix here.
2022-09-07 15:25:31 -07:00
d1ffe30f13 Merge pull request #5566 from kaleb-himes/OE40-45-support
Proposed changes based on customer report(s) under consideration by t…
2022-09-07 13:45:06 -07:00
ac1a0293e2 Merge pull request #5565 from tmael/workbench_doc
Improve Workbench docs
2022-09-07 13:41:37 -07:00
ef7377d64c fix whitespace and line length. 2022-09-07 15:30:32 -05:00
57a7430b6a wolfcrypt/src/pkcs7.c: in wc_PKCS7_DecryptKtri(), refactor handling of OAEP keys to fix uninited value access detected by clang-analyzer-core.UndefinedBinaryOperatorResult; fix whitespace. 2022-09-07 15:14:26 -05:00
28a82237d9 RSA-PSS signed OCSP responses 2022-09-07 13:12:43 -07:00
9c88d8ac2c Merge pull request #5547 from JacobBarthelmeh/mcux
Port to RT685 with FreeRTOS
2022-09-07 12:54:54 -07:00
b2a80cbe65 Disable warning for MSVC 2022-09-07 12:05:29 -07:00
3ac985c2f1 Proposed changes based on customer report(s) under consideration by the team 2022-09-07 11:34:27 -06:00
0f0aae72c2 Improve Workbench docs 2022-09-07 09:58:23 -07:00
22bad7b06b fix spelling 2022-09-07 09:57:34 -06:00
d75bb2de62 Merge pull request #5561 from SparkiDev/sp_math_openssl_fix
SP math: fix build configuration with opensslall
2022-09-07 07:12:13 -07:00
bc1fca8c85 Merge pull request #5562 from SparkiDev/sp_int_521_fix
SP int: fix for SP_INT_DIGITS calc
2022-09-07 07:12:01 -07:00
1d2cd7af0f Expose API for src/api.c 2022-09-07 13:04:33 +02:00
28895ed0cd Use a union and struct for padding in DtlsFragBucket
Zero length arrays are not allowed so `byte padding[0]` is not a valid member. Changed to use a union and struct instead.
2022-09-07 13:04:26 +02:00
8bf3e0829e Don't over-allocate memory for DTLS fragments
Don't reserve the full message length of memory. Instead we only allocate memory for the fragments that we have already received. We also dynamically combine memory fragments when we receive overlap.
2022-09-07 13:04:06 +02:00
1fe9f2d894 SP int: fix for SP_INT_DIGITS calc
Implementation of sp_mont_red needs words * 2 + 1.
2022-09-07 17:22:22 +10:00
05634e286d SP math: fix build configuration with opensslall
./configure '--disable-shared' '--enable-keygen' '--enable-certgen'
'--enable-certreq' '--enable-certext' '--enable-ocsp' '--enable-crl'
'--enable-pwdbased' '--enable-opensslall' '--enable-pkcs7'
'--enable-pkcs12' '--enable-sp' '--enable-sp-math' '--disable-rsa'
'--disable-dh' '--enable-ecc'
2022-09-07 15:42:33 +10:00
12680a967a Merge pull request #5560 from douzzer/20220906-fixes
20220906-fixes
2022-09-06 17:56:33 -07:00
7d67ffac69 Fixup assembly to compile with ARMv7a 2022-09-07 09:30:06 +10:00
805b0eb606 ARM ASM: ARMv7a with NEON instructions
Change to build assembly code for ARMv7a with NEON instruction set.
./configure -host=armv7a --enable-armasm
Added ARM32 SHA-256 NEON only implementation.
2022-09-07 09:29:56 +10:00
602116c3f2 Merge pull request #5558 from embhorn/zd14776
Fix warning in DecodeAltNames
2022-09-06 16:00:02 -07:00
761fde31ad Merge pull request #5478 from miyazakh/rsaesoaep 2022-09-06 15:45:40 -06:00
bf29d6b2c7 wolfcrypt/test/test.c: refactor shake256_absorb_test() and shake256_test() to use a single buffer for "large_input", malloc()ed when WOLFSSL_SMALL_STACK, to stay within stack limits of all-max-func-stack-2k; move a couple declarations in openssl_test() to resolve declaration-after-statement. 2022-09-06 13:28:57 -05:00
14082ceeb9 CMakeLists.txt: add SHAKE128 coverage. 2022-09-06 13:28:45 -05:00
d72b401e8e Merge pull request #5545 from icing/evp_chacha
Add ChaCha20 as available cipher in the EVP API.
2022-09-06 10:42:54 -07:00
dcf215d52c Fix warning in DecodeAltNames 2022-09-06 11:33:30 -05:00
e2de8f3b6c Merge pull request #5554 from rizlik/dtls_cid_fix
fix: dtls13: do not negotiate ConnectionID in HelloRetryRequest
2022-09-06 09:28:25 -07:00
7b0128f9ac Merge pull request #5541 from SparkiDev/ecc_sign_k_nondyn
ECC sign_k: don't have it dynamically allocated
2022-09-06 07:52:45 -07:00
1a3c34ea99 Merge pull request #5557 from SparkiDev/sp_rsa_max_fix
RSA max and SP_INT_BITS: disabled RSA fix
2022-09-06 07:52:18 -07:00
a33368f314 Merge pull request #5516 from embhorn/zd14732 2022-09-06 13:51:58 +02:00
5927c4063a Removing FIXME comments after the fixing has been done. doh. 2022-09-06 10:06:02 +02:00
9b319b3782 Remove dependency on POLY1305 on testing CHACHA20 only. 2022-09-06 10:06:02 +02:00
9f47999002 Add ChaCha20 as available cipher in the EVP API.
- wire the wc_ChaCha_* implementation into the EVP API
  as `wolfSSL_EVP_chacha20`
- follow IV conversions of OpenSSL
- add test case
- have QUIC support use this for header protection when
  CHACHA20_POLY1305 has been negotiated in the handshake.
2022-09-06 10:06:02 +02:00
4b12d2f4ec RSA max and SP_INT_BITS: disabled RSA fix
Checking WOLFSSL_MAX_RSA_BITS against SP_INT_BITS even though RSA is
disabled.

/configure --disable-shared --enable-sp --enable-sp-math --disable-rsa
--disable-dh --enable-ecc
2022-09-06 17:15:22 +10:00
483d7189c7 Merge pull request #5512 from SparkiDev/tls13_64bit_milli
Make time in milliseconds 64-bits
2022-09-05 16:19:03 -07:00
31b8edd192 Merge pull request #5552 from SparkiDev/ed_make_key_fixes
Ed make public key wasn't checking whether private key set
2022-09-05 16:13:41 -07:00
e7dbb5b375 Merge pull request #5548 from dgarske/whitespace
Whitespace cleanup
2022-09-06 07:54:29 +10:00
aee81764f2 fix: dtls13: do not negotiate ConnectionID in HelloRetryRequest 2022-09-05 17:00:09 +02:00
38781bd7cf added testing for wolfSSL_set_cipher_list_bytes() 2022-09-05 16:57:07 +02:00
e76361d544 Merge pull request #5551 from SparkiDev/sha3_asm_fix
SHA-3: check BMI1 availablity for ASM
2022-09-05 05:03:52 -06:00
f153e65102 SHA-3: check BMI1 availablity for ASM
Added benchmarking of SHAKE128 and SHAK256.
2022-09-05 14:11:02 +10:00
f807c70637 Ed make public key wasn't checking whether private key set
Ed25519 and Ed448 make public key APIs now check whether the private key
was set.
The private key and public key flags setting and clearing also updated.
Testing of unset private key and calling make public key added for
Ed25519 and Ed448.
2022-09-05 12:21:51 +10:00
49065373aa Merge branch 'fix_sha256_debug' of github.com:gojimmypi/wolfssl 2022-09-04 19:26:38 -06:00
4ac113d135 ECDSA sign_k allocated when not WOLFSSL_NO_MALLOC
Fix up other WOLFSSL_NO_MALLOC issues.
2022-09-05 10:56:17 +10:00
b95df7529c Improve usage of 64-bit implementation of TimeNowInMilli
Change to use 64-bits for types stored - use WOLFSSL_32BIT_MILLI_TIME if
a 64-bit type is not available.
TimeNowInMill() returns 0 on error instead of GETTIME_ERROR.
2022-09-05 10:47:25 +10:00
69ed2b56d4 Replace a variable of AES-128 key size to the constant AES_128_KEY_SIZE 2022-09-04 13:31:24 +09:00
b52d193ee3 Fix an implicit type conversion 2022-09-03 23:56:54 +09:00
aa036b6ea4 Merge pull request #5532 from anhu/sphincs
Add sphincs to wolfCrypt.
2022-09-02 11:56:11 -07:00
232a750cc2 Whitespace cleanup. 2022-09-02 09:54:17 -07:00
4a8a11315b Merge pull request #5536 from SparkiDev/sha3_x64
SHA-3 improvements
2022-09-02 09:46:14 -07:00
8ca63b93a4 Merge pull request #5539 from dgarske/ocsp_async
Fix for async with OCSP non-blocking in `ProcessPeerCerts`
2022-09-02 10:42:09 -06:00
11bb8b3dc4 Merge pull request #5543 from SparkiDev/rsa_max_size_fix
RSA max key size checks
2022-09-02 09:26:19 -07:00
10ce703d71 Add sphincs to wolfCrypt.
Note that we will not support sphincs in TLS so nothing above wolfcrypt changes.
2022-09-02 11:53:55 -04:00
daadd4a1b7 Merge pull request #5540 from dgarske/socksz
Fixes for building with 32-bit and socket size sign/unsigned mismatch
2022-09-02 16:33:41 +10:00
959386422e Migrate async names from "test" to "software."
See async PR 52.
2022-09-01 17:53:18 -07:00
3bf6baf596 RSA max key size checks
Detect when certificate's RSA public key size is too big and fail on
loading of certificate.
Fix unit test to only attempt to use 3072 bit RSA-PSS keys when
RSA_MAX_SIZE supports it.
2022-09-02 10:37:12 +10:00
cef590131a ECC sign_k: don't have it dynamically allocated 2022-09-02 09:18:42 +10:00
23fd6456c2 Merge pull request #5534 from dgarske/zd14420
Fix for async session tickets
2022-09-02 08:50:35 +10:00
ef451d316c Make time in milliseconds 64-bits
Allow for longer session ticket lives.
2022-09-02 08:45:07 +10:00
f530101ef1 Fix for async with OCSP non-blocking in ProcessPeerCerts. ZD 14754. 2022-09-01 14:39:52 -07:00
65ca72c5a2 Improve EVP support for CHACHA20_POLY1305 (#5527)
* Add test case for OpenSSLs capability to init a evp context partially in several calls.
* EVP handling of CHACHA20_POLY1305 improvment
- save key at ctx for Init()s without IV
- reuse stored key for Init()s with new IV, reusing ctx
- free and zero key on ctx clenaup
* Adding type cast to XMALLOC to force compiler compatibility.
* EVP: using same DYNAMIC_TYPE in alloc and free of chacha20_poly1305 key.
Co-authored-by: Stefan Eissing <stefan.eissing@greenbytes.de>
2022-09-01 13:23:42 -07:00
2695f36642 Fixes for building with 32-bit and socket size sign/unsigned mismatch.
Tested with: `./configure --enable-all CFLAGS="-m32 -DXSOCKLENT=int" LDFLAGS="-m32" && make`
2022-09-01 11:39:34 -07:00
ba8ffc765d Merge pull request #5513 from rizlik/hrr_default
DTLSv1.3: Do HRR Cookie exchange by default
2022-09-01 07:45:18 -07:00
0222833f7e Merge pull request #5535 from douzzer/20220831-analyzer-coddling
20220831-analyzer-coddling
2022-09-01 07:40:11 -07:00
8ccef9f0d3 Merge pull request #5531 from embhorn/zd14665
Check return from call to wc_Time
2022-09-01 09:35:49 -05:00
85776f0069 Add wolfSSL_EVP_PKEY_new_CMAC_key to OpenSSL compatible API 2022-09-01 18:00:43 +09:00
08b89fbef9 server: add optional argument to -J disable hrr cookie 2022-09-01 09:37:35 +02:00
401cfbd8e4 dtls13: enable hrr cookie by default 2022-09-01 09:37:35 +02:00
edd723cc84 ssl: add new wolfSSL_disable_hrr_cookie() API to disable hrr cookie
Add a way to disable hrr cookie so it can be enabled by default for DTLS
connections.
2022-09-01 09:37:34 +02:00
ce8959ea77 SHA-3 improvements
Add x86_64 assembly code:
  - BMI2
  - AVX2 (using ymm, slower than BMI2)
  - AVX2 of 4 similtaneous hashes
Add SHAKE128 functions and tests.
Add Absorb and Squeeze functions for SHAKE128 and SHAK256 and tests.
Add doxygen for SHA-3 and SHAKE functions.
Update other generated x86_64 assembly files to include settings.h.
2022-09-01 17:11:58 +10:00
ea3959f2f6 analyzer coddling:
in api.c test_wolfSSL_dtls12_fragments_spammer(), inhibit clang-analyzer-deadcode.DeadStores;

in asn.c ParseCRL_Extensions() old (!WOLFSSL_ASN_TEMPLATE) version, fix bounds check to prevent overshift;

in misc.c ctMaskCopy(), use `*(x + i)`, not x[i], to tiptoe around cppcheck-2.9 objectIndex bug.
2022-08-31 22:56:08 -05:00
db6d69143e Merge pull request #5533 from lealem47/crlPrintFix
Add missing DN nid to work with PrintName()
2022-08-31 18:32:55 -07:00
fe583faf32 Merge pull request #5501 from haydenroche5/ecc_non_block
Add support for non-blocking ECC key gen and shared secret gen for P-256/384/521.
2022-08-31 18:31:28 -07:00
96ab26e6e9 Fix for async session tickets. ZD14420
```
./configure --enable-all --enable-asynccrypt CFLAGS="-DWOLFSSL_NO_DEF_TICKET_ENC_CB" && make
./examples/server/server -v 4 -r &
./examples/client/client -v 4 -r
```
2022-08-31 15:28:49 -07:00
2df1c25263 Add missing DN nid to work with PrintName() 2022-08-31 15:18:12 -07:00
41207f5d9b Add support for non-blocking ECC key gen and shared secret gen for
P-256/384/521.

New functions:

- sp_ecc_make_key_256_nb
- sp_ecc_make_key_384_nb
- sp_ecc_make_key_521_nb
- sp_ecc_secret_gen_256_nb
- sp_ecc_secret_gen_384_nb
- sp_ecc_secret_gen_521_nb

This commit also tweaks the testing for ECDSA testing in test.c. Instead of
testing with one of P-256/384/521, we test with all that are available.
2022-08-31 14:34:26 -07:00
38e4ecc27c Merge pull request #5529 from anhu/wextra
Fix Windows CMakeList compiler options
2022-08-31 14:04:24 -07:00
5a25525b2e Check return from call to wc_Time 2022-08-31 15:20:07 -05:00
9531552795 Merge pull request #5522 from tim-weller-wolfssl/update-ide-win10-build
Update ide win10 build files to add missing sp source files
2022-08-31 12:45:17 -07:00
b1301d9dc4 Merge pull request #5518 from CallumMcLoughlin/master
Allow Post Quantum Keyshare for DTLS 1.3
2022-08-31 12:29:08 -07:00
f0812fa21f Added vcpkg instructions to the INSTALL file. 2022-08-31 11:41:43 -07:00
8722a46d52 Merge pull request #5503 from julek-wolfssl/dtls-fragments
DTLS limit fragments
2022-08-31 09:53:09 -07:00
3b8d230223 Merge pull request #5515 from anhu/custExtDoc
Improve `wc_SetCustomExtension` documentation
2022-08-31 08:35:04 -07:00
f7482d96e6 Windows cl.exe does not support -Wextra other flags 2022-08-31 10:32:55 -04:00
1d9d8bdefb Removed sp_c64.c due to reliance on 128-bit type, replaced with sp_x86_64.c and _asm.asm. 2022-08-31 07:15:05 -07:00
71b1aca373 Merge branch 'master' into update-ide-win10-build 2022-08-31 06:32:20 -07:00
54bd786707 DTLS limit fragments
- Limit the amount of fragments we store per a DTLS connection
- Error out when we reach the DTLS fragment connection limit
2022-08-31 14:24:20 +02:00
44f81f8bc0 Merge pull request #5525 from JacobBarthelmeh/release
Release version 5.5.0
2022-08-30 10:35:13 -07:00
4ce1cf1d7c update RPM build 2022-08-30 08:50:41 -07:00
d75ce08d75 update readme for release 5.5.0 2022-08-30 09:31:28 -06:00
43388186bb Tidy up TLS 1.3 and DTLS 1.3 check 2022-08-30 19:59:36 +12:00
565d1b33e5 Update examples to allow post quantum KEM within DTLS 1.3 2022-08-30 18:39:57 +12:00
1afc92dd7b internal.c: WC_SHA256_DIGEST_SIZE for wc_Sha256GetHash when WOLFSSL_DEBUG_TLS 2022-08-29 17:06:52 -07:00
29f2dee991 handeling DER to internal of an OCSP response with no optional certificates 2022-08-29 15:25:50 -07:00
ac3cdb42b7 free structure in test case and return 0 from ocsp renew script 2022-08-29 15:25:50 -07:00
5b5f673c51 add simple ocsp response der verify test case 2022-08-29 15:25:50 -07:00
69d60f5099 Merge branch 'master' into update-ide-win10-build 2022-08-29 09:13:51 -07:00
a7f86f9473 Merge pull request #5517 from JacobBarthelmeh/Testing
misc. testing items from static analysis tools
2022-08-29 08:48:51 -07:00
11c553ea1d Merge pull request #5520 from julek-wolfssl/sni-tls-1.2
SNI can appear in ServerHello for TLS 1.2
2022-08-29 09:36:53 -06:00
88deaf9b5c SNI can appear in ServerHello for TLS 1.2
Co-authored-by: Eric Blankenhorn <eric@wolfssl.com>
2022-08-29 14:22:10 +02:00
91d3cd7111 Allow Post Quantum Keyshare for DTLS 1.3 2022-08-28 17:35:28 +12:00
1e673aee3b scan-build warning fix 2022-08-26 16:29:11 -07:00
ad0fd15a0d static analysis fix from infer 2022-08-26 14:55:42 -07:00
ce2cf3439d subject info. acc. should contain a CA repo entry not OCSP 2022-08-26 14:39:20 -07:00
1c83438eb3 Add compatibility layer macros 2022-08-26 14:56:35 -05:00
b1e9cc320b Add documentation telling the user not to modify a buffer. 2022-08-26 14:27:27 -04:00
e88bd66501 Merge pull request #5514 from julek-wolfssl/wolfSSL_EVP_MD_CTX_copy_ex-leak
Cleanup output object in wolfSSL_EVP_MD_CTX_copy_ex before copy
2022-08-26 11:08:17 -07:00
1bf441de4d add MCUXpresso IDE projects 2022-08-26 10:51:10 -07:00
b3fa6f654e no realloc, adjustable static test size, fsl RTC 2022-08-26 09:15:33 -06:00
d84bfd511d Merge pull request #5511 from SparkiDev/sp_submod_neg_fix
SP math: don't modify sign in sp_div
2022-08-26 08:07:37 -07:00
2fb3f58c03 Cleanup output object in wolfSSL_EVP_MD_CTX_copy_ex before copy 2022-08-26 13:07:45 +02:00
8b2719cc83 SP math: don't modify sign in sp_div
Not need to modify sign of a and d in sp_div().
Signs cached at start and used to calculate sign result.
2022-08-26 08:47:49 +10:00
1976601811 Merge pull request #5505 from julek-wolfssl/dtls-plaintext
Ignore plaintext on established connections
2022-08-25 07:25:03 -07:00
b9cee17b01 Merge pull request #5508 from SparkiDev/aes_ctr_arm32_neon_fix2
AES-CTR ARM32 ASM: Fix 128-bit counter increment
2022-08-25 07:04:48 -07:00
bd13fcc92a AES-CTR ARM32 ASM: Fix 128-bit counter increment
Include hash.h to sp_int.h for when no public key algorithms compiled in
- need WC_MAX_DIGEST_SIZE.
2022-08-25 14:54:00 +10:00
842d415de0 Merge pull request #5507 from haydenroche5/general_names_leak
Fix wolfSSL_GENERAL_NAMES_free memory leak.
2022-08-24 21:05:53 -07:00
2c829f19d3 Merge pull request #5506 from dgarske/dtlscid
Fixes for build warnings and string macros for DTLS CID
2022-08-25 13:52:55 +10:00
9f39ffdba7 Fix wolfSSL_GENERAL_NAMES_free memory leak.
This function was just freeing the stack object itself of GENERAL_NAMES with
wolfSSL_sk_free, but this doesn't free the data in the items of the stack. The
fix is to replace wolfSSL_sk_free with wolfSSL_sk_GENERAL_NAME_free.
2022-08-24 18:42:30 -07:00
a0448155d5 Fix for type warnings in example for DTLS CID ./configure --enable-dtls --enable-dtlscid --enable-dtls13. 2022-08-24 16:02:05 -07:00
8268214297 Merge pull request #5504 from ejohnstown/ppc-warn
API Test Fixes for GCC/PowerPC Warnings
2022-08-24 15:19:53 -07:00
159a3c8b03 Ignore plaintext on established connections 2022-08-24 21:40:19 +02:00
c4a61af311 drafted test case 2022-08-24 20:45:54 +02:00
a668953f70 cr fix 2022-08-24 20:35:56 +02:00
9b65f5819c API Test Fixes for GCC/PowerPC Warnings
1. In api.c, change the name of the devId global to testDevId.
2. In api.c, for the SNI test, some of the pointers were multiply
   typecast eventually to `void **`. An older compiler didn't like
   that. Just use void pointer.
2022-08-24 11:30:56 -07:00
7ea904c873 Added CertNew() and CertFree() info. (#5502)
* Updated wc_CertNew() dox for the return value listings, small changes to
description and add some detail to the example per peer review.
2022-08-24 13:09:50 -04:00
9b12011d71 Merge pull request #5499 from SparkiDev/aes_ctr_arm32_asm
AES-CTR ARM32 crypto ASM fix
2022-08-24 09:59:49 -07:00
53b74e2d32 Merge pull request #5498 from SparkiDev/tls_ecc_sig_fault
Check ECC signature in TLS
2022-08-24 09:59:06 -07:00
124cff60f1 Merge pull request #5500 from SparkiDev/sp_int_div_ss_rework
Rework sp_div to work around static analysis error
2022-08-24 09:58:13 -07:00
d087cbea1b Rework sp_div to work around static analysis error
Fix _sp_exptmod_mont_ext() to handle when number of bits in exponent is
a multiple of the window size.
2022-08-24 12:31:21 +10:00
9228354d29 AES-CTR ARM32 crypto ASM fix
Fix handling of counter to support incrementing across all bytes in
ARM32 crypto asm.
Added test cases for wrapping of counter when 2 blocks are being
encrypted to check assembly alternative path.
2022-08-24 10:51:56 +10:00
2571f65e85 Check ECC signature in TLS
Verifying gnerated ECC signature in TLS handshake code to mitigate when
an attacker can gain knowledge of the private key through fault
injection in the signing process.
Requires WOLFSSL_CHECK_SIG_FAULTS to be defined.
2022-08-24 09:01:18 +10:00
3b6124cf34 Merge pull request #5497 from douzzer/20220823-fixits
20220823-fixits
2022-08-23 13:45:02 -07:00
8f70f98640 wolfcrypt/src/asn.c: refactor _SMALL_STACK code path in ParseCRL_Extensions() to fix memory leaks and heap-use-after-free. 2022-08-23 13:52:42 -05:00
dcebd0d349 wolfssl/wolfcrypt/logging.h: when !WOLFSSL_VERBOSE_ERRORS, define WOLFSSL_ERROR_VERBOSE(e) as (void)(e) to avert clang-analyzer-deadcode.DeadStores, and avert bare semicolons. 2022-08-23 13:50:56 -05:00
769fb7cbee Merge pull request #5453 from rizlik/dtls_cid
Support ConnectionID Extension DTLS Negotiation
2022-08-23 11:29:25 -07:00
cab6ecd130 Merge pull request #5404 from JacobBarthelmeh/PKCS7
fix for not having default pkcs7 signed attributes
2022-08-23 11:04:17 -07:00
5c65974170 Fix for dynamic type macro typo. 2022-08-23 09:32:11 -07:00
9d5305ad07 Merge pull request #5495 from julek-wolfssl/ticket-alignment
Remove WOLFSSL_GENERAL_ALIGNMENT from WOLFSSL_TICKET_ENC_SZ calculation
2022-08-23 08:13:42 -07:00
3a8e6f2280 fix: add explicit cast to abide g++ compiler 2022-08-23 16:58:24 +02:00
f3262005e4 add basic ConnectionID DTLS tests 2022-08-23 16:58:24 +02:00
90fcd95f9b server/client: add --cid option to use ConnectionID extension 2022-08-23 16:58:24 +02:00
cfbd061625 add initial support for ConnectionID DTLS extension 2022-08-23 16:58:24 +02:00
83fad7bb45 drafted setting cipher list with bytes api 2022-08-23 14:16:43 +02:00
ae049706c6 Remove WOLFSSL_GENERAL_ALIGNMENT from WOLFSSL_TICKET_ENC_SZ calculation 2022-08-23 11:57:41 +02:00
171af05e96 tlsx: expose TLSX_Push
To be able to implement extension in separate compilation unit
2022-08-23 10:00:06 +02:00
bf9f4b88e4 Merge pull request #5494 from douzzer/20220822-bugprone-macro-parentheses
20220822-bugprone-macro-parentheses
2022-08-22 17:16:48 -07:00
48463f6d54 Merge pull request #5388 from lealem47/crlPrint
Adding X509_CRL_print() function
2022-08-22 17:16:19 -07:00
f9ca944106 Addressing some more feedback 2022-08-22 14:47:11 -07:00
1063090e38 fix bugprone-macro-parentheses in WOLFSSL_CRYPTO_EX_DATA_IGNORE_PARAMS() added in 8b2fcd0643. 2022-08-22 16:34:28 -05:00
bd49d37aaf Merge pull request #5492 from embhorn/zd14694
Fix for AddPacketInfo with WOLFSSL_CALLBACKS
2022-08-22 14:59:29 -06:00
91a7b8067c Addressing some PR feedback 2022-08-22 12:04:15 -07:00
c7c6fd98d7 Merge pull request #5491 from icing/quic-doc-update
Update of the QUIC documentation
2022-08-22 12:00:12 -07:00
b9d9dc02bb Merge pull request #5476 from julek-wolfssl/session-buffers
Remove WOLFSSL_SESSION_TYPE_REF buffers from WOLFSSL_SESSION
2022-08-22 11:59:39 -07:00
c0815b3bc6 Merge pull request #5493 from kaleb-himes/openssl3_0_testing_supplemental
Supplemental fix in addition to #5470
2022-08-22 11:14:49 -07:00
36facf52c9 Merge pull request #5490 from TakayukiMatsuo/no_rsa
Fixed build errors raised when NO_RSA is defined
2022-08-22 10:07:39 -07:00
d50e740c97 Merge pull request #5488 from julek-wolfssl/get_ex_new_index-docs
Add documentation explaining get_ex_new_index API limitations
2022-08-22 09:51:36 -07:00
a7e318a7ad Merge pull request #5484 from lealem47/allocators
Adding allocator funcs for dtls peer (for wrappers)
2022-08-22 09:29:54 -07:00
ce5a749fcb Merge pull request #5489 from SparkiDev/aes_ctr_arm_asm
AES-CTR ARM crypto ASM fix
2022-08-22 09:28:22 -07:00
1e5de8255e Merge pull request #5472 from satoshiyamaguchi/trial3
Add/Extend PEM_read compatibility API's
2022-08-22 09:24:39 -07:00
8f4b467f47 Fixing line lengths and SMALL_STACK code path 2022-08-22 09:17:23 -07:00
689d45eb59 Merge pull request #5425 from SparkiDev/ecc_sp_uncomp_ret
ECC SP uncompress: use error return
2022-08-22 09:00:52 -07:00
f98d8c5024 Update Windows 10 Visual Studio FIPS build file to include single-precision (sp) files to resolve missing symbols during link 2022-08-22 08:40:45 -07:00
77dec16b3b Supplemental fix in addition to #5470 2022-08-22 08:00:40 -06:00
22c44bd762 Fix for AddPacketInfo with WOLFSSL_CALLBACKS 2022-08-22 08:01:21 -05:00
240c261772 Update of the QUIC documentation
- explain what the QUIC support is
- examples of ngtcp2 use
- what is needed for HTTP/3
2022-08-22 14:36:14 +02:00
0dbd0ffb4e Merge pull request #5483 from embhorn/zd14659 2022-08-22 14:28:29 +02:00
e565d0d7de Refactor and code review
- Refactor object hashing into one function
- Allow multiple WOLFSSL_ASSERT_SIZEOF_GE in one function
2022-08-22 14:19:48 +02:00
8b2fcd0643 Add documentation explaining get_ex_new_index API limitations 2022-08-22 12:16:51 +02:00
c7d28e3bb9 ECC SP uncompress: use error return 2022-08-22 16:21:30 +10:00
48e7035af8 Fix build error when NO_RSA is defined 2022-08-22 14:03:19 +09:00
f7a8d4a44a AES-CTR ARM crypto ASM fix
Fix handling of counter to support incrementing across all bytes in ARM
crypto asm.
Added test cases for wrapping of counter.

Extracted ARM ASM for AES-CTR.
Use ASM to created encrypted temporary block.
2022-08-22 10:36:48 +10:00
26c61f8e0f Merge pull request #5473 from icing/quic-hello-retry
Respect disabled curves on HelloRetryRequests
2022-08-22 08:32:30 +10:00
2059d05b7a checking some ret values, fix trailing whitespace 2022-08-19 12:40:42 -07:00
2a65220527 Adding X509_CRL_print() function 2022-08-19 12:21:35 -07:00
da136e0c49 Adding allocator funcs for dtls peer (for wrappers) 2022-08-19 10:59:55 -07:00
b417f94435 Merge pull request #5485 from SparkiDev/tls13_state_string_long
wolfSSL_state_string_long - update for TLS 1.3 and DTLS 1.3
2022-08-19 10:09:09 -07:00
f3b9cfa71c Merge pull request #5487 from icing/tls13_early_nr
Improved EarlyData Indicator reply fix based on PR #5486
2022-08-19 09:54:17 -07:00
a7c0c4649e Fixing Handshake Hash update when Preshared Keys offered by client,
but none of them was accepted.

- This applies to TLSv1.3 and QUIC
- QUIC test case to trigger the bug enabled
2022-08-19 15:56:20 +02:00
1d0e83bd1a Merge pull request #5474 from julek-wolfssl/zd14644-2
Match OpenSSL self signed error return.
2022-08-19 06:46:26 -07:00
3d8562f07b Fixes for build and runtime issues 2022-08-19 08:12:04 -05:00
6cb0caa0a0 Adding disabledCurves as a member of WOLFSSL in the OPENSSL_EXTRA case.
- inheriting from WOLFSSL_CTX on creation
- enabling on WOLFSSL only when wolfSSL_set1_curves_list() is called
2022-08-19 11:03:23 +02:00
7a5170b6e1 Improved EarlyData Indicator reply fix based on PR #5486
- PR #5486 had test failures in tls13.test and quit unit.test
- the extension was no longer added in SessionTicket messages
- added extra parameter to clarify how the TLSX is used
2022-08-19 10:07:06 +02:00
a66516d3a5 Extending quic resumption tests. 2022-08-19 09:02:28 +02:00
61c7003520 Fix whitespace 2022-08-19 12:38:07 +09:00
4b8cd6c62b wolfSSL_state_string_long - update for TLS 1.3 and DTLS 1.3 2022-08-19 09:41:01 +10:00
06022e85a3 Fix avoidSysCalls logic 2022-08-18 19:43:40 +02:00
969ad96dee examples/{client,server}/{client,server}.c: remove spurious commas in --pqc help strings, and mollify clang-tidy bugprone-suspicious-missing-comma re --force-curve help strings. (#5480) 2022-08-18 13:32:58 -04:00
4d0ea62857 Refactor ticket size to not accidentally go over WOLFSSL_TICKET_ENC_SZ
- Optimize memory usage. Write directly to ssl->session->ticket in CreateTicket() and use a hash to make sure the InternalTicket was encrypted.
- DoClientTicket does not fatally error out anymore. Errors in the ticket result in the ticket being rejected instead.
2022-08-18 19:08:43 +02:00
6316e26bdc Adding the forgotten wolfSSL_CTX_free() at the end of the new test_quic_key_share case. 2022-08-18 10:24:18 +02:00
e830a0f613 Merge pull request #5434 from satoshiyamaguchi/trial4 2022-08-17 17:04:36 -06:00
aa812c8aa9 Added support for P384 pre-share in server (#5442)
Added support for new server `--force-curve` option.
2022-08-17 15:30:48 -07:00
91a49da4b8 Merge pull request #5468 from SparkiDev/wolfssl_clear 2022-08-17 15:51:25 -06:00
d494894268 Add to parse RSA ES OAEP Oid 2022-08-18 06:43:31 +09:00
91d1bbbd44 Merge pull request #5477 from douzzer/20220817-make-quic-optional
20220817-make-quic-optional
2022-08-17 14:34:12 -07:00
5b260ac52e configure.ac: remove enable-quic from enable-all feature set;
remove ENABLED_QUIC="yes" from "$ENABLED_CURL" = "yes" setup section;
add ENABLED_CURVE25519=yes if $ENABLED_QUIC = yes;

tests/unit.c: move QuicTest() and SrpTest() before SuiteTest().
2022-08-17 14:25:38 -05:00
68f71d0d96 Remove WOLFSSL_SESSION_TYPE_REF buffers from WOLFSSL_SESSION 2022-08-17 19:29:07 +02:00
be378a346e Merge pull request #5475 from dgarske/rsa_pss_async
Fixes for RSA PSS with `--enable-asynccrypt` in `ConfirmSignature`
2022-08-17 12:04:05 -05:00
b9c9ad0339 Fixes for RSA PSS with --enable-asynccrypt in ConfirmSignature. 2022-08-17 08:20:06 -07:00
3918a2e29a Renaming the named_curve parameter to curve_id to avoid shadowing. 2022-08-17 17:01:18 +02:00
008e947fec Match OpenSSL self signed error return.
OpenSSL compat expects ASN_SELF_SIGNED_E when a self signed cert can't be verified. This is useful when translating the error with GetX509Error into a X509_V_ERR_* error.
2022-08-17 12:40:16 +02:00
d6548b6b88 Small refactoring of named group handling for readability and de-duplicating of code.
- add wolfSSL_CTX_curve_is_disabled() and wolfSSL_curve_is_disabled()
  to have common checks on wether a curve has been disabled by user
- add macros returning 0 for above function when OPENSSL_EXTRA is not
  defined, enabling use without #fidef check
- add macros for checking if named groups are in a certain range
  WOLFSSL_NAMED_GROUP_IS_FFHDE()
  WOLFSSL_NAMED_GROUP_IS_PQC()

Fixed QuicTransportParam_free() use without case when compiling
with c++.
2022-08-17 11:46:48 +02:00
f5a257c383 Add WOLFSSL_LEAVE to wolfSSL_PEM_read_RSA_PUBKEY and wolfSSL_PEM_read_PUBKEY 2022-08-17 14:23:50 +09:00
7435402c30 Fixes to better handle re-use of a WOLFSSL object via wolfSSL_clear. 2022-08-16 15:44:05 -07:00
3f7d56d957 Merge pull request #5471 from icing/quic-mem-leak
Fix memory leak in QUIC transport parameters extension
2022-08-16 13:22:20 -07:00
be2a6cbeb9 Merge pull request #5420 from Uriah-wolfSSL/ms_abi
Ms abi
2022-08-16 09:21:14 -07:00
3434210b13 Fix memory leak in QUIC transport parameters extension 2022-08-16 18:13:25 +02:00
091fc71c74 Fix EVP_PKEY not freed and FILE pointer not closed 2022-08-17 01:03:09 +09:00
e1b3f14d35 Fix FILE pointer not closed in tests/api.c 2022-08-17 00:11:29 +09:00
524f9ebd32 Add argument check and error message to wolfSSL_PEM_read_RSA_PUBKEY 2022-08-16 17:35:51 +09:00
55eb460d1a Merge pull request #5403 from SparkiDev/ecc_import_priv_order
ECC import priv: validate priv is less than order
2022-08-15 21:36:46 -07:00
a954cf82e3 Merge pull request #5469 from anhu/init_CertName
Initialize the Enc memberss of CertName struct.
2022-08-15 20:42:26 -07:00
8aa2bde3c2 Merge pull request #5470 from kaleb-himes/openssl3_0_testing
Allow for renegotiation testing with openssl 3.0 installed on jenkins…
2022-08-16 11:02:22 +10:00
1dd318741d Allow for renegotiation testing with openssl 3.0 installed on jenkins slaves (also tested with openssl 1.1) 2022-08-15 16:33:06 -06:00
52ed047a44 Fix a mismatched decl and impl 2022-08-15 12:13:05 -04:00
23a01b3276 SP: CT from_mp when sp_digit bits equal mp_digit bits.
Made constant time copy of values from an mp_int int array of sp_digit.
Stops OOB writes when mp_int is bigger than it should be.
2022-08-15 09:02:24 -07:00
5e7cff71fd Initialize the Enc memberss of CertName struct.
Tested by reproducing the problem in an example and confirming fix makes problem
go away.
2022-08-15 11:43:33 -04:00
e56a2355ca Merge pull request #5464 from julek-wolfssl/zd14644
Translate the verify callback error to an X509_V_ERR_* value when OPENSSL_COMPATIBLE_DEFAULTS is defined
2022-08-15 06:30:36 -07:00
7e00b32c71 Corrected line spacing incorrect arg passings. 2022-08-14 20:16:42 -05:00
28f22859bb Merge pull request #5451 from embhorn/zd14428
Fix TSIP ret value in TLSX_KeyShare_ProcessEcc
2022-08-14 11:27:20 -07:00
dfb3616d50 Merge pull request #5465 from douzzer/20220812-fixes
20220812-fixes
2022-08-14 08:03:40 -07:00
fba534dce0 Add wolfSSL_PEM_read_RSA_PUBKEY to OpenSSL compatible API 2022-08-14 16:08:22 +09:00
f515916f68 Add liboqs integration to CMake build system (#5407)
* Add liboqs integration to CMake build system

* Rephrase WOLFSSL_OQS option

* Add new FindOQS.cmake file to cmake/include.am

Co-authored-by: Disyer <denialmc1@gmail.com>
2022-08-12 16:23:24 -04:00
e382905311 CMakeLists.txt: synchronize CMAKE_C_FLAGS with diagnostic flags set in autotools-generated Makefile (-Wall -Wextra -Wno-unused -Werror), and fix WOLFSSL_RSA_PSS to add -DWOLFSSL_PSS_LONG_SALT as needed by changes to test_wolfSSL_CertRsaPss() in fb531dacc2 (gating of those changes is also added in this commit). 2022-08-12 15:18:41 -05:00
b4f1b6d04d fix whitespace and C++-style comments. 2022-08-12 15:18:27 -05:00
60437bba6e Merge pull request #5378 from anhu/dilithium
Initial commit to add Dilithium NIST PQC winner.
2022-08-12 09:29:42 -07:00
0d78bd2127 Merge pull request #5459 from dgarske/docs
Improve documentation for CMAC
2022-08-12 10:37:07 -04:00
551acd2b19 Translate verify callback error with compat layer 2022-08-12 16:27:31 +02:00
126a570a37 Add HAVE_WOLFSSL_MSG_EX define when WOLFSSL_MSG_EX is available 2022-08-12 16:27:31 +02:00
90c65bd50b Merge pull request #5458 from icing/quic-earlydata
QUIC fixes for handling of early data
2022-08-11 17:52:29 -07:00
c66a21c40a Add Zephyr support for nRF5340 with CryptoCell-312, PSA Crypto fixes (#5418)
* PSA: set AES key bits, define PSA_ALG_NONE/PSA_KEY_ID_NULL if needed
* Zephyr: add TimeNowInMilliseconds() for tls13.c, clock_settime() for test.c, update CMakeLists.txt
* Skip including unistd.h for Zephyr in benchmark.c
* Zephyr: update README, add nRF5340dk support to wolfssl_test sample app
* Zephyr: add wolfCrypt benchmark sample app
* Zephyr: add nRF5340 support to tls_thread sample app
* PSA: use specific hash algo with psa_sign/verify_hash()
* Zephyr: add support for PSA Crypto API with PK callbacks to wolfssl_tls_threaded sample app
* Zephyr: add new files to zephyr/include.am
2022-08-11 17:42:05 -07:00
3f4b3605a6 Merge pull request #5460 from douzzer/20220811-quic-fixes-and-OLD-TLS-gating
20220811-quic-fixes-and-OLD-TLS-gating
2022-08-11 17:36:06 -07:00
d4646696ed Merge pull request #5448 from julek-wolfssl/ext-msg-check
Validate that extensions appear in correct messages
2022-08-12 08:39:42 +10:00
2b38ba0300 Merge pull request #5455 from dgarske/zd14420
Fix for handling `WC_PENDING_E` from decrypt session ticket callback
2022-08-12 08:20:57 +10:00
017c4e7a41 fix gating and unused-variable warnings in src/quic.c wolfSSL_quic_aead_is_{gcm,ccm,chacha20}();
fix TLS version gating in tests/quic.c;

fix gating in src/ssl.c for wolfSSLv2_client_method() and wolfSSLv2_server_method();

reorganize prototypes in wolfssl/ssl.h for wolf*_method*() to group systematically by protocol version and gate correctly on support for that version in the build.
2022-08-11 14:58:59 -05:00
5445b183ed Adding CMAC documentation. Fixes ZD14601. 2022-08-11 12:00:19 -07:00
b3de591c6f Rename of buffer to tmpbuffer to avoid collision with customer setup test. 2022-08-11 20:06:46 +02:00
499b9c4f35 Merge pull request #5456 from SparkiDev/ssl_set1_curve_fix
wolfSSL_CTX_set1_curves_list: X25519 and X448 defines
2022-08-11 09:19:25 -07:00
53fd4b37f2 QUIC fixes for handling of early data
- new internal field for keeping early data enabled status,
  as QUIC does not call SSL_write_early_data() itself.
- using read_/write_early_data() methods in QUIC handshake
  when early data is enabled. This triggers the internals
  that emit the proper early data indication handlings.
2022-08-11 18:08:37 +02:00
fef84e2c4c Fixes for asn_public.h documentation. Fix spelling error. 2022-08-11 08:58:32 -07:00
82a900b438 Initial commit to add Dilithium NIST PQC winner.
Also:

* added HAVE_FALCON guards as needed.
* corrected minor falcon bugs as I found them.
* handling OID sum collision between DILITHIUM_LEVEL5 and DILITHIUM_AES_LEVEL3

Tested with the following commands:

examples/server/server -v 4 -l TLS_AES_256_GCM_SHA384 \
    -c ~/tmp/dilithium_aes_level5_entity_cert.pem \
    -k ~/tmp/dilithium_aes_level5_entity_key.pem \
    -A ~/tmp/dilithium_aes_level5_root_cert.pem --pqc P521_KYBER_LEVEL5

examples/client/client -v 4 -l TLS_AES_256_GCM_SHA384 \
    -c ~/tmp/dilithium_aes_level5_entity_cert.pem \
    -k ~/tmp/dilithium_aes_level5_entity_key.pem \
    -A ~/tmp/dilithium_aes_level5_root_cert.pem --pqc P521_KYBER_LEVEL5

with permutations of SHAKE,AES variants and levels 2,3,5
2022-08-11 11:38:31 -04:00
5e6c45a6fb Merge pull request #5397 from SparkiDev/cert_rsa_pss
Certs with RSA-PSS sig
2022-08-11 08:19:12 -07:00
66644c2e31 Merge pull request #5457 from kaleb-himes/openssl-test-stuck-fix
Fix a very frequent stuck scenario with the openssl.test script
2022-08-11 07:43:23 -07:00
8efc8b0819 Fix up other test scripts using the same logic 2022-08-11 06:26:43 -06:00
a317126509 Validate that extensions appear in correct messages 2022-08-11 10:53:10 +02:00
dd2a6410d1 Merge pull request #5454 from dgarske/docs_hashtype
Improve the documentation for HMAC hash types
2022-08-11 16:50:55 +10:00
87d96c9c96 Merge pull request #5452 from icing/quic-resume
QUIC session resumption and early data handshake handling.
2022-08-10 22:33:13 -07:00
995100eed1 Fix for handling WC_PENDING_E from decrypt session ticket callback. ZD14420 2022-08-10 22:20:49 -07:00
9ec61d4ce4 Merge pull request #5449 from douzzer/20220809-quic-fixes
20220809-quic-fixes
2022-08-10 21:56:45 -07:00
4d8a713783 wolfSSL_CTX_set1_curves_list: X25519 and X448 defines
Support wolfSSL_CTX_set1_curves_list being available when X25519 and/or
X448 only defined.
Don't recognize X25519 or X448 if corresponding define is not set.
Enable test in api.c.
2022-08-11 14:13:04 +10:00
fb531dacc2 Certs with RSA-PSS sig
Add support for parsing and verifying certificates with RSA-PSS
signatures. Including check PSS parameters in key with those in
signature algorithm.
Add support for parsing private RSA PSS key.
Add support for parsing public RSA PSS key.
2022-08-11 09:43:01 +10:00
a0e1c2567e Fix a very frequent stuck scenario with the openssl.test script 2022-08-10 17:41:54 -06:00
5ef47cc86f Addressed code review. 2022-08-10 17:18:38 -05:00
8197f958a9 address peer review on PR #5449. 2022-08-10 13:33:57 -05:00
f771181e1a fixes for issues introduced in #5384:
added numerous missing _SMALL_STACK code paths (PK objects on the stack);

in settings.h, enable WOLFSSL_SMALL_STACK_STATIC by default when WOLFSSL_SMALL_STACK is defined (NO_WOLFSSL_SMALL_STACK_STATIC to override);

fixes for unsafe strcat()s in tests/quic.c;

fix for unsafe macro WOLFSSL_IS_QUIC();

fix to exclude quic from enable-all when enable-linuxkm (quic needs opensslextra, and opensslextra currently only works in-kernel in cryptonly builds);

fix for signed/unsigned clash in wolfSSL_quic_receive().
2022-08-10 13:33:56 -05:00
c707186b9f Improve the documentation for HMAC hash types. 2022-08-10 09:23:01 -07:00
b46693f8c8 Merge pull request #5445 from douzzer/20220808-fixes
20220808-fixes (unchecked snprintf() retvals)
2022-08-10 10:21:07 -06:00
ea04ffc99f QUIC session resumption and early data handshake handling.
In test with ngtcp2 example client using openssl, session resumption
against a QUIC wolfssl server failed. The error was tracked down to
wolfSSL believing EaryData needs to be handled and returning SUCCESS
from wolfSSL_SSL_do_handshake() after the server Finished had been
sent.

However the handshake was not complete and ngtcp2 invoked the
post_handshake processing for new data arriving from the client.
This failed a check in post processing that the ssl->handShakeState
actually was HANDSHAKE_DONE.

The workaround in this PR repeats do_handshake until the ssl
state acually says it is complete. This way, session resumption works.

Either this alternative do_handshake() is merged for QUIC protocol
hanlders. Or we need to fix the 'normal' do_handshake() to no return
SUCCESS when early data is expected on a QUIC WOLFSSL.
2022-08-10 15:17:30 +02:00
bcb9f3f70d Fix TSIP ret value in TLSX_KeyShare_ProcessEcc 2022-08-10 08:15:24 -05:00
c07d0fe4b4 address peer review:
use camel case not underscores in variable names;

restore use of const int variables for buffer sizes in several spots (for ease of smallstack code paths should they be needed);

use more MISRAish flow control in X509PrintSignature().

also, capture the retval from several more snprintf()s to pass directly to wolfSSL_BIO_write(), avoiding frivolous strlen()s.
2022-08-09 23:23:11 -05:00
eceee6ac95 Merge pull request #5444 from anhu/PQ_get_curve_name
Bugfix: wolfSSL_get_curve_name() will now print post-quantum group names.
2022-08-09 16:53:55 -07:00
57dc263d05 Make clang happy. 2022-08-09 14:35:59 -04:00
fa97923005 Merge pull request #5384 from icing/quic
QUIC support for wolfSSL
2022-08-09 10:13:29 -07:00
5049b16325 Param correction. 2022-08-08 19:43:54 -05:00
371fbc698c src/x509.c: mollify bugprone-unused-return-value warnings around XSNPRINTF();
fix various possible buffer overruns;

fix various runtime-error-driven memory leaks;

various refactors for efficiency, clarity, and safety, including refactors to eliminate unsafe XSTRNCAT() calls.
2022-08-08 18:55:38 -05:00
f8c9393235 Added ABI tags for certs, wc_CertNew(), wc_CertFree()
wc_CertNew() and wc_CertFree() is for use by ABI type aplications, and
others, for having wolfCrypt perform the new/free of the certification
structure w/o the application needing too, and more importantly, needing
to contain knowledge of the structure.
2022-08-08 18:12:06 -05:00
ae0faa40cf Bugfix: wolfSSL_get_curve_name() will now print post-quantum group names. 2022-08-08 17:51:45 -04:00
e3310984b6 Merge pull request #5443 from TakayukiMatsuo/doalert 2022-08-08 15:22:18 -06:00
039bf721c4 Merge pull request #5440 from miyazakh/sce_compile_failure 2022-08-08 10:36:15 -06:00
b0aaf4a23d Minor ABI updates. 2022-08-08 10:16:05 -05:00
c9c19c82b3 Added next set of ABI for ECC APIs 2022-08-08 09:08:24 -05:00
65d402d8d7 Revert "Revert "Removed duplicate WOLFSSL_ABI tag.""
This reverts commit e5c51b2638a374aa987c30be8598a78e3f370c7a.
2022-08-08 09:08:24 -05:00
d283510aa9 Revert "Removed duplicate WOLFSSL_ABI tag."
This reverts commit d17021bc4e8e3f12b0c0406f7fe400ed4c0bc2cd.
2022-08-08 09:08:23 -05:00
f2677c29ec Removed duplicate WOLFSSL_ABI tag. 2022-08-08 09:08:23 -05:00
cc8fb1f978 git push origin ms_abi 2022-08-08 09:08:23 -05:00
b200d65a6a Added new ABI reference hooks. This is round two, more to come. 2022-08-08 09:08:23 -05:00
46f423b8b9 Added ABI macros for managing interface changes 2022-08-08 09:08:23 -05:00
4431438fb2 add QUIC support. 2022-08-08 13:24:00 +02:00
7004157869 Merge pull request #5387 from TakayukiMatsuo/tk14445
Suppress build errors when defining some disable macros
2022-08-07 20:09:41 -07:00
9fd56c9c5c Changes in response to other PRs 2022-08-08 02:10:14 +09:00
79fb1783c4 Suppress build errors when defining some disable macros 2022-08-07 17:11:22 +09:00
2d2c55f1c1 Merge pull request #5431 from haydenroche5/wolfssl_error
Expand error queue usage with new macro WOLFSSL_ERROR_VERBOSE.
2022-08-05 15:14:44 -07:00
96fcc129ec Merge pull request #5213 from JacobBarthelmeh/req
expand functions included in opensslextra and add REQ print out
2022-08-05 13:20:21 -07:00
2288082d9a Make wolfSSL quiet_shutdown functions available when using OPENSSL_EXTRA_X509_SMALL. 2022-08-05 11:51:34 -07:00
3bf21b5a05 Expand error queue usage with new macro WOLFSSL_ERROR_VERBOSE.
We have users who need to debug errors coming out of libwolfssl in production,
where --enable-debug isn't an option. Our error queue implementation is the
solution, but our usage of WOLFSSL_ERROR isn't consistent. This commit greatly
expands our usage of WOLFSSL_ERROR. There are too many error cases to tackle
all at once, and not all error cases are particularly meaningful or likely to be
hit in regular operation of the library. I've tried to focus on errors that
users are likely to hit, and I've chosen to ignore things like the mountain of
BUFFER_E and BAD_FUNC_ARG cases (for the most part). I've also tried to expand
WOLFSSL_ERROR usage in files where we haven't been using it historically
(e.g. aes.c), so the pattern is now there for other developers to follow. In
order to prevent these additions from exploding the size of libwolfssl, they're
all behind a new macro, WOLFSSL_ERROR_VERBOSE. If WOLFSSL_VERBOSE_ERRORS is
defined, WOLFSSL_ERROR_VERBOSE just maps to WOLFSSL_ERROR.
2022-08-05 10:32:18 -07:00
d6c895d19d use or with all/extra macro guard 2022-08-05 09:31:42 -07:00
83f1ade1fc use extension free function with opensslextra and remove debug printf 2022-08-05 09:15:35 -07:00
cedfe9938a Fix the comment about the argument of wolfSSL_PEM_read_RSAPrivateKey. 2022-08-06 00:15:49 +09:00
4f181576ef Fix the position of wolfSSL_PEM_read_RSAPrivateKey definition in pem.h 2022-08-06 00:14:30 +09:00
192f081833 Merge pull request #5439 from SparkiDev/tls13_ext_msgs 2022-08-05 10:49:13 +02:00
f30b3f1163 fix compile error 2022-08-05 16:00:09 +09:00
c35b47f265 TLS !.3: restrict extension validity by message
Extensions ServerName, SupportedGroups and ALPN must not appear in
server_hello.
Removed server_hello from the valid checks.
2022-08-05 08:26:09 +10:00
56be09005f Merge pull request #5427 from julek-wolfssl/dtls-timeout-and-closed-socket
DTLS socket and timeout fixes
2022-08-05 08:13:14 +10:00
ff512a34c6 adjust temporary buffer size and memory free'ing 2022-08-04 15:11:24 -07:00
7465691c70 Merge pull request #5437 from douzzer/20220804-fixes
20220804 fixes
2022-08-04 13:55:03 -07:00
9d5e633a96 wolfcrypt/src/pkcs12.c: add WOLFSSL_SMALL_STACK path in freeDecCertList(). 2022-08-04 11:16:47 -05:00
d7e33b3293 wolfcrypt/src/asn.c: fix null pointer deref in SetReqAttribSingle() (clang-analyzer-core.NonNullParamChecker). 2022-08-04 11:12:09 -05:00
99dad91344 Merge pull request #5435 from douzzer/20220803-gcc-12-ASAN
20220803-gcc-12-ASAN
2022-08-04 08:41:26 -07:00
6d4f0146ca Refactor sending alert on decryption failure
Take sending of the alert outside of DecryptTls() and DecryptTls13(). The alert is now sent in ProcessReplyEx().
2022-08-04 12:06:26 +02:00
ebcfa31993 Refactor checking socket type into a function 2022-08-04 11:35:27 +02:00
3278210e1c Silently discard DTLS msgs that fail decryption
Don't send alerts when decryption fails inside a DTLS connection.
TLS should always send a bad_record_mac when decryption fails.
2022-08-04 11:27:45 +02:00
fd1e8c49eb Reset timeout when reading a valid DTLS message
- Increment the DTLS 1.3 timeout on a long timeout
2022-08-04 11:27:45 +02:00
67d518544b EmbedReceiveFrom: fix when using a TCP socket
- recvfrom() returns 0 on a closed TCP socket
- TCP sockets set WOLFSSL_CBIO_ERR_ISR on a timeout
2022-08-04 11:27:45 +02:00
9ea3e173d0 Merge pull request #5277 from JacobBarthelmeh/req_attr
expand subject name and req attribute support
2022-08-04 14:32:14 +10:00
2c2a7750a4 Merge pull request #5414 from darktohka/feature/chacha20-poly1305-evp
Integrate chacha20-poly1305 into the EVP interface
2022-08-03 18:21:17 -07:00
1dc848d8e3 Merge pull request #5429 from dgarske/sniffer_async2
Fix for sniffer to ensure the session was polled before trying to reprocess it
2022-08-04 08:18:55 +10:00
e32cfb79e5 Merge pull request #5419 from dgarske/aurix
Support for Infineon AURIX IDE and minor compiler warnings.
2022-08-04 08:01:57 +10:00
3f07900c1b Merge pull request #5432 from embhorn/zd14172
Fix dead code warnings and build error
2022-08-03 15:01:20 -07:00
791250c6c0 Merge pull request #5428 from TakayukiMatsuo/rx65n_fix
Fix build error and update manuals for Renesas RX boards
2022-08-03 11:04:25 -07:00
6e8417e631 wolfssl/wolfcrypt/blake2-int.h: remove alignment specs on __blake2s_state and __blake2b_state, as they are unneeded, and are not honored by gcc-12+ in stack allocations, leading to (true positive) misaligned-access errors from ASAN. 2022-08-03 12:30:45 -05:00
a7f0c92c0d src/internal.c: in GetCipherKeaStr(), when gcc-12 or higher and __SANITIZE_ADDRESS__, wrap in a pragma to ignore -Wstringop-overread, due to false positives. 2022-08-03 12:30:29 -05:00
664fe390d6 Merge pull request #5382 from icing/announce-pskkem-plain
Announce TLSX_PSK_KEY_EXCHANGE_MODES in non-resuming ClientHello
2022-08-03 07:40:24 -07:00
0c1add08e3 Merge pull request #5416 from darktohka/feature/chacha20-outl-bytes
Ensure ChaCha20 updates out length during cipher update
2022-08-03 07:26:02 -07:00
4937557ddc Merge pull request #5422 from julek-wolfssl/dtls-async-fix
Fix dtls + async multi-test misc errors
2022-08-03 07:24:58 -07:00
ecdccb6180 Fix build error with WOLFSSL_AES_DIRECT 2022-08-03 09:09:28 -05:00
f713c75a73 Fix dead code warnings in evpCipherBlock and wc_CryptKey 2022-08-03 08:08:00 -05:00
53e0483e47 Support for Infineon AURIX IDE. Fixes for Aurix compiler warnings. 2022-08-02 16:53:47 -07:00
72b0f15075 Merge pull request #5424 from anhu/curl_ftps_fix 2022-08-02 23:22:11 +02:00
9d2ed67a5c Fix for sniffer to ensure the session was polled before trying to reprocess it. 2022-08-02 08:11:21 -07:00
013ad0d564 Add wolfSSL_PEM_read_RSAPrivateKey to OpenSSL compatible API 2022-08-03 00:02:40 +09:00
fd412ed298 Fix so curl can do FTPS on TLS 1.3 with session resumption. 2022-08-02 10:51:14 -04:00
3c51d872ea Fix build error and update manuals 2022-08-02 16:45:37 +09:00
9db4ae64b9 Merge pull request #5423 from douzzer/20220729-fixes
20220729-fixes
2022-08-02 08:03:53 +10:00
99ed727179 add WOLFSSL_CERT_NAME_ALL macro guard and new values to set subject 2022-08-01 10:52:09 -07:00
52b80ea52a expand functions included in opensslextra and add REQ print out 2022-08-01 09:21:43 -07:00
4602e6d892 Merge pull request #5426 from rizlik/epoch_bits_fix
fix: dtls13: use correct buffer index to get epoch bits
2022-08-01 07:41:44 -07:00
8878922f95 fix: dtls13: use correct buffer index to get epoch bits
Fixes: d079662765
2022-08-01 14:24:20 +02:00
791508220f wolfssl/internal.h: fix spurious assert failure on jumbo RSA key configurations (> 8192 bits); mollify bugprone-macro-parentheses. 2022-07-29 09:33:14 -05:00
fb2feee9b6 Fix dtls + async multi-test misc errors
DTLS uses DtlsMsgStore() to process messages when using async crypto. A check was skipping the storing straight to DtlsMsgDrain().
2022-07-29 15:49:49 +02:00
a943de7969 Changes after PR review.
- removed additions to REAME.md
- changed coding style of conditional PSKKEM announce
  as requested.
2022-07-29 11:26:08 +02:00
1db8013566 Update README with note about change in TLSX_PSK_KEY_EXCHANGE_MODES use. 2022-07-29 11:18:56 +02:00
c8008e29b9 Announce TLSX_PSK_KEY_EXCHANGE_MODES in non-resuming ClientHello.
- can be reverted to previous style by defining NO_TLSX_PSKKEM_PLAIN_ANNOUNCE
- QUIC interop testing reveals that at least QUIC stacks refrain from
  issuing session tickets unless the ClientHello shows this extension.
2022-07-29 11:18:56 +02:00
da422eb422 Merge pull request #5406 from SparkiDev/mp_int_size
Maths bit size: ensure size is right
2022-07-28 15:36:58 -07:00
d568e8c893 Merge pull request #5413 from SparkiDev/x509_san_crit
ASN template: allow SAN to be critical
2022-07-28 15:14:23 -07:00
ac85000a02 Merge pull request #5415 from douzzer/20220728-fixes
20220728-fixes
2022-07-28 12:48:40 -07:00
fde2097503 Merge pull request #5405 from SparkiDev/clang-x86
TFM: change inline x86 asm code to compile with clang
2022-07-28 08:42:17 -07:00
e599bb5048 Mark chacha20-poly1305 as an AEAD cipher 2022-07-28 18:36:52 +03:00
e3dd7677c8 Add tests for chacha20-poly1305 EVP integration 2022-07-28 18:21:12 +03:00
e8febaf414 Ensure ChaCha20 updates out length during cipher update 2022-07-28 18:06:41 +03:00
545ba58cc0 sp_int.c sp_div(): add missing (err == MP_OKAY) clause to fix null ptr deref. 2022-07-28 09:28:36 -05:00
3ac04fa3ee wolfcrypt/benchmark/benchmark.c: fix gating for #include <unistd.h>. 2022-07-28 09:28:36 -05:00
52cc73a6a4 Integrate chacha20-poly1305 into the EVP interface 2022-07-28 13:01:35 +03:00
70c38f2183 Cert: SAN extension critical
Add field to Cert to indicate SAN extension is critical.
Handle the field being set when encoding.
2022-07-28 14:16:56 +10:00
824d44b705 Merge pull request #5412 from douzzer/20220726-multi-test-fixes
20220726-multi-test-fixes
2022-07-27 20:44:46 -07:00
7b65a1f1c2 Merge pull request #5411 from anhu/selfsigned_template
Fix ASN template to use the subject as issuer if cert is selfsigned
2022-07-27 16:02:14 -07:00
6ecf2c0a5e Merge pull request #5399 from SparkiDev/sp_exptmod_reduce
SP int: exptmod ensure base is less than modulus
2022-07-27 15:43:16 -07:00
58cc326621 Calcuate ---> Calculate 2022-07-27 16:56:45 -04:00
33579045f2 Fix ASN template code to use the subject as issuer if cert is selfsigned. 2022-07-27 16:38:17 -04:00
9256d6aa7c src/internal.c: fixes for redundant assignments and preprocessor typo. 2022-07-27 14:42:00 -05:00
c63e22701f src/pk.c: fix type mismatch in return value. 2022-07-27 14:42:00 -05:00
ed449d5b20 wolfsentry integration: avoid redundant and frivolous dispatches (ssl.c wolfSSL_connect(), wolfSSL_negotiate(), wolfSSL_accept(); tls13.c wolfSSL_connect_TLSv13(), wolfSSL_accept_TLSv13()). 2022-07-27 14:42:00 -05:00
feb911c612 Merge pull request #5398 from dgarske/make_dist_small
Script to produce a small source/header only package
2022-07-27 14:33:59 -05:00
a56d25d58e Merge pull request #5408 from julek-wolfssl/FreeAsyncCtx-location
FreeAsyncCtx should only be called when advancing state
2022-07-27 09:59:28 -07:00
0f0b7c553c Keep .i files needed for fast math. Use test_paths.h from .in to remove user path info. 2022-07-27 08:33:27 -07:00
6f282c2c57 Merge pull request #5402 from rizlik/dke_rsa
doClientKeyExchange improvements
2022-07-27 08:01:16 -07:00
e9b3b5936f FreeAsyncCtx should only be called when advancing state
The call to FreeAsyncCtx after SendBuffered was added to clean up state when we are ready to advance state. If we do not advance state, then clean up should be handled in the relevant state.
2022-07-27 14:14:22 +02:00
460845ba49 Maths bit size: ensure size is right
Ensure WOLFSSL_MAX_RSA_BITS works.
Fix SP math size defines.
Regression testing maths implementations.
2022-07-27 18:58:30 +10:00
788348dce2 TFM: change inline x86 asm code to compile with clang 2022-07-27 14:05:37 +10:00
01aad13c38 Rework 2022-07-27 12:02:15 +10:00
f31c8223f2 fix for not having default pkcs7 signed attributes 2022-07-26 16:45:44 -07:00
9ac3c9ec05 ECC import priv: validate priv is less than order
Valid private key must be less than order.
Check on import when WOLFSSL_VALIDATE_ECC_IMPORT defined.
2022-07-27 09:29:07 +10:00
9c480ece66 Fix to use the new outTmp. 2022-07-26 15:48:58 -07:00
c2476e3858 SP int: exptmod ensure base is less than modulus
Ensure sp_div uses rem only when rem is big enough.
2022-07-27 08:48:28 +10:00
5f47adba3c Merge pull request #5401 from dgarske/cmake_install_spmathall 2022-07-26 15:02:42 -07:00
856ea2ffc8 internal.c: RsaDec improvements 2022-07-26 20:59:01 +02:00
1727efbc2c internal.c: rsa decription buffer handling 2022-07-26 20:59:01 +02:00
2e1e8d2789 misc.c: introduce ctMaskCopy() 2022-07-26 20:59:01 +02:00
344ad48f03 Fix for CMake not installing sp_int.h for SP math all. 2022-07-26 11:29:21 -07:00
1003dfeefc Merge pull request #5392 from JacobBarthelmeh/caam
more macro guards with CAAM builds
2022-07-26 09:41:21 -07:00
9e213cab19 Fixes for the script (from Douzzer). 2022-07-26 08:50:27 -07:00
a5b1838d8f Merge pull request #5393 from TakayukiMatsuo/leakfix 2022-07-26 09:44:19 -06:00
a05b38059e Merge pull request #5385 from miyazakh/sce_jenkins_fail 2022-07-26 09:41:46 -06:00
48016adf52 Script to produce a small source/header only package (with CMake support) 2022-07-25 17:08:13 -07:00
a98642ba61 Merge pull request #5383 from julek-wolfssl/negating-ciphersuites
Expand SetCipherList()
2022-07-25 08:26:47 -07:00
97970d87a5 Merge pull request #5350 from SparkiDev/sp_math_fixes_1
SP math
2022-07-25 08:18:55 -07:00
7174e6766b Merge pull request #5391 from embhorn/gh5366
Fix to copy TLS version with wolfSSL_write_dup
2022-07-25 07:56:14 -07:00
cceb35abe2 Merge pull request #5394 from SparkiDev/pathlen_set_0
Cert path length: add flag to indicate path length set
2022-07-25 07:54:30 -07:00
ec565250ed Merge pull request #5395 from SparkiDev/encrypt_len_fix
ENCRYPT_LEN fix
2022-07-25 07:53:50 -07:00
5a0afc512e Fix memory leak in ECDHE with TSIP 2022-07-25 19:43:32 +09:00
e7cd1562b4 Expand SetCipherList()
- support disabling ciphersuites starting from the default list
2022-07-25 11:14:16 +02:00
8e20a5900c ENCRYPT_LEN fix
Fix check for WOLFSSL_SP_MATH_ALL and WOLFSSL_SP_MATH instead of
WOLFSSL_SP_MATH twice.
2022-07-25 09:35:43 +10:00
8fa2449a63 Cert path length: add flag to indicate path length set
A path length is allowed to be 0.
Can't check path len for 0 to determine when value is set.
Added flag to indicate path length is set.
2022-07-25 09:07:14 +10:00
56bec875b4 Merge pull request #5390 from kareem-wolfssl/bnGenPrimeRsa
Update sp_rand_prime's preprocessor gating to match wolfSSL_BN_generate_prime_ex's.
2022-07-25 08:10:06 +10:00
35d40f263e more macro guards with CAAM builds 2022-07-22 16:19:55 -07:00
4369873540 Fix to copy TLS version with wolfSSL_write_dup 2022-07-22 15:09:35 -05:00
dc92ec2aa9 Update sp_rand_prime's preprocessor gating to match wolfSSL_BN_generate_prime_ex's. 2022-07-22 11:07:46 -07:00
6f2889c07d BIO_eof returns 1 when no more data remains in the BIO 2022-07-22 13:24:32 +02:00
491ebb7a3d fixed compile error due to degression
fixed memory leak in wc_SCE_EccVerify
2022-07-22 08:29:05 +09:00
dc8b796d1d Merge pull request #5347 from dgarske/async_sess_tick
Support for asynchronous session ticket callback
2022-07-22 08:04:48 +10:00
02e512142c Merge pull request #5359 from haydenroche5/unit_test_refactor
Begin refactor of api.c.
2022-07-21 15:52:40 -05:00
281825db20 Merge pull request #5353 from rizlik/dtls13_async_fixes
Dtls13 async fixes
2022-07-21 13:24:35 -07:00
69e2f5243c Merge pull request #5326 from gojimmypi/ESP32_HW_Update_PR
Espressif ESP32 Hardware Acceleration Update and Cleanup
2022-07-21 12:09:09 -07:00
163acb89af dtls13: consider certificate_request processed on WC_PENDING_E
The error is due to the message triggered by the processing of the
message (Connect()->SendTls13Certificate/SendTls13CertificateVerify/SendTls13Verify). Consider
the message processed to avoid double processing.
2022-07-21 12:00:18 -07:00
aca83b42d7 fix: dtls13: send immediately post-handshake certificate request 2022-07-21 12:00:18 -07:00
53dde1dafe dtls12: async: store the message only if async is really used 2022-07-21 12:00:18 -07:00
964ea85d3d Fix typos for dynamic types in dtls13.c. 2022-07-21 12:00:18 -07:00
dce63fdfb3 async: fix issue with DTLSv1.3 2022-07-21 12:00:16 -07:00
07afc594a8 dtls13: aesthetic only changes 2022-07-21 11:55:50 -07:00
b5ce0b021e Merge pull request #5381 from rizlik/async_fix
fix: async: don't rewind index if post-handshake connect() fails
2022-07-21 11:53:15 -07:00
c5e7ccca2c Merge pull request #5380 from danielinux/typo-doc
Fixed typo in dox_comments
2022-07-21 11:52:56 -07:00
daf5135642 Begin refactor of api.c.
- Modify all existing tests to return an int. This moves us in the direction of
being able to return error/success from a test rather than just calling abort
when something fails. Also, all tests now have the same signature, so they can
easily be members of an array of test cases.
- Wrap each test in a TEST_CASE struct, which just stores a pointer to the test
function and the name of the test, for now. In the future, other metadata can
be added (e.g. should this test be run/skipped) to TEST_CASE, if desired.
- Modify all tests to return 0 on success. Right now, this doesn't do us much
good because the failure mechanism isn't returning some value != 0, it's
abort.
- Add TestSetup and TestCleanup functions that run before and after each test,
respectively. The former does nothing right now, and the latter clears the
error queue, if the error queue is compiled in.
2022-07-21 10:12:26 -07:00
1281d97b1e Merge pull request #5373 from haydenroche5/error_queue_fix
Fix backwards behavior for various wolfSSL_ERR* functions.
2022-07-21 09:35:21 -06:00
a235de25fe fix: async: don't rewind index if post-handshake connect() fails
During post-handshake authentication async code mistakes connect() error code
with the error code of DoTls13CertificateRequest and wrongly rewinds the buffer.

The bug was never triggered because of side effects of ShrinkBuffer (removed in
40cb6e0853)
2022-07-21 16:35:43 +02:00
a18b1939ac Fixed typo in dox_comments 2022-07-21 10:19:51 +02:00
c60fae8731 wc_Sha256Free checks lockDepth for Espressif RTOS 2022-07-21 09:08:10 +02:00
bd28b52aaa #include "wolfssl/wolfcrypt/settings.h" 2022-07-21 09:06:01 +02:00
9da0ff0f31 Merge branch 'master' of https://github.com/wolfSSL/wolfssl into ESP32_HW_Update_PR 2022-07-21 08:21:17 +02:00
58aec606c6 wolfSSL license, not wolfSSH 2022-07-21 08:12:54 +02:00
6937062b9a wolfSSL license, not wolfSSH 2022-07-21 08:09:19 +02:00
a4e3dc9638 Merge pull request #5379 from douzzer/20220720-fixes
20220720-fixes
2022-07-20 21:34:08 -06:00
8605195709 Support for asynchronous session ticket callback (can return WC_PENDING_E). Requires wolfAsyncCrypt support. ZD 14420. 2022-07-20 16:43:17 -07:00
542c53f3ac snip out errant "#/" strings added to various text files by copyright boilerplate update in 8eaa85e412. 2022-07-20 18:23:28 -05:00
a3fd714501 configure.ac: allow --enable-opensslextra with --enable-linuxkm if --enable-cryptonly is also given. 2022-07-20 18:21:29 -05:00
3842889649 src/tls13.c: in SendTls13ClientHello(), move nullness check on WOLFSSL* ssl back to the start of the function. 2022-07-20 18:19:58 -05:00
706ab6aac0 Merge pull request #5377 from kareem-wolfssl/rsaKeyEncipher
Don't require digital signature bit for static RSA cipher suites.  Make wolfSSL_CTX_clear_options available without OPENSSL_EXTRA.
2022-07-20 15:28:55 -07:00
bd2b510487 Merge pull request #5376 from dgarske/sniff_tlsv12_sessticket
Fixes for sniffer session ticket resumption with TLS v1.2
2022-07-21 08:22:33 +10:00
9450fa1412 Merge pull request #5375 from LinuxJedi/se050-private-key-add
Add ECC private key insertion for SE050
2022-07-20 12:42:13 -07:00
741d61574b Make wolfSSL_CTX_clear_options available without OPENSSL_EXTRA. 2022-07-20 12:24:47 -07:00
873890316c Don't require digital signature bit for static RSA cipher suites. 2022-07-20 12:08:20 -07:00
564f79c91a Merge pull request #5371 from douzzer/20220719-linuxkm-get_thread_size-no-thunks
linuxkm: inhibit thunk generation in get_thread_size.
2022-07-20 11:48:48 -07:00
1c7f64cce9 Fixes for sniffer session ticket resumption with TLS v1.2. ZD14531. 2022-07-20 11:18:19 -07:00
b46a308544 Merge pull request #5361 from embhorn/zd14491
Fix for build with NO_TLS
2022-07-20 09:28:23 -07:00
e6da540fb3 Fix backwards behavior for various wolfSSL_ERR* functions.
wolfSSL_ERR_get_error and wolfSSL_ERR_peek_error_line_data should return the
earliest error in the queue (i.e. the error at the front), but prior to this
commit, they returned the latest/most recent one instead.

In DoAlert, we were adding an error to the queue for all alerts. However, a
close_notify isn't really an error. This commit makes it so DoAlert only adds
errors to the queue for non-close_notify alerts. In ReceiveData, similarly, we
were adding an error to the queue when the peer sent a close_notify, as
determined by ssl->error == ZERO_RETURN. Now, we don't add an error in this
case.
2022-07-20 08:56:48 -07:00
07d2940757 Fix issue caused by undo in IDE 2022-07-20 16:42:09 +01:00
ab60865178 Merge pull request #5374 from julek-wolfssl/dtls-multiple-msgs
ShrinkInputBuffer should not be called in the middle of ProcessReply
2022-07-20 08:27:56 -07:00
d7b4abfa0b Fixups to the SE050 ECC pkey insert function 2022-07-20 16:25:39 +01:00
719e814841 Merge pull request #5370 from rizlik/dtls13_partial_read_fixes
dtlsv1.3 fixes
2022-07-20 08:03:29 -07:00
e4c1e71b38 Merge pull request #5364 from embhorn/zd14519
Fix wolfSSL_Init error handling
2022-07-20 08:03:08 -07:00
f4191a102b Merge pull request #5304 from SKlimaRA/SKlimaRA/cert-pathlen
drafted pathlen for cert struct
2022-07-20 07:54:13 -07:00
aab2459d1f Merge pull request #5372 from JacobBarthelmeh/copyright
update copyright year to 2022
2022-07-20 07:52:05 -07:00
c029b23043 Merge pull request #5308 from SparkiDev/ecies_gen_iv
ECIES: Google Pay generates IV and places it before msg
2022-07-20 06:46:14 -07:00
2e0d53a07d fix: dtls13: use correct handshaketype on hello retry request 2022-07-20 15:25:50 +02:00
3850e6b554 fix: dtls13: use aes for record numbers encryption if using aes-ccm 2022-07-20 15:25:50 +02:00
066f17faad fix: dtls13: hello_retry_request type isn't an encrypted message 2022-07-20 15:25:50 +02:00
c0fc87342c tls13: avoid spurious state advances in connect/accept state machine 2022-07-20 15:25:50 +02:00
11dfb713e9 openssl_compatible_default: use DTLSv1.0 as minDowngrade in DTLS 2022-07-20 15:25:46 +02:00
6711756b03 dtls13: support stream-based medium
Don't assume that the underlying medium of DTLS provides the full message in a
single operation. This is usually true for message-based socket (eg. using UDP)
and false for stream-based socket (eg. using TCP).

Commit changes:

- Do not error out if we don't have the full message while parsing the header.
- Do not assume that the record header is still in the buffer when decrypting
  the message.
- Try to get more data if we didn't read the full DTLS header.
2022-07-20 14:53:07 +02:00
40cb6e0853 ShrinkInputBuffer should not be called in the middle of ProcessReply 2022-07-20 11:57:48 +02:00
ea34fb1643 Add ECC private key insertion for SE050
This adds a utility function which allows an ECC private key to be
inserted into the SE050's permanent storage.
2022-07-20 10:45:26 +01:00
66c5a947fd XSTRNCPY, fixed typos 2022-07-20 08:56:59 +02:00
09bba3510f ECIES: Google Pay ECIES
Generates IV and places it before msg
Uses 12 byte IV with AES-CTR
Add API to explicitly set KDF salt.
2022-07-20 09:30:47 +10:00
8eaa85e412 update copyright year to 2022 2022-07-19 10:44:31 -06:00
8b904e9082 Fix for build with NO_TLS 2022-07-19 11:12:18 -05:00
0dac3ec022 linuxkm: inhibit thunk generation in get_thread_size. 2022-07-19 10:20:04 -05:00
1a44bad8cc drafted test case for path len 2022-07-19 15:34:20 +02:00
3d721bd533 more WOLFSSL_CERT_EXT 2022-07-19 11:00:36 +02:00
6ce5f645f3 added ASN template code and WOLFSSL_CERT_EXT, still missing testcase 2022-07-19 10:38:47 +02:00
9a3efb67b8 Merge pull request #5368 from lealem47/disableAes
Fix for --disable-aes without --disable-aesgcm
2022-07-18 15:05:59 -07:00
feb3f889af Merge pull request #5369 from embhorn/zd14522
Fix var init in wc_ecc_shared_secret
2022-07-18 14:17:53 -07:00
cee9f9a871 Fix for --disable-aes without --disable-aesgcm 2022-07-18 10:26:20 -07:00
c63abe398f Merge pull request #5321 from miyazakh/tsip_add_usecase 2022-07-18 09:35:43 -06:00
f55fe7fccd Fix var init in wc_ecc_shared_secret 2022-07-18 09:13:07 -05:00
218ab7e396 Merge pull request #5362 from haydenroche5/ssl_set_options_public
Make wolfSSL_(get|set)_options available outside compat layer.
2022-07-15 10:36:29 -07:00
e7303d697b Fix wolfSSL_Init error handling 2022-07-15 09:30:30 -05:00
8a757ef7cf Merge pull request #5363 from dgarske/se050_curve25519
Fixes for SE050 Curve25519 endianness
2022-07-15 08:49:27 +01:00
15725400a7 addressed review comments 5 2022-07-15 13:46:30 +09:00
a1b7c29309 Make wolfSSL_(get|set)_options available outside compat layer.
Also make wolfSSL_CTX_get_options available.
2022-07-14 16:03:58 -07:00
dec8a7fd93 Fixes for SE050 Curve25519 endianness (SDK assumes little endian). Fix for ECC se050_ecc_shared_secret use of wrong pointer on error handle free. 2022-07-14 15:34:50 -07:00
6cc2665a81 Merge pull request #5358 from SparkiDev/sp_int_armv6
SP int ARM32: replace clz instruction when not supported
2022-07-14 15:32:00 -07:00
350ff552c4 Merge pull request #5351 from kojo1/renesas-csp 2022-07-14 16:10:34 -06:00
abba59f735 order of array of names for asn template build 2022-07-14 13:15:59 -07:00
8862e1f8cf resolve name conflict 2022-07-14 09:41:36 -07:00
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
fd885d89eb Added multi thread use case
Improve not to use forward declaration struct definition

 - include ssl.h rather than forward declaration struct to resolve struct name
 - to include ssl.h, it needs to avoid cyclic reference for crypt structure. therefore, Sha and Aes definitions are moved to another header file
2022-07-14 17:25:21 +09:00
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
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
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
f6c4e295b1 add more subject name support and expande REQ attributes creation support 2022-07-13 22:02:49 -07:00
5dcb1ba21f remove carriage return from CONF strings 2022-07-13 22:02:49 -07:00
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
33b3ebb1e9 SP int ARM32: replace clz instruction when not supported 2022-07-14 09:37:28 +10:00
2d5bc72c9b Fixes for ED25519/ED448 private key with public key export (RFC8410). Added length only support. 2022-07-13 16:17:08 -07:00
586ae71dac Fixes for SE050 ECC and Curve25519 with TLS. 2022-07-13 10:50:10 -07:00
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
065991bab5 Merge pull request #5348 from douzzer/20220707-attend-return-values
20220707-attend-return-values
2022-07-13 08:50:29 -07:00
1b6ce6150e unsigned pathlen 2022-07-13 09:07:02 +02:00
96fe356dd8 SP math
Enable ForceZero for SP math and all RSA.
Disable use of 128-bit type in SP unless WOLFSSL_UINT128_T_DEFINED is
defined.
2022-07-13 14:54:34 +10:00
69bf0345c4 Renesas cs+ project. Remove depreciated algorithms 2022-07-13 10:24:44 +09:00
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
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
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
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
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
e30899b676 Merge pull request #5334 from LinuxJedi/se050-fixes
Fixes to SE050 port
2022-07-11 16:15:08 -07:00
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
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
57aac1c50b Merge pull request #5345 from JacobBarthelmeh/release
Release version 5.4.0
2022-07-11 11:10:10 -07:00
a48129eb99 update README for release 2022-07-11 07:28:15 -07:00
032d59b077 adjust sizeof type for getsockopt argument 2022-07-11 07:10:11 -07:00
86662bca2f update library version to 5.4.0 2022-07-08 16:04:26 -07:00
7379e377ab cast for g++ warning 2022-07-08 15:11:29 -07:00
983b9fc5fb Merge pull request #5343 from dgarske/ecc_oid_coding
Fixes for ECC OID encoding/decoding
2022-07-08 15:38:47 -06:00
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
66aed8193a Merge pull request #5341 from dgarske/various_20220708
Various fixes and cleanups
2022-07-08 13:56:51 -06:00
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
720030b5a9 Improvements to error handling for AddSessionToClientCache. 2022-07-08 09:06:51 -07:00
03a32250da Fix for KCAPI HMAC forcing use of software for HKDF. 2022-07-08 09:06:30 -07:00
3d124c093e Fix PK function name in log. Remove the ECC logging (spams benchmark with --enable-debug). 2022-07-08 09:06:08 -07:00
905f71d80d Fix with macro redefinition error if building with NO_WOLFSSL_ALLOC_ALIGN. 2022-07-08 09:05:29 -07:00
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
2d6b6d62b2 Gate ALT_ECC_SIZE on NO_MALLOC and STATIC_MEMORY since they conflict. 2022-07-08 10:52:01 -04:00
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
48d3cf593e tests/api.c: fix bugprone-macro-parentheses in DUW_TEST(). 2022-07-08 07:57:29 -05:00
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
58cb91602d Merge pull request #5337 from douzzer/20220707-DtlsUpdateWindowGTSeq-overshift
20220707-DtlsUpdateWindowGTSeq-overshift
2022-07-07 21:53:26 -07:00
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
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
49d292ec4f Merge pull request #5335 from SparkiDev/ecc_imp_exp_fix
ECC import and export fixes
2022-07-07 17:52:20 -07:00
b952c2f777 src/internal.c: add codepath in _DtlsUpdateWindowGTSeq() to avoid a word32 overshift. 2022-07-07 19:36:20 -05:00
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
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
4e1e1e922a Merge pull request #5278 from ejohnstown/dtls-seq
Refactor DTLS Window Update (Fix #5211)
2022-07-07 10:22:21 -07:00
5e453ad932 Merge pull request #5323 from SparkiDev/sha512_arm32_asm_align 2022-07-07 09:47:37 -06:00
e295328436 Fix window handling around word32 boundary 2022-07-07 17:37:10 +02:00
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
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
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
2111d6b179 Merge pull request #5322 from SparkiDev/sp_math_all_arm32_div_word_fix
SP math all: fix div word for ARM32
2022-07-06 22:18:07 -05:00
74baa0dafa SP math: fix configure.ac to allow its use
Choosing SP and SP math was resulting in only integer.c being used.
Fixed now.
Reorder realloc calls for memory logging to ensure scripts can match
allocate and free calls.
2022-07-07 12:16:12 +10:00
644050a736 Merge pull request #5329 from douzzer/20220706-fips-and-aarch64-fixes
20220706-fips-and-aarch64-fixes
2022-07-06 18:39:38 -07:00
cb6fa921a4 Merge pull request #5328 from haydenroche5/cmake_sp_math_all_default
Make changes to CMake to support SP math default.
2022-07-06 18:39:30 -07:00
8f3449ffea Refactor DTLS Window Update (Fix #5211)
1. Rename _DtlsUpdateWindow() as wolfSSL_Dtls_UpdateWindow() and make
   it public so it may be tested.
2. Rename the internal functions DtlsWindowUpdate(), DtlsWindowCheck(),
   and DtlsUpdateWindowGTSeq() as _DtlsWindowUpdate() and
   _DtlsWindowCheck(), and _DtlsUpdateWindowGTSeq().
3. When updating the DTLS sequence window, and the next sequence
   number (lo) wraps to zero, increment the next sequence number (hi)
   by 1.
4. Fix an off-by-one error that wrapped around when saving the
   packet sequence number in the bit-field window.
5. Adding a test for wolfSSL_DtlsUpdateWindow() function. With many test
   cases. It is set up in a table format with running check values.
6. Change location of incrementing the difference when calculating the
   location for setting the bit.
7. Updated the check of the sequence difference in the GT scenario.
8. In the DTLS window update functions remove newDiff and just use diff.
9. Handle the cases where the DTLS window crosses the high order word
   sequence number change.
10. Add a debug option to print out the state of the DTLS sequence number
   window.
2022-07-06 18:20:06 -07:00
90c2f4ad00 Merge pull request #5327 from kareem-wolfssl/connectRetFix
Fix storage of SendBuffered's return code in wolfSSL_Connect.
2022-07-06 17:53:04 -07:00
9ba77300f9 AESNI: fix configure to use minimal compiler flags 2022-07-07 09:30:48 +10:00
992c7b3b6f SP math all: fix div word for ARM32
Fixup sp_mulmod NULL access.
2022-07-07 08:56:31 +10:00
82b1dc0cd0 wolfcrypt/src/asn.c: move final return in DecodeECC_DSA_Sig() outside the NO_STRICT_ECDSA_LEN gate, to avoid no-return-from-non-void. 2022-07-06 17:39:59 -05:00
eff4fe398b src/include.am: fix gating around sha* and BUILD_ARMASM, to avoid empty-translation-unit warnings for sha{256,512}.c on armasm builds. 2022-07-06 17:37:43 -05:00
7c49449a79 wolfcrypt/src/port/arm/armv8-sha512.c: gate out Sha512_Family_GetHash() in builds that have 224 and 256 bit hashes gated out, to fix unused function warning. 2022-07-06 17:35:15 -05:00
6b6abfac54 examples/client/client.c: remove break after err_sys() to mollify clang-tidy unreachable-break sensor. 2022-07-06 17:32:26 -05:00
19106a9510 configure.ac and tests/api.c: lock out compkey on FIPS 140-3 RC12 and ready, and add backward-compat code in test_wc_ecc_export_x963_ex() to allow RC12 compkey builds to pass unit.test. 2022-07-06 17:31:56 -05:00
d9bf39ffaa Make changes to CMake to support SP math default.
We recently made SP math the default big integer math library. Some changes to
the CMake code are needed for this to work.
2022-07-06 14:14:12 -07:00
44a49aeefa Fix potentially uninitialized variables in Dtls13SetRecordNumberKeys. 2022-07-06 13:45:15 -07:00
c8f5bd3d61 Fix storage of SendBuffered's return code in wolfSSL_Connect. Store in ret initially, only store in ssl->error if there's an error. This matches the logic in wolfSSL_accept. 2022-07-06 12:09:47 -07:00
b2d1bf96ed Merge pull request #5276 from rizlik/dtls13_client_downgrade
Dtls: improve version negotiation
2022-07-06 11:57:53 -07:00
a7fa7875e4 Merge pull request #5244 from julek-wolfssl/wpas-dpp
Support for new DPP and EAP-TEAP/EAP-FAST in wpa_supplicant
2022-07-06 11:35:52 -07:00
e92034cf6f Merge pull request #5274 from JacobBarthelmeh/Certs
remove subject/issuer email from altEmailNames list
2022-07-06 10:48:21 -07:00
e2484a97f2 Merge branch 'master' of https://github.com/wolfSSL/wolfssl into ESP32_HW_Update_PR 2022-07-06 09:32:07 -07:00
8bb6ff8dbb Espressif HW acceleration update & cleanup 2022-07-06 09:30:49 -07:00
711b2bb17a add a test case 2022-07-06 09:39:03 -06:00
a171bebba4 Fix the wc_EccPublicKeyToDer_ex doxy. 2022-07-06 07:58:18 -07:00
3abffc3a3c doc: add documentation for wolfDTLS[v1_3]_*_method() 2022-07-06 16:18:44 +02:00
683adb5917 tests: add dtls downgrade tests 2022-07-06 16:18:44 +02:00
fd4836772b examples: support DTLS version downgrading 2022-07-06 16:18:44 +02:00
df7e81d187 dtls: support version negotiation 2022-07-06 16:18:44 +02:00
8fe3f51ecb dtls13: client: recompute transcript hash on downgrade
If a lower version is negotiated, the transcript hash must be recomputed using
the <= v1.2 rules.
2022-07-06 16:18:44 +02:00
5d74c49ecb dtls13: allow processing of HelloVerifyRequest to support downgrade
HelloVerifyRequest is used in DTLSv1.2 to perform a return routability check, so
it can be the legitim reply from a DTLSv1.2 server to a ClientHello.
2022-07-06 16:18:44 +02:00
ec8149cd69 Merge pull request #5324 from julek-wolfssl/dtls13-hrr-fix
TLSX_COOKIE is only defined with WOLFSSL_SEND_HRR_COOKIE
2022-07-06 06:56:25 -07:00
9b085a44be sessionSecretCb should only be called when a ticket is present 2022-07-06 15:08:57 +02:00
63b4c475d4 wolfSSL_set_session_secret_cb: fix for NULL input 2022-07-06 14:23:08 +02:00
39e53c2b7c Add wc_EccPublicKeyToDer_ex doxygen entry 2022-07-06 11:59:29 +02:00
ef73409fd4 TLSX_COOKIE is only defined with WOLFSSL_SEND_HRR_COOKIE 2022-07-06 10:04:15 +02:00
8b73feb8ef SHA-512 ARM NEON: ensure data being hashed is 64-bit aligned 2022-07-06 16:18:18 +10:00
ff6edbff94 refactor name constraint checks 2022-07-05 17:20:50 -06:00
9a256ca002 Merge pull request #5288 from haydenroche5/openldap
Add --enable-openldap option to configure.ac.
2022-07-05 16:04:51 -07:00
4376ade9c8 Merge pull request #5123 from fabiankeil/configure-amd64-support
configure: Improve defaults for 64-bit BSDs
2022-07-05 13:52:02 -07:00
08488b0fae Merge pull request #5318 from embhorn/gh5314
Fix typos and bad macro names
2022-07-05 12:34:35 -07:00
f5a5d4ada5 Enhance OpenLDAP support.
- Add --enable-openldap to configure.ac
- Fix some issues around subject alt names and the WOLFSSL_GENERAL_NAME struct.
2022-07-05 10:40:07 -07:00
eb9a9ceef8 configure: Improve defaults for 64-bit BSDs
... by consistently treating host cpu "amd64" like host cpu "x86_64".

Tested on ElectroBSD amd64.
2022-07-05 19:37:31 +02:00
ded3f4e9b6 Merge pull request #5284 from julek-wolfssl/dtls-good-ch-cb
DTLS 1.3: additions for event driven server in wolfssl-examples
2022-07-05 10:14:59 -07:00
1c009e8f91 Merge pull request #5311 from SparkiDev/ed_check_pubkey
Ed25519/Ed448: assume public key is not trusted
2022-07-05 09:25:50 -07:00
394f36a0d7 Fix typos and bad macro names 2022-07-05 10:31:11 -05:00
4caffee590 ForceZero the private key on import error 2022-07-05 13:44:31 +02:00
20e5c98b2c Error out when server indicates resumption but does full handshake 2022-07-05 09:42:39 +02:00
fd7bf8d04d Do resuming check as soon as we get a non-resumption msg 2022-07-05 08:49:00 +02:00
144f2612e4 wc_ecc_export_x963_ex returns LENGTH_ONLY_E on a NULL output 2022-07-05 08:49:00 +02:00
8e84560f71 CSR: confirm the signature when verify == VERIFY 2022-07-05 08:49:00 +02:00
afaf41823c wpa_supplicant uses larger challenge passwords for x509 requests 2022-07-05 08:49:00 +02:00
5179741ddb wpas: validate ecc points are on the curve 2022-07-05 08:48:37 +02:00
ee3636f2e7 wc_EccPublicKeyToDer_ex: exporting the public key in compressed form 2022-07-05 08:48:18 +02:00
448cde5a4b Support for new DPP in wpa_supplicant
- Add null check to asn template code in MakeCertReq and test
- ENABLED_ECCCUSTCURVES can also be "all"
2022-07-05 08:48:18 +02:00
4a962b7fb2 Ed25519/448: improvements
Check lengths of buffers in import functions.
priv/pub key set flag set on success only.
2022-07-05 09:02:05 +10:00
1b64b82a6f Merge pull request #5316 from LinuxJedi/fix-embos-mutex
Use the correct mutex type for embOS
2022-07-04 11:51:20 -07:00
07b8f45d35 Merge pull request #5315 from rizlik/dtls_doDtls_fix
fix: examples/server: dtls mode checking
2022-07-04 10:20:20 -07:00
f8c67345d6 Use the correct mutex type for embOS
OS_MUTEX_Lock() is acutally a non-blocking mutex lock, for
wc_LockMutex() we need a blocking mutex. Switch to this.
2022-07-04 15:59:36 +01:00
9dc2c27e3d Expand wolfDTLS_SetChGoodCb() docs 2022-07-04 14:31:24 +02:00
10c8a1668e Reset cookie when resetting DTLS 1.3 state 2022-07-04 12:52:25 +02:00
a8adde66c8 Use wc_HmacInit and wc_HmacFree in cookie logic 2022-07-04 12:51:50 +02:00
00391a5ace Rename callback to wolfDTLS_SetChGoodCb and add doxygen for it. Clarify DTLS_CTX.connected. Fix build errors for ./configure --enable-dtls --enable-dtls13 --disable-examples CFLAGS="-DNO_WOLFSSL_SERVER". 2022-07-04 11:08:39 +02:00
7ea13bf5bf Apply connected to sendto and address code review 2022-07-04 11:08:39 +02:00
dd7073740b DTLS 1.3: tie cookie to peer address 2022-07-04 11:08:39 +02:00
e605cfeccb Add docs for new features 2022-07-04 11:08:39 +02:00
afdd5648aa Address code review 2022-07-04 11:08:39 +02:00
d72edd03b8 dtls: wolfSSL_set_dtls_fd_connected
wolfSSL_set_dtls_fd_connected sets the connected socket file descriptor. This descriptor should be called without addr and addr_len.
2022-07-04 11:08:39 +02:00
c6aa4fc526 DTLS 1.3: allow the server to operate without maintaining state 2022-07-04 11:08:39 +02:00
8fb48464e3 Add callback when we parse a verified ClientHello 2022-07-04 11:08:39 +02:00
80f3db6e1d fix: examples/server: dtls mode checking
This fixes using ssl to check if we are using dtls or not, when ssl is not yet
valid.

Fix: 060dfe1a69
2022-07-04 10:21:11 +02:00
1077829f9d Merge pull request #5313 from douzzer/20220701-sp_div-deadstore
fix clang-analyzer-deadcode.DeadStores in sp_div().
2022-07-04 08:32:50 +10:00
7b9c214b3c Merge pull request #4985 from kareem-wolfssl/iarWarningsFix
Fix compilation warnings from IAR.
2022-07-04 08:23:26 +10:00
b16c2a2aef fix clang-analyzer-deadcode.DeadStores in sp_div(). 2022-07-01 23:49:58 -05:00
5819332f89 Merge pull request #5312 from dgarske/fips_v5dev
FIPS in core hash using SHA2-256 and SHA2-384
2022-07-01 23:25:52 -05:00
6c7db7318e Merge pull request #5309 from kareem-wolfssl/arrayBoundFix
Pass in and check output length in SetCurve.
2022-07-01 18:58:42 -07:00
b9be5c2c24 Update to FIPS v5-ready will use latest master. Support for FIPS in core hash using SHA2-256 and SHA2-384 in fips_test.h. Fixes for MATH_INT_T. Fix error: ‘tls13_kdf_test’ declared ‘static’ but never defined. 2022-07-01 15:40:21 -07:00
bb68766bda For ED255219 and ED448 if importing private only and public key is already set then check it. 2022-07-01 14:13:45 -07:00
90749b7f88 Don't declare tls13_kdf_test if TLS 1.3 is not enabled, to avoid unused function warning. 2022-07-01 13:22:16 -07:00
96aedc2f47 Fix SetCurve max sizes. Add fix for potentially uninitialized type in ProcessReplyEx. 2022-07-01 13:18:33 -07:00
7a7d8d170d Pass in and check output length in SetCurve. 2022-07-01 13:18:33 -07:00
bd75e1d6a4 Merge pull request #5307 from kareem-wolfssl/miscfixes2
Fix a couple of STM32 bugs, and add some missing mutex frees.
2022-07-01 09:46:22 -07:00
0459e83a59 Merge pull request #5310 from SparkiDev/memusage_fix_1
TLS memusage: reduce usage
2022-07-01 09:13:05 -07:00
2c943282f0 Ed25519/Ed448: assume public key is not trusted
In defense against attack, assume the imported public key is not trusted
and check it matches the private key if set.
Added APIs that allow application to explicitly trust public key.
Original APIs default to not trusting public key.
2022-07-01 09:05:43 -07:00
b9a8f18a97 Merge pull request #5300 from douzzer/20220629-multi-test-fixes
20220629-multi-test-fixes
2022-07-01 16:22:05 +10:00
7d58dc5678 TLS memusage: reduce usage
Reduce the amount allocated to reduce maximum overall dynamic memory
usage.
Rework ServerKeyExchange by extracting the handling of the signed data.
2022-07-01 14:24:59 +10:00
b2e7f4a8eb Fix cast spacing. Don't cast in wolfSSL_X509_set_version, check is valid as is. 2022-06-30 16:26:43 -07:00
7555cd0685 Fix a couple of STM32 bugs, and add some missing mutex frees. 2022-06-30 16:11:16 -07:00
402a4dafd4 Merge pull request #5306 from kareem-wolfssl/ltc_ed235519
Fix missing return checks in KSDK ED25519 code.
2022-06-30 16:06:45 -07:00
fc5f1f5eca Merge pull request #5305 from dgarske/cryptonly
Improvements to configure.ac cryptonly and math selection
2022-06-30 17:55:27 -05:00
2bdcbcc8be src/tls13.c: fix whitespace. 2022-06-30 17:17:50 -05:00
4f6527353b src/{pk.c,x509.c}: style/clarity cleanups from dgarske. 2022-06-30 17:07:35 -05:00
1a9388b935 src/pk.c: fix misuses around snprintf(). 2022-06-30 17:07:35 -05:00
28213ad198 src/x509.c: fix wolfSSL_X509_signature_print() to print raw signature algorithm as hex digits, not as an (unprintable) string; fix printed-null bug in wolfSSL_X509_NAME_print_ex() (relates particularly to calls from wolfSSL_X509_NAME_print_ex_fp()). 2022-06-30 17:07:35 -05:00
5bd8288b37 fix printed-null bug in wolfssl_print_number(). 2022-06-30 17:07:35 -05:00
b7ec529f61 wolfcrypt/src/siphash.c: in wc_SipHash(), use FALL_THROUGH macro, not /* fall-through */. 2022-06-30 17:07:35 -05:00
867a1f7afa Merge pull request #5289 from TakayukiMatsuo/tls13 2022-06-30 15:49:53 -06:00
e09bbb1989 Fix compilation warnings from IAR. 2022-06-30 14:30:06 -07:00
13beadbfc3 Fix missing return checks in KSDK ED25519 code. 2022-06-30 13:35:00 -07:00
2f1e236305 Improvements to --enable-cryptonly in configure.ac output. Improvement to math select order in configure.ac and stray heap math=yes. 2022-06-30 12:42:55 -07:00
ed1fdc410e Merge pull request #5303 from SparkiDev/match_dyn_type_fix_1
Fix mismatched dynamic types
2022-06-30 08:56:43 -07:00
26a62b4b9e drafted pathlen for cert struct 2022-06-30 17:16:10 +02:00
ba19737627 Add support for TLS1.3 2022-06-30 23:00:05 +09:00
e8e35c9a92 Merge pull request #5301 from SparkiDev/aes_gcm_word_ct
AES-GCM: make word implementation of GMULT constant time
2022-06-29 20:26:33 -07:00
1ba9ea9759 Fix mismatched dynamic types 2022-06-30 13:00:57 +10:00
9cc928cb29 Merge pull request #5299 from SparkiDev/sp_submod_fix
SP int math; submod fix
2022-06-29 18:52:15 -07:00
8b93d4510d AES-GCM: make word implementation of GMULT constant time
If performance is impacted then define: AES_GCM_GMULT_NCT
2022-06-30 09:29:04 +10:00
0159f17692 SP int math; submod fix
Fix for sp_submod() to reduce by modulus when a or b are equal to
modulus as well as when greater.
2022-06-30 08:53:25 +10:00
f2acaa8ee9 Merge pull request #5242 from SKlimaRA/SKlimaRA/strict-verification
zd14249
2022-06-30 08:19:42 +10:00
28d149a103 Merge pull request #5297 from ejohnstown/esp-build
ESP-IDF Build Cleanup
2022-06-29 14:03:02 -07:00
e941a729a7 Merge pull request #5290 from embhorn/gh5270
Add support for aligned data with clang llvm
2022-06-29 12:14:42 -05:00
2257030792 Merge pull request #5296 from dgarske/sniffer
Sniffer fixes (async TLS v1.3, async removal of `WC_HW_WAIT_E` and sanitize leak)
2022-06-29 09:16:54 -07:00
999d3b3ab7 Merge pull request #5298 from douzzer/20220628-multi-test-and-crossbuild-fixes
20220628-multi-test-and-crossbuild-fixes
2022-06-29 09:14:59 -07:00
5adf7e4eb7 wolfcrypt/src/asn.c wc_BuildEccKeyDer(): fix for clang-analyzer-deadcode.DeadStores. 2022-06-28 19:14:58 -05:00
90aaeb283e wolfcrypt/src/siphash.c: add missing !WOLFSSL_NO_ASM clause in gate around inline asm. 2022-06-28 18:19:58 -05:00
ce61653a9a wolfcrypt/src/asn.c: fixes for ARM portability (GetASN_Items()), unintended fallthrough (OidFromId()), and uninitialized variable (DecodeSubjInfoAcc()). 2022-06-28 18:18:42 -05:00
17659ed48c configure.ac: when --enable-fips=disabled, don't touch DEF_SP_MATH/DEF_FAST_MATH;
don't enable sp-math-all asm gates when !ENABLED_ASM;

add --with-arm-target to allow selecting thumb or cortex in conjunction with a full --host tuple (e.g. --host=armv6zk-softfloat-linux-gnueabi --with-arm-target=thumb).
2022-06-28 18:15:28 -05:00
d76c46a96f Fix for sniffer async issue with TLS v1.3. 2022-06-28 16:01:06 -07:00
f51c29d3ca Merge pull request #5293 from SparkiDev/asnt_setecc
ASN template: Handle HAVE_OID_ENCODING
2022-06-28 15:45:13 -07:00
e56394a2ab ESP-IDF Build Cleanup
1. Update the list of files to leave out of the build. They are ones
   that are included into ssl.c automatically.
2022-06-28 15:38:58 -07:00
092b37f709 Merge pull request #5287 from haydenroche5/aes_ctr_clear_left_on_iv_set
Clear the leftover byte count in Aes struct when setting IV.
2022-06-29 08:30:01 +10:00
28df62921a Merge pull request #5292 from dgarske/freertos_memtrack
Fix for using track memory feature with FreeRTOS.
2022-06-29 08:00:36 +10:00
e49f07694e Fix for sniffer possible malloc of zero size causing a -fsanitize=address leak report. 2022-06-28 12:54:25 -07:00
5ade360d9e Fix to avoid using WC_HW_WAIT_E for sniffer. ZD14398 2022-06-28 12:38:57 -07:00
b87b255d52 Merge pull request #5295 from rizlik/dtls13_bugfix
server: fix wrong minVersion setting when non in dtls
2022-06-28 09:35:23 -07:00
741393e84f Merge pull request #5291 from kaleb-himes/FRDM-K64-Fixes
Add necessary includes for cross-builds
2022-06-28 09:35:06 -07:00
14c65e0117 Merge pull request #5281 from miyazakh/example_japanese_translate 2022-06-28 10:08:06 -06:00
cb80ffc1b5 Merge pull request #5251 from kojo1/ja 2022-06-28 09:51:21 -06:00
d4d7e2e5f2 Merge pull request #5294 from SparkiDev/sp_math_all_no_128bit
SP math all: don't use sp_int_word when SQR_MUL_ASM available
2022-06-28 07:38:42 -07:00
060dfe1a69 server: fix wrong minVersion setting when non in dtls 2022-06-28 12:10:18 +02:00
22336d30e5 SP math all: don't use sp_int_word when SQR_MUL_ASM available
1. _WIN64 doesn't have 128-bit type but now can use 64-bit sp_int_digit
when assembly code snippets are being used.
2. Fix sp_div() to support values closer to maximum size.
3. Fix builds to work for more configurations.
4. Have ECC uncompressed code keep intermediate values in range of
maximum (x^3 calculation fixed).
5. Fix configuation.ac's check of FIPS for using signed SP Math All.
Default now not signed as intended.
2022-06-28 15:51:53 +10:00
3c3a90c988 ASN template: Handle HAVE_OID_ENCODING
When HAVE_OID_ENCODING is defined, the named curve OID is encoded rather
than the full OID.
Use SetCurve to get the OID encoding in ASN template implemenation.
2022-06-28 09:04:42 +10:00
31498de7a9 Fix for using track memory feature with FreeRTOS. 2022-06-27 14:08:45 -07:00
9d11e9092f Add necessary includes for cross-builds 2022-06-27 13:50:27 -06:00
94e7eacc5f Merge pull request #5072 from JacobBarthelmeh/Compatibility-Layer
add support for importing private only EC key to a WOLFSSL_EVP_PKEY s…
2022-06-27 12:34:00 -07:00
456e463640 Merge pull request #5283 from SparkiDev/sp_arm32_asm_rework
SP ASM ARM32: reworked generation using common asm ruby code
2022-06-27 09:17:20 -07:00
b84b808b1b Merge pull request #5167 from ejohnstown/cac-ext
Add support for some FPKI certificate cases, UUID, FASC-N, PIV extension
2022-06-27 09:06:15 -07:00
999fa8394e SP ASM ARM32: reworked generation using common asm ruby code
Add support for ARMv6 and ARMv3.
2022-06-27 11:19:50 +10:00
10dfd8d129 Clear the leftover byte count in Aes struct when setting IV.
Setting the key already does this. The same needs to be done when setting the
IV.
2022-06-26 15:56:05 +04:00
55414290df Merge pull request #5286 from douzzer/20220624-multi-test-fixes-sp-math-default
20220624-multi-test-fixes-sp-math-default
2022-06-24 19:26:49 -07:00
9211825121 sp_int.c: fix refactor of undefined-semantics shift in _sp_mul(). 2022-06-24 18:04:51 -05:00
790584113f configure.ac: WOLFSSL_WPAS[_SMALL] requires OPENSSL_EXTRA. 2022-06-24 16:38:56 -05:00
49740c5543 initialize variables 2022-06-24 15:21:20 -06:00
9a29dfc8cb fix whitespace. 2022-06-24 16:08:38 -05:00
047c662af8 fix math errors unmasked by change to sp-math-all as default math back end. 2022-06-24 15:56:54 -05:00
940d0140f9 configure.ac fixes related to change in default math back end (to sp-math-all): wolfRand doesn't use fastmath;
FIPS v5-dev follows the non-FIPS default (now sp-math-all);

add -DWC_NO_CACHE_RESISTANT to AM_CFLAGS when $ENABLED_HARDEN != yes;

add ENABLED_BIGNUM sensor and use it in linuxkm math back end assert;

add configuration callout for "Side-channel Hardening" reporting value of $ENABLED_HARDEN.
2022-06-24 15:55:08 -05:00
1977a13754 improve comment for FPKI additions 2022-06-24 12:04:26 -06:00
8dfcc76f50 Merge pull request #5279 from embhorn/gh5273
Fix config with WOLFSSL_WPAS_SMALL
2022-06-24 11:22:58 -06:00
5ef507c78d Merge pull request #5280 from douzzer/20220623-enable-dh-const
--enable-dh=const
2022-06-24 08:29:35 -07:00
ce977e8c0b requested review changes 2 2022-06-24 15:37:10 +02:00
00b82888bc Merge pull request #4759 from dgarske/sp_math_default
Enable wolfSSL SP Math all (sp_int.c) by default
2022-06-23 16:14:54 -07:00
c34c32f621 translated Japanese messages 2022-06-24 08:09:28 +09:00
43e11ec756 improve comments for subject name email matching 2022-06-23 15:52:28 -06:00
4de90efbe2 clear out PKEY when setting new key 2022-06-23 14:21:53 -07:00
a5250482ce examples/: refactor a couple help strings to avoid hitting clang-tidy bugprone-suspicious-missing-comma. 2022-06-23 15:25:23 -05:00
768737d21e configure.ac: support --enable-dh=const, and link with libm ("LT_LIB_M") only if ENABLED_DH = yes. 2022-06-23 15:00:59 -05:00
79ea30a957 memory free on failure, spelling, better function name 2022-06-23 13:40:45 -06:00
02dde373d1 Add support for aligned data with clang llvm 2022-06-23 13:26:11 -05:00
78d3284c3c Fix for FIPS 140-2 and older ACVP math selection. Fix for building with "--disable-sp-math-all --disable-fastmath". Fix for building SAKKE with HAVE_WOLF_BIGINT. 2022-06-23 11:10:44 -07:00
e2ad62b3d1 Merge pull request #5266 from rizlik/udp_help
examples: update usage() with DTLSv1.3 version
2022-06-23 09:27:53 -07:00
7fb17e0584 Fix build error with --enable-opensslextra=x509small --enable-debug 2022-06-23 11:26:57 -05:00
1cdc81546d Fix config with WOLFSSL_WPAS_SMALL 2022-06-23 09:19:14 -05:00
ee12c12e98 Fixes required to make SP Math default
fasthugemath means turn on fastmath
Use sp_int_digit and not sp_digit in sp_int.c.
test.c needs to use large static buffer when SP Math used like fastmath.
When building static memroy, SP math all without WOLFSSL_SP_NO_MALLOC is
a valid configuration.
Fix freeing of bigint in sp_int.c.
Cast x to a signed value to negate and then back to unsigned. (For
Windows builds.)
Remove warning about empty file on Windows about integer.obj.
Allow RSA verify only and RSA public only to be used with other public
key algorithms.
If building for FIPS, then older versions of RSA and ECC require SP Math
to support negative numbers.
Get old FIPS files building with SP int.
Disallow --enable-sp-math and --enable-sp-math-all.
When just --enable-sp-math on configuration line then disable SP Math
all.
2022-06-23 14:15:54 +10:00
8d804f6378 Merge pull request #5260 from dgarske/sp_ecc_nb_hash
Fix for SP math ECC non-blocking to always check `hashLen`
2022-06-23 07:59:28 +10:00
fdc4cdf5ec examples: update usage() with DTLSv1.3 version 2022-06-22 18:50:18 +02:00
acc9f3701a Merge pull request #5261 from dgarske/sha3_shake_flags
Configure fixes for SHA3 and SHAKE256
2022-06-22 11:50:28 +10:00
40dda7e80f fix XMALLOC in test and add filesystem macro guard 2022-06-21 17:24:14 -06:00
deb0c3e6fa Merge pull request #5272 from lealem47/skip
Display SKIP instead of PASS when tests skipped for make check
2022-06-21 16:06:58 -07:00
4db7732d78 Fixes for --enable-sha3 reproducibility with small. Fixes for shake256 typo and making sure WOLFSSL_NO_SHAKE256 gets set when disabled. Replaces PR #4225. 2022-06-21 16:02:42 -07:00
7d62fd09e4 remove subject/issuer email from altEmailNames list 2022-06-21 16:59:36 -06:00
74d692d6d5 Fix for SP math ECC non-blocking to always check hashLen. ZD14141 2022-06-21 15:54:01 -07:00
9e1ecf3fb5 Merge pull request #5194 from TakayukiMatsuo/heaphint 2022-06-21 16:39:07 -06:00
7dbf1a5154 Merge pull request #5262 from miyazakh/qt_unit_failure 2022-06-21 16:35:37 -06:00
bd536d3c9d Merge pull request #5229 from miyazakh/sce_example_update 2022-06-21 16:33:54 -06:00
40d9473e6a Display SKIP instead of PASS when tests skipped for make check 2022-06-21 13:11:08 -07:00
b8cff49044 Merge pull request #5268 from anhu/micrium_dtls_guard
Fix missing WOLFSSL_DTLS guard in Micrium build
2022-06-21 12:01:47 -07:00
099afe4419 errant if 2022-06-21 11:33:08 -04:00
beddc777d4 milliseconds not only for DTLS13 2022-06-21 11:07:19 -04:00
f05bcb30e0 div by 4 in milliseconds 2022-06-21 10:48:48 -04:00
ff4eabb17f same fix to MicriumReceive 2022-06-21 10:42:20 -04:00
1e84d1eb67 Change inspired by Rizlik review comments. 2022-06-21 10:22:44 -04:00
d41745cd28 Merge pull request #5269 from anhu/micrium_xstr
Fixup XSTR processing for MICRIUM
2022-06-20 16:23:06 -07:00
0b0518bd55 Fixup XSTR processing for MICRIUM 2022-06-20 17:00:24 -04:00
73435389ed Fix missing WOLFSSL_DTLS in Micrium build 2022-06-20 16:33:04 -04:00
38ac96aefb Merge pull request #5267 from douzzer/20220620-multi-test-fixes
20220620-multi-test-fixes
2022-06-20 12:13:39 -07:00
69ca1d37c0 fixes for defects identified by wolfssl-multi-test: whitespace, missing void in arg lists, and -Wunused-but-set-variable found by clang-15 (prerelease). 2022-06-20 10:54:55 -05:00
7c827d3a82 requested review changes 2022-06-20 11:27:09 +02:00
db6c14e7f9 Merge pull request #5265 from SparkiDev/dh_api_names
DH: Fix names wolSSL_* -> wolfSSL_*
2022-06-19 20:24:12 -07:00
fab05f2527 DH: Fix names wolSSL_* -> wolfSSL_* 2022-06-20 08:58:35 +10:00
59e19cfd6c Merge pull request #5258 from dgarske/stm32u5_bench
Fixes for STM32 Hash/PKA and additional benchmark
2022-06-20 08:33:25 +10:00
b5cac49be9 fix qt_unit_test_failure
add/remove spaces and line-feed to be the same as before
2022-06-18 10:04:10 +09:00
390908bccc Merge pull request #5236 from SparkiDev/mem_zero
Check memory is zeroized
2022-06-17 12:01:34 -07:00
92fcea39db Fix for DES3 with STM32 and STM32_CRYPTO_AES_ONLY (broken in #5223) . Add U5 PKA support and benchmarks. Fix MD5 with OPENSSL_EXTRA and HAVE_MD5_CUST_API. 2022-06-17 11:50:29 -07:00
9c5821569f For STM32 hashing to wait for hash done on block size + 1 word. Updated the STM32U5 benchmarks. Added note about new GCM_TABLE_4BIT. 2022-06-17 09:07:45 -07:00
2f6b5a97a4 Merge pull request #5257 from SparkiDev/i2d_RSA_fix
i2d AIPs move pointer on when a pointer to a buffer is passed in
2022-06-16 21:44:23 -07:00
6a0682d422 i2d AIPs move pointer on when a pointer to a buffer is passed in
Restore behaviour to be compatible with OpenSSL.
Replace comparison of DER data using AsserStrEQ to use memcmp.
2022-06-17 12:36:06 +10:00
66775d90d4 Merge pull request #5250 from dgarske/rsa_public
Fix to expose the RSA public DER export functions with certgen
2022-06-17 12:25:19 +10:00
4fc709d2af Merge pull request #5256 from dgarske/cert_chain_der
Fixes for loading a DER/ASN.1 certificate chain
2022-06-17 11:55:49 +10:00
6795e1bf21 Attempt to fix issue with duplicate prototype wc_RsaKeyToPublicDer with FIPS v2 selftest. 2022-06-16 16:51:51 -07:00
e34dda9383 Fix to expose the RSA public DER export function with certgen. The core function SetRsaPublicKey was being compiled, but the wrappers wc_RsaKeyToPublicDer and wc_RsaKeyToPublicDer_ex were not included. 2022-06-16 16:36:17 -07:00
128ebf54e9 Fix for loading certificate DER chain longer than 2 deep. Fix to properly trap BUFFER_E in ProcessUserChain. ZD14048. 2022-06-16 16:19:37 -07:00
fe8169c830 Add multi thread use case for RA6M4
fix devId conflict while using multi threads

update README

Fix TSIP examples bcause of updating user context
2022-06-17 07:44:12 +09:00
2834c22ce0 Merge pull request #5204 from lealem47/basicConst
Encoding the X509 Basic Constraint when CA:FALSE
2022-06-17 08:33:57 +10:00
f2abf1892c Merge pull request #5255 from lealem47/i2d_RSA
Call RSA_To_Der instead of RSA_To_Der_ex in i2dd_RSA key funcs
2022-06-16 14:43:58 -07:00
1322c1a0b2 Merge pull request #5248 from lealem47/no_aes
Fix build failure caused by missing NO_AES macro guard
2022-06-16 13:18:09 -07:00
911f361285 Call RSA_To_Der instead of RSA_To_Der_ex in i2d_RSA key funcs 2022-06-16 12:26:47 -07:00
8c0157c035 Merge pull request #5253 from rizlik/clang_uninit
kdf: fix clang uninitialized.Assign
2022-06-16 11:06:43 -07:00
8f7db87f01 Merge pull request #5249 from dgarske/rsa_ifc
Cleanup the RSA consistency check
2022-06-16 09:14:08 -07:00
5e63740c6c Ensuring that X509 Basic Constraint is set when CA:FALSE 2022-06-16 08:46:52 -07:00
7560199f18 Merge pull request #5254 from rizlik/nigthly_fixes
dtls: abide deadstore static analyzer warnings
2022-06-16 07:42:38 -07:00
8f0da12824 Merge pull request #5252 from SparkiDev/mod_zero
TFM: mp_exptmod_ex didn't handle exceptional cases
2022-06-16 07:42:17 -07:00
6a0c6049ce dtls: abide deadstore static analyzer warnings 2022-06-16 14:02:09 +02:00
621f4f14af kdf: fix clang uninitialized.Assign
commit f1ce0cc95d tigger static analyzer warnings
about unitialized assign.
2022-06-16 13:55:46 +02:00
6d2a41b9fd Enable wolfSSL SP Math all (sp_int.c) by default. If --enable-fastmath or USE_FAST_MATH is set the older tfm.c fast math will be used. To use the old integer.c heap math use --enable-heapmath or USE_INTEGER_HEAP_MATH. 2022-06-16 10:57:30 +10:00
8145ee6cef TFM: mp_exptmod_ex didn't handle exceptional cases
fp_exptmod_ex() changed to match execptional case handling in
fp_exptmod().
2022-06-16 10:47:00 +10:00
1b29f7353a Check memory is zeroized
Add a define WOLFSSL_CHECK_MEM_ZERO to turn on code that checks that
memory that must be zeroized before going out of use is zero.
Everytime sensitive data is put into a allocated buffer or stack buffer;
the address, its length and a name is stored to be checked later.
Where the stack buffer is about to go out of use, a call is added to
check that the required parts are zero.

wc_MemZero_Add() adds an address with length and name to a table of
addressed to be checked later.
wc_MemZero_Check() checks that the memory associated with the address is
zeroized where required.
mp_memzero_add() adds mp_int's data pointer with length and name to
table.
mp_memzero_check() checks that the data pointer is zeroized where
required.

Freeing memory will check the address. The length was prepended on
allocation.
Realloction was changed for WOLFSSL_CHECK_MEM_ZERO to perform an
allocate, check, copy, free.
2022-06-16 10:22:32 +10:00
8f68e32ef1 initial tranlation of API headers in JA 2022-06-16 08:24:18 +09:00
7e1549c684 Cleanup the RSA consistency check. Should only be enabled for FIPS v2 (3389), FIPS v5 or later. Can be forcefully enabled for non-FIPS using WOLFSSL_RSA_KEY_CHECK. The existing WOLFSSL_NO_RSA_KEY_CHECK macro will also disable it. This change was introduced in PR #4359. 2022-06-15 14:46:23 -07:00
fb704774a0 Merge pull request #4907 from rizlik/dtls13
DTLSv1.3 support
2022-06-15 13:57:02 -07:00
9bcbd645d6 Fix build failure caused by missing NO_AES macro guard 2022-06-15 13:30:56 -07:00
dab0d5a7b0 Merge pull request #5240 from SparkiDev/sp_armv6
SP ARM32: support for arch with no ldrd/strd and clz
2022-06-15 11:28:30 -07:00
d9d8b7e2d8 Merge pull request #5245 from SparkiDev/force_zero
Memory zeroization fixes
2022-06-15 11:16:04 -07:00
aa8df1af78 Fixes for building without DTLS v1.2 and TLS v1.2. Fixes for explicit cast warnings. 2022-06-15 10:49:18 -07:00
3a9176bcc9 scripts: test for dtls13 retransmission
Co-authored-by: Juliusz Sosinowicz <juliusz@wolfssl.com>
2022-06-15 10:46:43 -07:00
25cf98a417 test: add DTLSv1.3 test suites 2022-06-15 10:46:43 -07:00
12a3efeca8 client/server: tolerate WANT_WRITE errors 2022-06-15 10:46:43 -07:00
4e112419f5 examples: client/server: support DTLSv1.3 (-u -v4)
This commits add some new options to examples/[server,client] to support testing
of DTLS v1.3.

client: add waitTicket option

If this option is used, the client will wait until it receives a sessionTicket
from the server. This is useful when testing DTLS retransmission.

client: add waitKeyUpdate option

When this option is set, the client waits until the UpdateKey message is
acknowledged by the server. This is useful to test DTLS retransmission logic
2022-06-15 10:46:43 -07:00
c1dc90d9b0 server: request cert only once if doing post-handshake auth 2022-06-15 10:46:43 -07:00
ca05ad2dc0 dtls13: introduce wolfSSL_dtls_13_has_pending_msg() API 2022-06-15 10:46:43 -07:00
e2abdf23a7 internal: return from wolfSSL_Peek() with sz 0 if we don't have data
This way we can use wolfSSL_Peek() invoked with sz == 0 to process pending
records and, if none of this records is an application data record, we will not
block.
2022-06-15 10:46:43 -07:00
dfc9873c0f dtls13: support KeyUpdate messages 2022-06-15 10:46:43 -07:00
d1924928c0 dtls13: support retransmission
Introduce ACK and retransmission logic, encapsulated in a Dtls13RtxFsm
object. The retransmission or the sending of an ACK is scheduled by setting the
appropriate flag inside the Dtls13RtxFSM object but the actual writing on the
socket is deferred and done in wolfSSL_Accept/Connect.

* Retransmission

Each sent message is encapsulated in a Dtl13RtxRecord and saved on a list. If we
receive an ACK for at record, we remove it from the list so it will be not
retransmitted further, then we will retransmit the remaining
ones. Retransmission is throttled: beside link congestion, this also avoid too
many sequence numbers bounded with a record.

* ACK

For each received record we save the record sequence number, so we can send an
ACK if needed. We send an ACK either if explicitly needed by the flight or if we
detect a disruption.

Co-authored-by: Juliusz Sosinowicz <juliusz@wolfssl.com>
2022-06-15 10:46:43 -07:00
d079662765 dtls13: support fragmentation, sending and receiving
This commit implements the core of the header parsing, building, and the sending
and receiving routines that handle fragmentation and defragmentation.

* In DTLSv1.3 the header used for protected messages is a variable-length header,
and it is described RFC9147 Section 4.

* Fragmentation happens after building the full message, if necessary. If the
underlying I/O can't send a fragment because of a WANT_WRITE error, the sending
of fragments will continue in the next invocation of
wolfSSL_connect/wolfSSL_accept/wolfSSL_write. In this case the message is saved
in a buffer inside the WolfSSL object.

* Defragmentation works like DTLSv1.2 defragmentation, and re-use
most of the same code.

* The Dtls13AddHeaders() function does not add the record layer header, but it
lefts space for it. It is eventually placed by BuildTls13Message() to allow
easier management of sequence numbers.
2022-06-15 10:46:43 -07:00
173077b142 dtls: refactor DtlsUpdateWindow() window
split the DtlsUpdateWindow() function, so part of the code can be reused by
DTLSv1.3 code.
2022-06-15 10:46:43 -07:00
30fb664163 internal.c: add runProcessingOneRecord section
DTLSv1.3 needs to do some operation per-record, this commit adds an appropriate
section to ProcessReplyEx.
2022-06-15 10:46:43 -07:00
2696c3cdd3 dtls13: change encryption keys dynamically based on the epoch
In DTLSv1.3, because of retransmission and reordering, we may need to encrypt or
decrypt records with older keys. As an example, if the server finished message
is lost, the server will need to retransmit that message using handshake traffic
keys, even if he already used the traffic0 ones (as, for example, to send
NewSessionTicket just after the finished message).

This commit implements a way to save the key bound to a DTLS epoch and setting
the right key/epoch when needed.
2022-06-15 10:46:43 -07:00
de04973051 dtls13: record number encryption and decryption 2022-06-15 10:46:43 -07:00
60834ba516 dtls13: new methods and version negotiation 2022-06-15 10:46:42 -07:00
9d22e11776 misc.c: introduce w64wrapper to handle 64bit numbers
as word64 is not always available, introduce an abstract type and companion
operations. They use a word64 if available and fallback on word32[2] otherwise.
2022-06-15 10:46:42 -07:00
7586851734 dtls13: export functions
They will be used by DTLSv1.3 code
2022-06-15 10:46:42 -07:00
d8ac35579c dtls13: add autotools, cmake build options and vstudio paths 2022-06-15 10:46:42 -07:00
d51ba35ff9 Merge pull request #5246 from rizlik/dtls_header_fixes
dtls: handshake header parsing fixes
2022-06-15 09:33:41 -07:00
6630a83182 dtls: handshake header parsing fixes 2022-06-15 12:00:26 +02:00
e073500e8e SP ARM32 ASM: Improve performance of P-256 mont mul/sqr 2022-06-15 16:39:13 +10:00
af4fff80db SP ARM32: support for arch with no ldrd/strd and clz
Defined WOLFSSL_SP_ARM_ARCH to be less than 7 to use alternative
instructions.
2022-06-15 12:07:49 +10:00
f1ce0cc95d Memory zeroization fixes
Zeroize secrets in stack buffers and allocated memory.
mp_forcezero to ensure private MP integers are zeroized.
Fix whitespace and add some comments.
2022-06-15 11:26:11 +10:00
9656963f61 Merge pull request #5231 from dgarske/glitch_harden
Added sanity check on TLS encrypt to trap against glitching
2022-06-15 09:48:18 +10:00
ed5470c991 Merge pull request #5239 from dgarske/asn_decode_ext
Fix for ASN template parsing of extended key usage
2022-06-15 09:29:44 +10:00
0cac6cef39 Merge pull request #5237 from anhu/bench_psk
Support psk ciphersuites in benchmarks.
2022-06-14 16:12:15 -07:00
ed6c9639d6 Merge pull request #5243 from douzzer/20220614-multi-test-fixups
20220614-multi-test-fixups
2022-06-14 16:11:44 -07:00
f414e65d4b linuxkm: eliminate duplicative WOLFSSL_KTHREADS macro (just use WOLFSSL_LINUXKM). 2022-06-14 12:45:30 -05:00
2f4864cab2 Added sanity check on TLS encrypt to trap against glitching. 2022-06-14 09:37:44 -07:00
7a25b9cd85 Merge pull request #5241 from SparkiDev/wycheproof_sp_arm64_asm
SP ASM: fixes for Wycheproof tests
2022-06-14 09:08:15 -07:00
22eee3206d Fixups from review by dgarske 2022-06-14 11:13:28 -04:00
a22da10956 linuxkm: tweak setup of wolfSSL_Mutex to assure complete type availability in applications (client modules). 2022-06-14 09:45:33 -05:00
5a8c130040 fix whitespace 2022-06-14 09:43:05 -05:00
a0dd92234b draft 2022-06-14 13:37:49 +02:00
fb10c90935 Fix for Cube HAL v2 back-to-back DES/DES3. Whitespace. Enable the new FIFO 16 block logic for all hardware that supports it. 2022-06-14 11:48:51 +02:00
c52c2e5dfb Fixes for STM32H7 hash and crypto. 2022-06-14 11:48:51 +02:00
ad3f7e1de2 The STM32U5 does not support DES3 or AES 192-bit (only 128/256 bit) 2022-06-14 11:48:51 +02:00
502cbc3847 Fix for STM32U5 hash/crypto support. ZD 14305. 2022-06-14 11:48:51 +02:00
013066ca06 SP ASM: fixes for Wycheproof tests
ARM64 ASM: Fix P256 Montogomery Reduce.
Fix div to handle large dividend word.
2022-06-14 16:11:46 +10:00
c0f49b57e1 Fix for ASN template parsing of DecodeExtKeyUsage. ZD 14344. 2022-06-13 16:50:20 -07:00
af3a55a94c Merge pull request #5220 from kaleb-himes/ZD14318
Resolves inter-library API conflict reported in ZD14318
2022-06-13 14:28:13 -07:00
f401a3b53d Merge pull request #5232 from cconlon/june10
test/benchmark.c: rename Android tag, reset vars in memcb_test()
2022-06-13 14:24:17 -07:00
4d4ee3b2db Support psk ciphersuites in benchmarks.
Also fixed some small errors during shutdown in benchmarks.

Tested with:

./configure --enable-psk CFLAGS=-DWOLFSSL_STATIC_PSK
make all check
./examples/benchmark/tls_bench
2022-06-13 13:33:51 -04:00
364bf482eb adjust wolfCrypt test/benchmark Android log TAG name, reset malloc/free counts in memcb_test() 2022-06-13 09:42:02 -06:00
0b78961111 Merge pull request #5186 from SparkiDev/pk_c_rework_1
pk.c: rework
2022-06-13 08:35:09 -07:00
5018da7f9f Merge pull request #5234 from gojimmypi/PR_Espressif_Version_README
Add note regarding ESP-IDF Version
2022-06-13 08:34:25 -07:00
9ee1833bd2 Merge pull request #5235 from SparkiDev/sess_sec_cb_fixup
Improve SessionSecret_callback code.
2022-06-13 08:21:45 -07:00
1de54ed8d7 Improve SessionSecret_callback code. 2022-06-13 10:43:09 +10:00
8899112456 Merge pull request #5230 from dgarske/tls_bench
Fix for TLS v1.1 length sanity check for large messages
2022-06-13 09:38:03 +10:00
f35eb20954 Add note regarding ESP-IDF Version 2022-06-12 12:39:04 -07:00
d5791d5c74 Fixes for TLS benchmarking app (tls_bench) for shutdown and formatting brace cleanups. 2022-06-10 13:48:46 -07:00
cafe5646b6 Fix for TLS v1.1 length sanity check for large messages. 2022-06-10 13:35:06 -07:00
afc63a3bfa Merge pull request #5199 from embhorn/zd12999
Add doc for wolfSSL_dtls_retransmit
2022-06-10 10:57:17 -07:00
d600a4b887 Spelling and Whitespace cleanups. Fix issue with trying to build pk.c directly and always getting warn even with WOLFSSL_IGNORE_FILE_WARN. 2022-06-10 09:06:55 -07:00
ba3991af5e Merge pull request #5228 from haydenroche5/strongswan
Add an --enable-strongswan option to configure.ac.
2022-06-10 08:19:32 -07:00
49008b169c Merge pull request #5087 from haydenroche5/x509_print
Add support for more extensions to wolfSSL_X509_print_ex.
2022-06-10 08:19:23 -07:00
c59ec54713 initialize variable to fix warning 2022-06-10 06:22:54 -06:00
ba20f54b5b add UPN other name parsing and updating skip 2022-06-09 21:32:55 -06:00
890abfbefc pk.c: rework
Re-order RSA functions.
Add comments to RSA functions.
Rework RSA function implementations.
2022-06-10 09:54:32 +10:00
df673b987e Merge pull request #5227 from LinuxJedi/embOS-emNET
Support for SEGGER embOS and emNET
2022-06-09 08:04:29 -07:00
9954afa538 Merge pull request #5222 from tmael/rsa_sanity
Add a sanity check in RsaPad_OAEP
2022-06-09 08:04:16 -07:00
f479600066 Add support for more extensions to wolfSSL_X509_print_ex.
- Key usage
- Extended key usage
- Subject alt name

Additionally, print out the criticality of the extensions.
2022-06-09 16:50:10 +02:00
df87eb5508 Add an --enable-strongswan option to configure.ac.
Also, clean up some repetition around adding `-DHAVE_OCSP`.
2022-06-09 16:24:41 +02:00
190476dafe Support for SEGGER embOS and emNET
Adds support for embOS memory and mutex functions. Also adds support for
emNET's error codes, it uses a BSD compatible TCP/IP stack for network
functions.

There is no easy native way to detect that you are compiling with emNET
or embOS so these require the user to define WOLFSSL_EMBOS /
WOLFSSL_EMNET.
2022-06-09 11:34:55 +01:00
2748bfc737 Add a check in RsaPad_OAEP 2022-06-08 10:07:26 -07:00
9fb1143eba Merge pull request #5218 from gojimmypi/PR_zepher_legacy_link
add link to new location for old zephyr references
2022-06-07 16:40:14 -07:00
37ee5e2540 Resolves inter-library API conflict reported in ZD14318 2022-06-07 14:48:27 -06:00
85e18b2f06 Merge pull request #5219 from douzzer/20220607-strlcpy
use XSTRLCPY() and XSTRLCAT() in EncryptDerKey()
2022-06-07 09:34:40 -07:00
088d378ba4 ssl.c:EncryptDerKey(): use XSTRLCPY() and XSTRLCAT() to build up cipherInfo, and remove XSTRCPY() macro from wolfssl/wolfcrypt/types.h (clang-tidy hates on it, albeit frivolously). 2022-06-07 08:22:48 -05:00
047ed8ef61 minor change for commit author update 2022-06-06 16:47:40 -07:00
fbb6faaa2f Merge pull request #5191 from SparkiDev/sp_win_asm_xmm_nv
SP Winx64 ASM: XMM6-15 are non-volatile
2022-06-06 15:58:10 -07:00
3c634e1f59 Merge pull request #5217 from SparkiDev/pk_enc_mem_2
ECC, DH: improve encrypted memory implementations
2022-06-06 15:27:10 -07:00
711a900ff7 Merge pull request #5214 from lealem47/ghostFunc
Removing ghosts and updating defines in openssl/buffer.h
2022-06-06 17:05:33 -05:00
4ffa63c938 Merge pull request #5216 from kojo1/static-mem
wc_MakeRsKey  with Static memory pool
2022-06-06 14:42:32 -07:00
86023378f8 free decoded cert in test case and x509 2022-06-06 14:31:41 -07:00
8e69b1fa0e add include.am 2022-06-06 13:10:37 -07:00
07e0a6fa8e Removing ghost functions and fixing overflow warning in ssl.c 2022-06-06 11:33:26 -07:00
86312be79e Merge pull request #5210 from kaleb-himes/new-azsphere-rev3
New azsphere example for CI testing
2022-06-06 10:00:43 -07:00
2cd9ca0c8f add support for asn template build 2022-06-06 09:42:03 -07:00
927ee21752 add link to new location for old references 2022-06-06 08:39:40 -07:00
0bcd38f7d8 ECC, DH: improve encrypted memory implementations 2022-06-06 08:40:09 +10:00
7bfe6aa127 Extend HEAP_HINT to all InitRsaKey in api.c 2022-06-05 09:12:49 +09:00
eb28d38fa8 Merge pull request #5212 from kaleb-himes/various-warnings
Fix various warnings and an uninitialized XFILE
2022-06-04 17:10:17 -07:00
1b9f922ec3 wc_MakeRsKey with static mem pool 2022-06-05 09:04:42 +09:00
dbfa207344 Merge pull request #5116 from embhorn/zd14172
Fix TSIP build with NO_AES_CBC
2022-06-04 17:51:16 +09:00
802e3127c0 Merge pull request #5145 from JacobBarthelmeh/caam
CAAM support with QNX i.MX8, add AES-CTR crypto callback
2022-06-03 15:24:10 -07:00
873b2169f9 Add readme to include.am 2022-06-03 13:33:12 -06:00
2af09a7151 Merge pull request #5205 from haydenroche5/evp_cipher_aes_gcm
Fix another AES-GCM EVP control command issue.
2022-06-03 11:47:57 -07:00
30d836dc90 Implement peer review feedback 2022-06-03 11:34:02 -06:00
96d5814bfe Implement peer review feedback 2022-06-03 11:06:46 -06:00
debb598499 Merge pull request #5008 from tmael/vx_6x
Add support for VxWorks 6.x
2022-06-03 09:40:39 -07:00
1bb2a35164 Merge pull request #5207 from anhu/longer_sigalg_list
For inter-op with OQS's OpenSSL fork, support longer sigalg list.
2022-06-03 09:24:38 -07:00
fdaf418fe0 fix spelling and remove dead else statement 2022-06-03 09:21:27 -07:00
3bcdef1972 Fix various warnings and an uninitialized XFILE 2022-06-03 09:52:53 -06:00
8fbd4d70e6 Merge pull request #5209 from TakayukiMatsuo/fix14172 2022-06-03 09:07:01 -06:00
e30ae359a4 Fix build err missing XSTRNCASECMP 2022-06-03 08:17:39 -06:00
55f3b7c277 New azsphere example for CI testing 2022-06-03 08:04:50 -06:00
42754ce98b Exclude calling some funcs when WOLFSSL_AEAD_ONLY is defined 2022-06-03 14:47:41 +09:00
64eaf74e83 Merge pull request #5206 from dgarske/user_settings
Fixes for user settings with SP ASM and ED/Curve25519 small
2022-06-03 09:25:17 +10:00
ee78e63b87 Merge pull request #5203 from dgarske/zd14289
Fix the supported version extension to always check minDowngrade
2022-06-03 08:31:36 +10:00
8307a55429 Fixes --enable-usersettings with SP ASM and ED/Curve25519 small CURVED25519_SMALL. 2022-06-02 14:17:25 -07:00
a6465c2bd0 Merge pull request #5202 from julek-wolfssl/wolfssl-multi-test/send-alert-refactor
wolfssl-multi-test fixes
2022-06-02 14:08:46 -07:00
0cda12d446 For inter-op with OQS's OpenSSL fork, support longer sigalg list. 2022-06-02 16:52:35 -04:00
fb3c611275 Fix another AES-GCM EVP control command issue.
With PR 5170, I added logic that requires a EVP_CTRL_GCM_SET_IV_FIXED command be
issued before a EVP_CTRL_GCM_IV_GEN command. This matches OpenSSL's behavior.
However, OpenSSL also clears the flag enabling EVP_CTRL_GCM_IV_GEN after
EVP_CTRL_GCM_SET_IV_FIXED if EVP_CipherInit is called with a NULL key.
Otherwise, the flag retains its value. We didn't mirror this logic, and that
caused problems in OpenSSH unit testing. This commit aligns our logic with
OpenSSL's and adds a regression test to test_evp_cipher_aes_gcm for this case.
2022-06-02 12:32:59 -07:00
2dd27c8d4a Fix the supported version extension to check the ssl->options.minDowngrade always. 2022-06-02 11:17:25 -07:00
cd008aac6a Add support for VxWorks 6.x
Use rand_r and define SEM_ID_NULL
Fix redefinition of typedef 'SOCKADDR'
2022-06-02 09:54:27 -07:00
56c48b31ad Merge pull request #5105 from tmael/rsa_oaep_nomalloc
Support RSA OAEP with nomalloc
2022-06-02 08:45:01 -07:00
2e307e1cd3 tls13.c: fix null pointer deref in FreeDcv13Args(). 2022-06-02 10:32:05 -05:00
3d71956b48 wolfssl-multi-test fixes:
- Remove RetrySendAlert and SendAlert recursion
- args possible NULL dereference
2022-06-02 16:08:25 +02:00
fb9f90b98b Merge pull request #5200 from dgarske/qat_fsanitize
Fixes for buffers when testing with Intel QAT hardware
2022-06-02 08:35:24 +10:00
9f2e3a2405 Merge pull request #5198 from dgarske/qat_ecc_marker 2022-06-01 21:35:47 +02:00
5672e2a885 Fixes for buffers when testing with Intel QAT hardware and fsanitize=address:
* PKCS7 should use allocated buffer for RSA.
* PKCS7 small stack typo for `keyAlgArray` size in `wc_PKCS7_AddRecipient_KTRI`.
* Fix for use of `free`, which should be `XFREE` in api.c.
* Cleanup old RSA benchmarking MDK5/WINCE code no longer needed with `WC_DECLARE_ARRAY_DYNAMIC_DEC` and `WC_DECLARE_ARRAY_DYNAMIC_EXE`.
2022-06-01 12:07:57 -07:00
8b9d2ad657 Merge pull request #5196 from douzzer/20220601-multi-test-fixes 2022-06-01 11:41:26 -07:00
9cfcdfc7aa Merge pull request #5149 from julek-wolfssl/store-frags-v2
Re-use async to support WANT_WRITE while sending fragments
2022-06-01 10:52:54 -07:00
2543970419 Add doc for wolfSSL_dtls_retransmit 2022-06-01 12:03:36 -05:00
cced5bd700 Merge pull request #5195 from LinuxJedi/ULL-fix
Fix 64bit postfix for constants
2022-06-01 09:40:26 -07:00
19c51dac45 Fix for QAT ECC to gate use of HW based on marker. Introduced in PR #4997. 2022-06-01 09:36:21 -07:00
494a9fe41a Merge pull request #5193 from SparkiDev/tls13_send_ticket
TLS 1.3: send ticket
2022-06-01 08:37:52 -07:00
b212853bce evp.c: in EvpCipherAesGCM(), make sure ctx->gcmAuthIn is non-null before clearing it; fix whitespace. 2022-06-01 10:29:40 -05:00
d29c656d4f SendAlert: clear output buffer to try and send the alert now 2022-06-01 16:48:57 +02:00
11a7756527 Fix 64bit postfix for constants
GCC 4.0.4 PowerPC 32bit cross-compiler complains when `UL` is used
instead of `ULL` for 64bit constants.
2022-06-01 15:04:29 +01:00
df10e1fad2 Store RetrySendAlert error in ssl->error 2022-06-01 14:59:10 +02:00
13135e72db Add a global variable for heap-hint, mainly in case heap info cannot be referenced by TSIP 2022-06-01 10:24:03 +09:00
be743b2204 TLS 1.3: send ticket
Can send a new session ticket any time after handshake is complete with
TLS v1.3.
Added API for server application to do this.
Added tests.
2022-06-01 10:36:01 +10:00
3944a8737a WIN64: compiling with __clang__ _udiv128 not defined 2022-06-01 08:54:57 +10:00
dd0b9fb871 SP Winx64 ASM: XMM6-15 are non-volatile
Put the used non-volatile XMM registers on the stack at the start and
get them off again at the end.
2022-06-01 08:46:27 +10:00
81cd1e652e Merge pull request #5170 from haydenroche5/evp_cipher_aes_gcm
Fix EVP_CTRL_GCM_IV_GEN with AES-GCM.
2022-06-01 08:20:33 +10:00
c74315f1ef Save pending alerts when using async io
- Don't overwrite ssl->error
- Clear the error in ssl->error because the return of SendBuffered is now stored in ret instead
2022-05-31 18:17:11 +02:00
0554b02215 Merge pull request #5177 from JacobBarthelmeh/PKCS7 2022-05-31 09:46:14 -06:00
da91578bc7 Merge pull request #5180 from miyazakh/tsipv_up 2022-05-31 09:41:47 -06:00
2ed85926d5 Merge pull request #5187 from kareem-wolfssl/hsHashesNull
Confirm ssl->hsHashes is not NULL before attempting to dereference it.
2022-05-30 10:41:35 -07:00
8aa2da532c Combine preproc check into one statement 2022-05-30 15:27:36 +02:00
c83120d8c8 Merge pull request #5097 from tmael/c89_fixes
Fix for c89, use WOLF_C89
2022-05-28 08:29:42 -05:00
baaff96045 Merge pull request #5188 from kaleb-himes/PR5174-SUPPLEMENT
Supplement to @julek-wolfssl's fantastic find, just allow for proper expansion
2022-05-27 20:36:20 -07:00
6245395f34 Simulate WANT_WRITE only with async I/O support 2022-05-27 23:23:18 +02:00
a91a2482e7 Merge pull request #5158 from anhu/ECDHE_PSK
Add TLS 1.2 ciphersuite ECDHE_PSK_WITH_AES_128_GCM_SHA256 from RFC 8442
2022-05-27 13:25:48 -07:00
e061bc23f4 Fix asn1.h NOLINT comments. 2022-05-27 13:05:56 -07:00
f5bbad185f Supplement to @julek-wolfssl's fantastic find, just allow for proper expansion 2022-05-27 13:52:26 -06:00
8cb4819b53 Fix curve group matching on secure renegotiation 2022-05-27 21:26:55 +02:00
84bca63b2e Add WOLFSSL_NO_ASYNC_IO to low resource build 2022-05-27 21:26:55 +02:00
50c0b3d2a2 Add testing/docs for blocking write
- Fix case where message grouping can make CheckAvailableSize return a WANT_WRITE
- CheckAvailableSize in tls13.c will not return a WANT_WRITE since it only does so for DTLS <=1.2
2022-05-27 21:26:55 +02:00
decf9972bb fix whitespace. 2022-05-27 14:22:22 -05:00
8c10c3776d wolfcrypt/src/asn.c: in C89 codepath of GetFormattedTime(), add buffer size checks before calls to sprintf(). 2022-05-27 14:20:38 -05:00
aca199cb05 Fix to compile with c89
strncasecmp and snprintf are unavailable in C89
use // static analyzer suppressions
2022-05-27 14:20:37 -05:00
6e6c4500d6 Fix comments in asn1.h to use ANSI C style. 2022-05-27 11:01:29 -07:00
98ec442b37 Confirm ssl->hsHashes is not NULL before attempting to dereference it. 2022-05-27 10:57:23 -07:00
df06db114d Add TLS 1.2 ciphersuite ECDHE_PSK_WITH_AES_128_GCM_SHA256 from RFC 8442
Testing:

./autogen.sh
./configure --enable-psk
make all check

$ ./examples/server/server  -j -l ECDHE-PSK-AES128-GCM-SHA256
SSL version is TLSv1.2
SSL cipher suite is TLS_ECDHE_PSK_WITH_AES_128_GCM_SHA256
SSL curve name is SECP256R1
Client message: hello wolfssl!

$ ./examples/client/client  -s -l ECDHE-PSK-AES128-GCM-SHA256
SSL version is TLSv1.2
SSL cipher suite is TLS_ECDHE_PSK_WITH_AES_128_GCM_SHA256
SSL curve name is SECP256R1
I hear you fa shizzle!
2022-05-27 11:05:55 -04:00
81ad463026 fix a compile error by clang 2022-05-27 11:37:26 +09:00
4e8c362152 Allocate ssl->async seperately to the SSL object 2022-05-26 23:08:48 +02:00
733fe1a8d3 Use WOLFSSL_ASYNC_IO for WOLFSSL_NONBLOCK_OCSP
- Enable ssl->async to store function arguments for non-blocking OCSP
- Remove ssl->nonblockarg
2022-05-26 23:08:48 +02:00
c151dcec50 Re-use async to support WANT_WRITE while sending fragments
- Async I/O can be turned off with WOLFSSL_NO_ASYNC_IO
- WOLFSSL_ASYNC_IO functionality enabled in SendCertificateVerify() and SendServerKeyExchange() to allow safe re-entry into SendHandshakeMsg()
- Testing size of structs is refactored int WOLFSSL_ASSERT_SIZEOF_GE()
2022-05-26 23:08:48 +02:00
f93b23b524 Merge pull request #5169 from kareem-wolfssl/miscFixes
Misc. fixes
2022-05-26 12:52:39 -07:00
0b6f7c1533 Merge pull request #5176 from embhorn/zd14227
Fix to move wolfSSL_ERR_clear_error outside gate for OPENSSL_EXTRA
2022-05-26 08:33:52 -07:00
ea895e99b7 Merge pull request #5184 from SparkiDev/asn_templ_make_cert_ext
ASN template: properly handle WOLFSSL_CERT_EXT
2022-05-26 06:53:10 -07:00
2800d00bb4 Fix to move wolfSSL_ERR_clear_error outside gate for OPENSSL_EXTRA 2022-05-26 06:11:45 -05:00
cacf5aeb7e ASN template: properly handle WOLFSSL_CERT_EXT
Encoding extensions didn't properly handle WOLFSSL_CERT_EXT not being
defined.
2022-05-26 10:01:59 +10:00
a5fa98e5f0 addressed code review
update Copyright year
2022-05-26 08:50:02 +09:00
ad49aea17d fix for setting AES-CCM decrypt nonce with crypto callback 2022-05-25 13:59:56 -07:00
fa80aa6505 Merge pull request #5132 from JacobBarthelmeh/req
Add support for additional CSR attributes
2022-05-25 13:35:46 -07:00
e8d779ab78 Merge pull request #5077 from gojimmypi/ESP8266_Development
Add ESP-IDF WOLFSSL_ESP8266 setting for ESP8266 devices
2022-05-25 12:46:10 -07:00
17d7098bf6 Merge pull request #5168 from rizlik/dtls_resume
internal.c: dtls:  HelloVerifyRequest on resumption
2022-05-25 11:23:08 -07:00
2d8cc055f0 Merge pull request #5179 from SparkiDev/sp_armv6_fix_1
SP ARM32 ASM: moving large immediate value
2022-05-25 09:59:47 -07:00
da1cbfda46 Merge pull request #5178 from cconlon/nounaligned
Add define to skip SHA-512 unaligned memory test in test.c
2022-05-25 09:55:29 -07:00
3cf636163b Fix EVP_CTRL_GCM_IV_GEN with AES-GCM.
Discovered the AES-GCM flow using this command didn't work in our OpenSSH port.
This commit makes the behavior match OpenSSL and adds testing using known
OpenSSL-generated test vectors to prevent regressions. This was one of those
problems where two ends of a connection would work fine if they were both using
wolfSSL but not if one was using OpenSSL (i.e. OpenSSH interop with AES-GCM
was broken).
2022-05-25 07:00:15 -07:00
c3e4c6b6bc Merge pull request #5174 from julek-wolfssl/ocsp-typo
Typo in testing script
2022-05-25 08:16:58 -05:00
b664cea735 Typo in testing script 2022-05-25 12:10:27 +02:00
0d59d36a80 update TSIP VER to 1.15 for RX65N and RX72N
fix -140 error when enabling -O2

fix no_crypto_hash
2022-05-25 18:31:23 +09:00
6c0b65d655 internal.c: dtls: HelloVerifyRequest on resumption 2022-05-25 10:38:32 +02:00
d2cb0278f6 SP ARM32 ASM: moving large immediate value
ARMv6 and early doesn't support moving an immediate value larger than 8
bits. Compiler doesn't have enough spare registers to handle it.
2022-05-25 10:58:32 +10:00
a1fb385450 free recipent list in error cases 2022-05-24 15:12:39 -07:00
5aea58d1e8 Merge pull request #5175 from douzzer/20220524-shellcheck-warnings
20220524-shellcheck-warnings
2022-05-24 14:21:49 -07:00
a5225af1c7 Merge pull request #4973 from JacobBarthelmeh/CSharp
add example C# PSK client
2022-05-24 13:37:14 -07:00
bcb5ff5ed9 Increase MAX_ECC_STRING to include the trailing \0 for longer order strings (in eg. SECP160R1). Note that this now matches the check in wc_EccPublicKeyDecode. 2022-05-24 13:20:52 -07:00
03e086a139 Code review feedback. 2022-05-24 13:12:59 -07:00
74cbd08ff5 Merge pull request #5164 from cconlon/x509date
Remove WOLFSSL_ALT_NAMES restriction on notBefore/notAfter use in Cert struct
2022-05-24 12:41:00 -07:00
321d404d6b add define to skip unaligned memory tests in test.c 2022-05-24 11:55:21 -06:00
5c14bef6a8 global fixes for shellcheck warnings SC2027, SC2069, SC2154, SC2141, SC3014, SC3037 (all true positives). note, does not fix SC2057 in ocsp-stapling.test, which is addressed by PR #5174 . 2022-05-24 12:13:14 -05:00
b66fa1680a fix whitespace. 2022-05-24 12:13:14 -05:00
6a26dab73a X.509 cert validity for CertFromX509() and EncodeCert() shouldn't be protected by WOLFSSL_ALT_NAMES 2022-05-24 10:28:46 -06:00
5f148c3dcc Merge pull request #5172 from SparkiDev/jenkins_fixes_5
benchmark.c: fix Jenkins failure where byte, word32 not defined
2022-05-24 08:09:47 -07:00
fab9e29513 benchmark.c: fix Jenkins failure where byte, word32 not defined 2022-05-24 12:10:01 +10:00
350f1d6496 Only use __builtin_offsetof on GCC 4+. It is not supported in GCC 3 or earlier. 2022-05-23 14:44:56 -07:00
26a92977f0 Remove MCAPI project's dependency on zlib version. 2022-05-23 14:29:44 -07:00
b329a16832 Update Zephyr fs.h path. 2022-05-23 13:45:30 -07:00
465a6ceb64 Merge pull request #4920 from SparkiDev/old_timing_pad_verify
Make old less secure TimingPadVerify implementation available
2022-05-23 13:43:59 -07:00
6424af120c Merge pull request #5161 from SparkiDev/sp_armv7a
SP ARM 32: Fixes to get building for armv7-a
2022-05-23 10:01:49 -07:00
36db5ef929 add test case for UUID and FASC-N 2022-05-23 09:17:42 -07:00
cdfdefe9af improve checking on UUID getter function 2022-05-22 17:18:20 -07:00
9e4de4bfc8 add FASC-N and UUID alt. name support 2022-05-22 17:18:20 -07:00
62cb2b4ca9 ASN.1 Additions for FPKI/CAC
1. Add some OIDs used in the Federal PKI Policy Authority standard.
2. Added the SubjectDirectoryAttributes extension to certificate
   parsing. (limited to country of citizenship)
3. Rename constant label SUBJECT_INFO_ACCESS to SUBJ_INFO_ACC_OID
4. Added the SubjectInfoAccess extension to certificate parsing.
   (limited to one URL)
5. Add the SSH extended key usage flags.
6. Use some of the template changes on the new certificate items.
2022-05-22 17:18:20 -07:00
b5d65b9579 Merge pull request #5159 from kareem-wolfssl/fipsv3HmacMd5
Allow using 3DES and MD5 with FIPS 140-3, as they fall outside of the FIPS boundary.
2022-05-20 18:40:29 -07:00
9a74745246 Merge pull request #5163 from haydenroche5/evp_pkey_derive_guard
Remove unneeded FIPS guard on wolfSSL_EVP_PKEY_derive.
2022-05-20 17:12:24 -07:00
ec39ee2cb6 Merge pull request #5070 from miyazakh/crypto_only_flwup 2022-05-20 17:08:29 -06:00
d80b282fdd Merge pull request #5156 from anhu/HAVE_AES_GCM
Rename HAVE_AES_GCM guard to HAVE_AESGCM in the tests.
2022-05-20 15:03:57 -07:00
04ddd0abe4 Merge pull request #5095 from haydenroche5/decoded_cert_crit_fields
Make the critical extension flags in DecodedCert always available.
2022-05-20 15:03:39 -07:00
2fc129e236 Merge pull request #5162 from rliebscher/master
Remove unused warning in ecc.c
2022-05-20 11:42:39 -07:00
a6b948ae59 Remove unneeded FIPS guard on wolfSSL_EVP_PKEY_derive. 2022-05-20 11:29:01 -07:00
f19b426a3f fix for files included in make dist 2022-05-20 09:26:53 -06:00
a8024a32c5 Remove unused warning in ecc.c
When WOLFSSL_ECIES_OLD is defined you get an unused warning
in ecc.c / wc_ecc_encrypt_ex().
Just suppress it by "using" the parameter.
2022-05-20 16:05:10 +02:00
9427ebc5be Merge pull request #5160 from haydenroche5/tls_unique
Provide access to "Finished" messages outside the compat layer.
2022-05-19 21:30:30 -07:00
b6290f1590 Merge pull request #5157 from douzzer/20220519-multi-test-fixes
20220519-multi-test-fixes
2022-05-20 13:47:09 +10:00
bc5262a5d0 SP ARM 32: Fixes to get building for armv7-a
Change ldrd to either have even first register or change over to ldm
with even first register.
Ensure shift value in ORR instruction has a hash before it.
Don't index loads and stores by 256 or more - make them post-index.
div2 for P521 simplified.
2022-05-20 12:15:58 +10:00
6d9fbf7ab3 Provide access to "Finished" messages outside the compat layer.
Prior to this commit, if you wanted access to the Finished messages from a
handshake, you needed to turn on the compatibility layer, via one of
OPENSSL_ALL, WOLFSSL_HAPROXY, or WOLFSSL_WPAS. With this commit, defining any
of these causes WOLFSSL_HAVE_TLS_UNIQUE to be defined (a reference to the
tls-unique channel binding which these messages are used for) in settings.h.
This allows a user to define WOLFSSL_HAVE_TLS_UNIQUE to access the Finished
messages without bringing in the whole compat layer.
2022-05-19 16:34:13 -07:00
efc8d36aa5 configure.ac: add whitespace separators to "((" groupings to mollify shellcheck SC1105 "Shells disambiguate (( differently or not at all. For subshell, add spaces around ( . For ((, fix parsing errors." 2022-05-19 18:19:11 -05:00
6984cf83b2 scripts/ocsp-stapling.test: fix whitespace. 2022-05-19 16:45:50 -05:00
e35c1e5a61 setup of default build config 2022-05-19 14:54:22 -06:00
8de3765af9 clean up namespace and remove settings files 2022-05-19 14:28:23 -06:00
d8817266be trim down sln 2022-05-19 13:54:07 -06:00
6dc47580ce fixing dependency for new project 2022-05-19 13:45:09 -06:00
832a7a40a6 Allow using 3DES and MD5 with FIPS 140-3, as they fall outside of the FIPS boundary. 2022-05-19 12:06:20 -07:00
249afbbfc9 update output directory and add psk client example 2022-05-19 12:11:00 -06:00
5988f35593 src/wolfio.c: in EmbedReceiveFrom((), clear peer before recvfrom() to fix clang-analyzer-core.UndefinedBinaryOperatorResult; add DTLS_ prefix to macros SENDTO_FUNCTION and RECVFROM_FUNCTION, and gate their definitions on their being undefined to allow overrides. 2022-05-19 11:31:24 -05:00
f2e9f5349f wolfcrypt/src/asn.c: refactor DecodeBasicOcspResponse() to keep DecodedCert off the stack in WOLFSSL_SMALL_STACK builds. 2022-05-19 11:28:34 -05:00
368854b243 scripts/: refactor TLS version support tests to use -V, rather than -v (which makes frivolous connection attempts). 2022-05-19 11:18:34 -05:00
cf81ae79e4 HAVE_AESGCM 2022-05-19 11:30:58 -04:00
9c2903c176 Remove HAVE_AES_GCM guard as it is never defined. 2022-05-19 01:20:55 -04:00
4a3ff40eb3 Merge pull request #5138 from haydenroche5/issuer_names
Add ability to store issuer name components when parsing a certificate.
2022-05-18 16:56:55 -07:00
cd41c8beaf Merge pull request #5147 from rizlik/do_alert_reset
internal.c:reset input/processReply state if exiting after DoAlert()
2022-05-19 09:36:44 +10:00
b53484be10 Merge pull request #5155 from cconlon/configFix
Fix --enable-openssh FIPS detection syntax in configure.ac
2022-05-18 17:34:43 -05:00
628a34a43d fix --enable-openssh FIPS detection syntax in configure.ac 2022-05-18 12:52:07 -06:00
1026c7141e Merge pull request #5148 from JacobBarthelmeh/PKCS7 2022-05-18 11:44:20 -06:00
be172af3cd internal.c: check that we have data before processing messages
We should never encounter this bug under normal circumstances. But if we enter
processReplyEx with a wrongly `ssl->options.processReply` set to
`runProcessingOneMessage` we check that we have some data.
2022-05-18 18:49:33 +02:00
6940a5eaae internal.c:reset input/processReply state if exiting after DoAlert() 2022-05-18 18:35:29 +02:00
40063f7487 Merge pull request #5109 from rizlik/dtls_peer_matching_fix
wolfio: dtls: fix incorrect peer matching check
2022-05-18 09:12:26 -07:00
5de9c45161 resolve merge and conflict 2022-05-18 11:37:22 +09:00
ac3fc89df9 Merge pull request #5151 from SparkiDev/tls13_premaster
TLS 1.3:  pre-master secret zeroizing
2022-05-17 19:18:43 -07:00
54a96cef06 add test case 2022-05-18 11:16:10 +09:00
88abc9f3c1 addressed review comments
add to call wc_ecc_rs_to_sig and wc_ecc_verify_has
2022-05-18 11:16:07 +09:00
c1f117413f get crypto only compiled with openssl extra 2022-05-18 11:16:03 +09:00
1765e2c482 Merge pull request #5150 from haydenroche5/benchmark_main_void
Fix main signature in benchmark.c.
2022-05-18 10:10:07 +10:00
04ff6afbad Add ability to store issuer name components when parsing a certificate.
This is turned on when `WOLFSSL_HAVE_ISSUER_NAMES` is defined. This allows the
user to inspect various issuer name components (e.g. locality, organization,
etc.) by using these new fields in a `DecodedCert`.
2022-05-17 16:29:52 -07:00
2f91028f2d TLS 1.3: pre-master secret zeroizing 2022-05-18 08:52:38 +10:00
fd535242a0 Fix main signature in benchmark.c.
If `NO_CRYPT_BENCHMARK` is defined, the main function is `int main()`, but it
should be `int main(void)`.
2022-05-17 14:28:43 -07:00
8b46c95f06 macro guard for build with disable ecc 2022-05-17 11:36:09 -06:00
d6935ed3be Review comments 2022-05-17 09:21:20 -07:00
c9ae021427 Merge pull request #5143 from julek-wolfssl/x509-ret-empty-name
Return subject and issuer X509_NAME obj even when not set
2022-05-17 09:16:54 -07:00
50cc6d0422 Merge pull request #5139 from cconlon/opensshfips
Modify --enable-openssh to not enable non-FIPS algos for FIPS builds
2022-05-17 09:16:21 -07:00
6df65c0162 wolfio: dtls: fix incorrect peer matching check
Ignore packet if coming from a peer of a different size *or* from a different
peer. Avoid whole memcmp of sockaddr_in[6] struct because is not portable (there
are optional fields in struct sockaddr_in).
2022-05-17 11:01:55 +02:00
fc12c68601 Merge pull request #5146 from dgarske/kcapi_keywrap
Fix to allow enabling AES key wrap (direct) with KCAPI
2022-05-17 08:16:00 +10:00
1dc5e4cee5 add padding for variable ecc signature size 2022-05-16 15:26:29 -06:00
ec619e3f35 Merge pull request #5107 from julek-wolfssl/wpas-ex-data-leak
Call ctx->rem_sess_cb when a session is about to be invalid
2022-05-16 13:27:08 -07:00
579a37bdf0 Merge pull request #5117 from cconlon/getrandom
add support for Linux getrandom() with WOLFSSL_GETRANDOM
2022-05-16 12:36:30 -07:00
0ef4707859 Merge pull request #5137 from JacobBarthelmeh/docs 2022-05-16 12:18:14 -06:00
7f8f0dcffe Refactor cache ex_data update/retrieve into one function
- Add explicit pointer cast
2022-05-16 13:01:05 +02:00
d996086a6d Return subject and issuer X509_NAME obj even when not set
This allows the user to set the attributes of the subject and issuer name by calling X509_REQ_get_subject_name and adding attributes to it.
2022-05-16 12:49:34 +02:00
fb9b96d498 fix for index increment and change test case expected return values 2022-05-13 14:07:29 -07:00
6b1e3003fb Merge pull request #5142 from SparkiDev/ssl_move_pk
ssl.c rework
2022-05-13 12:56:14 -07:00
3a4feddf75 update code for continued support with i.MX6 2022-05-13 13:21:45 -06:00
643cd78ea2 Fix to allow enabling AES key wrap (direct) with KCAPI. 2022-05-13 11:15:32 -07:00
1a57e3065a Small cleanups. Missing (void), spelling and formatting. Also fixes for variations of 25519/448 build. 2022-05-13 09:24:59 -07:00
7305616452 Merge pull request #5080 from JacobBarthelmeh/DH
with WOLFSSL_NO_DH186 restriction allow odd DH param size generations
2022-05-13 08:57:33 -07:00
50f53f9576 Merge pull request #5129 from LinuxJedi/remove-python-wrappers
Remove the Python wrappers from wolfSSL source
2022-05-13 08:36:33 -07:00
630c5ef364 Merge pull request #5140 from SparkiDev/sp_fixes_7
SP fixes
2022-05-12 21:57:48 -07:00
852d5169d4 ssl.c rework
Move the public key APIs out of ssl.c and into pk.c.
(RSA, DSA, DH and EC)
2022-05-13 11:12:44 +10:00
eea537e5ea Merge pull request #5124 from kaleb-himes/WIN_MULTICONFIG
Address issues ID'd by new windows multi-config test
2022-05-13 09:39:15 +10:00
e8160f049e SP fixes
Fix div_word without using div.
Fix ARM32 and Cortex-M builds to work for 4096 again.
2022-05-13 09:37:24 +10:00
c3a79f50d8 modify --enable-openssh to not enable non-FIPS algos for FIPS builds 2022-05-12 16:53:57 -06:00
e6ce735ed8 add support for Linux getrandom() with WOLFSSL_GETRANDOM 2022-05-12 16:51:38 -06:00
6aaee73585 Merge pull request #5133 from rizlik/cookie_keyshare_fix
tls13: fix cookie has keyShare information check
2022-05-13 08:01:59 +10:00
d1308fcdfc Merge pull request #5122 from rizlik/tls13_pad_calc
internal.c: fix pad-size when more records are received at once
2022-05-13 07:59:36 +10:00
52fc3844a6 Merge pull request #5127 from rizlik/wolfss_msg_fix
wolfcrypt: logging: use do{}while(0) to disable WOLFSSL_MSG* macro
2022-05-13 07:55:18 +10:00
988236ca70 remove port print out 2022-05-12 13:07:04 -07:00
8124368319 Merge pull request #5136 from douzzer/20220512-stderr
print errors to stderr, not stdout
2022-05-12 13:59:41 -06:00
c4920021d8 print errors to stderr, not stdout;
fix whitespace in internal.c;

add missing error handling in examples/server/server.c around recvfrom().
2022-05-12 13:07:32 -05:00
60864f19da Merge pull request #5130 from JacobBarthelmeh/examples
print out test errors to stderr instead of stdout
2022-05-12 12:44:45 -05:00
2cf87a8049 Merge pull request #5084 from julek-wolfssl/zd14101-dtls-want-write
DTLS fixes with WANT_WRITE simulations
2022-05-12 09:36:40 -07:00
7316a275ae Add EXTRA_DIST entry for include.am 2022-05-12 17:00:02 +01:00
c3d4c3086e Add README to point to the new Python locations 2022-05-12 16:55:26 +01:00
05ce8329c9 Merge pull request #5067 from miyazakh/compat_altcertchain
"veify ok" if alternate cert chain mode is used
2022-05-12 08:54:51 -07:00
7a95be1a97 Merge pull request #5126 from JacobBarthelmeh/crl
do not error out on CRL next date if using NO_VERIFY
2022-05-12 08:44:29 -07:00
9ca1206bf3 Merge pull request #5131 from SparkiDev/sp_win_fixes_1
SP: Windows build fixes
2022-05-12 09:56:27 -05:00
44be4e1cc8 Reset ret in client and server after wolfSSL_dtls_got_timeout()
- Do UDP connect only with simulateWantWrite to accommodate macOS that doesn't like sendto being called on connected UDP sockets
- Call wolfSSL_dtls_get_current_timeout only on a DTLS connection
2022-05-12 16:48:04 +02:00
9914da3046 Fix resumption failure and use range in connect state logic 2022-05-12 15:46:08 +02:00
a31b76878f DTLS fixes with WANT_WRITE simulations
- WANT_WRITE could be returned in unexpected places. This patch takes care of that.
- Change state after SendBuffered only if in a sending state to begin with.
- Adapt client and server to simulate WANT_WRITE with DTLS
2022-05-12 15:46:08 +02:00
829e9f5277 tls13: fix cookie has keyShare information check
Fix the check to see if the cookie has key_share information or not (needed to
reconstruct the HelloRetryRequest). At the moment, it looks like we never send a
cookie without KeyShare extension. Indeed the HelloRetryRequest is sent only
because the client didn't provide a good KeyShareEntry in the first
ClientHello. When we will support DTLSv1.3, the HelloRetryRequest will be used
as a return-routability check and it may be sent without the KeyShare extension.
2022-05-12 12:10:58 +02:00
8e3d7fc6f4 wolfcrypt: logging: use do{}while(0) to disable WOLFSSL_MSG* macro
otherwise statement of the type:

if (condtion)
    WOLFSSL_MSG("");

after preprocessing will become:

if (condition)
    ;

The empty body emits a warning from the compiler.
2022-05-12 09:59:27 +02:00
36739bca62 cleanup memory on structure free 2022-05-11 21:57:13 -07:00
818ac2b8dd add more REQ attribute support 2022-05-11 22:27:48 -06:00
798d81723b Merge pull request #5128 from rizlik/dtls_bidrectional_shutdown
Support DTLS bidirectional shutdown in the examples
2022-05-11 17:00:44 -07:00
f5b0d3c0b4 SP: Windows build fixes 2022-05-12 08:25:46 +10:00
36575ff480 Merge pull request #5125 from douzzer/20220510-strncmp-misuse
s/strncmp/strcmp/g
2022-05-12 08:22:00 +10:00
5d93a48ddf veify ok if alternate cert chain mode for verifyCallback 2022-05-12 06:15:18 +09:00
5caef7eaba avoid dead store with test case 2022-05-11 11:53:17 -06:00
9bee0281cb print out test errors to stderr instead of stdout 2022-05-11 11:40:54 -06:00
fd9e1e21ed Remove the Python wrappers from wolfSSL source
The wolfCrypt and wolfSSL Python wrappers are maintained in the
wolfCrypt-py and wolfSSL-py trees respectively. The duplicates in this
tree are stale. The content has been checked and any important changes
have been ported over to their respective trees.
2022-05-11 15:02:51 +01:00
eb6f9152db Revert modifications addressed by wolfSSL/scripts PR #235 2022-05-11 07:27:16 -06:00
761ab6b17a tests: add bidirectional shutdown UDP tests 2022-05-11 13:27:37 +02:00
257c55a311 examples: allow bidirectional shutdown in UDP
This commit allows the examples to perform a bidirectional shutdown also when
using UDP. It is useful to test DTLS retransmission.

Signed-off-by: Marco Oliverio <marco@wolfssl.com>
2022-05-11 13:27:24 +02:00
27e73818c5 tests: run test_wolfSSL_dtls_export() over UDP instead of TCP 2022-05-11 12:20:15 +02:00
692a01238e tests: support udp in test_server_nofail() 2022-05-11 12:19:09 +02:00
dca71d36f6 SP: Script changed, generated result update 2022-05-11 10:51:19 +10:00
d90a89898c wolfssl/test.h:OCSPRespFreeCb(): fix non-void return of and from void function. 2022-05-10 15:14:21 -05:00
9fbb4a923f src/internal.c:GetCipherKeaStr(): allow "ECDH" (in addition to "ECDHE") as a suite clause that maps to KEA "ECDH". 2022-05-10 15:12:00 -05:00
77fa0ccb82 src/tls.c:BuildTlsFinished(): work around false positive -Wmaybe-uninitialized. 2022-05-10 15:10:23 -05:00
531120131a do not error out on CRL next date if using NO_VERIFY 2022-05-10 14:00:21 -06:00
26673a0f28 where appropriate, use strcmp/strcasecmp, not strncmp/strncasecmp;
add macro XSTRCASECMP();

update XSTRNCASECMP() for XC32 >= 1.00 to use strncasecmp.
2022-05-10 12:20:12 -05:00
cb6a138caf Implement peer review feedback 2022-05-10 08:43:18 -06:00
f06ac9965c internal.c: fix: plaintext check account for the current record only 2022-05-10 13:12:09 +02:00
db23d8a0cf internal.c: don't skip records if we don't process early-data
If we don't process early data, we want to skip only the current record and not
all the received data
2022-05-10 13:04:43 +02:00
445c1e6ceb internal.c: don't check TLS13 plaintext limit twice
Plaintext size is checked before decryption in TLS 1.3
2022-05-10 12:51:50 +02:00
0747a16893 Merge pull request #5119 from JacobBarthelmeh/fuzzing
adjust setting of input pointer with BER pkcs7 edge case
2022-05-10 09:40:51 +10:00
d5f7beefd4 Address issues ID'd by new windows multi-config test 2022-05-09 16:50:56 -06:00
063e757f6b Merge pull request #5121 from miyazakh/sce_example_update2 2022-05-09 14:15:13 -06:00
d133fa6143 server: check that the first packet of udp connection is clientHello
Used to allow for bi-directional shutdown tests with UDP and DTLS
2022-05-09 13:45:27 +02:00
0c7e9a0104 internal.c: fix pad-size when more records are received at once
don't consider the end of the record the end of received data as more records
may be read at once when DTLS will be supported.
2022-05-09 11:00:31 +02:00
59fdf05155 Merge pull request #5111 from kaleb-himes/ABI-check-test-rev2
Refactor wolfSSL_ASN1_TIME_adj to use GetFormattedTimeString (new API)
2022-05-09 09:15:57 +10:00
d95b2e69b5 Merge pull request #5112 from JacobBarthelmeh/Testing
fix for indef buffer check with pkcs7
2022-05-09 09:03:10 +10:00
b76c70d969 Merge pull request #5120 from dgarske/v5.3.0_cubepack 2022-05-08 07:50:20 -06:00
75d90aaf2f update key data and add fixes
Fix Aes gcm memory curruption

  - fix delta size calculation
  - add logging SEGGER printf for RA6M4
  - update client example

Added test cases

 - Fixed aes buffer overflow
 - Fixed usable
 - Fixed sce - no-sce use case
 - Add logging SEGGER printf for RA6M4
2022-05-07 10:43:43 +09:00
421f54e60a Merge pull request #5118 from douzzer/20220405-declaration-after-statement
20220405 declaration after statement
2022-05-06 16:16:52 -07:00
74b3df4f6c Refactor tmpF in RsaMGF1 2022-05-06 16:14:47 -07:00
bc877dab2a Changes to support v5.3.0 cube pack for ST. 2022-05-06 15:49:11 -07:00
1e1a722332 Merge pull request #5113 from JacobBarthelmeh/docs
fix markdown in readme notes
2022-05-06 14:20:16 -07:00
576f0aa045 adjust setting of input pointer with BER pkcs7 edge case 2022-05-06 14:22:53 -06:00
6be3dae6d3 Merge pull request #5104 from tmael/32_bit_ssize
Fix for stack and heap measurements of a 32-bit build
2022-05-06 14:32:06 -05:00
ad2119b2f8 Review comments 2022-05-06 12:00:32 -07:00
36877d78b4 Merge pull request #5078 from julek-wolfssl/wpas-tls13
Clean up wolfSSL_clear() and add some more logging
2022-05-06 11:45:43 -07:00
b59ac022c9 fix comment explaining ConstantCompare() in AES_GCM_decrypt_C(). 2022-05-06 13:36:54 -05:00
ccc9b1535d fix whitespace. 2022-05-06 13:34:32 -05:00
99b44f15ef fix various -Wdeclaration-after-statement, with and without --enable-smallstack. 2022-05-06 13:34:32 -05:00
3e774be88c Minor text and formatting cleanups. 2022-05-06 11:01:40 -07:00
e1aefc08ac Merge pull request #5110 from douzzer/20220405-NETWORK_UNSHARE_HELPER
$NETWORK_UNSHARE_HELPER
2022-05-06 09:46:36 -07:00
88443dea8c Merge pull request #5114 from SparkiDev/ct_fixes_2
SP: Div fixes for constant time
2022-05-06 09:44:11 -07:00
b6b007de3c Call ctx->rem_sess_cb when a session is about to be invalid
Allow the user to register a session remove callback with wolfSSL_CTX_sess_set_remove_cb() that will be called when the session is about to be free'd or evicted from cache.
2022-05-06 16:34:28 +02:00
ef89e2e637 Rename utc_str[_buf] -> time_str[_buf] (semantic change) 2022-05-06 08:18:14 -06:00
3e1ba5d4d4 Implement peer review feedback and leave some breadcrumbs in the event of future updates 2022-05-06 07:50:39 -06:00
b19f70d182 Fix TSIP build with NO_AES_CBC 2022-05-06 07:31:13 -05:00
7e9896d162 Only clear session when we didn't complete a handshake
- Allow overriding buffer size with `WOLFSSL_MSG_EX_BUF_SZ`
- Allow disabling `WOLFSSL_MSG_EX` by defining `NO_WOLFSSL_MSG_EX`
2022-05-06 12:35:49 +02:00
9ffc300641 SP: Div fixes for constant time
Implement div words for different platforms.
Use implementation not using a divide instruction unless
SP_DIV_WORD_USE_DIV or we know there is a div instruction.
Fix Thumb implementation of div word.
2022-05-06 16:02:18 +10:00
a9c7bc9d00 fix markdown in readme notes 2022-05-05 17:12:55 -06:00
853db0841f fix for indef buffer check with pkcs7 2022-05-05 16:25:28 -06:00
ecf449dfe0 Refactor wolfSSL_ASN1_TIME_adj to use GetUnformattedTimeString (new API) 2022-05-05 16:25:25 -06:00
a4eaa31b5e Merge pull request #5101 from dgarske/sniffer_async_test
Improve the sniffer asynchronous test case to support multiple concurrent streams
2022-05-06 08:14:32 +10:00
4d4145e6a0 add support for $NETWORK_UNSHARE_HELPER to the relevant scripts/. 2022-05-05 15:59:11 -05:00
19e8bb05f3 wolfcrypt/src/aes.c: fix shiftTooManyBitsSigned in AES_GCM_decrypt_C(). 2022-05-05 15:54:31 -05:00
ffe5599013 Fix testsuite 32-bit build 2022-05-05 08:08:09 -07:00
6e880495dc Merge pull request #5102 from SparkiDev/ct_valgrind_fixes_1
Constant time changes
2022-05-05 07:43:00 -07:00
189c9ab234 Constant time changes
GCM: make borrow constant time.
AES-GCM decrypt: compare at end and constant time.
Random: array_add touchs all elements every time.
RSA-OAEP: look for padding byte in constant time (look at every byte in
array).
SP
 - reduce conditional use (make them bit ops)
 - Fix point adds to not use double when adding infinity to infinity
 - Implement signed div as __divi3 is not constant time.
 - Move check sof input variables to API.
2022-05-05 12:26:57 +10:00
e81670a3c0 Merge pull request #5106 from douzzer/20220504-linuxkm-wc-port-h
linuxkm_wc_port.h: move several more definitions outside the BUILDING_WOLFSSL gate
2022-05-04 13:09:19 -07:00
9767631ebe Merge pull request #5100 from anhu/enable-wolfssh
For consistency, add --enable-wolfssh
2022-05-04 13:02:54 -07:00
af8865d13e linuxkm_wc_port.h: move several more definitions outside the BUILDING_WOLFSSL gate, as they are needed for applications to include various wolfssl headers. 2022-05-04 13:16:45 -05:00
bdd6072ede Check nomalloc with verify inline 2022-05-04 09:33:38 -07:00
f12fd6ab8b fix spelling 2022-05-04 09:11:12 -07:00
af8f18b634 Merge pull request #5103 from danielinux/rsa-encryptsize
wc_RsaEncryptSize needed in verify only and no-PSS builds
2022-05-04 07:53:06 -07:00
fff3402ed4 WOLFSSL ---> WOLFSSH 2022-05-04 09:28:08 -04:00
e606cccb10 wc_RsaEncryptSize needed in verify only and no-PSS builds 2022-05-04 14:20:44 +02:00
97f54e8e0a Support RSA OAEP with no malloc 2022-05-03 22:57:47 -07:00
ca955032a0 Fix 32-bit enable-trackmemory build 2022-05-03 20:48:38 -07:00
a9d28da7ce Fix 32-bit enable-stacksize build 2022-05-03 20:16:56 -07:00
5f539b3921 Improve the sniffer asynchronous test case to support multiple concurrent streams. 2022-05-03 16:43:15 -07:00
cb929e1247 For consistency, add a --enable-wolfssl; keep --enable-ssl for backwards compat. 2022-05-03 12:08:13 -04:00
e722c15be8 Merge pull request #5098 from JacobBarthelmeh/Release
- prep for release 5.3.0
2022-05-03 10:48:53 +10:00
628a91efda Fix for size calculation for encrypt then mac without openssl extra enabled. Fix for cast warning. 2022-05-02 17:11:48 -06:00
6f5be32d3a update rpm spec 2022-05-02 17:08:38 -06:00
94e34d7a98 use NO_SESSION_CACHE_REF with titan cache due to session rows too big error 2022-05-02 17:08:38 -06:00
29401334d3 prepare for release 5.3.0 2022-05-02 17:08:38 -06:00
48cb185ce9 Merge pull request #5096 from JacobBarthelmeh/Testing
- static analysis test fixes
2022-05-02 10:05:08 -07:00
14ff3d1f0f fix for macro guard with test case building with trusted peer certs 2022-04-29 14:46:35 -07:00
35f46018a5 Merge pull request #5094 from SparkiDev/mrg_armv8_old_c_2
Move delaration to before code statements.
2022-04-29 11:02:32 -06:00
9d7a02b28e remove uint from test case and put variable declaration at top of scope 2022-04-29 10:40:44 -06:00
38c01b9d9f fix for infer diff report 2022-04-29 10:34:38 -06:00
895522aa18 Make the critical extension flags in DecodedCert always available.
Prior to this commit, these were guarded by OPENSSL_EXTRA ||
OPENSSL_EXTRA_X509_SMALL. Adding them into the struct for non-compatibility
layer builds only increases memory usage slightly and is useful for the user.
2022-04-28 15:46:16 -07:00
ef4d484f85 Move delaration to before code statements. 2022-04-29 08:13:20 +10:00
ea8e9ee699 Merge pull request #5063 from kaleb-himes/ZD13349
Ensure supported curves and curve size(s) WIN FIPS
2022-04-28 11:50:19 -06:00
df4dd7d5b3 Merge pull request #5088 from dgarske/sniffer_async_2
Fix to properly trap errors in sniffer (broken after async additions)
2022-04-28 09:47:05 -06:00
2ec7951de6 Merge pull request #4803 from danielinux/tirtos-update-202201
Update TIRTOS support
2022-04-28 10:12:32 -05:00
9970b68e45 Add HAVE_TLS_EXTENSIONS 2022-04-28 09:10:13 -06:00
881b9e5b07 Merge pull request #5093 from SparkiDev/rsa_fermat_fix
Fix use of WC_RSA_NO_FERMAT_CHECK
2022-04-28 06:40:08 -07:00
f91936944d Fix use of WC_RSA_NO_FERMAT_CHECK 2022-04-28 16:29:48 +10:00
67838e099d Merge pull request #5092 from ejohnstown/cert-ext-gen-test
Certificate Extension Generation Test
2022-04-28 10:25:28 +10:00
8b39f863e6 fix for buffer size and key cover 2022-04-27 13:14:22 -07:00
3294a3f8f8 Certificate Extension Generation Test
The test for certificate extensions requires both the test certs option
and the certificate generation option to run. The certs for the test are
generated by wolfCrypt. This disables the extensions test if
certificate generation is disabled.
2022-04-27 13:08:28 -07:00
22802604c0 Merge pull request #5090 from dgarske/public_dh
Fix for DH public FFDHE incorrectly getting enabled
2022-04-27 13:08:46 -05:00
277d6dc5dd Fix minor clang-tidy warnings for async. 2022-04-27 10:22:19 -07:00
93e8133453 Merge pull request #4896 from elms/compat/const_casting_fun
Casting away `const` for improved compatibility
2022-04-27 09:35:58 -07:00
7e803f346d Merge pull request #5076 from JacobBarthelmeh/fuzzing
fix for sanity check on PKCS7 indef read
2022-04-27 09:34:34 -07:00
8bf228d346 Merge pull request #5083 from SparkiDev/d2i_ecpriv_der
d2i_ECPrivateKey() takes DER encoded data
2022-04-27 09:32:04 -07:00
1d64c735ce Merge pull request #5086 from elms/cmake/ocsp_crl
cmake: Add CRL, OCSP, and OCSP stapling options
2022-04-27 09:31:51 -07:00
ad68bb9a7a Merge pull request #5091 from SparkiDev/mrg_armv8_old_c
Can't declare variables in for statements
2022-04-27 09:31:19 -07:00
83f4f9e5ef Espressif notes for user_settings.h preference 2022-04-27 08:41:33 -07:00
fbc2ccca1e Fix to properly trap errors in sniffer SetupKeys after async changes. Fix minor scan-build warnings. 2022-04-27 08:28:36 -07:00
11bdb8550e Correction 2022-04-27 08:33:56 -06:00
c0d7f3b2e6 add support for i.MX8 with QNX CAAM 2022-04-27 02:27:05 -07:00
ac48438bd0 Can't declare variables in for statements 2022-04-27 11:10:53 +10:00
7233732159 move ESP8266-specific to separate section 2022-04-26 17:58:14 -07:00
f86f4a8ca0 d2i_ECPrivateKey() takes DER encoded data
Code was incorrectly using data as a private key instead of DER
decoding.
Fixed i2d_EcPrivateKey() to output DER encoded data.
2022-04-27 09:39:50 +10:00
ec38048711 cmake: Add CRL, OCSP, and OCSP stapling options 2022-04-26 16:23:46 -07:00
25e8bd6b45 Merge pull request #5044 from SparkiDev/sp_read_radix_10_oob
SP Math
2022-04-26 16:21:11 -07:00
67029dc4e7 Fix to make sure the old public DH API's are not enabled unless FIPS v2 or older. Broken in PR #5018. 2022-04-26 15:39:54 -07:00
321e44226a Casting away const for improved compatibility
This is appears to be an existing pattern.

Fixes #4893
2022-04-26 14:31:40 -07:00
a6d019ecf9 Merge pull request #5073 from JacobBarthelmeh/PKCS7 2022-04-26 14:41:13 -06:00
cbc27f7de4 Merge pull request #5085 from douzzer/20220426-multi-test
20220426 multi-test fixups
2022-04-26 11:15:59 -07:00
7436a41bc7 Merge pull request #5046 from SparkiDev/cppcheck_fixes_8
cppcheck: fixes
2022-04-26 10:37:42 -07:00
7e8598f75b Merge pull request #5081 from dgarske/sniffer_decrypt
Restore sniffer internal decrypt function. This allows decrypting TLS…
2022-04-26 09:37:32 -07:00
67a3326e6d Merge pull request #5082 from SparkiDev/sp_c++
CPP protection for extern references to asm code
2022-04-26 08:33:15 -07:00
4e02d7e404 fix clang-tidy-Customer-CFG-7 readability-redundant-preprocessor. 2022-04-26 10:20:26 -05:00
704a18d103 Merge pull request #5079 from tmael/rsa_vfg
Fix no malloc RSA  test
2022-04-26 08:11:44 -07:00
e6d267ef16 src/ssl.c wolSSL_DH_new_by_nid(): fix cppcheck nullPointer report. 2022-04-26 09:58:07 -05:00
5e1a358dff wolfcrypt/src/evp.c wolfSSL_EVP_PKEY_free(): fix clang-diagnostic-implicit-fallthrough. 2022-04-26 09:57:54 -05:00
2c5db7b64c fix whitespace. 2022-04-26 09:57:25 -05:00
0be79a8629 CPP protection for extern references to asm code 2022-04-26 10:17:25 +10:00
8737d46bb1 Merge pull request #5018 from haydenroche5/libspdm
Make changes to compatibility layer to support libspdm.
2022-04-26 09:55:22 +10:00
d362b6dd08 Merge pull request #5033 from haydenroche5/ec_key_print_fp
Add wolfSSL_EC_KEY_print_fp to compat layer.
2022-04-26 09:51:37 +10:00
273ed1df76 Restore sniffer internal decrypt function. This allows decrypting TLS v1.2 traffic ignoring AEAD errors. 2022-04-25 16:28:09 -07:00
20e5e654a3 cppcheck: fixes
CBIORecv/Send are only assigned once.
IOCB_ReadCtx/WriteCtx only assigned once.
BuildMessage checks output and input wiht sizeOnly every call - state
machine doesn't cache these.
Renamed alias_tbl variables to something unique.
Other cppcheck fixes.
Also reworked pem_read_bio_key().
2022-04-26 09:26:41 +10:00
1181081c38 Merge pull request #5075 from dgarske/cryptocb
Fix for PKCS7 with Crypto Callbacks
2022-04-25 17:23:28 -06:00
3ab5ccd04f Add support for EVP_PKEY_sign/verify functionality (#5056)
* Fix wolfSSL_RSA_public_decrypt() return value to match Openssl
* Add support for EVP_PKEY_verify_init() and EVP_PKEY_verify()
* wpa_supplicant SAE public key functionality requires this function.
* Add DSA support for EVP_PKEY_sign/verify()
* Add ECDSA support for EVP_PKEY_sign/verify()
* Add tests for EVP_PKEY_sign_verify()
* Fix "siglen = keySz" at error cases
* Fix wolfSSL_DSA_do_sign() usage
1. Check wolfSSL_BN_num_bytes() return value
2. Check siglen size
3. Double the siglen
* Check return code of wolfSSL_i2d_ECDSA_SIG() in wolfSSL_EVP_DigestSignFinal()
* Add size calculations to `wolfSSL_EVP_PKEY_sign`
* Add size checks to wolfSSL_EVP_PKEY_sign before writing out signature
* Use wc_ecc_sig_size() to calculate ECC signature size
Signed-off-by: Masashi Honma <masashi.honma@gmail.com>
Co-authored-by: Juliusz Sosinowicz <juliusz@wolfssl.com>
2022-04-25 14:19:56 -07:00
9bf4a94796 with WOLFSSL_NO_DH186 restriction allow odd DH param size generations 2022-04-25 15:13:24 -06:00
bfd24cfa23 Merge pull request #5071 from dgarske/scan-build
Fixes for various nightly scan-build errors and warnings
2022-04-25 13:30:43 -07:00
85ef91ce6d Move up local variable at the beginning 2022-04-25 12:40:31 -07:00
34d541109d Additional scan-build warning fixes. 2022-04-25 09:55:36 -07:00
18a6a7c4a7 Fix RSA nomalloc test 2022-04-25 09:50:50 -07:00
cd2c7e1438 guard on test case for ecc curves 2022-04-25 09:01:24 -06:00
4013f83e4f Add some missing logs and implement WOLFSSL_MSG_EX()
WOLFSSL_MSG_EX() uses XVSNPRINTF to allow for formatted strings to be printed. It uses a 100 byte internal stack buffer to format the log message.
2022-04-25 15:59:07 +02:00
15a48e411d Add WOLFSSL_ESP8266 for ESP-IDF 2022-04-23 12:30:34 -07:00
70ad19467c Merge pull request #5068 from cconlon/jniPKCallbacks
Don't enable PK Callbacks with JNI FIPS builds
2022-04-22 16:08:29 -07:00
4ecf3545d7 Improve scan-build fix for ProcessPeerCertParse checking of empty dCert. With WOLFSSL_SMALL_CERT_VERIFY it is NULL. 2022-04-22 16:07:24 -07:00
e9b80e53fa Fix issue with InitX509Name. 2022-04-22 16:02:54 -07:00
74cd2fd910 Fix for integer.c possible uses of mp_int input with DP NULL. 2022-04-22 16:02:54 -07:00
ea2841fa7a Make sure ASN1 isDynamic is always set to 0. SK Cipher doesn't have free (data is contained in the SK). 2022-04-22 16:02:54 -07:00
84a33183a6 Various scan-build fixes. 2022-04-22 16:02:54 -07:00
3755b88a02 Fix InitX509Name to set dynamicName on init. 2022-04-22 16:02:53 -07:00
c41b1b1b9b Fix to ensure args->dCert is set for ProcessPeerCertParse. 2022-04-22 16:02:53 -07:00
a6a89d3316 Fix for integer.c s_mp_add output to make sure it grows if not set. 2022-04-22 16:02:53 -07:00
5a75e0f6c6 Fix for MCAPI CRYPT_AES_CTX size with ./configure --enable-pkcallbacks --enable-mcapi --enable-ecc --enable-sha512 --with-libz --enable-opensslextra. 2022-04-22 16:02:53 -07:00
293d7e1241 Fix for report of Use of memory after it is freed. Force the dataIsAlloc set to 0. 2022-04-22 16:02:53 -07:00
8fb1bb8781 Merge pull request #5074 from embhorn/zd14105
Fix for mingw builds
2022-04-22 15:27:58 -07:00
9cbf92df01 Fix for PKCS7 sign to allow providing a public key only if using crypto callback w/devId. ZD13949. 2022-04-22 14:29:43 -07:00
d96bd30398 fix for sanity check on PKCS7 indef read 2022-04-22 15:28:03 -06:00
b543aa0148 Fix for mingw builds 2022-04-22 14:35:46 -05:00
bf16696d8c Merge pull request #5036 from dgarske/sniffer
Fixes for minor sniffer and async issues
2022-04-22 12:24:33 -07:00
ed58cfdc0f Add DEBUG_CRYPTOCB and wc_CryptoCb_InfoString to help with debugging crypto callbacks. 2022-04-22 12:20:55 -07:00
d5927a58dd add store of PKCS7 cert used for verify 2022-04-22 11:26:34 -06:00
8ea953f8c0 add support for importing private only EC key to a WOLFSSL_EVP_PKEY struct 2022-04-22 10:20:42 -06:00
cb1dbb75f8 Fixes for sniffer-gen.sh. 2022-04-22 08:25:00 -07:00
8c4887c166 Free session in wolfSSL_clear
- Define `NO_SESSION_CACHE_REF` in wpa build
2022-04-22 15:54:04 +02:00
6606984101 Fix for building sniffer without ECC while Curve25519 is enabled. 2022-04-21 16:54:11 -07:00
2fa1e19fe7 Fix for ./configure --enable-sniffer --enable-session-ticket --disable-ecc && make. 2022-04-21 13:28:38 -07:00
cfa338314d do not enable PK Callbacks with JNI in FIPS mode 2022-04-21 11:06:54 -06:00
4a4b019e30 tests/api.c: in test_wc_ecc_verify_hash_ex(), check that passing zero r and/or s to wc_ecc_verify_hash_ex() returns MP_ZERO_E. 2022-04-21 07:21:42 +02:00
cfab451328 Merge pull request #5024 from dgarske/zd13538 2022-04-20 13:08:13 -07:00
7964fa4195 Merge pull request #5055 from elms/cmake/out_of_src 2022-04-20 11:16:50 -07:00
f9acaab6fe Fix memory leak with pcap bpf_program not calling pcap_freecode. 2022-04-19 16:45:49 -07:00
ec76f79e9d Fixes for sniffer decrypt broken in PR #4875. The TLS v1.2 sniffer decrypt did not have ssl->curRL set for proper auth tag calculation and was placing the data at offset + 8 to leave room for explicit IV. 2022-04-19 16:31:27 -07:00
49f510544a Merge pull request #5057 from haydenroche5/pem_write_ec_rsa_pub
Add wolfSSL_PEM_write_RSAPublicKey and wolfSSL_PEM_write_EC_PUBKEY.
2022-04-19 16:19:38 -07:00
696c5eed25 Ensure supported curves and curve size(s) WIN FIPS 2022-04-19 16:16:15 -06:00
29392ac6b3 spell fix: OSCP -> OCSP 2022-04-19 15:11:08 -07:00
d4e8922dfd cmake: fixup install lib structure for windows 2022-04-19 15:11:08 -07:00
a7cc438c9c cmake: out of source support
Add `WOLFSSL_BUILD_OUT_OF_TREE` option to force not changing the
source tree. Also defaults to `CMAKE_DISABLE_SOURCE_CHANGES` to avoid
failures
2022-04-19 15:11:08 -07:00
5d0654ee56 Merge pull request #5062 from dgarske/clang_str
Fix for issue with `error: format string is not a string literal`
2022-04-19 14:27:36 -05:00
d7085069d6 Add wolfSSL_PEM_write_RSAPublicKey and wolfSSL_PEM_write_EC_PUBKEY.
These were compatibility layer stubs before.
2022-04-19 09:42:10 -07:00
95a85d16d2 Fix for issue with error: format string is not a string literal. 2022-04-19 08:49:05 -07:00
70a0983bbc Fix for minor warning with chain input enabled and async disabled. 2022-04-18 16:17:37 -07:00
52b176b6a1 Merge pull request #5060 from cconlon/ecFipsReady
ECDH_compute_key: allow setting of globalRNG with FIPS 140-3 / Ready
2022-04-18 16:15:14 -07:00
710f49795f Fix for session cache locking with session stats in get_locked_session_stats. 2022-04-18 14:29:42 -07:00
659d33fdaf Fixes for minor sniffer and async issues:
* Sniffer: Remove old restrictions for max strength, encrypt-then-mac and forcing openssl-extra.
* Fix bound warning with strncpy in sniffer.c.
* Fix for async DH issue.
* Fix for SP math all not initializing raw big int.
* Fix for array bounds warning with "-O3" on SetEccPublicKey.
* Fix a sniffer async edge case with TLS v1.2 static RSA and extended master.
* Improved the sniffer test script detection of features.
* Disable ECC custom curve test with Intel QuickAssist.
2022-04-18 11:46:40 -07:00
9172abc969 Merge pull request #5059 from julek-wolfssl/missing-XFCLOSE
Add missing XFCLOSE()
2022-04-18 14:16:36 -04:00
567ae7ca55 Merge pull request #5061 from miyazakh/sce_keydata_update 2022-04-18 09:14:34 -06:00
6e70cdf3b5 Update key data for sce example 2022-04-17 14:29:44 +09:00
e89b4cce4c Merge pull request #5045 from SparkiDev/wycheproof_armasm
Wycheproof testing of Aarch64 ASM
2022-04-15 11:23:45 -07:00
8eed940e3a Merge pull request #5040 from SparkiDev/wycheproof_intelasm
Wycheproof fixes
2022-04-15 11:19:57 -07:00
3ab87ba2ed Merge pull request #5039 from SparkiDev/ecc_pub_api
ECC: make public APIS for add and double points
2022-04-15 11:09:37 -07:00
35cb3c8a79 ECDH_compute_key: allow setting of globalRNG with FIPS 140-3 / Ready 2022-04-15 09:36:14 -06:00
6c16b9c0b5 Merge pull request #5054 from miyazakh/tsipV1p15_grose
Update Renesas TSIP version to 1.15 on GR-ROSE
2022-04-15 09:34:09 -06:00
a70e188758 Merge pull request #5058 from douzzer/20220414-clang-tidy-intmath
20220414-clang-tidy-intmath
2022-04-15 10:17:27 -05:00
a6319fc2a9 Add missing XFCLOSE() 2022-04-15 16:26:31 +02:00
607a24b499 fixes for clang-tidy and sanitizer hygiene with --disable-fastmath. 2022-04-14 21:06:04 -05:00
096889927d wolfcrypt/src/port/devcrypto/devcrypto_aes.c: remove redundant "int ret" in wc_AesCtrEncrypt() (supersedes #5052). 2022-04-14 20:23:31 -05:00
2e3ebd7d8c Merge pull request #5053 from kaleb-himes/CLOUD_PORTING_A
Change void cast(s) to be non-conditional and consolidate condition l…
2022-04-14 14:21:42 -05:00
2fbe030e5e update tsip version to 1.15 2022-04-14 06:42:11 +09:00
d706e2be32 Change void cast(s) to be non-conditional and consolidate condition logic 2022-04-13 10:25:43 -06:00
947c72937f Merge pull request #5049 from miyazakh/unused_param 2022-04-13 09:02:26 -06:00
6cd87d56d4 Merge pull request #5042 from TakayukiMatsuo/certupdate 2022-04-13 09:00:10 -06:00
26b5d032b7 Merge pull request #5050 from SparkiDev/ecc_import_fail
ECC: fix import failure return
2022-04-13 08:02:27 -05:00
824b7a3f3f ECC: fix import failure return
Passing in x=0 and y=0 meant to return ECC_INF_E.
Passing in x=0, y=not 0 or x=not 0, y=0 now checks whether the point is
valid and forces a return of BAD_FUNC_ARG when IS_POINT_E is returned
from check.
2022-04-13 14:03:13 +10:00
c5056f408f fix unused parameter when using CRYPTO_CB_ONLY_RSA 2022-04-13 07:48:18 +09:00
55e13d40b3 SP Math
sp_read_radix_10: check _sp_add_d doesn't error due to overflow
_sp_add_d: Don't change value of used for result until it is known to be
valid.
2022-04-13 08:33:30 +10:00
6cc91c8f9b Wycheproof testing of Aarch64 ASM
Fix which bytes are incremented for AES-GCM - only 4 bytes are counter.
Fix Curve25519 to reduce to below modulus at end.
2022-04-12 11:45:14 +10:00
0ef7435580 Make changes to compatibility layer to support libspdm.
- Add support for ASN1_TIME_compare, DH_new_by_nid, OBJ_length, OBJ_get0_data,
and ChaCha20-Poly1305 and HKDF in the EVP layer.
- Map EC_POINT_get_affine_coordinates to
wolfSSL_EC_POINT_get_affine_coordinates_GFp and EC_POINT_set_affine_coordinates
to wolfSSL_EC_POINT_set_affine_coordinates_GFp.
- Add kdf.h compatibility header.
2022-04-11 15:07:27 -07:00
0717135e49 Add wolfSSL_EC_KEY_print_fp to compat layer. 2022-04-11 13:02:38 -07:00
830db63bcf Update certificate signature data for TSIP in response to /certs update 2022-04-12 02:55:58 +09:00
e87ded85b4 Merge pull request #5041 from embhorn/zd13969
Add ability to set ECC Sign userCTX using WOLFSSL_CTX
2022-04-11 09:38:52 -07:00
ab6dc8d669 Add ability to set ECC Sign userCTX using WOLFSSL_CTX 2022-04-11 08:41:27 -05:00
2995c96f11 Wycheproof fixes
Curve25519: reduce to less than mod at end of curve25519, optimize to
not use imulq when andq can be used instead.
x86_64 Karatsuba Mul: Don't put add carry into overflow and then
continue adding zero. Overflow is lost.
2022-04-11 15:09:40 +10:00
b6db087a62 ECC: make public APIS for add and double points
Use internal API internally.
2022-04-11 09:19:23 +10:00
0298a29a6f Merge pull request #5037 from JacobBarthelmeh/hsm
fix for function rename
2022-04-11 08:48:28 +10:00
cd1344bbed Merge pull request #5032 from kaleb-himes/ZD13946
Add logic equivalent to configure.ac in settings.h for poly1305
2022-04-08 15:13:16 -06:00
83ad0b7010 fix for function rename 2022-04-08 15:05:08 -06:00
79e2b2b4ce Merge pull request #5030 from LinuxJedi/add-iar-msp430
Add IAR MSP430 example
2022-04-08 13:15:42 -07:00
5d46d10933 Address peer feedback 2022-04-08 10:12:24 -06:00
c84c465fc6 Merge pull request #5035 from douzzer/20220408-fuzz-6262033210802176
oss-fuzz 6262033210802176
2022-04-08 08:34:16 -07:00
50bc20e340 Fix include.am for MSP430 2022-04-08 16:26:48 +01:00
6a21a90f41 Merge pull request #5034 from SparkiDev/sp_wycheproof_fixes
SP fixes from Whycheproof tests
2022-04-08 08:20:56 -07:00
997feecd6e Remove unused header from MSP430 example 2022-04-08 15:42:38 +01:00
676fe19e2f Fixes to the MSP430 example
* Fix include.am missing line
* Fix macros
* Add "static" keyword where needed
* Make compatible with MSP430 GCC
* Add MSP430 GCC Makefile
* Fix watchdog issue with GCC, also fixes IAR when large data model is
  used
* Fix comment style
* Fix typo in RNG (makes it ever so slightly more random)
* Add example output to README
2022-04-08 15:08:55 +01:00
1c570fae3b wolfcrypt/src/asn.c GetLength_ex(): test for overlong length spec before using length as shift operand. 2022-04-08 08:15:02 -05:00
ed7e1f9770 SP fixes from Whycheproof tests
EC point add is a double if affine ordinates are the same.
Fix AVX2 implementation of mod inv to do conversion from 26 bits in
32-bit registers to 64 bits in 64-bit registers. Also handle negative
value.
RSA OAEP: loop down to last byte. Must have a separator.
Div for x86_64: fix to have all 1s when high word equals divisor.
2022-04-08 15:01:06 +10:00
9859492222 Merge pull request #5029 from haydenroche5/asn1_time_diff_2038 2022-04-07 16:45:11 -06:00
5ea38b059e For improved compatibility populate the extension value for NID_subject_alt_name. 2022-04-07 11:10:03 -07:00
5231dc63fa Merge pull request #5031 from douzzer/20220407-clang-tidy
20220407 clang-tidy
2022-04-07 09:03:56 -07:00
c1421b1be8 Add logic equivalent to configure.ac in settings.h for poly1305 2022-04-07 09:00:26 -06:00
be742cabda Add missing include.am 2022-04-07 15:39:32 +01:00
288fdbcc3e fix readability-named-parameter. 2022-04-07 08:02:24 -05:00
28cefb0d1a fix clang-analyzer-core.NonNullParamChecker. 2022-04-07 08:01:00 -05:00
4efd06fdc1 fix readability-inconsistent-declaration-parameter-name. 2022-04-07 07:59:59 -05:00
0083afc279 fix whitespace. 2022-04-07 07:59:07 -05:00
2663f5abaf Add IAR MSP430 example
A basic MSP430 example for IAR IDE.
2022-04-07 11:07:27 +01:00
161d74879a Change time2epoch to TimeToUnixTime. 2022-04-06 21:38:24 -07:00
284ebacc57 Merge pull request #4916 from JacobBarthelmeh/hsm
Add SECO use and expand cryptodev
2022-04-07 10:21:32 +10:00
80766566fc Fixes for X509_add_ext and new test case. 2022-04-06 16:35:53 -07:00
87dc197284 Merge pull request #5028 from douzzer/20220406-cppcheck
fixes to mollify cppcheck (sizeofDivisionMemfunc, zerodivcond, shiftTooManyBits, signConversionCond)
2022-04-07 08:45:24 +10:00
e9aae8b571 use hash grow function with cmac 2022-04-06 15:08:19 -06:00
f6f6d91ae1 Merge pull request #5027 from LinuxJedi/fix-dox
Minor documentation cleanup
2022-04-06 14:01:08 -07:00
9b2d927de7 Merge pull request #5026 from danielinux/fix_unititialized_var
Fixed unused variable in asn.c
2022-04-06 13:03:47 -05:00
1b5af2fdd9 Merge pull request #5022 from SparkiDev/wycheproof_fixes
Wycheproof fixes/changes
2022-04-06 10:29:17 -07:00
49e72633b8 Merge pull request #5025 from SparkiDev/ssl_move_x509
ssl.c break out
2022-04-06 10:10:18 -07:00
2a0b726c15 add AES init functions to ECB test case 2022-04-06 09:42:38 -07:00
4e8c180290 fixes to mollify cppcheck (sizeofDivisionMemfunc, zerodivcond, shiftTooManyBits, signConversionCond). 2022-04-06 11:36:01 -05:00
5ea9d11295 Minor documentation cleanup
Fixes two things across all the Doxygen:

1. Remove WOLFSSL_API from each definition
2. Add missing parameter names from functions
2022-04-06 16:17:36 +01:00
91d883d99f macro guard on ECB test case and use realloc for hash 2022-04-06 07:04:17 -07:00
3d9a1647d4 Fixed unused variable in asn.c 2022-04-06 15:35:28 +02:00
25aa0af260 ssl.c break out
Move the X509 API out of ssl.c into x509.c
2022-04-06 17:25:26 +10:00
e9187f5f00 Wycheproof fixes/changes
Allow Chachac20-Poly1305 to take an empty msg.
Allow AES-SIV to have an empty nonce.
Don't allow the length to be malleable. Must use the smallest number of
bytes to represent value.
ECDSA and DSA signature values are positive.
Add Sha512-224 and Sha512-256 OIDs.
ASN template - ensure the ECDSA/DSA signature uses all data.
Curve25519/Curve448 - WOLFSSL_ECDHX_SHARED_NOT_ZERO means shared secret
can't be 0.
Curve25519/Curve448 - check public value is less than order.
ECC - x or y may be zero but not both.
Ed25519/Ed448 - check S is less than order.
Ed448 - ge_p3_dbl can be simplified for ASM.
Prime check (integer.c/tfm.c/sp_int.c): Don't allow negative values and
make sure random candidate doesn't have bits higher than those in a set
when bits not a multiple of 8.
RSA: support Sha512-224 and Sha512-256.
RSA: Fix check for invalid in decryption. Affects plaintexts 256 bytes
and longer.
RSA: Don't allow base be larger than modulus.
RSA: Check small ciphertext (1 or 0) on decrypt when not using OAEP.
RSA: WOLFSSL_RSA_DECRYPT_TO_0_LEN allows decrypted value to be 0.
SP math all: fix div to handle large a and d when checking size of
remainder.
SP math all: set sign of result in sp_mod_2d()
2022-04-06 15:35:01 +10:00
a338b4c933 refactor SHA grew function, revert benchmark devid, increase SHA_CTX size, add AES ECB cryptocb test 2022-04-05 14:45:18 -07:00
4f5aa81031 Merge pull request #5000 from ejohnstown/tls13-wctest
Add TLSv1.3 KDF to wolfCrypt Test
2022-04-05 10:45:35 -07:00
6a3f98627e Merge pull request #5013 from anhu/wc_CheckCertSigPubKey
Add new public API wc_CheckCertSigPubKey()
2022-04-05 09:48:08 -07:00
99fbd6f160 Merge pull request #4963 from SparkiDev/tls13_psk_multi_id
TLS 1.3 PSK: multiple ids for a cipher suite
2022-04-05 09:47:14 -07:00
e9a238ca86 Merge pull request #5021 from JacobBarthelmeh/certs
allow up to and including CTC_MAX_SKID_SIZE (32 byte hash)
2022-04-05 09:46:34 -07:00
97b85552e8 Merge pull request #5023 from douzzer/20220405-strict-aliasing
enforce strict aliasing rules
2022-04-05 09:46:12 -07:00
eefc0f2f57 Add TLSv1.3 KDF to wolfCrypt Test
Added a test for the TLSv1.3 KDF to the wolfcrypt test. It uses 6
different test cases from the CAVP tests. A set of 8 session keys are
generated using multiple exporters.
2022-04-05 08:56:15 -07:00
328de3ed63 remove -Wno-strict-aliasing from AX_HARDEN_CC_COMPILER_FLAGS and AX_HARDEN_CXX_COMPILER_FLAGS in m4/ax_harden_compiler_flags.m4, and fix strict aliasing infractions in api.c. 2022-04-05 08:10:16 -05:00
e3409a40a5 configure.ac: when $ENABLED_LINUXKM_DEFAULTS, set -DWOLFSSL_OLD_PRIME_CHECK only if $ENABLED_FIPS == no. 2022-04-05 08:10:03 -05:00
b2a2a8af4a fix whitespace. 2022-04-05 08:09:48 -05:00
df9335ee0a Merge pull request #4988 from tmael/sp_loop
Fixes for Diab C89 and armclang
2022-04-05 08:20:47 +10:00
8dd07bbb73 Merge pull request #5011 from dgarske/ecc_key_decode
Fix to check if `wc_EccPublicKeyToDer` has enough output buffer space
2022-04-05 08:03:03 +10:00
77485d987e Merge pull request #5010 from haydenroche5/asn1_time_diff_2038
Fix year 2038 problem in wolfSSL_ASN1_TIME_diff.
2022-04-05 07:58:36 +10:00
c3a9520eb5 Merge pull request #5016 from dgarske/async_fixes
Fixes for async in wolfCrypt test
2022-04-05 07:56:08 +10:00
fc6e10ff42 Another test fixup. 2022-04-04 17:42:25 -04:00
68ebb051e5 allow up to and including CTC_MAX_SKID_SIZE (32 byte hash) 2022-04-04 15:19:17 -06:00
f39bd5e02b Merge pull request #5014 from dgarske/kcapi_ecc_import 2022-04-04 14:08:29 -07:00
829a8a4039 Merge pull request #5009 from embhorn/zd13980
Fix build errors for NO_WOLFSSL_SERVER and NO_WOLFSSL_CLIENT
2022-04-04 12:43:49 -07:00
6513e2ce8f Merge pull request #5019 from douzzer/20220404-linux5v18-etc
20220404 linux5v18 etc
2022-04-04 11:08:18 -07:00
bb4698a9e8 Merge pull request #5020 from douzzer/20220402-fips-linuxkm-pie-only-on-linuxkm
--enable-fips=v5 --disable-linuxkm-pie
2022-04-04 11:08:06 -07:00
9c1e2a83d1 Fix year 2038 problem in wolfSSL_ASN1_TIME_diff.
Prior to this commit, this function used XMKTIME (mktime) to convert the
passed in WOLFSSL_ASN1_TIMEs to Unix timestamps. On platforms where time_t is
32 bits long, times after the year 2038 can't be represented with this type. To
fix this, we need to not use XMKTIME. With this commit, the static function
time2epoch is added to ssl.c, which uses the date time information to compute
seconds since the Unix epoch without the use of mktime. It returns the seconds
as a long long. This is sufficient to make the function work for years > 2038 on
the platform of the user who discovered this problem in the first place (Yocto
Linux on ARMv7).
2022-04-04 11:01:21 -07:00
400c7238ef Test fixup. 2022-04-04 13:43:06 -04:00
ae9926cc42 Missing flag in unit test. 2022-04-04 12:39:10 -04:00
9b5ad6f218 Merge pull request #4968 from miyazakh/cryptonly
add WOLF_CRYPTO_CB_ONLY_RSA and WOLF_CRYPTO_CB_ONLY_ECC
2022-04-04 08:31:41 -07:00
757c93c6d5 Merge pull request #4945 from kaleb-himes/ZD13795
Fix for ZD13795 and also remove all-caps parameter
2022-04-04 08:25:10 -07:00
04385f8557 configure.ac: fips 140-3: don't insist on linuxkm-pie unless configuring an actual linuxkm build. 2022-04-04 10:14:22 -05:00
0d6c283f7a fixes for -Werror=declaration-after-statement in debug builds. 2022-04-04 09:29:26 -05:00
492704992a wolfssl/wolfcrypt/settings.h: #ifdef WOLFSSL_LINUXKM, make sure config.h is included only once, before masking out inapplicable autodetected features. 2022-04-04 09:28:06 -05:00
0fba16a394 Merge pull request #4998 from haydenroche5/get_conv_form
Add wolfSSL_EC_KEY_get_conv_form to compatibility layer.
2022-04-04 08:47:14 +10:00
880afe0d89 Add wolfSSL_EC_KEY_get_conv_form to compatibility layer. 2022-04-02 13:57:33 -07:00
54aa211fee Merge pull request #5015 from douzzer/20220401-Wvla-Wdeclaration-after-statement
fix codebase for -Wvla -Wdeclaration-after-statement
2022-04-01 18:48:00 -07:00
8e4abb0011 addressed code review comment 2022-04-02 09:18:28 +09:00
c522baa75e Unit tests. 2022-04-01 18:34:21 -04:00
ae3996fd0e fix codebase for -Wvla -Wdeclaration-after-statement; fix some whitespace. 2022-04-01 14:44:10 -05:00
211007fb44 WOLFSSL_ASN_API ---> WOLFSSL_API 2022-04-01 15:24:40 -04:00
bd0e222fec Merge pull request #5012 from julek-wolfssl/evp-enc-dec-block
Implement `EVP_EncodeBlock` and `EVP_DecodeBlock`
2022-04-01 12:24:23 -07:00
6ec0c22a28 Fixes for async in wolfCrypt test. 2022-04-01 12:04:31 -07:00
ded168f238 Add check for buffer space in wc_EccPublicKeyToDer. Refactor SetEccPublicKey to put public key directly into output buffer and eliminate small stack. Fixes ZD 13904. 2022-04-01 11:46:27 -07:00
9c572efa40 Disable the public key check in import private key for KCAPI. Fix type warning in KCAPI AES. 2022-04-01 11:27:17 -07:00
e1965094ad Add check for ULONG_MAX in SP math to detect if pre-processor correctly handles 64-bit types. 2022-04-01 09:24:46 -07:00
edea6428d9 Add new public API wc_CheckCertSigPubKey() 2022-04-01 11:40:25 -04:00
ef16ce806c Fix build errors for NO_WOLFSSL_SERVER and NO_WOLFSSL_CLIENT 2022-04-01 08:04:41 -05:00
6dffa8a13d Implement EVP_EncodeBlock and EVP_DecodeBlock 2022-04-01 13:29:40 +02:00
4db45cea4e Fixes to build with diab and armclang 2022-03-31 20:48:28 -07:00
99af84f1e2 Whitespace cleanups. 2022-04-01 09:36:53 +09:00
d3a379adac add WOLF_CRYPTO_CB_ONLY_RSA and WOLF_CRYPTO_CB_ONLY_ECC 2022-04-01 09:36:52 +09:00
b45cd921b6 Merge pull request #5005 from dgarske/renesas_spell 2022-03-31 17:44:04 -06:00
7b21cd8cf0 Merge pull request #5001 from dgarske/kcapi_ecc
KCAPI ECC/AES optimizations to further reduce page memory use
2022-04-01 08:36:23 +10:00
79444fdb56 Merge pull request #4997 from dgarske/qat_eckg
Support for Intel QuickAssist ECC KeyGen acceleration
2022-04-01 08:32:21 +10:00
1add8703e2 Merge pull request #4996 from haydenroche5/bn_rand
Improve wolfSSL_BN_rand.
2022-04-01 08:12:22 +10:00
5a8fc919ef Merge pull request #5006 from dgarske/mcapi_test 2022-03-31 18:06:13 -04:00
33d2f2687f Merge pull request #5007 from douzzer/20220331-ignore-readability-avoid-const-params-in-decls
20220331-ignore-readability-avoid-const-params-in-decls
2022-03-31 15:05:22 -07:00
01f9f7df5f Merge pull request #5002 from JacobBarthelmeh/Compatibility-Layer
sanity check before copy with new memory bio
2022-03-31 15:08:26 -05:00
0f0fdea7ff Merge pull request #5004 from julek-wolfssl/apache-enable-etm
Allow encrypt then mac with apache
2022-03-31 12:08:50 -07:00
773170464e undo changes to header files (see b7cecbacb) made to mollify clang-tidy's overly pedantic readability-avoid-const-params-in-decls -- keep declarations and definitions fully aligned, to mollify broken compilers. 2022-03-31 14:02:08 -05:00
acb04bec0c Fix mcapi_test.c to include the settings.h before crypto.h. 2022-03-31 10:54:53 -07:00
61f6b5e29c Peer review feedback. 2022-03-31 10:04:23 -07:00
064888bb2a Add KCAPI ECC support for using a private key id. 2022-03-31 09:05:03 -07:00
f8007b2d8f Further KCAPI AES/ECC memory optimizations. Adds KCAPI_USE_XMALLOC option for AES and ECC to reduce page memory use in certain KCAPI cases that allow it. 2022-03-31 08:58:22 -07:00
1993851274 Renesas spelling, code formatting and whitespace fixes. 2022-03-31 08:02:00 -07:00
90fe2ab894 Merge pull request #4999 from embhorn/zd13969
Add wolfSSL_CTX_SetCertCbCtx to set user context for CB
2022-03-31 07:43:47 -07:00
4b5649edc9 Allow encrypt then mac with apache 2022-03-31 15:55:57 +02:00
3f03f4e40a Handle case where bits is 0 properly. 2022-03-30 16:56:53 -07:00
1de5165dcc KCAPI ECC optimization to further reduce page memory use. 2022-03-30 15:01:01 -07:00
8136c55a39 sanity check before copy with new memory bio 2022-03-30 14:02:03 -07:00
a914d782c0 Merge pull request #4810 from anhu/engine_fla 2022-03-30 13:43:09 -07:00
c905c613e9 Support for Intel QuickAssist ECC KeyGen acceleration. 2022-03-30 13:07:47 -07:00
ea38e1aab5 Add wolfSSL_CTX_SetCertCbCtx to set user context for CB 2022-03-30 12:27:11 -05:00
366f159fbb Merge pull request #4991 from gojimmypi/patch-2
Overhaul Espressif ESP-IDF wolfSSL setup_win.bat
2022-03-30 06:56:49 -07:00
2029bf0a0b Merge pull request #4992 from JacobBarthelmeh/Compatibility-Layer
support creating new mem bio of length 0
2022-03-30 06:55:53 -07:00
d9df00cdfb Merge pull request #4994 from dgarske/kcapi
KCAPI ECC memory optimizations and KCAPI AES build fix
2022-03-30 11:50:39 +10:00
2077690bf0 Improve wolfSSL_BN_rand.
- Previously, this function would round up the requested bits to the next
multiple of 8. With this commit, the function returns a number of exactly the
number of bits requested, which is the same behavior as OpenSSL. This problem
was discovered by a user using the compatibility layer with OpenSSH's ssh-keygen
utility.
- This function now respects the top and bottom parameters.
- Improved unit testing.
2022-03-29 18:08:21 -07:00
409a0acb88 fine tuning on wolfcrypt\test\test_paths.h 2022-03-29 16:07:10 -07:00
d72d28ac60 copy errors are now only warnings 2022-03-29 15:39:09 -07:00
1dc3808aae Merge pull request #4986 from cconlon/sslFipsReady
Fix FIPS defines in wolfSSL_RSA_sign_generic_padding() / RSA_verify_ex()
2022-03-29 16:02:17 -05:00
d287863a35 Update setup_win.bat
more copy error checking. remove trailing whitespace.
2022-03-29 12:52:50 -07:00
d10e72bc98 Fix for KCAPI AES with WOLFSSL_NO_KCAPI_AES_CBC. 2022-03-29 12:50:28 -07:00
4ad2f68071 fix defines for FIPS around RSA-PSS in wolfSSL_RSA_sign_generic_padding() and wolfSSL_RSA_verify_ex() 2022-03-29 10:03:16 -06:00
0989a14395 Merge pull request #4995 from douzzer/20220328-multi-test-fixes
fix reproducible-build for libtool 2.4.7
2022-03-29 08:00:45 -07:00
e9b941e16e configure.ac: fix --enable-reproducible-build to cope with update from libtool-2.4.6 to -2.4.7. 2022-03-29 07:53:43 -05:00
8edf237f75 Merge pull request #4993 from SparkiDev/sakke_gen_table_tmp_size_fix
SP: fix number of temps alloced in sp_ecc_gen_table
2022-03-28 21:32:35 -05:00
194138f0b8 Merge pull request #4990 from dgarske/async_fix
Fixes for async ECC
2022-03-29 10:30:38 +10:00
9a8be82653 Merge pull request #4987 from julek-wolfssl/ffmpeg
Add support for `--enable-ffmpeg`
2022-03-28 16:33:20 -07:00
f50514b228 SP: fix number of temps alloced in sp_ecc_gen_table
Ony affects SAKKE and as a result of point add changes.
2022-03-29 09:11:45 +10:00
1abcd4b035 Reduce KCAPI ECC page memory allocation sizes. 2022-03-28 15:40:07 -07:00
05f377011b Fix for building with KCAPI AES enabled. 2022-03-28 15:05:58 -07:00
f7f94cede0 support creating new mem bio of length 0 2022-03-28 15:52:42 -06:00
0627437048 Suggestions from haydenroche5 2022-03-28 17:44:00 -04:00
12349f39e6 Merge pull request #4974 from kareem-wolfssl/iotsafe
IOTSafe workarounds
2022-03-28 13:49:44 -07:00
b203726623 Overhaul Espressif ESP-IDF wolfSSL setup_win.bat
# Description

This is a replacement to https://github.com/wolfSSL/wolfssl/pull/4989, per the [comment](https://github.com/wolfSSL/wolfssl/pull/4989#issuecomment-1080998040)

Overhauled `win_setup.bat` for more robust and flexible install of wolfSSL to ESP-IDF `component` directory. 

Functionally, there are no significant changes.  However this version:

- more verbose output 
- show directories used
- more error checking
- check for existing wolfSSL component; prompt to purge or update
- save and optionally re-use `config.h` and `user_settings.h`
- optionally target an alternate ESP-IDF path (useful for VisualGDB)
- offer tips and reminders upon completion

# Testing

Tested on Windows 10 with both ESP-IDF command prompt and stand-alone DOS prompt (e.g. for VisualGDB)

# Checklist

 - [ ] added tests
 - [ ] updated/added doxygen
 - [ ] updated appropriate READMEs
 - [ ] Updated manual and documentation

cc: @dgarske
2022-03-28 11:54:50 -07:00
5b0735cdb4 Fixes for async ECC broke in PR #4982. 2022-03-28 11:29:33 -07:00
52902f1d37 IoTSafe: Add SP_RSA to user_settings.h template. 2022-03-28 10:25:05 -07:00
6dc86e7df1 Add support for --enable-ffmpeg 2022-03-28 12:47:19 +02:00
be938ed197 IoTSafe Workarounds: Address code review feedback. 2022-03-25 16:17:53 -07:00
25d5a624d2 Merge pull request #4975 from cconlon/smallStack
smallstack cleanup for OpenSSL Compatibility Functions
2022-03-25 17:06:59 -06:00
0ee01f08bc Merge pull request #4984 from douzzer/20220325-multi-test-cleanup
20220325 multi-test fixes
2022-03-25 15:06:34 -07:00
3af3274dcd Merge pull request #4982 from SparkiDev/sp_x64_improvements
SP ASM improvements
2022-03-25 13:04:01 -07:00
07f9ca60ac Fix for async without threading. ./configure --enable-asynccrypt --enable-all CFLAGS="-DWC_NO_ASYNC_THREADING". 2022-03-25 12:43:04 -07:00
0930086fa1 Fix for increased mcapi (used by Microchip) ctx sizes if PK callbacks is enabled due to key id/label. 2022-03-25 12:36:07 -07:00
008c8509c6 multi-test fixes: whitespace in wolfcrypt/src/random.c and wolfcrypt/test/test.c, bugprone-macro-parentheses and -Wenum-compare in WS_RETURN_CODE() (wolfssl/ssl.h), and clang-analyzer-deadcode.DeadStores in api.c. 2022-03-25 13:26:41 -05:00
04e2b6c62a Merge pull request #4983 from douzzer/20220324-gcc-12-fixes
fixups for warnings from gcc-12
2022-03-24 19:16:27 -07:00
7eb95674ee Merge pull request #4966 from dgarske/kcapi
Fixes for KCAPI AES GCM and ECC
2022-03-25 10:18:16 +10:00
fd66f6bcec SP ASM improvements
Change Karatsuba implementations for x86_64.
Fix ECC code to better handle corner cases.
Add 'lower' versions of functions wehn an input is known to be less than m.
Add mont_add/dbl/tpl/sub for P384.
Change ECC point add to be cache-attack resistant.
Change mod_exp to be cache-attack resistant.
2022-03-25 10:04:25 +10:00
14522f25ff Merge pull request #4904 from kaleb-himes/OE22_NS9210_FIX
Fix up random.h conflicts with cert 3389 releases and some NETOS issues
2022-03-24 16:07:23 -07:00
feb58a8455 Merge pull request #4956 from julek-wolfssl/bind-9.18.0
bind 9.18.0 fixes
2022-03-25 08:27:34 +10:00
12776b3772 fixups for warnings from gcc-12:
src/internal.c: use XMEMCMP(), not ==, to compare array elements (fixes conflict of 74408e3ee3 vs 617eda9d44);

fix spelling of NAMEDGROUP_LEN (was NAMEDGREOUP_LEN);

src/ssl.c: in CheckcipherList() and wolfSSL_parse_cipher_list(), use XMEMCPY(), not XSTRNCPY(), to avoid (benign) -Wstringop-truncation;

scripts/sniffer-tls13-gen.sh: fix for shellcheck SC2242 (exit 1, not -1).
2022-03-24 16:33:36 -05:00
b509e174bb Whitespace fix. 2022-03-24 10:19:28 -07:00
ceae169a34 Merge pull request #4969 from dgarske/pk_pubkey 2022-03-24 12:40:03 -04:00
624f1499f0 Merge pull request #4978 from julek-wolfssl/issue/4970
Prefer status_request_v2 over status_request when both are present
2022-03-24 08:30:12 -07:00
5a0d794e88 Merge pull request #4980 from anhu/iv_docs
Correction about AES using IV in docs
2022-03-24 08:29:55 -07:00
29c0c9bf48 Rebase fixes 2022-03-24 13:41:50 +01:00
850b8c5c3b OpenSSL compatible API
`WOLFSSL_ERROR_CODE_OPENSSL` breaks ABI compatiblity due to changing the expected return code. Let's only do this when building with the full compatibility layer.
2022-03-24 12:16:59 +01:00
88d5059c36 Jenkins fixes
`WS_RETURN_CODE` was not functioning properly in master
2022-03-24 12:16:59 +01:00
98bc8402db Refactor memory BIO
- use the `WOLFSSL_BUF_MEM` struct to resize the internal memory buffer
- add a `WOLFSSL_BIO_RESIZE_THRESHOLD` define that will be used to determine how often to shrink the internal buffer. This should cut down on the number of free/malloc calls made significantly. This should help with our inefficient 1 byte reads in `loadX509orX509REQFromPemBio`.
- implement `wolfSSL_BUF_MEM_resize` which allows bi-directional buffer size manipulation
2022-03-24 12:16:59 +01:00
ae9b01c5b8 bind 9.18.0 fixes
- return `1` from `wolfSSL_BIO_set_mem_eof_return` instead of `0` for success
- bind requires ALPN
- `OPENSSL_COMPATIBLE_DEFAULT` defined for bind
- `WOLFSSL_ERROR_CODE_OPENSSL` defined when using compatibility layer
- return `bio->eof` on no pending data to read in memory BIO (defaults to `WOLFSSL_BIO_ERROR`)
- `flags` is no longer an input parameter in `wolfSSL_ERR_get_error_line_data`
- allow lazy parameter loading in `wolfSSL_DH_set0_key`
- implement reference counter in `WOLFSSL_EC_KEY`
- load serial number from `x509->serialNumber` if `x509->serial` is empty
2022-03-24 12:16:59 +01:00
f71a85d5f9 Merge pull request #4979 from dgarske/sniffer_tidy 2022-03-23 15:13:20 -04:00
1bc71da1df Correction about AES using IV in docs 2022-03-23 13:35:13 -04:00
6e550c8d75 Fix for KCAPI ECC KeyGen. Disable ECC consistency checks with KCAPI. Allow public AddSignature (used to be public). Fix KCAPI ECC SharedSecret output size. 2022-03-23 09:37:50 -07:00
8bafa7f601 Fix for KCAPI ECC sign (was not returning the signature, since ret always 0). 2022-03-23 09:37:50 -07:00
c9e3094cb0 Fixes for KCAPI ECC verify. Cleanup of the pubkey_raw. Fix KCAPI AES possible used uninitialized. 2022-03-23 09:37:50 -07:00
8d695f97c9 Fix for KCAPI KcapiEcc_LoadKey parameter to kcapi_kpp_keygen. Added option to release handle on load. Fixes for KCAPI sign output length. Added additional argument checking. 2022-03-23 09:37:50 -07:00
318350f63b Fix for ecc_check_privkey_gen with KCAPI. Fix KCAPI ECDSA to ensure we don't leak handle for multiple sign/verify calls. 2022-03-23 09:37:50 -07:00
9f2dc408a0 Fixes for KCAPI AES GCM. Add guards for algorithm macros on KCAPI. 2022-03-23 09:37:50 -07:00
1b0e5f4806 Allow disabling DRBG with KCAPI. Add KCAPI /dev/hwrng support. 2022-03-23 09:37:50 -07:00
5fe6f1c875 For KCAPI do not force enable ECC curves, set K or seed callback, disable AES GCM tests with non standard IV. 2022-03-23 09:37:50 -07:00
b04954dc98 Merge pull request #4977 from SparkiDev/ssl_move_x509_store
ssl.c: move out X509 store APIs to new file
2022-03-23 09:36:33 -07:00
f129c32273 Fixes for whitespace, script bug and bit-field type. 2022-03-23 09:31:04 -07:00
b6e590836d initialize ENABLE_FIPS 2022-03-23 10:29:59 -04:00
4412496adb Prefer status_request_v2 over status_request when both are present
Reported in https://github.com/wolfSSL/wolfssl/issues/4970
2022-03-23 11:20:22 +01:00
90f53aed34 ssl.c: move out X509 store APIs to new file 2022-03-23 13:59:54 +10:00
3dd2219548 Don't over-write ENABLED_FIPS with no if user didn't specify anything. 2022-03-22 20:33:27 -04:00
d864fc9a3f Merge pull request #4972 from julek-wolfssl/asn-time-tz-diff
`mktime` may return a negative due to timezones around the unix epoch
2022-03-22 14:03:59 -05:00
cf0e4a0e3d Merge pull request #4976 from anhu/kill_tabs
Get rid of tabs I added previously.
2022-03-22 11:35:00 -07:00
906ea4ad03 smallstack reduction for wolfSSL_EC_POINT_invert 2022-03-22 10:00:17 -06:00
64a309e245 smallstack reduction for wolfSSL_ASN1_INTEGER_to_BN 2022-03-22 10:00:17 -06:00
ddc1899d48 smallstack reduction for wolfSSL_EC_POINT_get_affine_coordinates_GFp 2022-03-22 10:00:17 -06:00
94e1b87ae0 smallstack reduction for wolfSSL_X509_set_ext, wolfSSL_EC_POINT_mul, wolfSSL_ECDSA_do_sign, wolfSSL_i2d_X509_NAME, wolfSSL_X509_REQ_sign 2022-03-22 10:00:13 -06:00
c41bef6486 Get rid of tabs I added previously. 2022-03-22 11:56:15 -04:00
aa38d99538 Fix for TLS PK callback issue with Ed25519/Ed448 and public key not being set. 2022-03-22 08:33:54 -07:00
c377a709e1 Merge pull request #4953 from cconlon/apiVersionDiff
More checks on OPENSSL_VERSION_NUMBER for API prototype differences
2022-03-21 16:59:06 -06:00
2babac6cb5 Merge pull request #4875 from dgarske/sniffer_async 2022-03-21 16:47:23 -04:00
210eb6283c smallstack reduction for wc_ecc_import_x963_ex, mp_jacobi 2022-03-21 14:43:43 -06:00
851ff9e661 smallstack reduction for PrintPubKeyRSA, PrintPubKeyDSA, PrintPubKeyDH 2022-03-21 14:43:43 -06:00
339e44bd87 smallstack reduction for wc_ecc_import_point_der_ex() 2022-03-21 14:43:43 -06:00
59665a44b5 Fixes for allowing server to have a public key set when using external key with PK callbacks. 2022-03-21 13:14:24 -07:00
29c120356e Sniffer asynchronous support.
* Adds stateful handling of DH shared secret computation in `SetupKeys`.
* Improved the decrypt handling to use internal functions and avoid generating alerts on failures.
* Fix for sniffer resume due to missing `sessionIDSz` broken in #4807.
* Fix sniffer test cases to split resume (session_ticket) tests.
* Add `snifftest` list of build features so test script can gate running resume test.
2022-03-21 12:05:08 -07:00
af70edb99d Strip trailing zeroes from cert buffer when using IOTSAFE_NO_GETDATA. 2022-03-21 10:53:36 -07:00
4951646c91 touch up class name and function comments 2022-03-21 10:56:09 -06:00
fb3d38c3e8 add example C# PSK client 2022-03-21 10:19:45 -06:00
c213c725d7 Merge pull request #4971 from SparkiDev/fp_div2_mod_ct_oob
TFM fp_div_2_ct: rework to avoid overflow
2022-03-21 09:11:41 -07:00
8bf14ba1d3 Merge pull request #4957 from JacobBarthelmeh/Compatibility-Layer
alter return value and add error string
2022-03-21 09:10:04 -07:00
08d6474878 Merge pull request #4954 from SparkiDev/rsa_fermat
RSA: check for small difference between p and q
2022-03-21 09:09:38 -07:00
b90df0a6aa Merge pull request #4951 from ejohnstown/wolfrand
wolfRand for AMD
2022-03-21 09:09:19 -07:00
d7037da0b5 mktime may return a negative due to timezones around the unix epoch 2022-03-21 17:07:13 +01:00
9763030675 Merge pull request #4845 from cconlon/pkcs7compat 2022-03-21 15:26:37 +01:00
8dbd8b0ad6 RSA: check for small difference between p and q 2022-03-21 10:58:14 +10:00
aa14607a6f TFM fp_div_2_ct: rework to avoid overflow
Don't set the overflow word. Instead integrate the div by 2 into the
function so that the overflow word doesn't need to be stored.
2022-03-21 10:43:06 +10:00
2f52d3cd20 Merge pull request #4965 from dgarske/aes_win_clang
Fixes for Windows AESNI with clang
2022-03-21 08:24:21 +10:00
dcaa218ed8 Merge pull request #4927 from cconlon/upRef 2022-03-18 18:10:36 -07:00
7ea6b73c7b Merge pull request #4928 from cconlon/compatCleanups 2022-03-18 16:23:56 -07:00
2637e5e361 Merge pull request #4926 from cconlon/namePrintRFC5523 2022-03-18 15:53:07 -07:00
c491a6c829 EVP_PKEY_copy_parameters: correctly mark inner struct owned 2022-03-18 16:37:45 -06:00
a79daa5ea8 Merge pull request #4959 from haydenroche5/asn1_time_diff_bug
Fix bug in wolfSSL_ASN1_TIME_diff.
2022-03-18 14:28:23 -07:00
582f0d82e4 address review feedback for PKCS7 compat additions 2022-03-18 12:07:44 -06:00
bfee3dffc6 Merge pull request #4967 from dgarske/pubkey_size
Fix for `wc_EccPublicKeyToDer` incorrectly requiring too much buffer
2022-03-18 09:22:52 -06:00
bcce015496 Merge pull request #4964 from julek-wolfssl/wolfSSL_get_session-docs
Update `wolfSSL_get_session` docs
2022-03-18 06:51:27 -07:00
bb27fa4555 Fix for wc_EccPublicKeyToDer incorrectly requiring too much buffer. Merge error included old ASN code and incorrectly excluded ASN template. ZD13904. 2022-03-17 18:51:37 -07:00
ef66a12a24 Merge pull request #4961 from dgarske/cust_fixups
Various portability improvements (Time, DTLS epoch size, IV alloc)
2022-03-18 11:38:57 +10:00
f117308135 Merge pull request #4921 from dgarske/private_keyid
Added private key id/label support - improve PK callback public key use
2022-03-18 11:36:28 +10:00
b546b2a5ec Improve logic around private key id/label. Adds WOLF_PRIVATE_KEY_ID. 2022-03-17 14:48:30 -07:00
f954aef973 Fixes for Windows AESNI with clang. Improve 32-bit support. 2022-03-17 14:05:24 -07:00
ae25a48509 Improve the build message to not always allocate the IV (16 byte) (use fixed buffer if <= 16 bytes). 2022-03-17 14:01:57 -07:00
3fba5d17c3 Various portability improvements:
* Change DTLS epoch size word16.
* Allow override of the `RECORD_SIZE` and `STATIC_BUFFER_LEN`.
* Remove endianness force from game build.
* Add `gmtime_s` option.
* Fix for macro conflict with `MAX_KEY_SIZE`.
* Expose functions `wolfSSL_X509_notBefore`, `wolfSSL_X509_notAfter`, `wolfSSL_X509_version` without `OPENSSL_EXTRA`.
2022-03-17 14:00:55 -07:00
54477d1bea improvements around keystore key update 2022-03-17 12:04:52 -06:00
40c79b1134 add macro guards to handle build with QNX CAAM 2022-03-17 12:04:52 -06:00
9bf2962852 default to strict NVM operations with key generation 2022-03-17 12:04:52 -06:00
090932b65c FIPS benchmark of cmac and ecb 2022-03-17 12:04:52 -06:00
55b42dd85a Add SECO use and expand cryptodev 2022-03-17 12:04:52 -06:00
1fd090d094 Update wolfSSL_get_session docs
Recommend using `wolfSSL_get1_session` and `NO_SESSION_CACHE_REF` for session resumption purposes. `wolfSSL_get_session` should not be used unless to inspect the current session object.
2022-03-17 12:56:28 +01:00
f76105a93b TLS 1.3 PSK: multiple ids for a cipher suite
When WOLFSSL_PSK_MULTI_ID_PER_CS is defined, multiple identities can be
returned for a cipher suite.
The first byte of the identity is the count of identites that have been
seen so far for the cipher suite.
2022-03-17 09:31:25 +10:00
aa8e5a29d4 Merge pull request #4947 from cconlon/compatSmallStack
Stack/smallstack cleanup for OpenSSL compatibility functions
2022-03-15 16:47:23 -07:00
a52539c489 Merge pull request #4958 from TakayukiMatsuo/example 2022-03-15 17:39:07 -06:00
5b268c0852 Merge pull request #4960 from anhu/stm32_pq_bench
Add Post-quantum KEM benchmark for STM32
2022-03-15 16:36:08 -07:00
f80faebfe5 wolfRand for AMD
1. Add configure option to enable AMD's RDSEED.
2. Add seed parameters when building specifically for AMD using RDSEED.
3. Update the wolfCrypt test to play nice with the larger seed size.
2022-03-15 15:20:08 -07:00
fbfb1fee91 Add Post-quantum KEM benchmark for STM32 2022-03-15 14:49:40 -04:00
6e6aa5b0c1 Fix bug in wolfSSL_ASN1_TIME_diff.
This function should not error out if one of the passed in times is the Unix
epoch. This amounts to erroring out when the XMKTIME returns < 0, rather than
<= 0.
2022-03-15 10:52:05 -07:00
d0e83be596 alter return value and add error string 2022-03-15 10:26:59 -07:00
365a4de154 Fix settings and removed warnings 2022-03-16 02:12:45 +09:00
d531e21f34 Merge pull request #4946 from dgarske/async_earlydata
Fixes for TLS v1.3 early data with async
2022-03-15 12:12:09 -05:00
9c29102c43 Merge pull request #4948 from SparkiDev/tls12_pa_failsafe
TLS: add peer authentication failsafe for TLS 1.2 and below
2022-03-15 09:42:56 -07:00
6762cd90da add tests for PKCS7_sign(), PKCS7_final(), SMIME_write_PKCS7() 2022-03-15 10:21:22 -06:00
ce514e6fc5 add PKCS7_sign, PKCS7_final, SMIME_write_PKCS7. add signer cert verify support to PKCS7_verify, support for PKCS7_TEXT, PKCS7_DETACHED, PKCS7_STREAM 2022-03-15 10:21:22 -06:00
ba4f3379ba remove unimplemented wc_MIME_* prototypes in asn.h 2022-03-15 10:21:22 -06:00
a7d5e6400d add support for PKCS7_TEXT flag to PKCS7_verify() 2022-03-15 10:21:22 -06:00
2febed01a5 Merge pull request #4949 from SparkiDev/ssl_move_conf
ssl.c: move TXT and CONF APIs out into conf.c
2022-03-15 09:02:42 -07:00
f7c5c9f713 extra checks for OPENSSL_VERSION_NUMBER for API prototype differences 2022-03-15 09:41:51 -06:00
7c63dd6245 smallstack reduction for wolfSSL_set_accept_state() 2022-03-15 09:40:51 -06:00
062003916c stack/smallstack reduction for wolfssl_x509_make_der(), d2iGenericKey(), PrintPubKeyEC(), wolfSSL_EC_POINT_add() 2022-03-15 09:40:48 -06:00
343e8bccdd ssl.c: move TXT and CONF APIs out into conf.c 2022-03-15 12:09:24 +10:00
4ec49d2189 Merge pull request #4943 from SparkiDev/sp_arm64_perf_1
SP ASM performance improvements
2022-03-14 18:40:51 -07:00
e3276ca683 Merge pull request #4939 from SparkiDev/aes_gcm_align
AES-GCM: stack alignment issues
2022-03-14 18:37:11 -07:00
9ed061cc96 TLS: add peer authentication failsafe for TLS 1.2 and below
Tightened the TLS 1.3 failsafe checks too.
2022-03-15 08:51:44 +10:00
eeb7f72a07 AES-GCM: stack alignment issues
Don't expect stack to be aligned.
vmovdqu is no longer slower than vmovdqa.
2022-03-15 08:49:43 +10:00
b3319bd952 Undo the logic around enable sha as its enabled by default already. 2022-03-14 16:29:13 -04:00
34e491f39f Merge pull request #4950 from SparkiDev/regression_fixes_3
TLS 1.3 script test: wait for server to write file
2022-03-14 13:24:06 -07:00
821e293ed4 Fix to add test where needed. 2022-03-14 15:54:39 -04:00
b3e28fab67 Make the code simpler. 2022-03-14 13:51:05 -04:00
ea500bd1c8 --enable-engine=fips-v2,fips-readyetc., etc. 2022-03-14 13:51:05 -04:00
07ee2bcecf Created new --enable-engine and --enable-engine-witout-fips flags 2022-03-14 13:51:05 -04:00
2c1ecacbfc TLS 1.3 script test: wait for server to write file
Also fixes for:
./configure --enable-psk --disable-rsa --disable-ecc --disable-dh
C_EXTRA_FLAGS=-DWOLFSSL_STATIC_PSK
./configure --disable-shared --enable-curve448 --enable-ed448
--disable-rsa --disable-dh --enable-tls13 --disable-ecc --enable-certgen
--enable-keygen
2022-03-14 14:42:47 +10:00
4966eb7897 Merge pull request #4944 from douzzer/20220310-asn-template-EncodeExtensions-overrun
wolfcrypt/src/asn.c: fix buffer underrun in EncodeExtensions() and leak in ParseCRL_Extensions()
2022-03-13 21:21:07 -05:00
cdb45b12c5 Merge pull request #4884 from haydenroche5/i2d_x509_name_fix
Improve wolfSSL_i2d_X509_name.
2022-03-14 11:57:07 +10:00
20562b3f78 DecodeNameConstraints (ASN Template): free ASNGetData 2022-03-14 09:14:19 +10:00
a816f329cc Merge pull request #4856 from anhu/stm32u5
Enable support for STM32U585 and PQC for STM32
2022-03-11 14:49:46 -08:00
fb0c9b2a66 ssl.c: use InitHandshakeHashes(), not FreeHandshakeHashes(), to reset ssl->hsHashes. 2022-03-11 16:26:24 -06:00
dd8fb41f66 Fixes for TLS v1.3 early data with async. 2022-03-11 14:03:46 -08:00
830431ccdf scripts/tls13.test: fix whitespace. 2022-03-11 13:54:50 -06:00
82ab7bf32c ssl.c: fix hash state memory leaks in wolfSSL_clear() and wolfSSL_TicketKeyCb(). 2022-03-11 13:40:01 -06:00
8cba961bac Comment fixups, bad braces, and stray &. 2022-03-11 12:14:02 -05:00
9fff321e3e address PR review feedback on EVP_PKEY changes 2022-03-11 10:11:02 -07:00
82c6f58eb0 define BIO_CTRL_SET, BIO_CTRL_GET 2022-03-11 09:53:56 -07:00
6e6108bb98 remove duplicate BIO_CLOSE/BIO_NOCLOSE definition, already in openssl/bio.h 2022-03-11 09:53:56 -07:00
238072c84d map BIO_s_accept to BIO_s_socket for basic use 2022-03-11 09:53:56 -07:00
2639c5e268 X509V3_set_ctx arg check fix, debug log cleanup 2022-03-11 09:53:51 -07:00
385ece92d8 ECCSI and SAKKE: fix smallstackcache memory leaks in library, and blue-moon undefined behavior bugs in test.c eccsi_test(() and sakke_test(). 2022-03-11 10:06:18 -06:00
fc92584bd2 Address the one that was missed 2022-03-11 08:36:36 -07:00
64953299cf scripts/tls13.test: retries (up to 10) for early data scenarios, to mitigate race noted in #4918 . 2022-03-11 08:18:14 -06:00
7602eef98f src/ssl.c: use strlcpy(), not strncpy(), to make string_fortified happy (else "error: ‘__builtin_strncpy’ specified bound 46 equals destination size"). 2022-03-11 08:15:44 -06:00
b2ae7f4230 wolfssl/openssl/asn1.h: in ASN1_SIMPLE(), use OFFSETOF() macro. 2022-03-11 07:59:08 -06:00
c3eab0dcdd Fixes from sanitizer build
Fix OID index in SetNameRdnItems for multi attributes.
Stop warning about strncpy to small.
Fix casting in ASN1_SIMPLE to use consistent type.
2022-03-11 14:27:50 +10:00
cf030de48a Merge pull request #4930 from SparkiDev/tfm_alloc_fails
TFM: handle more alloc failure cases gracefully
2022-03-10 15:42:21 -08:00
3ea5e56c26 SP ASM performance improvements
Mostly improving Aarch64 assembly.
Change Karatsuba implementations.
Specialised code for exponentiating to 0x10001 for RSA.
2022-03-11 08:42:46 +10:00
570daa6a7f Enable support for STM32U585 and PQ on M4 2022-03-10 14:19:01 -05:00
0eef90f951 Fix for ZD13795 and also remove all-caps parameter 2022-03-10 11:40:32 -07:00
c78bfa4db8 scripts/tls13.test: when $early_data = yes, print the matching line counts. 2022-03-10 11:56:20 -06:00
227804f034 wolfcrypt/src/asn.c: in ParseCRL_Extensions(), add missing FREE_ASNGETDATA(). 2022-03-10 11:45:37 -06:00
170b125b39 wolfcrypt/src/asn.c: fix buffer underrun in EncodeExtensions(), due to faulty iteration limit calculation, when smallstack build. 2022-03-10 09:38:19 -06:00
6b7f0d4ee7 Merge pull request #4905 from anhu/custom_ext_parse
Injection and parsing of custom extensions in X.509 certificates.
2022-03-10 10:39:05 +10:00
b30ada1608 Merge pull request #4940 from ejohnstown/wolfrand
Fix wolfRand Build
2022-03-09 15:42:19 -08:00
47895fe78d Merge pull request #4942 from dgarske/sp_math_opensslextra
Fixes to support building opensslextra with SP math
2022-03-10 08:53:21 +10:00
b4df909df0 Merge pull request #4934 from haydenroche5/x509_v_err_sync
Sync up X509_V_ERR codes with OpenSSL.
2022-03-10 08:37:10 +10:00
98f733767b Use MAX_OID_SZ 2022-03-09 17:20:50 -05:00
e1da313b91 EVP_PKEY_copy_parameters: add support for EVP_PKEY_DH 2022-03-09 14:34:09 -07:00
141cf822f2 Merge pull request #4941 from douzzer/20220309-script-cleanup
20220309 script cleanup
2022-03-09 13:30:50 -08:00
bcfe8bf2e2 Merge pull request #4933 from haydenroche5/x509_set_ext_ext_key_usage 2022-03-09 13:22:49 -07:00
3a62857dbd Fixes to support building opensslextra with SP math. Disables some of the compatibility layer BN and ECC point handling. 2022-03-09 11:53:56 -08:00
b043225dbd Fixes inspired by review by SparkiDev. 2022-03-09 13:39:53 -05:00
d6fb454063 Fix wolfRand Build
1. Remove the v3 FIPS build from configure and automake. This was for
   the old FIPS Ready build, which is now fixed to the certificate 3389
   configuration.
2. Remove AES-GCM, PKCS12, and SHA-3 from wolfRand build. They were
   getting reenabled later in the configure.
2022-03-09 10:35:39 -08:00
abfc788389 script cleanup: use #!/bin/bash on all scripts that use "echo -e" (/bin/sh is sometimes a non-Bourne/non-POSIX shell, e.g. dash/ash, with no support for "echo -e"); fix whitespace. 2022-03-09 12:28:22 -06:00
67cc8ed482 tests/api.c: fix test_wolfSSL_BIO_Qt_usecase() "function declaration isn’t a prototype". 2022-03-09 12:27:19 -06:00
4ff82e22e6 Merge pull request #4938 from douzzer/20220308-shellcheck-errors
fixes for shell script errors detected by shellcheck --severity=error.
2022-03-08 12:51:11 -08:00
70857f7b3c Merge pull request #4923 from miyazakh/set_bio
Set bio read/write flag obviously
2022-03-08 13:08:33 -07:00
c256d8ca92 Merge pull request #4936 from julek-wolfssl/no-force-ecc-ca
Don't force a ECC CA when a custom CA is passed with `-A`
2022-03-08 10:58:35 -08:00
c9a7393923 fixes for shell script errors detected by shellcheck --severity=error. 2022-03-08 12:51:48 -06:00
a4229c6cf8 Merge pull request #4932 from SparkiDev/tls_hmac_fix
TLS HMAC: fix number of blocks to not process
2022-03-08 10:06:11 -08:00
4a912f29d1 Merge pull request #4843 from tmael/sp_diab
Support (no)inline with Wind River Diab compiler
2022-03-08 10:00:16 -08:00
3c64731c4f Don't force a ECC CA when a custom CA is passed with -A
The following config would fail `../configure --enable-opensslall CFLAGS="-DOPENSSL_COMPATIBLE_DEFAULTS" && make -j check`. This is because `test-fails.conf` `ECC no signer error` test expects a failure while the ECC CA was being added as a trusted cert due to  `OPENSSL_COMPATIBLE_DEFAULTS`.
2022-03-08 15:02:43 +01:00
031c97f835 Merge pull request #4931 from douzzer/20220307-early-data-and-c99-fixes
enable-earlydata vs enable-fips/enable-asynccrypt
2022-03-08 07:34:58 -06:00
f71be0546c addressed review comments 2022-03-08 18:20:30 +09:00
31736307fd Sync up X509_V_ERR codes with OpenSSL.
We defined these codes to values that didn't match those in OpenSSL. This is a
problem if a user is porting code from OpenSSL to wolfSSL that uses hardcoded
versions of these values. While the user's code should be fixed to not use
hardcoded values, we can make the port smoother by syncing the values up.
2022-03-07 15:58:46 -08:00
2cbe28fcf9 Sequences are constructed 2022-03-07 18:50:38 -05:00
872ed28882 Merge pull request #4925 from kareem-wolfssl/nullSslMethod
Add SSL_R_NULL_SSL_METHOD_PASSED.
2022-03-07 15:36:56 -08:00
f49983b3b3 EVP_PKEY_keygen: add DH keygen support, fixes to EVP_PKEY_set1/get1_DH 2022-03-07 16:32:23 -07:00
939ce713df EVP_PKEY_derive: set internal DH key if needed 2022-03-07 16:32:22 -07:00
f3f0d49fce EVP_PKEY_CTX_new: set curve NID from pkey if available 2022-03-07 16:32:22 -07:00
85f85cc76a add DH_up_ref() and unit test 2022-03-07 16:32:22 -07:00
8e0f5f9289 EVP_PKEY_get1/set1_EC_KEY: modify for EC_KEY_up_ref support 2022-03-07 16:31:09 -07:00
76014260f6 add EC_KEY_up_ref() and unit test 2022-03-07 16:31:09 -07:00
9b808bde20 Fixes for building with HAVE_EX_DATA no compat layer. 2022-03-07 17:20:58 -06:00
39d975a3c3 Add extended key usage support to wolfSSL_X509_set_ext. 2022-03-07 15:20:01 -08:00
0231304607 fixes for make check with --enable-all (now including --enable-earlydata) with fips or asynccrypt:
in scripts/tls13.test, use fips-compatible server-side cipher suite for "TLS v1.3 cipher suite mismatch" test, and modernize some syntax;

in configure.ac, omit earlydata from enable-all when asynccrypt, pending fix;

also in configure.ac, fix AC_CHECK_DECLS()-overriding-AC_CHECK_FUNCS() kludge, to fix CPPFLAGS=-std=c99 builds.
2022-03-07 17:19:31 -06:00
0a91d42f2c TLS HMAC: fix number of blocks to not process
Change made to line for static analysis.
Change was made incorrectly due to bracketting.
This fixes it.
2022-03-08 08:10:52 +10:00
a9cc1ca877 Merge pull request #4924 from dgarske/coexist_fixes 2022-03-07 13:00:22 -08:00
d77d9b93dc This fixes a make check error.
The flags activated code that didn't account for the new oid encoding. This
code fixes that.
2022-03-07 15:47:47 -05:00
0e0ac14bbf Merge pull request #4901 from SparkiDev/kcapi_ecdh_fixes
Fixes for KCAPI ECDH/DH and page alignment
2022-03-07 11:01:16 -08:00
e7041d2315 Merge pull request #4929 from SparkiDev/siphash_clang
SipHash: Replace gcc specific ASM instruction with generic
2022-03-07 10:34:13 -08:00
3b4ba669d4 Merge pull request #4922 from dgarske/async_disable_fixes
Fixes for async disables around the DevCopy calls
2022-03-07 13:51:09 +10:00
1ca35f6cca TFM: handle more alloc failure cases gracefully 2022-03-07 13:20:39 +10:00
d5989dc15e SipHash: Replace gcc specific ASM instruction with generic
clang would not compile movxzb.
Replaced with movzbq.
2022-03-07 08:49:28 +10:00
a68261cd82 Merge pull request #4757 from kareem-wolfssl/xstatstruct
Add separate "struct stat" definition XSTAT_TYPE to make overriding XSTAT easier.
2022-03-07 08:32:05 +10:00
7006efe97f Merge pull request #4861 from JacobBarthelmeh/ECC
Deterministic ECDSA: fix for larger curve sizes
2022-03-07 08:26:35 +10:00
84beb5ed7b Merge pull request #4918 from miyazakh/enableall_earlydata
enable early data when specifying `--enable-all` option
2022-03-07 08:05:36 +10:00
6bc3b7fc9d addressed jenkins failure 2022-03-06 07:41:37 +09:00
a572c19268 set bio flag obviously
fix nightly Qt test
2022-03-06 07:41:36 +09:00
9be0633ce3 Merge pull request #4824 from dgarske/fips_ready_user
User settings template for FIPS v5 ready
2022-03-05 07:52:03 -06:00
2fc47fedee Merge pull request #4900 from miyazakh/esp_waituntil
Fix wait-until-done in rsa hw primitive acceleration of ESP-IDF port
2022-03-04 17:32:06 -07:00
930a3d85e1 add support to X509_NAME_print_ex() for RFC5523 basic escape 2022-03-04 17:19:33 -07:00
0c3b9c733f Fixes for KCAPI ECDH/DH and page alignment. ZD 13763 2022-03-04 15:06:16 -08:00
f162d7f530 Add SSL_R_NULL_SSL_METHOD_PASSED. 2022-03-04 15:11:09 -07:00
719ed213d5 Add separate "struct stat" definition XSTAT_TYPE to make overriding XSTAT easier. 2022-03-04 14:54:56 -07:00
0a1c052c40 doxygen for wc_SetCustomExtension() 2022-03-04 16:24:27 -05:00
e6189a638c IOTSafe workarounds: Allow reading files with no GetSize command available, allow sign command response with no padding. 2022-03-04 14:03:47 -07:00
806cd4fbba doxygen for myUnknownExtCallback() 2022-03-04 15:32:11 -05:00
3839b0e675 Fixes for building wolfSSL along side openssl. 2022-03-04 12:06:24 -08:00
ce8ef8f7c6 Merge pull request #4913 from kareem-wolfssl/makeClean
Allow disabling forced 'make clean' at the end of ./configure.
2022-03-04 12:02:08 -08:00
e1829e614d Merge pull request #4820 from haydenroche5/evp_pkey_paramgen
Add wolfSSL_EVP_PKEY_paramgen to the compatibility layer.
2022-03-04 11:49:21 -07:00
a4a4bdc20f fix typo, add macro guard, remove dead code path 2022-03-04 10:49:11 -07:00
90355df4b0 disable early data for --enable-distro
addressed jenkins failure
2022-03-04 17:00:29 +09:00
e91f0f173b Fixes for async disables around the DevCopy calls. ZD13824 2022-03-03 16:33:18 -08:00
09e7b7150f Allow overriding make command used for make clean with make. 2022-03-03 15:51:26 -07:00
9ec30f02a6 Merge pull request #4898 from kaleb-himes/140-2-ready 2022-03-03 14:43:02 -08:00
3ad94c63f5 Pass the tests! 2022-03-03 17:02:26 -05:00
7ec61dfe05 Make jenkins happy 2022-03-03 15:44:00 -05:00
0e8066dda0 Fix typo 2022-03-03 11:45:42 -07:00
d1212f9247 add P521 test case and fix for k generation 2022-03-03 10:44:24 -07:00
2567cd5e5a Merge pull request #4912 from julek-wolfssl/ZD13742
Check `input` size in `DecodeNsCertType`
2022-03-03 08:22:49 -08:00
3a5f78b55a Merge pull request #4919 from julek-wolfssl/ZD13737
Reported in ZD13737
2022-03-03 08:22:11 -08:00
949f8b5be1 Revert back to word16 API. 2022-03-03 10:41:05 -05:00
63e4ba5854 Merge pull request #4906 from julek-wolfssl/ZD13606-master
Fix issues reported in ZD13606
2022-03-03 21:27:22 +10:00
85fc2bb7fa Make old less secure TimingPadVerify implementation available
For customers that don't need full side channel security.
2022-03-03 21:17:25 +10:00
bdb7399398 Reported in ZD13737
Implement `wolfSSL_BIO_eof` support for most available BIO's
2022-03-03 10:25:09 +01:00
c7c3ee00bb Address code review
- Use functions instead of accessing `BIO` members
- Add `wolfSSL_BIO_method_type`
2022-03-03 10:09:41 +01:00
b45bbdc078 enable early data when enabled all 2022-03-03 16:36:03 +09:00
dad2332a95 Merge pull request #4917 from kaleb-himes/TIRTOS_KDF_ADD
Add the new kdf.c file to the TIRTOS build
2022-03-02 17:02:47 -08:00
56de8cd622 add check on hash size passed in 2022-03-02 16:52:04 -07:00
a54045113a fixes from review by dgarske 2022-03-02 17:39:15 -05:00
5d0614c630 Merge pull request #4911 from SparkiDev/enc_pem_cbc_padding
ASN PemToDer: remove padding when AES_CBC encrypted
2022-03-02 14:32:45 -08:00
59970d94f5 Merge pull request #4908 from dgarske/tick_pad
Fix for padding in session tickets
2022-03-03 08:20:35 +10:00
25556dea8d Add the new kdf.c file to the TIRTOS build 2022-03-02 14:56:46 -07:00
d86122a5e7 Merge pull request #4909 from JacobBarthelmeh/PKCS12
refactor PKCS12 parse key creation
2022-03-02 12:37:06 -08:00
deea6261e9 Allow disabling forced 'make clean' at the end of ./configure. 2022-03-02 13:20:22 -07:00
0053bd3af1 Now we can inject as wellgit checkout custom_ext_parse 2022-03-02 15:16:39 -05:00
aa18209c99 free buffer since pkey struct makes its own copy 2022-03-02 09:59:21 -07:00
f846aceee2 Check input size in DecodeNsCertType 2022-03-02 17:17:17 +01:00
8b24be04e8 ASN PemToDer: remove padding when AES_CBC encrypted 2022-03-02 11:33:44 +10:00
119f2d2651 Fix for padding in session tickets. Adds padding based on WOLFSSL_GENERAL_ALIGNMENT. Increases enc_len to 32-bit. Related to PR #4887 2022-03-01 15:40:57 -08:00
d1ba82d5e5 Merge pull request #4903 from julek-wolfssl/psk-resuming-certs
OpenSSL considers PSK resuming
2022-03-02 08:57:40 +10:00
b03233a35e handle free'ing up items in fail case 2022-03-01 15:24:53 -07:00
c3e7ff0e61 addressed code review 2022-03-02 07:09:33 +09:00
45ff8af026 refactor PKCS12 parse key creation 2022-03-01 14:49:59 -07:00
b21036947c Merge pull request #4894 from SparkiDev/sp_p521_hashlen_fix
SP P521: hash len needs special attention when 521 bits
2022-03-01 12:04:51 -08:00
71056f6591 Merge pull request #4902 from SparkiDev/tlsx_usc_leak
TLSX: supported groups in temporary not always freed
2022-03-01 12:04:35 -08:00
a104cf887e Ticket failure should result in a regular handshake 2022-03-01 10:34:43 +01:00
645f385031 Fix BioReceive for closed connection
The pending check was forcing a `WOLFSSL_CBIO_ERR_WANT_WRITE` return even though the underlying socket was closed and `WOLFSSL_BIO_FLAG_READ|WOLFSSL_BIO_FLAG_RETRY` was not set. The `wolfSSL_BIO_ctrl_pending(ssl->biord) == 0` is old and I can't find a reason to keep checking it. I left it just in the case where there is output data pending.
2022-03-01 10:34:20 +01:00
5aef687414 OpenSSL considers PSK resuming
- `SSL_VERIFY_FAIL_IF_NO_PEER_CERT` check passes on a TLS 1.3 PSK connection that isn't a ticket
2022-03-01 10:09:24 +01:00
605d701113 SP P521: hash len needs special attention when 521 bits
Need to right shift number down when hash is more than 521 bits.
Previously handled at a byte level and now at bit level.
Always return err from sp_*_ecc_mulmod_add_only_*().
When ECC add and double points are public and only have SP
implementation, check that the point ordinates are the right size.
2022-03-01 09:56:22 +10:00
1aff4399d1 Merge pull request #4899 from dgarske/kcapi
Improvements to KCAPI support
2022-03-01 08:52:55 +10:00
cb95aed41b Parsing of custom extensions in X.509 certificates. 2022-02-28 16:35:19 -05:00
9644a04db2 Peer review fix. 2022-02-28 11:32:12 -08:00
ac7bd0aae8 Fix up random.h conflicts with cert 3389 releases and some NETOS issues 2022-02-28 12:09:50 -07:00
c22282a8aa Merge pull request #4864 from TakayukiMatsuo/rsk65n 2022-02-28 09:12:24 -07:00
92bd5a4076 Merge pull request #4891 from dgarske/multi_test 2022-02-28 15:28:39 +01:00
1cb7342f61 Merge pull request #4895 from SparkiDev/benchmark_threaded
Benchmark: support multi-threaded testing
2022-02-27 21:41:07 -08:00
350881b1bb TLSX: supported groups in temporary not always freed
Fix handling of errors so that temporary is always freed.
2022-02-28 11:40:58 +10:00
f3df4400d5 Merge pull request #4886 from dgarske/zd13745
Adds CSR userId support in subject name
2022-02-28 10:15:41 +10:00
4f4a509e8c fix wait until in rsa primitive 2022-02-26 09:52:14 +09:00
9bdef1577b Fixes for hmac. 2022-02-25 15:19:52 -08:00
cc2eb0ab71 KCAPI Testing fixes. 2022-02-25 15:16:55 -08:00
870ff5b352 Merge pull request #4890 from miyazakh/objinfo
fix to use EXT_KEY_USAGE_OID in object_info
2022-02-25 16:02:48 -07:00
ce6b6951d2 Fix issue with missing OID's for ASN template. 2022-02-25 14:23:01 -08:00
ae1072afad Cleanup mess of ASN_NAME_MAX. 2022-02-25 14:23:01 -08:00
a2381ba954 Adds CSR userId support in subject name. Minor build fixes for ASN template. 2022-02-25 14:22:59 -08:00
08d1e5cb60 Merge pull request #4897 from anhu/bad_macro
Correct bad macros
2022-02-25 14:18:57 -08:00
3fdb6f0a4a Only use pthreads if supported in config. 2022-02-25 13:05:04 -08:00
27c445235c Add a cert 3389 ready option 2022-02-25 13:50:06 -07:00
821fd3c898 Peer review fixes. Check idSz and add comment about session variable use. 2022-02-25 11:38:05 -08:00
1a9faa1f7e fix suggested by dgarske 2022-02-25 14:00:07 -05:00
e3e1426b91 Improve benchmark threading macros and text output. Thread protections on variables. Fixes for testing with async. 2022-02-25 10:51:19 -08:00
997a3aabc6 Correct bad macros 2022-02-25 13:19:35 -05:00
a39a1c1d87 More fixups from cppcheck and clang-tidy. 2022-02-25 10:03:17 -08:00
56adf831a3 Benchmark: support multi-threaded testing 2022-02-25 14:12:03 +10:00
5859b90ad8 Merge pull request #4841 from haydenroche5/vs_resource_file_update
Update Visual Studio resource files.
2022-02-24 15:29:46 -08:00
c33ae4c245 Improve wolfSSL_i2d_X509_NAME and wolfSSL_i2d_X509_NAME_canon.
Like other i2d functions, these functions should be able to take a NULL output
parameter and return the necessary output buffer size. This commit adds this
ability. This commit also removes some redundant code in wolfSSL_i2d_X509_NAME.
2022-02-24 14:48:52 -08:00
269ab86002 Fixes for DoClientTicket changes. 2022-02-24 14:28:50 -08:00
c2987a9ef9 Fix for IPv6 sockaddr_len set but not read. 2022-02-24 14:09:08 -08:00
6dd7a289e7 Fix for "set but not used". 2022-02-24 13:43:56 -08:00
6e24e21d5a Fix for heap pointer in wolfSSL_DupSession. 2022-02-24 12:56:39 -08:00
2b794f03c1 Fixes for multi-test pass. Breaks from PR #4807. 2022-02-24 11:48:40 -08:00
07fdca1d62 Merge pull request #4885 from SparkiDev/asn_templ_bad_name 2022-02-24 12:44:27 -05:00
86e08525cb Merge pull request #4852 from elms/fix/more_oot
automake: fix fips touch and cleanup
2022-02-24 09:04:05 -08:00
5fdc339e34 Merge pull request #4889 from SparkiDev/sp_int_iar
SP math all: IAR doesn't accept comment lines in assembly
2022-02-24 08:37:51 -08:00
de81447b2d fix to use EXT_KEY_USAGE_OID in object_info 2022-02-24 15:18:32 +09:00
3d5b933f3c SP math all: IAR doesn't accept comment lines in assembly
Replace assembly comment lines with C comment lines.
2022-02-24 16:06:31 +10:00
bb50777f1a ASN template: handle short OIDs
cert_asn1_test was constructing a BER encoding of a certificate that
didn't have all the components. It was trying to test putting in a bad
OID in the certificate name.
The original ASN.1 parsing code stopped at the bad name. ASN.1 template
code does the whole structure and then digs into the name.
A complete certificate should have always been used.
2022-02-24 15:36:56 +10:00
b13826a3a5 Merge pull request #4840 from haydenroche5/visual_studio_cleanup
Clean up Visual Studio output and intermediate directories.
2022-02-24 15:07:13 +10:00
25407e955b Update Visual Studio resource files.
- Add a resource file for the wolfSSL FIPS VS solution.
- Update copyright year in existing wolfssl.rc.
2022-02-23 16:53:26 -08:00
d1895e5679 automake: fix fips touch and cleanup
This fixes an issue with yocto that only occurs when using `devtool`
which builds out of tree.
2022-02-23 14:11:31 -08:00
51d66877f7 Add wolfSSL_EVP_PKEY_paramgen to the compatibility layer.
Currently, it only supports ECC, which is all we need it for for the OpenSplice
port we're working on. In the ECC case, all it needs to do is set the group
appropriately. The logic is very similar to `wolfSSL_EVP_PKEY_keygen`, minus
the final step of actually generating the key.
2022-02-23 13:59:15 -08:00
666cf508a2 Merge pull request #4874 from dgarske/ocsp_ipv6 2022-02-23 13:37:16 -08:00
fbc7d5a6b2 Minor textual fixes. Thanks Hayden. 2022-02-23 09:43:10 -08:00
0824a64c92 Merge pull request #4807 from julek-wolfssl/stunnel-5.61
stunnel 5.61 support
2022-02-23 09:41:51 -08:00
b84086a482 Merge pull request #4883 from SparkiDev/ssl_bio_move
BIO: move APIs out of ssl.c
2022-02-23 09:38:54 -08:00
0afc5e2cf1 Merge pull request #4881 from SparkiDev/sp_asm_shift_fix
SP asm: fix for modexp corner case
2022-02-23 09:37:25 -08:00
8623b0c089 Merge pull request #4849 from SparkiDev/sp_p521
SP: Add support for P521
2022-02-23 09:33:49 -08:00
3a34a4cd1d Merge pull request #4882 from SparkiDev/even_mod_check
RSA/DH: check for even modulus
2022-02-23 09:33:12 -08:00
2c978a96b2 Prevent possibility of an infinite retry loop and resource exhaution
Reported in ZD13606
2022-02-23 10:07:21 +01:00
fb943a2f23 Rebase and make wolfSSL_CTX_up_ref always available
`wolfSSL_CTX_up_ref` is a small and potentially useful API for users so it doesn't need to be restricted only to the compatibility layer. The reference counting mechanisms are always available anyway. This just exposes the functionality to the user.
2022-02-23 09:55:52 +01:00
d1f53055e9 Peeking can't return a WOLFSSL_ERROR_WANT_READ in compatibility mode 2022-02-23 09:47:34 +01:00
617eda9d44 Fix misc memory issues
- Make `InternalTicket` memory alignment independent
2022-02-23 09:47:34 +01:00
b402102e58 Add backwards compatibility for wolfSSL_get_session
Before this pull request, `wolfSSL_get_session` always returned a pointer to the internal session cache. The user can't tell if the underlying session hasn't changed before it calls `wolfSSL_set_session` on it. This PR adds a define `NO_SESSION_CACHE_REF` (for now only defined with `OPENSSL_COMPATIBLE_DEFAULTS`) that makes wolfSSL only return a pointer to `ssl->session`. The issue is that this makes the pointer returned non-persistent ie: it gets free'd with the `WOLFSSL` object. This commit leverages the lightweight `ClientCache` to "increase" the size of the session cache. The hash of the session ID is checked to make sure that the underlying session hasn't changed.
2022-02-23 09:47:34 +01:00
ceff401269 Fixes for Jenkins tests
- Move test to `HAVE_IO_TESTS_DEPENDENCIES`
- Implement `wolfSSL_trust_peer_cert`
- have{cipher} options weren't being set with only RSA enabled
2022-02-23 09:47:34 +01:00
91b08fb691 Allocate ssl->session separately on the heap
- Refactor session cache access into `AddSessionToCache` and `wolfSSL_GetSessionFromCache`
2022-02-23 09:47:34 +01:00
1d712d47ba Access to session cache is now atomic
- Adding and getting sessions to and from the local cache is now atomic.
  - The new internal `wolfSSL_GetSessionFromCache` requires a destination object to be supplied when retrieving from the cache so that items can be retrieved independently from the cache. For most existing calls, the destination is `ssl->session`.
  -`PREALLOC_SESSION_TICKET_LEN` defines how much memory is temporarily allocated for the ticket if it doesn't fit in the static session buffer.
2022-02-23 09:47:34 +01:00
afca455cda stunnel 5.61 support
- New/Implemented API
  - `SSL_has_pending`
  - `wolfSSL_CertManagerLoadCRLFile`
  - `wolfSSL_LoadCRLFile`
  - `wolfSSL_CTX_LoadCRLFile`
  - `wolfSSL_CTX_add_session`
- Calling chain certificate API (for example `wolfSSL_CTX_use_certificate_chain_file`) no longer requires an actual chain certificate PEM file to be passed in as input. `ProcessUserChain` error in `ProcessBuffer` is ignored if it returns that it didn't find a chain.
- Add `WOLFSSL_TICKET_HAVE_ID` macro. When defined tickets will include the original session ID that can be used to lookup the session in internal cache. This is useful for fetching information about the peer that doesn't get sent in a resumption (such as the peer's certificate chain).
  - Add `ssl->ticketSessionID` field because `ssl->session.sessionID` is used to return the "bogus" session ID sent by the client in TLS 1.3
- `OPENSSL_COMPATIBLE_DEFAULTS` changes
  - Define `WOLFSSL_TRUST_PEER_CERT` and certificates added as CA's will also be loaded as trusted peer certificates
  - Define `WOLFSSL_TLS13_MIDDLEBOX_COMPAT`
- Seperate `internalCacheOff` and `internalCacheLookupOff` options to govern session addition and lookup
- `VerifyServerSuite` now determines if RSA is available by checking for it directly and not assuming it as the default if static ECC is not available
- `WOLFSSL_SESSION` changes
  - `ssl->extSession` added to return a dynamic session when internalCacheOff is set
  - `ssl->session.refPtr` made dynamic and gets free'd in `SSL_ResourceFree`
- If `SSL_MODE_AUTO_RETRY` is set then retry should only occur during a handshake
- `WOLFSSL_TRUST_PEER_CERT` code now always uses `cert->subjectHash` for the `cm->tpTable` table row selection
- Change some error message names to line up with OpenSSL equivalents
- Run `MatchSuite` again if certificate setup callback installed and successful
- Refactor clearing `ASN_NO_PEM_HEADER` off the error queue into a macro
- `wolfSSL_get_peer_certificate` now returns a duplicated object meaning that the caller needs to free the returned object
- Allign `wolfSSL_CRYPTO_set_mem_functions` callbacks with OpenSSL API
- `wolfSSL_d2i_PKCS12_bio` now consumes the input BIO. It now supports all supported BIO's instead of only memory BIO.
- stunnel specific
  - Always return a session object even if we don't have a session in cache. This allows stunnel to save information in the session external data that will be transfered to new connections if the session is reused
  - When allocating a dynamic session, always do `wolfSSL_SESSION_set_ex_data(session, 0, (void *)(-1)`. This is to mimic the new index callback set in `SSL_SESSION_get_ex_new_index`.
- Fix comment in `wolfSSL_AES_cbc_encrypt`
- Trusted peer certificate suite tests need to have CRL disabled since we don't have the issuer certificate in the CA store if the certificates are only added as trusted peer certificates.
tested
2022-02-23 09:47:34 +01:00
2eb044dc60 SP: Add support for P521 2022-02-23 14:51:47 +10:00
d33b787993 BIO: move APIs out of ssl.c
Get configuration working: --enable-all CFLAGS=-DNO_BIO
2022-02-23 14:11:30 +10:00
b5ed5c9b99 RSA/DH: check for even modulus 2022-02-23 09:51:15 +10:00
194466c35a Peer review fixes. 2022-02-22 15:22:27 -08:00
5b6130889e SP asm: fix for modexp corner case
When exponent bit length is a multiple of the window size and the top
word has only window bits in it, then n is shifted down by an undefined
value (size of a word). The n value is not used after this.
Check for this condition and don't attempt to shift n.
2022-02-23 09:17:08 +10:00
2beb27972b OCSP IPv6 support with --enable-ipv6 or WOLFSSL_IPV6. Improve the logic around C99 and getaddrinfo. 2022-02-22 15:07:05 -08:00
fef8a57eb2 Merge pull request #4880 from julek-wolfssl/plain-alert
Detect if we are processing a plaintext alert
2022-02-22 10:11:08 -08:00
e8c9a413ca Merge pull request #4878 from SparkiDev/sp_x64_oob_write_fix_1
ECC with SP math: OOB write
2022-02-22 09:53:32 -08:00
b40226099d Merge pull request #4877 from SparkiDev/sp_x64_asm_fix_1
SP asm: fix map function to use p not point
2022-02-22 09:50:53 -08:00
d10900e124 ECC with SP math: OOB write
Don't let input points ordinates be greater than modulus in length.
2022-02-22 17:00:23 +10:00
78f116b27f SP asm: fix map function to use p not point 2022-02-22 16:33:24 +10:00
2a750acf03 Merge pull request #4873 from dgarske/async_v5.2.0
Asynchronous Release v5.2.0: TLS 1.3 HelloRetryRequest
2022-02-22 10:35:17 +10:00
250a06f759 Merge pull request #4865 from SparkiDev/sp_int_mont_red
SP int: Montgomery Reduction
2022-02-21 16:20:17 -08:00
31abc99f6f Fix for async handling of TLS v1.3 hello retry broken in #4863. 2022-02-21 14:14:20 -08:00
6a81cc976e Merge pull request #4872 from SparkiDev/tls13_empty_cert_cli
TLS 1.3: fail immediately if server sends empty certificate message
2022-02-21 14:10:40 -08:00
38d4da56ab Merge pull request #4857 from julek-wolfssl/ZD13631
Reported in ZD13631
2022-02-21 14:01:51 -08:00
d834c50c85 Merge pull request #4858 from julek-wolfssl/ZD13611
Reported in ZD13611
2022-02-21 14:01:42 -08:00
e6c07a296d Merge pull request #4866 from ejohnstown/release
Prepare for release 5.2.0
2022-02-21 09:09:58 -08:00
9263e6ead3 TLS 1.3: fail immediately if server sends empty certificate message 2022-02-21 21:34:13 +10:00
eb9220a0b5 Modify example app to work with FreeRTOS+IoT 2022-02-21 12:46:43 +09:00
ad8bf40b5e Update readme for release. 2022-02-20 13:05:04 -08:00
bb8af1cac5 Prepare for release 5.2.0
1. Update versions as appropriate.
2. Modify FreeAtomicUser() to only free the Aes data in the callback
   contexts if the contexts exist.
2022-02-18 13:55:22 -08:00
ffb4ae07df Merge pull request #4871 from wolfSSL/small-leak
Fix Small Memory Leaks
2022-02-18 13:53:56 -08:00
041d300b2b Fix Small Memory Leaks
Found with the configuration running the unit test through valgrind.

    % ./configure CFLAGS=-DNO_WOLFSSL_CIPHER_SUITE_TEST \
      --enable-all --disable-fastmath --enable-debug --disable-shared

1. ssl.c: In wolfSSL_DSA_generate_key(), we initialize (and allocate)
   all the parameters in the key (p, q, g, x, y), and then we generate a
   key, initializes (and allocates) x and y, again. mp_clear them
   first.
2. evp.c: When printing public keys, the temporary mp_int wasn't getting
   correctly freed.
3. evp.c: When printing public keys, modified the utility functions to
   return once with a do-while-0 loop.
2022-02-18 10:01:49 -08:00
4b0c8c07f4 Merge pull request #4870 from elms/fix/tls13_renegotiation_info_ext
tls13: fix not including RENEGOTIATION_INFO ext
2022-02-17 13:09:02 -08:00
208c457348 tls13: fix to not send RENEGOTIATION_INFO ext
Introduced in PR #4742 to enable sending of extension in TLS1.2
without fully supporting secure renegotiation in accordance with
RFC 5746 4.3 https://datatracker.ietf.org/doc/html/rfc5746#section-4.3
2022-02-17 11:22:17 -08:00
95ae242550 Merge pull request #4869 from wolfSSL/silabs-aes
SILABS port: fix sizeof
2022-02-17 10:45:47 -08:00
b343c2691b Merge pull request #4867 from maximevince/master
Fix WOLFSSL_NO_TLS12 for Async dev
2022-02-17 10:18:18 -08:00
4361d1bdd2 SILABS port: fix sizeof
A sizeof wasn't dereferencing a pointer using the sizeof the pointer and
not the actual struct. This is limited to setting the key for an AES
operation only when using SILABS SE2 acceleration.
2022-02-17 08:52:46 -08:00
111ae9da84 Fix WOLFSSL_NO_TLS12 for Async dev 2022-02-17 08:10:19 +01:00
c5875cfc5a Detect if we are processing a plaintext alert 2022-02-16 10:50:44 +01:00
df0b516c68 Merge pull request #4863 from SparkiDev/tls13_auth
TLS 1.3: improved checks on received message type
2022-02-15 11:33:34 -08:00
a5ce2a33eb add macro guard around test case 2022-02-15 11:58:59 -07:00
15d0dd258a Add cert test for UID name component 2022-02-15 14:05:46 +01:00
ea5785f6fd SP int: Montgomery Reduction
Improve performance for ECC curves when all bits in words are used (mask
is 0).
On 64-bit platforms, improves performance for 256 and 384 bit curves.
On 32-bit platforms, improves performance for 224, 256, 384 bit curves.
2022-02-15 17:19:57 +10:00
94c03a77f5 TLS 1.3: improved checks on received message type
pskNegotiated field added to indicate Session Ticket or PSK negotiated.

peerAuthGood field added to indicate that any require peer
authentication (certificate, if required, or PSK) have been performed.
2022-02-15 13:25:16 +10:00
9906c9c55e Merge pull request #4862 from dgarske/no_server
Fix typo for no server
2022-02-15 10:31:12 +10:00
07045083a9 Merge pull request #4859 from SparkiDev/sp_int_thumb_small
SP int: fixup ARM Thumb asm for small builds
2022-02-14 16:07:50 -08:00
6571151d17 SP int: fixup ARM Thumb asm for small builds
Small builds or arm Thumb can't use r7.
2022-02-15 08:34:21 +10:00
c992ddbfc0 Merge pull request #4853 from SparkiDev/curve448_128bit_perf
Curve448: inline Karatsuba in sqr and mul for 128-bit impl
2022-02-14 12:04:57 -08:00
16566f329e Fix typo for no server. Should be NO_WOLFSSL_SERVER. 2022-02-14 10:37:34 -08:00
ff4ee20f05 Merge pull request #4860 from SparkiDev/disable_hmac
Configure HMAC: define NO_HMAC when HMAC disabled
2022-02-14 10:08:32 -08:00
f0a0cd1078 fix for larger curve sizes with deterministic ECC sign 2022-02-14 09:55:38 -07:00
445ed2f234 Reported in ZD13631
`ssl->peerVerifyRet` wasn't being cleared when retrying with an alternative cert chain
2022-02-14 11:01:59 +01:00
f02296a4e6 Configure HMAC: define NO_HMAC when HMAC disabled 2022-02-14 17:22:10 +10:00
38653510eb Curve448: inline Karatsuba in sqr and mul for 128-bit impl 2022-02-14 09:09:57 +10:00
4e5380668c Reported in ZD13611
The `UID` name component could not be parsed if it appears in a subject or issuer name
2022-02-12 00:36:07 +01:00
40b171124f Fixes to resolve a few make check issues. 2022-02-11 15:20:25 -08:00
2fa542eb28 Merge pull request #4846 from haydenroche5/fips_mode_compat
Implement FIPS_mode and FIPS_mode_set in the compat layer.
2022-02-11 12:50:30 -08:00
88f202aa22 Merge pull request #4855 from julek-wolfssl/issue-4854
wolfSSL_get_error may return SSL_ERROR_NONE on ret <= 0
2022-02-11 09:01:16 -08:00
4f8ffc4586 wolfSSL_get_error may return SSL_ERROR_NONE on ret <= 0
Fix docs mismatch reported in https://github.com/wolfSSL/wolfssl/issues/4854
2022-02-11 12:37:12 +01:00
34b6102816 Merge pull request #4847 from douzzer/20220209_clang-Os
fixes for clang -Os on clang >= 12.0.0
2022-02-10 21:31:01 -06:00
7da3b8458a Merge pull request #4851 from miyazakh/update_RA6M3_rmunsrc 2022-02-10 18:14:09 -07:00
fbf38fff07 wolfcrypt/src/sp_int.c: fix comment around clang-12+ -Os. 2022-02-10 16:43:17 -06:00
5c9510d92e fips_check.sh: for linuxv2 add COPY_DIRECT with wolfcrypt/src/{aes_asm.S,aes_asm.asm}; for linuxv5 add wolfcrypt/src/aes_gcm_asm.S to COPY_DIRECT; fix whitespace. 2022-02-10 16:01:08 -06:00
cbc253d713 wolfcrypt/test/test.c: gate ecc_encrypt_e2e_test() on !HAVE_FIPS || FIPS_VERSION_GE(5,3). 2022-02-10 16:00:52 -06:00
c581e13380 bwrap tweaks:
in scripts/ocsp.test, don't call ping.test when $AM_BWRAPPED = yes (ping is setuid, so fails under bwrap);

in scripts/unit.test.in, don't bwrap if $AM_BWRAPPED = yes (double-bwrapping always fails);

in testsuite/testsuite.c testsuite_test(), build tempName using tempDir, and try to assign tempDir from XGETENV("TMPDIR"), fallback to hardcoded "/tmp".
2022-02-10 15:54:39 -06:00
91578df19d fixes for clang -Os on clang >= 12.0.0; fixes for bugs in blake2s. 2022-02-10 15:54:10 -06:00
562fcd3916 Implement FIPS_mode and FIPS_mode_set in the compat layer. 2022-02-10 13:14:05 -08:00
34c87b83e2 Merge pull request #4848 from SparkiDev/sp_int_div_word_2
SP int, cortex, thumb div_word: fix to work
2022-02-10 07:42:00 -08:00
a1198549dd Merge pull request #4844 from dgarske/bench_cleanups 2022-02-10 10:24:55 -05:00
d1267b5203 Merge pull request #4805 from SparkiDev/ecies_aes_ctr
ECIES: add support for more encryption algorithms
2022-02-10 07:04:24 -08:00
e351f1a7e7 rm unused src links 2022-02-10 22:21:24 +09:00
e8fb17f7b5 SP int, cortex, thumb div_word: fix to work
Cortex builds needed # before number. Arm32 works with or without.
Thumb div_word needed to shift up if divisor too small (like other ARM
implementations).
2022-02-10 12:07:11 +10:00
e50f661639 ECIES: add support for more encryption algorithms
Add support to ECIES for AES-256-CBC, AES-128-CTR, AES-256-CTR.
Added new API wc_ecc_ctx_set_algo() that sets the encryption, KDF and
MAC algorithms.
Cleanup formatting of ECIES code.
2022-02-10 09:54:22 +10:00
4f1aa9a475 Fix benchmark input/output arguments. Cleanup line length and whitespace. 2022-02-09 13:13:42 -08:00
cba262440a Merge pull request #4842 from SparkiDev/sha3_arm_fixup
ARMASM, SHA-3: fixup when not using crypto instructions
2022-02-09 10:20:46 -08:00
bee025842e Merge pull request #4828 from TakayukiMatsuo/rtos 2022-02-09 09:37:47 -07:00
0d5edfadcb Merge pull request #4837 from SparkiDev/sp_c_config
SP C: when sp_c32.c ad sp_c64.c are included in build changed
2022-02-09 07:51:20 -08:00
c472b3582e Merge pull request #4839 from douzzer/20220207-clang-tidy-15
20220208 clang-tidy-15 fixes etc.
2022-02-09 08:36:18 -06:00
343cb0da23 SP C: when sp_c32.c ad sp_c64.c are included in build changed
When compiling with the CFLAG -m32, sp_c32.c is used and not sp_c64.c.
The build system cannot detect that this is a 32-bit platform and to use
sp_c32.c.

The SP code detects which implementaiton to use and sets defines that
enable the code in sp_c32.c or sp_c64.c.

ENABLED_64BIT, 64-bit platform, was on by default, which is not always
true.
By making ENABLED_64BIT not default then the decision of which SP C
files to include in the build had to change to not being the other.
That is, sp_c64.c is not included when the configuration line explicitly
enables 32bit and sp_c32.c is not include when the configuration line
explicitly enables 64bit.
2022-02-09 15:56:57 +10:00
f49b7107a0 Add __inline__ for Diab compiler 2022-02-08 19:54:26 -08:00
32c80781bf Prevent diab compiler from inlining functions 2022-02-08 19:25:13 -08:00
b436262cdf ARMASM, SHA-3: fixup when not using crypto instructions 2022-02-09 09:36:00 +10:00
49defbd2cc Merge pull request #4836 from embhorn/zd13634
Remove deprecated VS solution
2022-02-08 15:18:21 -08:00
67b2a1be40 Merge pull request #4831 from dgarske/zd13571_2
Improve the client certificate checking logic
2022-02-09 08:27:03 +10:00
1bd4cb4eee Modify example app to work with FreeRTOS+IoT 2022-02-09 07:18:39 +09:00
34946c2440 Merge pull request #4832 from TakayukiMatsuo/rose 2022-02-08 14:54:47 -07:00
74408e3ee3 fixes for whitespace, C++ warnings, and LLVM 15 clang-tidy defects/carps:
* whitespace in src/ssl.c, tests/api.c, wolfssl/openssl/fips_rand.h.

* clang-analyzer-core.StackAddressEscape from llvm-15 clang-tidy, in tests/suites.c:execute_test_case().

* bugprone-suspicious-memory-comparison from llvm-15 clang-tidy, in src/internal.c:DoSessionTicket() and src/ssl.c:wolfSSL_sk_push().
2022-02-08 15:20:22 -06:00
ed1fc9fc51 Merge pull request #4833 from SparkiDev/sha3_arm_crypto
SHA-3, ARM64: add assembly support for crypto instructions
2022-02-08 11:05:35 -08:00
7ec1e69dba Fixes for supporting the openssl compatibility layer. Adds ChaCha/Poly, DH extra and verify callbacks. 2022-02-08 10:18:41 -08:00
6930cc0b21 Clean up Visual Studio output and intermediate directories.
Currently, wolfssl.vcxproj and IDE/WIN10/wolfssl-fips.vcxproj do not use the
same scheme for their output and intermediate directories. Further, across
configuration/platform combinations, wolfssl.vcxproj isn't consistent, either.
For example:

```
Release|x64
OutDir: $(SolutionDir)$(Platform)\$(Configuration)\
IntDir: $(Platform)\$(Configuration)\obj\

Release|Win32
OutDir: $(SolutionDir)$(Configuration)\
IntDir: $(Configuration)\obj\
```

This commit makes every configuration/platform combo for all Visual Studio
projects follow the same pattern:

```
OutDir: $(SolutionDir)$(Platform)\$(Configuration)\
IntDir: $(Configuration)\$(Platform)\$(ProjectName)_obj\
```

The `$(ProjectName)_obj` piece gets rid of a Visual Studio warning about not
mingling the intermediate objects of disparate builds.
2022-02-08 09:23:27 -08:00
3ee6e93590 Merge pull request #4838 from SparkiDev/g++_fix_4
Rework functions to avoid warning with g++
2022-02-08 10:20:58 -06:00
1f69c52ce8 Merge pull request #4830 from dgarske/no_hmac
Fixes for building without HMAC
2022-02-07 22:26:38 -06:00
d2307186d9 Rework functions to avoid warning with g++ 2022-02-08 12:36:36 +10:00
0042a2594c SHA-3, ARM64: add assembly support for crypto instructions
Add ability to compile ARM assembly from inline C code.
2022-02-08 12:21:38 +10:00
b60d2dccce Include the havePeerCert argument in the check. 2022-02-07 16:31:50 -08:00
5169a3cf89 Improve header comments and logic. Remove NO_PWDBASED and added CRL. 2022-02-07 15:58:10 -08:00
5e5a389afb Remove deprecated VS solution 2022-02-07 17:14:41 -06:00
d0246a280d Merge pull request #4834 from anhu/guard_wc_PKCS7_SetPassword
Fix tests to properly gate on ! NO_PWDBASED && ! NO_SHA
2022-02-07 15:12:22 -08:00
56c562a516 Fixes for building with ./configure --enable-opensslextra --enable-cryptonly CFLAGS="-DNO_HMAC" && make. Found this testing a customers configuration with latest. Also fixes some trailing whitespace. 2022-02-07 15:10:21 -08:00
d085984103 Merge pull request #4829 from kosmas-valianos/kTLS
Expose Sequence Numbers so that Linux TLS (kTLS) can be configured
2022-02-07 14:55:07 -08:00
5361c0bda0 Update signature as the certificate is renewed 2022-02-08 07:31:50 +09:00
e47dd675af Fix tests to properly gate on ! NO_PWDBASED && ! NO_SHA 2022-02-07 14:44:26 -05:00
dd2e0064b2 Merge pull request #4827 from SparkiDev/sp_int_dw_asm
SP math, Aarch64, ARM32: div word asm fixup
2022-02-07 11:32:14 -08:00
54e7db0a9a Merge pull request #4739 from rizlik/psa
support Platform Security Architecture (PSA) API
2022-02-07 10:40:21 -08:00
4c8f0709fc Merge pull request #4720 from dgarske/fips_compat 2022-02-07 09:56:24 -07:00
3cdb1c639d Improve the client certificate checking logic. Make sure calling wolfSSL_CTX_mutual_auth is also checked. 2022-02-07 08:09:38 -08:00
3d85a9690f Merge pull request #4819 from lealem47/hashMismatch
Fix for OpenSSL x509_NAME_hash mismatch
2022-02-07 08:08:49 -08:00
30b35acd39 Expose Sequence Numbers so that Linux TLS (kTLS) can be configured 2022-02-07 09:30:59 +01:00
f6d79ff598 Merge pull request #4813 from dgarske/zd13571
Fix for mutual authentication to prevent mismatch of certificate and sigalgo
2022-02-07 11:00:04 +10:00
f9ff551992 Fix for OpenSSL x509_NAME_hash mismatch 2022-02-04 16:59:51 -08:00
1f8ff7d9fe Merge pull request #4822 from embhorn/zd13613
Fix warnings in VS
2022-02-04 15:37:31 -08:00
2077184953 psa: add compile-time error if builded with crypto cb 2022-02-04 21:45:38 +01:00
b8635efda7 psa: add README.md and doxygen header 2022-02-04 21:45:38 +01:00
0cb2cc1705 psa: support pk callbacks for ECDSA, ECDH, HKDF 2022-02-04 21:45:38 +01:00
630b244cee psa: introduce global lock 2022-02-04 21:45:38 +01:00
a7165907da psa: support AES 2022-02-04 21:45:38 +01:00
9ccfc81f26 psa: support PSA SHA1/SHA256/SHA224 2022-02-04 21:45:38 +01:00
06915b6fa3 psa: support PSA random generator 2022-02-04 21:45:38 +01:00
08047b2d95 Add checking to make sure key is present in all cases. Explicitly set validSigAlgo to zero with comment to clarify the default assumption. 2022-02-04 11:47:06 -08:00
2d184348fb Merge pull request #4825 from embhorn/gh4815
Fix wolfSSL_PEM_X509_INFO_read with NO_FILESYSTEM
2022-02-04 10:42:40 -08:00
327e35fc25 Merge pull request #4826 from haydenroche5/evp_aes_gcm_iv_bug
Fix IV length bug in EVP AES-GCM code.
2022-02-04 10:38:02 -08:00
d1ca8fc673 Merge pull request #4821 from elms/cmake/help_cleanup 2022-02-04 09:37:39 -08:00
08fbcf5eae autoconf: add PSA options 2022-02-04 12:12:04 +01:00
bd1b58dd7f SP math, Aarch64, ARM32: div word asm fixup
ASM code is dividing by top half of divisor. If this value is very small
then bad results are calculated.
Moved the divisor up by a quarter of the width if top quarter of divisor
is 0.
2022-02-04 11:59:31 +10:00
b850cc89b0 Fix IV length bug in EVP AES-GCM code.
In `wolfSSL_EVP_CipherInit`, `ctx`'s `ivSz` field isn't being accounted for.
A common OpenSSL EVP AES-GCM flow looks like this:

- `EVP_CIPHER_CTX_new`
- `EVP_EncryptInit_ex`
- `EVP_CIPHER_CTX_ctrl` with command `EVP_CTRL_GCM_SET_IVLEN` to set the IV
length to 16 (AES block size) instead of the default 12
- `EVP_EncryptInit_ex` again to set the key and IV
- `EVP_EncryptUpdate` however many times
- `EVP_EncryptFinal`

In fact, we test this flow in our unit test `test_wolfssl_EVP_aes_gcm`. However,
in our implementation, the second call to `EVP_EncryptInit_ex` unconditionally
resets the IV length back to 12. This doesn't cause a test failure because
decryption has the same problem, so both sides of the equation have the same
wrong view of the IV.

The solution is to preserve the IV length in wolfSSL_EVP_CipherInit if ctx->ivSz
is non-zero. Otherwise, use the default of 12 (`GCM_NONCE_MID_SZ`).

This was discovered by a user migrating to the compatibility layer. As I
mentioned, it isn't exposed by our testing. It is exposed if you try to use the
same key and IV with OpenSSL and compare the resulting ciphertext with wolfSSL.
They won't be the same and thus won't interoperate.
2022-02-03 17:40:26 -08:00
50700c3c28 Make sure Rabbit and HC128 are disabled when building FIPS against older wolfSSL. 2022-02-03 14:53:11 -08:00
a0444bf72f Fix wolfSSL_PEM_X509_INFO_read with NO_FILESYSTEM 2022-02-03 16:52:08 -06:00
7b2e457d04 Fix VS unreachable code warning 2022-02-03 15:53:35 -06:00
db6d924d4b User settings template for FIPS v5. 2022-02-03 13:35:13 -08:00
53e64b55e1 Merge pull request #4823 from haydenroche5/alpn_bug
Fix bug in TLSX_ALPN_ParseAndSet when using ALPN select callback.
2022-02-03 13:16:13 -08:00
fab2e99bff Fix bug in TLSX_ALPN_ParseAndSet when using ALPN select callback.
At the start of this function, it attempts to find an ALPN extension in the
ssl object's extensions with `TLSX_Find`. If an ALPN select callback has been
set (i.e. via `wolfSSL_CTX_set_alpn_select_cb`), that gets called next. If that
callback finds a match, it removes all existing ALPN extensions found in the
ssl object. It then uses the new protocol name like this:

```
if (TLSX_UseALPN(&ssl->extensions, (char*)out, outLen, 0, ssl->heap)
                                                           == WOLFSSL_SUCCESS) {
    if (extension == NULL) {
        extension = TLSX_Find(ssl->extensions,
                              TLSX_APPLICATION_LAYER_PROTOCOL);
    }
}
```

The bug is exposed if `extension` is not NULL, i.e. it was found on that initial
`TLSX_Find` call. `extension` is not NULL but it now points to garbage because
all the old ALPN extensions were just removed. It won't have it's value assigned
to the new extension that just got pushed via `TLSX_UseALPN` because of this
NULL check. This results in a segfault later in the function.

The solution is to remove the NULL check and always update `extension` after the
`TLSX_UseALPN` call.

This bug was discovered by a customer when using nginx + wolfSSL. I was able to
reproduce locally with curl acting as the client
2022-02-03 09:36:18 -08:00
f0b953ce0c Fix warnings in VS 2022-02-03 07:19:43 -06:00
fab8eca2fd cmake: Check for valid voerride values
Also remove trailing whitespace
2022-02-02 16:32:00 -08:00
9b4289c751 cmake: Add KEYGEN option. Cleanup help messages.
Add `WOLFSSL_KEYGEN` option and override enable when `WOLFTPM` is
enabled

Also major reduction of variables for help messages. Override only
updates `VALUE`
2022-02-02 16:15:47 -08:00
d3e3f57b77 Merge pull request #4818 from julek-wolfssl/guido-13454
`object` and `value` need to be `free`'ed
2022-02-02 16:04:39 -08:00
17eee2ba0c Merge pull request #4817 from julek-wolfssl/ZD13495
ZD13495
2022-02-02 15:54:08 -08:00
97dd974a94 object and value need to be free'ed 2022-02-02 23:13:59 +01:00
e13861bcde Fix for mutual authentication to prevent mismatch of certificate and sig algo. Work from Sean P. ZD 13571 2022-02-02 12:20:02 -08:00
28d3292a16 Merge pull request #4811 from haydenroche5/dh_get_2048_256
Add DH_get_2048_256 to compatibility layer.
2022-02-02 12:12:34 -08:00
0618b69b6d Merge pull request #4816 from julek-wolfssl/ok-error
For `0` OpenSSL prints "ok"
2022-02-02 12:10:35 -08:00
9efb791abc Merge pull request #4814 from SparkiDev/bio_dump_iter
wolfSSL_BIO_dump: fix output format and make iterative
2022-02-02 12:02:07 -08:00
d5b294edc4 ZD13495
- `wolfSSLeay_version` now returns the version of wolfSSL
- `wolfssl/openssl/crypto.h` was not enveloped in a `extern "C"` wrapper
2022-02-02 17:38:36 +01:00
c629c3fcaa Add DH_get_2048_256 to compatibility layer. 2022-02-02 07:59:17 -08:00
1552e89810 For 0 OpenSSL prints "ok" 2022-02-02 15:54:21 +01:00
cebb127ac3 test: don't free AesXts struct in-between tests that reuse the key 2022-02-02 10:46:40 +01:00
641576390d wolfSSL_BIO_dump() and wolfSSL_OBJ_obj2txt() rework
wolfSSL_BIO_dump(): fix output format and make iterative
wolfSSL_OBJ_obj2txt(): make iterative, test and rework.
2022-02-02 12:43:06 +10:00
59ea65bad3 Merge pull request #4809 from haydenroche5/asn1_int 2022-02-01 13:44:32 -07:00
99799a3e3e Merge pull request #4806 from anhu/kill_idea
Purge IDEA cipher
2022-02-01 12:27:55 -08:00
24a2ed7e9e Merge pull request #4780 from dgarske/ipsec_racoon 2022-01-31 15:10:58 -08:00
df85ea7e87 Merge pull request #4800 from SparkiDev/sp_c_smul
SP C: multiplication of two signed types with overflow is undefined in C
2022-01-31 14:29:18 -08:00
13c759cc10 Merge pull request #4812 from douzzer/20220131-camellia-clang-tidy
wolfcrypt/src/camellia.c: clang-tidy fixes (bugprone-macro-parentheses).
2022-01-31 14:13:23 -08:00
a742c33c0c Mention IDEA removal in README.md. 2022-01-31 16:18:39 -05:00
9ea40f3a9c Purge IDEA cipher 2022-01-31 15:29:25 -05:00
a7de880745 wolfcrypt/src/camellia.c: clang-tidy fixes (bugprone-macro-parentheses). 2022-01-31 14:21:54 -06:00
ecb3f215b5 Merge pull request #4808 from lealem47/certreq
Fix for certreq and certgen options with openssl compatability
2022-01-31 10:16:22 -08:00
5bdaf44354 Merge pull request #4774 from anhu/kill_rabbit
Purge Rabbit cipher
2022-01-31 09:17:23 -08:00
6b71289ae1 Add new ASN1_INTEGER compatibility functions.
This commit adds:

- wolfSSL_i2d_ASN1_INTEGER
- wolfSSL_d2i_ASN1_INTEGER
- wolfSSL_ASN1_INTEGER_cmp
2022-01-29 17:01:16 -08:00
e58ff9e765 Merge pull request #4795 from wolfSSL/cmake/wolftpm
cmake: Add options to support wolfTPM
2022-01-28 14:52:53 -08:00
f509dafd6c README.md addition 2022-01-28 17:20:25 -05:00
f608b1a731 macro logic fix 2022-01-28 13:54:13 -08:00
e135ea7338 Fix for certreq and certgen options with openssl compatability 2022-01-28 12:39:00 -08:00
40fff86807 Merge pull request #4801 from tmael/cert_rr
cert subset improvements
2022-01-28 11:00:55 -08:00
b957a6e872 Purge Rabbit cipher 2022-01-28 13:13:53 -05:00
6e76f21f9e cmake: Add options to support wolfTPM
* certgen
 * certgencache
 * certreq
 * certext
 * cryptocb
 * pkcs7
 * X9.63 KDF
 * AES-CFB
2022-01-28 09:44:09 -08:00
c69010adef Peer review feedback. 2022-01-28 09:21:03 -08:00
6615f019f5 Improved HMAC_Init error logging and code comment for FIPS failure on wc_HmacSetKey call. 2022-01-28 09:21:03 -08:00
80ae237852 Fixes for building with ipsec-tools/racoon and openvpn:
* Fix for `EVP_CIPHER_CTX_flags`, which mapped to a missing function (broke openvpn)
* Added stack of name entries for ipsec/racoon support.
* Added `X509_STORE_CTX_set_flags` stub.
* Added PKCS7 NID types.
* Improved FIPS "SHA" logic in `test_wolfSSL_SHA`
* Added some uncommon NID type definitions.
* Expose the DH `DH_set_length` and `DH_set0_pqg` with OPENSSL_ALL
2022-01-28 09:21:03 -08:00
46f25ea3e0 Merge pull request #4804 from douzzer/20220127-clang-tidy-fips_test_h
clang-tidy hygiene for fips_test.h
2022-01-28 09:00:03 -08:00
cd72b4652b Merge pull request #4798 from lealem47/cmake 2022-01-28 08:42:29 -08:00
30b2073228 test.c: fix gating on wc_ecc_encrypt_ex() for FIPS <5.3 --enable-all. 2022-01-27 19:54:07 -06:00
19042023f4 MD5 vs. FIPS 140-3: fix gating so that unit.test succeeds when --enable-fips=v5 --enable-md5 (HMAC-MD5 is non-FIPS in 140-3, but even in a FIPS 140-3 build, the non-FIPS API can be accessed directly by #undef'ing wc_Hmac*()). 2022-01-27 18:37:29 -06:00
d9073f39e1 fips_test.h: add arg names to prototypes, and delete obsolete+unused DoIntegrityTest() prototype. 2022-01-27 18:37:29 -06:00
1465f99b12 Merge pull request #4734 from haydenroche5/fips_v5_des3
Allow DES3 with FIPS v5-dev.
2022-01-27 15:07:22 -08:00
667009007b Merge pull request #4799 from SparkiDev/file_gen_fixes
Generated files: fixes
2022-01-27 14:21:34 -08:00
77a64d0087 Merge pull request #4802 from SparkiDev/ecies_compressed
ECIES: allow compressed public keys
2022-01-27 14:21:12 -08:00
1c12490c98 Adding some CMake options 2022-01-27 11:52:37 -08:00
f323964e8a Update TIRTOS module
Use SP_MATH by default. Added missing object files.
2022-01-27 16:23:23 +01:00
b890a2f15d ECIES: allow compressed public keys
ECIES messages have a public key/point at start of the data.
It can be either uncompressed or compressed.
Adding support for decrypting and encrypting of compressed point.
2022-01-27 12:10:59 +10:00
a37e17084d Use mp_iszero 2022-01-26 17:33:42 -08:00
1c1bd413e0 cert subset SHA2-256, ecc-256, cert gen, cryptocb 2022-01-26 17:11:00 -08:00
91b1e541c5 SP C: multiplication of two signed types with overflow is undefined in C
Montgomery Reduction: cast variables to be unsigned where signed
multiplication with overflow is performed.
2022-01-27 10:25:02 +10:00
a242424abe Generated files: fixes
Fixups from updating scripts that generate the files.
Include settings.h for ARM32 assembly.
ARM32 SHA-512 ASM has only one function, Transform_Sha512_Len(). The
implementation is dependent on defines.
2022-01-27 10:05:45 +10:00
9bbc5e07e6 Merge pull request #4733 from JacobBarthelmeh/ECC
include hmac for deterministic ecc sign build
2022-01-26 10:01:46 -08:00
25c6417f03 Merge pull request #4797 from douzzer/20220124-clang-tidy
clang-tidying headers
2022-01-26 10:01:00 -08:00
b7cecbacb2 update headers to resolve clang-tidy carping (mostly bugprone-macro-parentheses and readability-named-parameter). also disables MSC C4028 because incompatible with readability-avoid-const-params-in-decls. 2022-01-26 02:06:37 -06:00
9250edc2ea wolfcrypt/src/fe_x25519_128.i: harmonize argument names in fe_cswap() and fe_cmov() with those used in fe_operations.c. 2022-01-26 02:05:26 -06:00
85da17bcf8 src/ssl.c: fix argument name in openssl compat layer wrappers of hash final funcs in ssl.c (use "output", not "input"). 2022-01-26 00:27:45 -06:00
1e3516d924 src/ssl.c: implement wolfSSL_SHA512_224_Transform() and wolfSSL_SHA512_256_Transform(). 2022-01-26 00:27:07 -06:00
7c9f4911c3 src/wolfio.c: protect __GLIBC__ comparison with defined(__GLIBC__). 2022-01-26 00:22:13 -06:00
cfc7337bda Merge pull request #4794 from rizlik/openssl_srtp_script_fix
dtls-srtp: don't run openssl_srtp.test on make check
2022-01-25 16:31:29 -08:00
d0dbdd374d Merge pull request #4775 from elms/cmake/asm_user_settings
cmake: enable ASM and fix thread with usersettings
2022-01-25 16:25:16 -08:00
38558d7fd1 dtls-srtp: don't run openssl_srtp.test on make check 2022-01-25 21:51:56 +01:00
588f4a11c9 Merge pull request #4785 from douzzer/20220120-aes-internal-error-handling
20220120-aes-internal-error-handling
2022-01-24 20:45:53 -08:00
58789991f9 Allow DES3 with FIPS v5-dev. 2022-01-24 15:18:44 -08:00
50e3565df6 Merge pull request #4779 from SparkiDev/dyn_cert
Cert: allow allocation of fields even with WOLFSSL_NO_MALLOC
2022-01-24 14:17:41 -08:00
746c05ca44 AES: peer review: remove gating around sanity checks on aes->rounds in software wc_AesEncrypt() and wc_AesDecrypt();
use local variable crypto_cb_ret around WOLF_CRYPTO_CB calls for clarity;

fix line length.
2022-01-24 15:47:23 -06:00
f0041852b5 aes.c: add error catching and percolation for wc_AesGetKeySize() on FREESCALE_LTC in wc_AesEncrypt(), wc_AesDecrypt(), and wc_AesCtrEncrypt(). 2022-01-24 13:34:22 -06:00
5ff1d98306 AES: fix linebreaks in newly overlong lines in aes.c and aes.h; add missing return code in armv8-aes.c wc_AesDecryptDirect(); add missing RESTORE_VECTOR_REGISTERS() in software wc_AesXtsEncrypt() (all pursuant to peer review in #4785 from Sean). 2022-01-24 12:32:25 -06:00
565a7b0aab aes.c: in linuxkm clause of WOLFSSL_AES_DIRECT section, gate on WOLFSSL_LINUXKM && WOLFSSL_AESNI (with no-asm falling through to the generic definition), and use wolfssl-idiomatic WARN_UNUSED_RESULT, not linux-kernel-idiomatic __must_check. (thanks to John S peer review) 2022-01-24 11:44:16 -06:00
a718637c6f AES: harmonize wc_Aes{Encrypt,Decrypt} and wc_Aes{Encrypt,Decrypt}Direct implementations to return int; add return values to all static void functions in aes.c that can fail; add WARN_UNUSED_RESULT to all static functions in aes.c with return values; implement missing error percolation around AES block cipher implementations; bump FIPS version for v5-ready and v5-dev to 5.3 (v5-RC12 is 5.2). 2022-01-24 11:44:16 -06:00
dee66cfe9e Merge pull request #4789 from SparkiDev/sp_invmod_oob
SP int: sp_modinv fixes for sizes
2022-01-24 09:08:08 -08:00
93404361ff Merge pull request #4783 from SparkiDev/mac_sha512_def
SHA-512 ASM: For Mac computers default to using SHA512 instructions
2022-01-24 09:03:08 -08:00
44c0a5f9f8 Merge pull request #4790 from SparkiDev/decodesubtree_oobr
ParseCert: check index in DecodeSubtree before accessing tag
2022-01-24 08:36:52 -08:00
3d63e41653 SP int: sp_modinv fixes for sizes
sp_invmod with even modulus requires a multiplication by modulus. Don't
let modulus overflow result variable 'r'.
Fix allocation of temporary sp_ints to be correct size.
Add test for maximum modulus size in test.c.

Remove leading spaces on functions so git correctly determines which
function has changed.
Put in Thumb code for more sizes of _sp_mul_*().
2022-01-24 15:18:20 +10:00
1dd213db76 ParseCert: check index in DecodeSubtree before accessing tag 2022-01-24 12:30:48 +10:00
198843aa34 Merge pull request #4787 from douzzer/20220121-fixits-20220118-clang-tidy
cleanup re #4772
2022-01-21 12:46:07 -08:00
2955d7339e remove a debugging printf, fix whitespace/indentation, and add a comment re gethostbyname_r buffer size. 2022-01-21 13:00:22 -06:00
7a36d57e8f Merge pull request #4784 from SparkiDev/sp_int_modinv_perf
SP int: minor improvements to sp_invmod
2022-01-21 10:30:09 -08:00
869246609a Merge pull request #4772 from douzzer/20220118-clang-tidy
clang-tidy fixes/cleanups
2022-01-21 10:29:26 -08:00
4f9d0b7ea7 fix whitespace. 2022-01-21 01:26:44 -06:00
bfada558bd remove extraneous build gates and fix whitespace justification in a comment (peer review re PR #4772). 2022-01-21 01:26:44 -06:00
386aac9694 AES-SIV:
in configure.ac, enable SIV only if !ENABLED_FIPS or if building FIPS v5-dev;

in cmac.{c,h}, remove !HAVE_FIPS gating on ShiftAndXorRb().
2022-01-21 01:26:33 -06:00
84f7d812d3 linuxkm/module_exports.c.template: include siphash.h. 2022-01-21 01:25:48 -06:00
10b8f56fec wolfio.c: in wolfIO_TcpConnect(), test for usability of gethostbyname_r by (__GLIBC__ >= 2) && defined(__USE_MISC), not defined(__GNUC__). 2022-01-21 01:25:48 -06:00
5e33da8147 fix whitespace. 2022-01-21 01:25:48 -06:00
bb07d0a490 wolfio.c: refactor wolfIO_TcpConnect(() to use gethostbyname_r() if GNUC && !SINGLE_THREADED, for thread safety. 2022-01-21 01:25:48 -06:00
6a56d3e131 jumbo patch of fixes for clang-tidy gripes (with some bug fixes).
defect/gripe statistics:

    configured --enable-all --enable-sp-math-all --enable-intelasm

    with LLVM 13 clang-tidy -checks=readability-*,bugprone-*,misc-no-recursion,misc-misplaced-const,misc-redundant-expression,misc-unused-parameters,misc-unused-using-decls,-clang-analyzer-security.insecureAPI.DeprecatedOrUnsafeBufferHandling,-clang-analyzer-optin.performance.Padding,-readability-braces-around-statements,-readability-function-size,-readability-function-cognitive-complexity,-bugprone-suspicious-include,-bugprone-easily-swappable-parameters,-readability-isolate-declaration,-readability-magic-numbers,-readability-else-after-return,-bugprone-reserved-identifier,-readability-suspicious-call-argument,-bugprone-suspicious-string-compare,-bugprone-branch-clone,-misc-redundant-expression,-readability-non-const-parameter,-readability-redundant-control-flow,-readability-misleading-indentation,-bugprone-narrowing-conversions,-bugprone-implicit-widening-of-multiplication-result

    [note these figures don't reflect additional defects fixed in this commit for --enable-smallstack, --enable-fips, --enable-async, --enable-asn=template, and --enable-fastmath, and --disable-fastmath]

    pre-patch warning count per file, with suppressions:

    clang-analyzer-security.insecureAPI.strcpy    6  wolfssl/tests/suites.c
    clang-analyzer-security.insecureAPI.strcpy    2  wolfssl/testsuite/testsuite.c
    bugprone-suspicious-missing-comma             3  wolfssl/examples/server/server.c
    bugprone-suspicious-missing-comma             3  wolfssl/examples/client/client.c
    readability-redundant-preprocessor            2  wolfssl/wolfcrypt/src/asn.c
    readability-redundant-preprocessor            1  wolfssl/wolfcrypt/src/rsa.c
    readability-redundant-preprocessor            9  wolfssl/src/ssl.c
    readability-redundant-preprocessor            2  wolfssl/src/tls13.c
    readability-redundant-preprocessor           18  wolfssl/tests/api.c
    readability-redundant-preprocessor            3  wolfssl/src/internal.c
    readability-redundant-preprocessor           10  wolfssl/wolfcrypt/test/test.c
    readability-named-parameter                   1  wolfssl/wolfcrypt/benchmark/benchmark.c
    readability-named-parameter                   7  wolfssl/src/internal.c
    readability-named-parameter                   1  wolfssl/wolfcrypt/src/ecc.c
    readability-named-parameter                   1  wolfssl/testsuite/testsuite.c
    readability-named-parameter                  11  wolfssl/wolfcrypt/src/ge_operations.c
    misc-no-recursion                             3  wolfssl/src/ssl.c
    readability-uppercase-literal-suffix          4  wolfssl/wolfcrypt/src/asn.c
    readability-uppercase-literal-suffix          1  wolfssl/src/ssl.c
    readability-uppercase-literal-suffix         13  wolfssl/wolfcrypt/benchmark/benchmark.c
    bugprone-too-small-loop-variable              1  wolfssl/wolfcrypt/src/rsa.c
    bugprone-too-small-loop-variable              2  wolfssl/wolfcrypt/src/sha3.c
    bugprone-too-small-loop-variable              4  wolfssl/wolfcrypt/src/idea.c
    bugprone-signed-char-misuse                   2  wolfssl/src/ssl.c
    bugprone-signed-char-misuse                   3  wolfssl/wolfcrypt/src/sp_int.c
    bugprone-signed-char-misuse                   3  wolfssl/examples/client/client.c
    bugprone-macro-parentheses                   19  wolfssl/wolfcrypt/src/aes.c
    bugprone-macro-parentheses                  109  wolfssl/wolfcrypt/src/camellia.c
    bugprone-macro-parentheses                    1  wolfssl/src/tls.c
    bugprone-macro-parentheses                    3  wolfssl/wolfcrypt/src/md4.c
    bugprone-macro-parentheses                    2  wolfssl/wolfcrypt/src/asn.c
    bugprone-macro-parentheses                   26  wolfssl/wolfcrypt/src/blake2b.c
    bugprone-macro-parentheses                  257  wolfssl/wolfcrypt/src/sha3.c
    bugprone-macro-parentheses                   15  wolfssl/src/ssl.c
    bugprone-macro-parentheses                    1  wolfssl/wolfcrypt/src/sha.c
    bugprone-macro-parentheses                    8  wolfssl/tests/api.c
    bugprone-macro-parentheses                    4  wolfssl/wolfcrypt/src/sp_int.c
    bugprone-macro-parentheses                    6  wolfssl/wolfcrypt/benchmark/benchmark.c
    bugprone-macro-parentheses                   38  wolfssl/wolfcrypt/src/hc128.c
    bugprone-macro-parentheses                   12  wolfssl/wolfcrypt/src/md5.c
    bugprone-macro-parentheses                   10  wolfssl/wolfcrypt/src/sha256.c
    bugprone-macro-parentheses                    4  wolfssl/wolfcrypt/test/test.c
    bugprone-macro-parentheses                    3  wolfssl/wolfcrypt/src/ecc.c
    bugprone-macro-parentheses                    2  wolfssl/tests/suites.c
    bugprone-macro-parentheses                    4  wolfssl/wolfcrypt/src/cpuid.c
    bugprone-macro-parentheses                   26  wolfssl/wolfcrypt/src/blake2s.c
    bugprone-macro-parentheses                   24  wolfssl/wolfcrypt/src/sha512.c
    bugprone-macro-parentheses                    3  wolfssl/wolfcrypt/src/poly1305.c
    bugprone-macro-parentheses                   24  wolfssl/wolfcrypt/src/ripemd.c
    readability-inconsistent-declaration-parameter-name    1  wolfssl/src/internal.c
    readability-inconsistent-declaration-parameter-name    1  wolfssl/testsuite/testsuite.c

    pre-patch warning count summaries, with suppressions:

    clang-analyzer-security.insecureAPI.strcpy                  8
    bugprone-suspicious-missing-comma                           6
    readability-redundant-preprocessor                         45
    readability-named-parameter                                21
    misc-no-recursion                                           3
    readability-uppercase-literal-suffix                       18
    bugprone-too-small-loop-variable                            7
    bugprone-signed-char-misuse                                 8
    bugprone-macro-parentheses                                601
    readability-inconsistent-declaration-parameter-name         2

    pre-patch warning count summaries, without suppressions:

    clang-analyzer-security.insecureAPI.strcpy                  8
    bugprone-branch-clone                                     152
    readability-non-const-parameter                           118
    bugprone-suspicious-missing-comma                           6
    bugprone-suspicious-include                                52
    readability-magic-numbers                               22423
    readability-redundant-preprocessor                         45
    readability-named-parameter                                21
    readability-function-cognitive-complexity                 845
    readability-else-after-return                             398
    bugprone-implicit-widening-of-multiplication-result       595
    readability-function-size                                  21
    readability-isolate-declaration                          1090
    misc-redundant-expression                                   2
    bugprone-narrowing-conversions                            994
    misc-no-recursion                                           3
    readability-uppercase-literal-suffix                       18
    bugprone-reserved-identifier                               56
    readability-suspicious-call-argument                       74
    bugprone-too-small-loop-variable                            7
    bugprone-easily-swappable-parameters                      437
    bugprone-signed-char-misuse                                 8
    readability-misleading-indentation                         94
    bugprone-macro-parentheses                                601
    readability-inconsistent-declaration-parameter-name         2
    bugprone-suspicious-string-compare                        495
    readability-redundant-control-flow                         20
    readability-braces-around-statements                    11483
    clang-analyzer-valist.Uninitialized                         1
    clang-analyzer-security.insecureAPI.DeprecatedOrUnsafeBufferHandling   3502
2022-01-21 01:25:48 -06:00
b75fe633ad SP int: minor improvements to sp_invmod 2022-01-21 16:47:59 +10:00
8a2cab8702 SHA-512 ASM: For Mac computers default to using SHA512 instructions 2022-01-21 16:40:35 +10:00
30e9d2813e Merge pull request #4782 from haydenroche5/aes_siv_gpp
Fix AES-SIV test with g++.
2022-01-21 15:37:12 +10:00
888bd2b304 Fix AES-SIV test with g++.
The string initializers for the AES-SIV test vector fields needed an extra byte
for the null terminator expected by g++.
2022-01-20 19:22:25 -08:00
848f5eeb0c Merge pull request #4755 from dgarske/dtls_srtp
DTLS SRTP (RFC5764) support (adds `--enable-srtp`)
2022-01-21 10:43:47 +10:00
d1a23a3285 Merge pull request #4758 from kareem-wolfssl/asioOldTls
Fix building ASIO with Old TLS disabled.
2022-01-20 10:44:41 -08:00
427b67d51b Merge pull request #4756 from kareem-wolfssl/noBio
Fix building with OPENSSL_EXTRA and NO_BIO defined.
2022-01-20 10:41:22 -08:00
5ea23d389c Merge pull request #4778 from haydenroche5/chrony
Add --enable-chrony configure option.
2022-01-20 08:46:00 -08:00
40f573df72 dtls-srtp: NIT: fix EKM size in comments 2022-01-20 16:55:44 +01:00
46c0809f5a dtls-srtp: add script to test interop with OpenSSL 2022-01-20 16:55:44 +01:00
d5aa76b161 dtsl-srtp: use PRF according to the DTLS version used
RFC 5764 sec 4.1.2
2022-01-20 16:55:30 +01:00
cdb2936244 dtls-srtp: PRF: fix correct order of client/server random in seed
see RFC 5705 Section 4
2022-01-20 16:12:04 +01:00
231a0bbb84 dtls-srtp: no ekm cross check on single threaded/no pthread conf 2022-01-20 16:12:04 +01:00
1af3ea56c8 Cert: allow allocation of fields even with WOLFSSL_NO_MALLOC
subjectCN and publicKey in a DecodedCert are needed by the certificate
store in some cases. For embedded, allow them to be allocated even with
WOLFSSL_NO_MALLOC defined.
2022-01-20 16:16:09 +10:00
d728a7f0e6 Merge pull request #4777 from SparkiDev/sp_modinv_even_fix
SP int: fix rework of sp_invmod
2022-01-19 20:32:48 -08:00
a05b1b012f Add --enable-chrony configure option.
This turns on the necessary features for using the chrony NTP package with
wolfSSL.
2022-01-19 19:13:34 -08:00
95efdccd7f Merge pull request #4751 from SparkiDev/sp_int_thumb_asm
SP int: ARM Thumb asm snippets
2022-01-19 18:52:02 -08:00
609d6442b1 Merge pull request #4753 from SparkiDev/siphash
Add SipHash algorithm
2022-01-19 18:51:44 -08:00
fcce4f7a92 Merge pull request #4765 from haydenroche5/aes_siv
Add AES-SIV (RFC 5297).
2022-01-19 18:51:12 -08:00
29513e1ec8 include hmac for deterministic ecc sign build 2022-01-20 09:25:32 +07:00
b767857abb SP int: fix rework of sp_invmod
Simplify code and check for m mod a == 0 which means there is no
inverse.
2022-01-20 10:37:31 +10:00
a6485a228d Add SipHash algorithm 2022-01-20 09:41:18 +10:00
a1185adf2c SP int: ARM Thumb asm snippets 2022-01-20 09:16:45 +10:00
62b07d8806 Add AES-SIV (RFC 5297).
This commit adds functions to encrypt and decrypt data using AES in SIV mode, as
described in RFC 5297. This was added in the process of porting chrony to
wolfSSL. chrony is an NTP implementation that can use NTS (network time
security), which requires AES-SIV.
2022-01-19 14:32:33 -08:00
d668037541 Merge pull request #4746 from elms/gh/templates
github: Initial templates
2022-01-19 14:04:21 -08:00
c6fdb34daa cmake: enable ASM and fix thread with usersettings
* Assembly files were not being compiled.
* With When `-DWOLFSSL_USER_SETTINGS` `HAVE_PTHREAD` was not
  propagating to `config.h`
2022-01-19 13:34:25 -08:00
7adbf59f22 Merge pull request #4767 from anhu/kill_hc128
Get rid of HC-128
2022-01-19 12:20:18 -08:00
c5d3581ac2 Merge pull request #4771 from SparkiDev/sp_c_mont_red
SP C: fix corner case of P256 and P384 mont red
2022-01-19 11:32:49 -08:00
0175013604 Merge pull request #4770 from anhu/cve
CVE-2022-23408
2022-01-19 11:31:24 -08:00
0f50ffb2ef github: Initial templates 2022-01-19 10:36:01 -08:00
8e0ece920b Test cleanups. Fix possible leak in TLSX_UseSRTP. 2022-01-19 09:22:02 -08:00
af71aec77e Mention removal of HC-128 in README.md 2022-01-19 09:49:25 -05:00
86ba0ef643 tests: support test for SRTP
the test will check that the same Exported Keying Material is generated between
client and server
2022-01-19 13:35:29 +01:00
9b69f693e4 dtls-srtp: check that length of strings matched before memcomparing
otherwise if profile_str_len is > strlen(gSrtpProfiles[i].name) we end up
comparing memory past gSrtpProfiles[i].name. -fsanitize=address catches this:

```
==100159==ERROR: AddressSanitizer: global-buffer-overflow on address 0x7f40d8d533b2 at pc 0x7f40d8eb014f bp 0x7f40d50fe240 sp 0x7f40d50fd9e8
READ of size 21 at 0x7f40d8d533b2 thread T107
    #0 0x7f40d8eb014e in MemcmpInterceptorCommon(void*, int (*)(void const*, void const*, unsigned long), void const*, void const*, unsigned long) /build/gcc/src/gcc/libsanitizer/sanitizer_common/sanitizer_common_interceptors.inc:860
    #1 0x7f40d8eb06e6 in __interceptor_memcmp /build/gcc/src/gcc/libsanitizer/sanitizer_common/sanitizer_common_interceptors.inc:892
    #2 0x7f40d8eb06e6 in __interceptor_memcmp /build/gcc/src/gcc/libsanitizer/sanitizer_common/sanitizer_common_interceptors.inc:887
    #3 0x7f40d8c2e830 in DtlsSrtpFindProfile src/ssl.c:1310
    #4 0x7f40d8c2e9ed in DtlsSrtpSelProfiles src/ssl.c:1347
    #5 0x7f40d8c2eada in wolfSSL_CTX_set_tlsext_use_srtp src/ssl.c:1359
    #6 0x563bf381b4c5 in server_test examples/server/server.c:2278
    #7 0x7f40d88f0258 in start_thread (/usr/lib/libpthread.so.0+0x9258)
    #8 0x7f40d88195e2 in __GI___clone (/usr/lib/libc.so.6+0xfe5e2)
```
2022-01-19 13:14:58 +01:00
c06ba390cd SP C: fix corner case of P256 and P384 mont red 2022-01-19 14:22:04 +10:00
4c05d35452 Merge pull request #4743 from miyazakh/tls_bench_onlymode 2022-01-18 15:41:48 -07:00
2984cb5abf Merge pull request #4768 from SparkiDev/sp_invmod_nr
SP math: sp_invmod changed to not call itself
2022-01-18 16:20:37 -06:00
65d1d32972 Merge pull request #4769 from SparkiDev/sp_mont_red_neg
SP math neg: Mont Reduce fix
2022-01-18 14:12:09 -08:00
884b8634af CVE-2022-23408 2022-01-18 16:06:08 -05:00
e6466f92b7 Counting properly 2022-01-18 15:41:16 -05:00
ff128c07a1 Remove extra references to Guid no longer required. Note that other count gaps exist so this should be fine. 2022-01-18 15:23:08 -05:00
ba589955f7 Improve the DTLS SRTP client side parsing. 2022-01-18 11:23:13 -08:00
e745de657f Merge pull request #4761 from haydenroche5/time_cb
Add time callback functionality.
2022-01-18 16:49:19 +10:00
53a4903e2f SP math neg: Mont Reduce fix
Compare the absolute value for negatives.
2022-01-18 16:22:38 +10:00
e11d484746 Merge pull request #4752 from LinuxJedi/fix-ber-der
Fix buffer overflows in BERtoDER
2022-01-17 21:05:39 -07:00
84b06ac1b6 Merge pull request #4730 from embhorn/zd13475
Document wc_AesCfbEncrypt and wc_AesCfbDecrypt
2022-01-17 19:45:45 -07:00
1b0926a3b8 Add time callback functionality.
This commit adds `wolfSSL_SetTimeCb` and `wolfSSL_time`. The former allows the
user to override the function wolfSSL uses to get the current time,
`wolfSSL_time`. If set, `wolfSSL_time` uses that function. If not set,
`wolfSSL_time` uses the `XTIME` macro by default. This functionality is needed
for the port of chrony to wolfSSL. chrony is an NTP implementation that uses
GnuTLS by default. For TLS, chrony uses the time it computes in place of the
default system time function.
2022-01-17 17:49:51 -08:00
fc861f3d6d SP math: sp_invmod changed to not call itself
When the modulus is even, calculate m^-1 mod a instead and fixup after.
Don't call self to do inverse.
2022-01-18 10:45:57 +10:00
f3f5b0f53b Peer review fixes. Improve profile not found handling or errors. Improve inline function. 2022-01-17 15:52:40 -08:00
c2860cb311 Get rid of HC-128 2022-01-17 18:11:54 -05:00
ec44747029 Merge pull request #4764 from SparkiDev/evp_cbn_casecmp
wolfSSL_EVP_get_cipherbyname: case compare
2022-01-17 14:11:07 -08:00
d38c5003d0 Merge pull request #4762 from ejohnstown/old-gcc
Old Compiler Warning Cleanup (GCC 4.0.2)
2022-01-17 09:44:44 -08:00
989a4f096e Merge pull request #4728 from miyazakh/sce_aes128_cryonly 2022-01-17 10:28:57 -07:00
e953707258 Merge pull request #4754 from miyazakh/update_espidfport 2022-01-17 10:27:28 -07:00
6197853f37 Document wc_AesCfbEncrypt and wc_AesCfbDecrypt 2022-01-17 11:27:19 -06:00
d06cf97d73 Old Compiler Warning Cleanup (GCC 4.0.2)
test.c:
1. Removed pragma disabling the warning for unused functions.
2. Fixed the guards around the function that wasn't getting removed from
   the build. And matched the guards to the call of the function. The
   issue is a test that fails only in a cert 3389 build using Arm
   assembly single-precision public keys.
3. Fixed the guards around a couple other functions.
2022-01-16 22:08:35 -08:00
1b5d0c75b8 wolfSSL_EVP_get_cipherbyname: case compare
Accept any case alternatives to name or alias.
Remove case only different aliases.
Tidy up formatting in function.
2022-01-17 09:39:16 +10:00
b68b14b499 Merge pull request #4724 from embhorn/zd13462
Improve param checks of enc
2022-01-16 15:35:54 -08:00
815527be6b Merge pull request #4745 from SparkiDev/m1_sha512
Aarch64 SHA512: fixup to work on Apple M1
2022-01-16 15:29:01 -08:00
15f501358d Merge pull request #4716 from julek-wolfssl/issue-4592
Verification: Domain check should only be performed on leaf certs
2022-01-17 08:40:14 +10:00
001469589b Old Compiler Warning Cleanup (GCC 4.0.2)
Fixed a lot of shadowed global values. Some were prototype and function
declaration parameter name conflicts. Some conflicted with typenames.
Some conflicted with globals in libc.
2022-01-14 17:43:21 -08:00
5ddf4392df Old Compiler Warning Cleanup (GCC 4.0.2)
pwdbased.c: Simplified some arithmetic to fix a variable promotion
warning.
2022-01-14 17:36:12 -08:00
2cf21a3f69 Old Compiler Warning Cleanup (GCC 4.0.2)
ecc.c,api.c: Initialize some variables to fix warning for possible
uninitialized variable use.
2022-01-14 17:33:49 -08:00
e724622506 Old Compiler Warning Cleanup (GCC 4.0.2)
ge_operations.c: Added the keyword `inline` to several function
prototypes for functions declared `inline`.
2022-01-14 17:19:01 -08:00
2085624a29 Old Compiler Warning Cleanup (GCC 4.0.2)
1. Removed pragma disabling the warning for non-literal format strings
on `printf()`.
2. Switched the `printf()` into two printf calls.
2022-01-14 17:11:55 -08:00
153b9abc31 Old Compiler Warning Cleanup (GCC 4.0.2)
ssl.c: Fix a couple of checks on hashType enum that were using a `< 0`
for the lower bound on an unsigned.
2022-01-14 16:32:18 -08:00
021f9171c5 Fix building ASIO with Old TLS disabled. 2022-01-14 15:00:02 -07:00
eade8ecdf1 DTLS SRTP improvements. Added support for client to send list of profiles. Added support for more SRTP profiles. 2022-01-14 13:43:29 -08:00
1ed152daeb Fix building with OPENSSL_EXTRA and NO_BIO defined. 2022-01-14 11:19:01 -07:00
31e84d82b8 Domain check should only be performed on leaf certs
- Refactor `*_set_verify` functions into common logic
- NULL protect `wolfSSL_X509_VERIFY_PARAM_set1_host` and add debug info
2022-01-14 18:16:42 +01:00
6ccbd8776f DTLS SRTP (RFC5764) support (adds --enable-srtp). Used with WebRTC to agree on profile for new real-time session keys. 2022-01-14 07:35:45 -08:00
a33d901409 update ESP-IDF port to fix failure 2022-01-14 15:35:28 +09:00
f81e15f342 Merge pull request #4750 from SparkiDev/etm-disable
TLS EncryptThenMac; fix when extension response sent
2022-01-13 13:33:57 -08:00
8d7059497e Merge pull request #4742 from elms/fix/secure_renegotiate_compat
TLS: Default secure renegotiation compatibility
2022-01-13 10:23:27 -08:00
1a4bc322f7 Fix buffer overflow in PKCS7_VerifySignedData
wc_PKCS7_AddDataToStream() was called the first time prior to BERtoDER
conversion, subsequent times afterwards which meant the stream idx
pointer was incorrect. This patch restarts the stream after conversion.

Fixes ZD13476
2022-01-13 14:49:31 +00:00
92d01611ff Fix buffer overflow in GetOID
When converting BER to DER we switched the pointer for pkiMsg to the DER
but not the size which could cause buffer overflow.

Fixes ZD13471
2022-01-13 13:26:32 +00:00
70b169e3f2 TLS EncryptThenMac; fix when extension response sent
Only respond with the extension when negotiated a block cipher.
2022-01-13 12:46:21 +10:00
ba579753ba Merge pull request #4749 from ejohnstown/vpath-fix 2022-01-12 17:06:37 -08:00
15c5ac880e PKCS7 Test Output
When running the test with PKCS7 enabled, there's an additional option
that will save to disk the generated PKCS7 blobs for by-hand review.
(PKCS7_OUTPUT_TEST_BUNDLES) Fixed a couple compile errors that were
missed with that option enabled.
2022-01-12 14:51:11 -08:00
33f0e2eda5 In the wolfCrypt test, fix a few filenames to use the VPATH versions. 2022-01-12 14:50:43 -08:00
0acf8d0e75 Merge pull request #4732 from embhorn/zd13375
SP int, TFM: Init vars for static analysis
2022-01-13 07:06:19 +10:00
3ddfb0f189 Aarch64 SHA512: fixup to work on Apple M1
Directive needed on Apple to indicate SHA3 extensions available.
Fixup C file as well - remove unused constants not avaiable and
prototype function that is extern elsewhere.
2022-01-12 12:56:39 +10:00
336e595ebb Remove some lingering oldname return values 2022-01-11 17:09:52 -08:00
723cfb2d0b make server/client only work 2022-01-12 09:23:23 +09:00
efe2cea8d1 TLS: Default secure renegotiation compatability
By default this change will have servers send the renegotiation info
extension, but not allow renegotiation. This is accordance with RFC 5746

From to RFC 5746:
> In order to enable clients to probe, even servers that do not support
> renegotiation MUST implement the minimal version of the extension
> described in this document for initial handshakes, thus signaling
> that they have been upgraded.

With openSSL 3.0 the default it not allow connections to servers
without secure renegotiation extension. See
https://github.com/openssl/openssl/pull/15127
2022-01-11 15:56:35 -08:00
abc9b7197d Merge pull request #4676 from ThalesGroup/iotsafe-hkdf-extract
Iotsafe hkdf extract
2022-01-11 07:37:30 -08:00
f0f65f41b7 addressed review comments 2022-01-11 19:53:54 +09:00
c7b0b7003e Merge pull request #4700 from dgarske/pkcs11_id
Improved the PKCS11 init to support slotId or tokenName
2022-01-11 14:25:37 +10:00
30777bb5ee nit minor changes 2022-01-11 10:08:52 +08:00
9a4981a5a8 Improved the PKCS11 init to support slotId or tokenName. Adds new wc_Pkcs11Token_InitName and alters existing wc_Pkcs11Token_Init to allow NULL tokenName. ZD13348 2022-01-10 16:53:01 -08:00
5910ada93d Merge pull request #4736 from douzzer/20220107-cppcheck-hygiene
cppcheck sweep
2022-01-10 12:52:22 -08:00
6a02826bbf Merge pull request #4740 from dgarske/sess_names_docs
Session doc and naming cleanups
2022-01-10 14:38:47 -06:00
5392190807 Merge pull request #4741 from danielinux/psoc6-sha512-fix
PsoC6 hw crypto: added missing wc_InitSha512_ex()
2022-01-10 12:32:13 -08:00
814e7c91e0 PsoC6 hw crypto: added missing wc_InitSha512_ex() 2022-01-10 18:30:53 +01:00
f72d198778 Merge pull request #4723 from dgarske/se050 2022-01-10 10:11:49 -07:00
43bbc5d2e5 Merge pull request #4738 from SparkiDev/sp_int_div_arm_2
SP int: ARM64/32 sp_div_word changes
2022-01-10 07:58:28 -08:00
6ce248e2f9 Improve documentation for wolfSSL_get1_session. Add wolfSSL specific naming on the internal session functions to avoid possible user conflicts. ZD13363 and ZD13487. 2022-01-10 07:47:19 -08:00
5cce1926bb Init vars for static analysis 2022-01-10 08:24:29 -06:00
6398087d5b SP int: ARM64/32 sp_div_word changes
Fixup up formatting.
Fix comments.
Aarch64: don't use variable r when hi can be used.
ARM 32-bit: Add a version that uses udiv - not available on all chips
and can be slower anyway.
2022-01-10 16:27:39 +10:00
1a291870a3 minor fixes 2022-01-10 10:28:14 +08:00
4bbf90d604 Merge pull request #4702 from SparkiDev/sp_int_div_arm
SP int: transplant the div_word from SP into SP int for ARM64 and ARM32
2022-01-09 17:54:39 -08:00
355b5821b2 WOLFSSL_SESSION_EXPORT: fixes for scan-build complaints (deadcode.DeadStores) building --enable-all --enable-sessionexport. 2022-01-08 11:43:56 -06:00
c50964cc35 src/internal.c: fix flubbed edit in wolfSSL_session_import_internal(). 2022-01-08 11:08:57 -06:00
49fc54ef1f linuxkm/linuxkm_wc_port.h: move XMALLOC/XREALLOC/XFREE definitions outside BUILDING_WOLFSSL gate as-was, for back-compat. 2022-01-08 02:41:02 -06:00
56c28ff307 src/ssl.c: in wolfSSL_SESSION_has_ticket(), add (void)sess if !defined(HAVE_SESSION_TICKET), to fix -Wunused-parameter. 2022-01-08 02:39:50 -06:00
ff0eb5a41e wolfcrypt/test/test.c: in wolfcrypt_test(), tweak formatting of CheckRunTimeSettings() to resolve invalidPrintfArgType_uint from cppcheck --force. 2022-01-08 01:35:46 -06:00
a4444e6c3e wolfcrypt/test/test.c: in rsa_oaep_padding_test(), remove accidentally repeated MEMORY_E check. 2022-01-08 01:10:02 -06:00
7341b54a20 wolfssl/wolfcrypt/tfm.h: fixes for cppcheck complaints: preprocessorErrorDirective[division/modulo by zero] 2022-01-08 00:34:33 -06:00
cb86da71fa wolfssl/wolfcrypt/ecc.h: fixes for cppcheck complaints: preprocessorErrorDirective[division/modulo by zero] 2022-01-08 00:34:22 -06:00
fdb6a2d87d wolfssl/test.h: fixes for cppcheck complaints: nullPointerRedundantCheck invalidScanfArgType_int 2022-01-08 00:34:09 -06:00
29fcbb0b19 wolfcrypt/test/test.c: fixes for cppcheck complaints: memleakOnRealloc nullPointerRedundantCheck uninitvar invalidPrintfArgType_uint 2022-01-08 00:33:54 -06:00
70ab36f81c wolfcrypt/src/wc_port.c: fixes for cppcheck complaints: uninitvar nullPointer 2022-01-08 00:33:33 -06:00
8aa1100508 wolfcrypt/src/wc_pkcs11.c: fixes for cppcheck complaints: uninitvar 2022-01-08 00:32:48 -06:00
71b0b89e95 wolfcrypt/src/srp.c: fixes for cppcheck complaints: identicalInnerCondition 2022-01-08 00:32:37 -06:00
82b508b917 wolfcrypt/src/sha512.c: fixes for cppcheck complaints: nullPointerRedundantCheck 2022-01-08 00:32:26 -06:00
6e763825ed wolfcrypt/src/sha.c: fixes for cppcheck complaints: bufferAccessOutOfBounds 2022-01-08 00:32:14 -06:00
094d89bfb9 wolfcrypt/src/rsa.c: fixes for cppcheck complaints: identicalInnerCondition 2022-01-08 00:32:03 -06:00
24bb007d3c wolfcrypt/src/random.c: fixes for cppcheck complaints: uninitvar 2022-01-08 00:31:51 -06:00
1488e28ea3 wolfcrypt/src/port/ti/ti-aes.c: fixes for cppcheck complaints: missingReturn[false positive] 2022-01-08 00:31:36 -06:00
9e76ec8855 wolfcrypt/src/pkcs7.c: fixes for cppcheck complaints: nullPointerArithmeticRedundantCheck 2022-01-08 00:31:07 -06:00
dc98f4dd30 wolfcrypt/src/pkcs12.c: fixes for cppcheck complaints: uselessAssignmentPtrArg 2022-01-08 00:30:52 -06:00
67de528d91 wolfcrypt/src/logging.c: fixes for cppcheck complaints: invalidPrintfArgType_sint 2022-01-08 00:30:32 -06:00
f126e6add5 wolfcrypt/src/integer.c: fixes for cppcheck complaints: nullPointerRedundantCheck[false positive; added suppression] 2022-01-08 00:30:20 -06:00
1eb5537e34 wolfcrypt/src/fe_low_mem.c: fixes for cppcheck complaints: funcArgOrderDifferent 2022-01-08 00:30:00 -06:00
d4aa6bd1fc wolfcrypt/src/evp.c: fixes for cppcheck complaints: bufferAccessOutOfBounds nullPointerRedundantCheck 2022-01-08 00:29:47 -06:00
c557a74953 wolfcrypt/src/ecc.c: fixes for cppcheck complaints: invalidPrintfArgType_sint identicalInnerCondition 2022-01-08 00:29:35 -06:00
d36a1be74b wolfcrypt/src/dh.c: fixes for cppcheck complaints: identicalInnerCondition 2022-01-08 00:29:18 -06:00
11f72877a2 wolfcrypt/src/asn.c: fixes for cppcheck complaints: invalidPrintfArgType_uint nullPointerRedundantCheck 2022-01-08 00:29:09 -06:00
8ba6027073 src/wolfio.c: fixes for cppcheck complaints: nullPointer uninitvar 2022-01-08 00:28:35 -06:00
bb727d2ef2 src/ssl.c: fixes for cppcheck complaints: uselessAssignmentPtrArg autoVariables[not a defect; added suppression] invalidPrintfArgType_sint nullPointerRedundantCheck pointerSize 2022-01-08 00:28:09 -06:00
4d3dfc451d src/sniffer.c: fixes for cppcheck complaints: negativeIndex 2022-01-08 00:27:59 -06:00
b69dc00bd7 src/internal.c: fixes for cppcheck complaints: nullPointerRedundantCheck uninitvar 2022-01-08 00:27:47 -06:00
ff4c6e5d7b linuxkm: relocate WOLFSSL_LINUXKM code in wolfssl/wolfcrypt/wc_port.h and wolfcrypt/src/memory.c to linuxkm/{linuxkm_wc_port.h,linuxkm_memory.c}, and gate SIMD in IRQ handlers on -DLINUXKM_SIMD_IRQ in prep for Linux 5.16;
linuxkm: when -DWOLFCRYPT_ONLY, don't include ssl.h in module_exports.c.template and module_hooks.c, and fix gating to work right with that;

wolfssl/wolfcrypt/types.h: add support for a WOLFSSL_XFREE_NO_NULLNESS_CHECK gate (used in cppcheck analysis).
2022-01-07 22:39:38 -06:00
a14982b079 configure.ac: add ENABLED_WPAS to the config summary. 2022-01-07 21:36:24 -06:00
b4da751076 Fixes for SE050 Ed25519/Curve25519. 2022-01-07 12:54:54 -08:00
bbc9bc5e2c wolfcrypt/src/port/kcapi/kcapi_hmac.c: fix memory leak in wc_HmacSetKey() (fixes #4731). 2022-01-07 12:40:31 -06:00
b97894c617 Merge pull request #4729 from anhu/STM32U575xx
Add support for STM32U575xx boards.
2022-01-06 16:34:28 -08:00
f3e1e8c155 Add support for STM32U575xx boards. 2022-01-06 15:40:45 -05:00
d21105b3ca Merge pull request #4725 from elms/cmake/min_ver_3.16
cmake: Increase minimum version to 3.16 and fix HomeBrew build
2022-01-06 08:09:44 -08:00
f74831a7da Improve param checks of enc 2022-01-06 09:12:18 -06:00
0e6ba492e5 update signed ca
fix aes128-gcm crypt only usecase
2022-01-06 15:18:16 +09:00
252e2b6a99 Merge pull request #4726 from ejohnstown/typos
Fix a couple typos in asn.c
2022-01-05 14:51:50 -08:00
1e903a20a5 Merge pull request #4722 from dgarske/minor 2022-01-05 15:03:44 -05:00
32223b9c3a Merge pull request #4697 from LinuxJedi/isotp
Add ISO-TP support to wolfio
2022-01-05 10:34:43 -08:00
66ade8006b Fix a couple typos in asn.c 2022-01-05 10:24:25 -08:00
cc2b69573c cmake: Increase minimum version to 3.16 and fix HomeBrew build
Increasing cmake version required to allow use of more recent
additions in the future.

Reported issue is that Homebrew use different compiler than AppleClang
(from XCode). Correctly test for AppleClang to set xcode specific `ar`
and `ranlib` flags. It may also be appropraite to use for ANDROID as
well see
7d057b2738 (diff-6f7a068f87ca22bd0105fef2143b0960e4993854863fd20c9416c677ee33a737R61-R67)
2022-01-05 09:29:27 -08:00
e847bf7301 ISO-TP buffer fixes
* Flow control failed on wrap around when there is going to be no more
  flow control packets.
* If ISOTP_Send is provided more than 4095 bytes, limit it to 4095 bytes
  as wolfSSL will retry with the rest.
* Set the default receive size to the max ISO-TP data size.
* A few other cleanups.
2022-01-05 11:37:15 +00:00
84df7a50dc Minor build warning fixes. Possible benchmark unused bench_pq_asym_algs. Fix if RSA enabled and WOLFSSL_SP_MATH set and WOLFSSL_HAVE_SP_RSA is not. 2022-01-04 15:38:35 -08:00
96e1f77c32 Adds compatibility FIPS DRBG API's and test cases. 2022-01-04 15:13:06 -08:00
35847c1371 Merge pull request #4717 from embhorn/zd13452
Fix heap-buffer-overflow in GetBerHeader
2022-01-04 16:11:03 -07:00
be69412e27 Merge pull request #4682 from JacobBarthelmeh/qnx
add check on mutex lock return value with qnx CAAM
2022-01-04 14:36:40 -08:00
db1bb9ea6a Merge pull request #4694 from anhu/with-curl
Add a --enable-curl build option
2022-01-04 13:39:07 -08:00
cf29badd52 Merge pull request #4721 from anhu/lighty
lighttpd requires WOLFSSL_KEY_GEN…
2022-01-04 12:37:41 -08:00
038a9d8fa9 lighttpd requires WOLFSSL_KEY_GEN. Without it, a call to wolfSSL_CTX_use_PrivateKey fails. 2022-01-04 13:09:13 -05:00
58d8f52107 Merge pull request #4719 from JacobBarthelmeh/release
bump version for dev and update year in readme
2022-01-04 08:40:06 -08:00
247cbdeef7 Cleanups for ISO-TP in wolfio
* Add Doxygen comments
* Make ISOTP_Send, ISOTP_Receive and wolfSSL_SetIO_ISOTP safer
* Reorder isotp_wolfssl_ctx
* Other minor cleanups
2022-01-04 12:57:11 +00:00
12d3f94c98 update build and update NULL salt usecase 2022-01-04 13:18:39 +08:00
7dd50a1beb bump version for dev and update year in readme 2022-01-03 16:02:10 -07:00
3134bd2e71 Fix heap-buffer-overflow in GetBerHeader 2022-01-03 14:51:47 -06:00
a0b9e2bead Merge pull request #4715 from JacobBarthelmeh/release
update README for release v5.1.1
2022-01-03 10:51:51 -08:00
5f16a826dd update README for release v5.1.1 2022-01-03 09:39:16 -07:00
70ca57790c Merge pull request #4713 from ejohnstown/fips-RC12
FIPS RC12
2021-12-30 17:16:03 -08:00
68e58bb321 Update configure and fips-check.sh for FIPS RC12. 2021-12-30 15:21:44 -08:00
7ad7821193 Merge pull request #4712 from rizlik/aes_free_fix
Fix potential resources leaks
2021-12-30 13:57:04 -08:00
ea5374c62d wolfcrypt: aes: gcm: streaming api: add missing wc_AesFree() 2021-12-30 20:33:23 +01:00
4907696ed4 wolfssl: keys: add missing wc_AesFree() when setting new keys 2021-12-30 20:30:36 +01:00
2679c386ae wolfcrypt: wc_encrypt: add missing wc_AesFree() 2021-12-30 20:30:36 +01:00
933065d696 wolfcrypt: cmac: add missing wc_AesFree() 2021-12-30 20:30:36 +01:00
7edc916057 wolfcrypt/wolfssl: tests: adding missing wc_Aes*Free()
In some Aes implementation this may leak resources
2021-12-30 20:30:33 +01:00
67b27f64d0 Merge pull request #4708 from dgarske/async_v5.1.0
Fixes for wolfSSL Async v5.1.0
2021-12-29 13:30:41 -07:00
ff68ab8eea Merge pull request #4707 from JacobBarthelmeh/release
bump version by .1 for developing on
2021-12-29 12:09:43 -08:00
c4f51931c9 Merge pull request #4710 from JacobBarthelmeh/sessionExport
fix for location of xmemset
2021-12-29 11:52:08 -08:00
69733e87c5 SNI and ALT_CERT_CHAINS 2021-12-29 12:50:50 -05:00
73b4cc9476 fix for location of xmemset 2021-12-29 10:48:06 -07:00
bc6690c584 Merge pull request #4709 from miyazakh/Update_fspv3p5_RA6M3 2021-12-29 09:10:18 -07:00
d11e88298a Add Make file and fix identation 2021-12-29 11:45:32 +08:00
4fc2891d5a Merge branch 'wolfSSL:master' into iotsafe-hkdf-extract 2021-12-29 11:15:13 +08:00
f5df363cdd remove configure.xml from include.am 2021-12-29 11:16:14 +09:00
1d107d0403 update RA6M3 projects to the latest e2studio and FSP v3.5.0 2021-12-29 11:06:48 +09:00
930cad649e Fix to resolve possible memory leak with DSA wc_DsaPublicKeyDecode in API unit test when used with HAVE_WOLF_BIGINT. 2021-12-28 16:34:54 -08:00
0f9550d80a increase version for rpm build 2021-12-28 15:35:14 -08:00
616026880e bump version by .1 for dev 2021-12-28 16:25:05 -07:00
2b670c026d Merge pull request #4705 from JacobBarthelmeh/DTLS
account for DTLS extra header size when reading msg from pool
2021-12-27 19:16:26 -08:00
a07673ad07 Merge pull request #4706 from douzzer/20211227-fix-null-pointer-wolfSSL_EVP_CIPHER_CTX_ctrl
wolfcrypt/src/evp.c: fix wolfSSL_EVP_CIPHER_CTX_ctrl() null pointer…
2021-12-27 20:08:43 -07:00
aa05eb2879 wolfcrypt/src/evp.c: fix wolfSSL_EVP_CIPHER_CTX_ctrl() null pointer passed to XMEMCPY(), found by sanitizers under gcc-11.2.1. 2021-12-27 17:59:28 -06:00
05a19c852b account for DTLS extra header size when reading msg from pool 2021-12-27 16:52:09 -07:00
930cc053d5 Merge pull request #4704 from JacobBarthelmeh/release
prepare for release 5.1.0
2021-12-27 12:35:49 -08:00
d1b03eb8b9 add missing header files for rpm build 2021-12-27 09:49:47 -08:00
816718ecd3 prepare for release 5.1.0 2021-12-27 10:34:09 -07:00
cbab5bb6cb add kdf.c to MYSQL cmake build 2021-12-27 10:10:35 -07:00
5a4e59c09d fix warning about NULL compare 2021-12-27 10:02:16 -07:00
4e1c39b4c6 Merge pull request #4701 from SparkiDev/asn_templ_fix_1
ASN template: get compiling
2021-12-24 07:42:56 -08:00
fd31c017e1 Merge pull request #4703 from douzzer/20211224-fixits
20211224 ssl.c fixes
2021-12-24 07:42:00 -08:00
7c2a2229c5 Use XMEMCPY and defined constannts for ISOTP 2021-12-24 11:56:16 +00:00
54e9076c45 src/ssl.c: fix whitespace and heap reference in FreeSession() (re 569c066fab). 2021-12-24 01:16:32 -06:00
9d49884274 Merge pull request #4690 from dgarske/resume
Fixes for session resumption edge cases
2021-12-24 15:28:06 +10:00
02186dbd23 Fix for TLS v1.3 client session ticket resumption where the server opts to do a new handshake. Fix to make sure preMasterSz is valid. 2021-12-23 18:45:52 -08:00
a92fb0eb42 Fix for session resumption to ensure use of the right cipher suite. ZD13297 2021-12-23 18:42:41 -08:00
80a4793201 SP int: transplant the div_word from SP into SP int for ARM64 and ARM32 2021-12-24 12:26:19 +10:00
f1f15f411f Merge pull request #4688 from embhorn/gh4684
Fix missing include ws2tcpip.h for VS build
2021-12-24 11:58:12 +10:00
929174be6b Merge pull request #4667 from dgarske/zd13363
Improve TLS client side session cache references
2021-12-24 11:23:06 +10:00
4c6af465c4 ASN template: get compiling 2021-12-24 11:21:18 +10:00
a75e152b93 Merge pull request #4698 from JacobBarthelmeh/Jenkins
fix for user_settings_all.h build on 'VS' and build with libz + pkcs7 test
2021-12-23 16:54:40 -08:00
37925e0b6a Merge pull request #4699 from douzzer/ssl-wolfCrypt_SetPrivateKeyReadEnable_fips 2021-12-23 16:42:06 -08:00
1e4b13dfac Only include ws2tcpip.h if not user IO. 2021-12-23 15:25:25 -08:00
8eea17d92a More stuff, probably not complete yet 2021-12-23 17:28:24 -05:00
569c066fab Improve TLS client side session cache references to provide option for not returning an internal session cache pointer. Now use wolfSSL_get1_sesson for reference logic, that requires calling wolfSSL_SESSION_free. To disable this feature use NO_SESSION_CACHE_REF. 2021-12-23 14:25:45 -08:00
7b5b1f5a4d src/ssl.c: refine integration of wolfCrypt_SetPrivateKeyReadEnable_fips(), started by 52754123d9: depend on fips 5.1+, and call as matched pair in wolfSSL_Init() and wolfSSL_Cleanup(). 2021-12-23 16:05:25 -06:00
f950f24b1a Merge pull request #4691 from JacobBarthelmeh/sessionExport
retain same size for exported session
2021-12-23 14:03:11 -08:00
21c8b19fc2 Merge pull request #4696 from JacobBarthelmeh/build_tests
fix for a couple reports from build_tests
2021-12-23 13:42:06 -08:00
801c0c7efd Merge pull request #4549 from elms/cmake/ac_catchup
cmake/configure consistency
2021-12-23 13:49:44 -07:00
57d2555ac8 Merge pull request #4695 from douzzer/20211222-fips-config-update-and-fix-test_RsaDecryptBoundsCheck
fips config update and test-driven cleanup
2021-12-23 10:38:36 -08:00
bb8d38c2a1 Add ISO-TP support to wolfio
ISO-TP is a commonly used simple transport layer for CAN bus which
allows larger than the 1-8 bytes payload than the CAN bus protocol
allows.

This implements our own ISO-TP transport layer for wolfSSL when compiled
with `WOLFSSL_ISOTP`.
2021-12-23 18:27:34 +00:00
f9c9f4c840 refactor IP macro defines 2021-12-23 09:59:05 -08:00
c4e50ef086 fix for libz test with pkcs7 2021-12-23 09:37:09 -08:00
a8605309c6 Merge pull request #4692 from haydenroche5/wolfssl_init_fipsv5
Call wc_SetSeed_Cb and wolfCrypt_SetPrivateKeyReadEnable_fips in wolfSSL_Init.
2021-12-23 09:28:36 -08:00
9892f1f2d5 Merge pull request #4679 from dgarske/fips_ecc_pct 2021-12-23 10:27:51 -07:00
dc073f9c1d cmake: add back de-duplication and fix formatting 2021-12-23 09:22:47 -08:00
37eec1ed19 cmake: reduce port includes
TESTING:

```
./autogen.sh && ./configure --enable-reproducible-build --prefix=$PWD/ac_repro && make install
cmake -B b2 -DWOLFSSL_REPRODUCIBLE_BUILD=yes -DCMAKE_INSTALL_PREFIX:PATH=$PWD/cmake_repro && cmake --build b2 && cmake --install b2
diff -rq ac_repro cmake_repro
```
2021-12-23 09:22:47 -08:00
6ff1e0b037 cmake: correct libtool version, default to shared library, generate pkgconfig 2021-12-23 09:22:47 -08:00
c89b7d5f79 configure and cmake: Closing gap on options and output
cmake:
 * 32-bit and 16-bit mode flags
 * Add 4bit to AESGCM
 * Add align data
 * Encrypted Keys option
 * PKC12 option
 * Header installation cleanup

configure:
 * Add comment for `v5-RC9`
 * update CFLAGS to always be appended instead of mix of prepend and append
 * removed duplicate `ARC4` logic
2021-12-23 09:22:47 -08:00
63df8f0836 add fe_low_mem.c to wolfssl vs project and fix a couple warnings 2021-12-23 16:55:51 +00:00
40d5bd052f Merge pull request #4693 from embhorn/zd13433
Fix to init ctx in wc_Des3_SetKey
2021-12-23 07:41:13 -08:00
86e51b97e9 Merge pull request #4689 from haydenroche5/wolfengine_compression_fix
Fix usage of SSL_OP_NO_COMPRESSION that was breaking wolfEngine.
2021-12-23 10:47:30 +10:00
a5b3daf216 fix whitespace. 2021-12-22 17:34:06 -06:00
951eb72ecb fips-check.sh: update+streamline flavors -- add linuxv5-dev (checks out fips master same as old linuxv5-ready) , drop linuxv5-RC8, linuxv5-RC9, linuxv5-RC10, and the desupported/unbuildable fips-v3-ready; update linuxv5 and linuxv5-ready to use WCv5.0-RC11; use the term "flavor" consistently for the fips key (versus "version" or "platform"); cleanup to satisfy shellcheck. 2021-12-22 17:32:36 -06:00
a6ed5dc92d configure.ac: update fips with RC11. 2021-12-22 17:32:36 -06:00
b0a5b16068 api.c: fix logic in test_RsaDecryptBoundsCheck(). 2021-12-22 17:32:36 -06:00
29c18a110b Fix to init ctx in wc_Des3_SetKey 2021-12-22 17:05:58 -06:00
11e8d729c2 Merge pull request #4685 from SparkiDev/sp_gen_fix_1
SP gen: Regenerate
2021-12-22 15:02:03 -08:00
991ddaadfc Add a --enable-curl build option 2021-12-22 17:34:58 -05:00
52754123d9 Call wc_SetSeed_Cb and wolfCrypt_SetPrivateKeyReadEnable_fips in wolfSSL_Init.
Additionally, remove wc_SetSeed_Cb calls applications (e.g. example client and
server), since they are now redundant.
2021-12-22 14:21:06 -08:00
8670e33baf Merge pull request #4651 from TakayukiMatsuo/tsip_sce 2021-12-22 15:00:32 -07:00
fd39197e4b retain same size for exported session 2021-12-22 14:28:42 -07:00
646ceb259a Fix usage of SSL_OP_NO_COMPRESSION that was breaking wolfEngine.
Replace instances of SSL_OP_NO_COMPRESSION with WOLFSSL_OP_NO_COMPRESSION in
ssl.c. Only define SSL_OP_NO_COMPRESSION when using the compatibility layer.
Before these changes, wolfEngine builds were failing due to
SSL_OP_NO_COMPRESSION being defined in both wolfSSL and OpenSSL headers.
2021-12-22 10:23:51 -08:00
38214bd083 Disable the FIPS consistency checks in ECC and DH for key generation by default. 2021-12-22 10:06:19 -08:00
8d4c22abda Merge pull request #4687 from julek-wolfssl/asn-template-var-init
`items` needs to be initialized as the compiler complains
2021-12-22 08:58:54 -08:00
9d137668c7 Merge pull request #4675 from julek-wolfssl/openssh-8.8
Fix macro name conflicts with openssh
2021-12-22 08:31:36 -08:00
713c4afcb4 Fix missing include ws2tcpip.h for VS build 2021-12-22 09:26:22 -06:00
8435eb4644 Add WC_ namespace to variable handling defines 2021-12-22 12:16:02 +01:00
618599656f items needs to be initialized as the compiler complains 2021-12-22 10:42:48 +01:00
81cf1ae38a fix alignment 2021-12-22 15:16:08 +08:00
c7fc0fac05 revert changes + spelling/comments 2021-12-22 15:11:50 +08:00
9091cbde5f Merge branch 'wolfSSL:master' into iotsafe-hkdf-extract 2021-12-22 14:46:28 +08:00
ea432f45cd Merge pull request #4686 from SparkiDev/fe448_cast
Curve448: add casts for Windows
2021-12-21 22:21:25 -08:00
cd96330f2a Integrate Renesas TSIP specific code into Renesas common logics 2021-12-22 13:18:32 +09:00
140cf8955d Merge branch 'wolfSSL:master' into iotsafe-hkdf-extract 2021-12-22 12:01:11 +08:00
80e291fcd1 Curve448: add casts for Windows 2021-12-22 12:57:15 +10:00
dd9b1afb72 Remove magic numbers from WOLFSSL_ASN_TEMPLATE code (#4582)
* pkcs8KeyASN and other misc asn fixes

- Test fixes for testing with `USE_CERT_BUFFERS_1024`

* intASN

* bitStringASN

* objectIdASN

* algoIdASN

* rsaKeyASN

* pbes2ParamsASN

* pbes1ParamsASN

* pkcs8DecASN

* p8EncPbes1ASN

* rsaPublicKeyASN

* dhParamASN

* dhKeyPkcs8ASN

* dsaKeyASN

* dsaPubKeyASN

- Add `wc_SetDsaPublicKey` without header testing

* dsaKeyOctASN

* rsaCertKeyASN

* eccCertKeyASN

* rdnASN

* certNameASN

* digestInfoASN

* otherNameASN

* altNameASN

* basicConsASN

* crlDistASN

* accessDescASN

* authKeyIdASN

* keyUsageASN

* keyPurposeIdASN

* subTreeASN

* nameConstraintsASN

* policyInfoASN

* certExtHdrASN

* certExtASN

* x509CertASN

* reqAttrASN

* strAttrASN

* certReqASN

* eccPublicKeyASN

* edPubKeyASN

* ekuASN

* nameASN

* certExtsASN

* sigASN

* certReqBodyASN_IDX_EXT_BODY

* dsaSigASN

* eccSpecifiedASN

* eccKeyASN

* edKeyASN

* singleResponseASN

* respExtHdrASN

* ocspRespDataASN

* ocspBasicRespASN

* ocspResponseASN

* ocspNonceExtASN

* ocspRequestASN

* revokedASN

* crlASN

* pivASN

* pivCertASN

* dateASN

* `wc_SetDsaPublicKey` was not including `y` in the sequence length

* All index names changed to uppercase

* Shorten names in comments

* Make sure extensions have sequence header when in cert gen

* Fix/refactor size calc in `SetNameEx`

* Pad blocks for encryption

* Add casting for increased enum portability

* Use stack for small ASN types
2021-12-22 11:28:01 +10:00
af0bcef0ef Merge pull request #4648 from embhorn/zd13365
Fix - wolfSSL_init should cleanup on failure of a component
2021-12-21 17:17:16 -08:00
bf612c075b Merge pull request #4668 from ejohnstown/kcapi-ecdsa
KCAPI ECDSA Memory
2021-12-21 15:32:33 -08:00
bf37845e2d Merge pull request #4680 from JacobBarthelmeh/certs
update certificate expiration dates and fix autorenew
2021-12-22 08:48:35 +10:00
395c5815bd SP gen: Regenerate
Put back in fix for SAKKE.
2021-12-22 08:24:33 +10:00
a6a071771b Merge pull request #4681 from SparkiDev/sp_arm64_p384_mr
SP ARM64: P-384 prime specific Montogmery Reduction
2021-12-21 13:50:33 -08:00
bbfcd0cac8 fix build warning with af_alg 2021-12-21 10:20:34 -08:00
d29cdd3537 fix for --enable-ip-alt-name build 2021-12-21 09:53:58 -08:00
d28cb70735 fix for ed25519 client cert generation 2021-12-21 09:03:54 -08:00
78a419fdf5 spelling 2021-12-21 15:57:19 +08:00
ebff24353a fix Spelling 2021-12-21 15:53:57 +08:00
f1bbfa5a24 revert change on Derive Master secret 2021-12-21 15:51:32 +08:00
31cf4f305c fixing comments and spelling; fallback hkdf imp + signature header 2021-12-21 15:41:43 +08:00
343cfb32f2 add check on mutex lock return value with qnx CAAM 2021-12-20 17:41:06 -07:00
9f2419246e SP ARM64: P-384 prime specific Montogmery Reduction
Improves performance
2021-12-21 10:18:12 +10:00
c0f8fd5f5d update certificate dates and fix autorenew 2021-12-20 16:04:05 -08:00
6b47954d58 Merge pull request #4670 from julek-wolfssl/krb5-missing-api
Missing config for krb5 1.16.1
2021-12-20 15:54:41 -08:00
3644d97dd8 Merge pull request #4613 from SparkiDev/sp_div_max
SP math all: div handling of length of dividend
2021-12-20 15:10:35 -08:00
360a513696 Merge pull request #4553 from SparkiDev/sp_mont_inv_order_fix
SP: fix when mont_mul_order is defined
2021-12-20 15:09:08 -08:00
463d050d3d Merge pull request #4678 from dgarske/nightly
Nightly fixes: PK with no AES and OCSP test with DTLS
2021-12-21 09:00:22 +10:00
0ce9703768 Merge pull request #4666 from SparkiDev/ecc_enc_mem
ECC: better protection when using encrypted memory
2021-12-20 14:48:13 -08:00
bb306d14b7 Merge pull request #4643 from kareem-wolfssl/zd13328
Fix building with OPENSSL_EXTRA defined and NO_WOLFSSL_STUB not defined.
2021-12-21 08:02:17 +10:00
d588437504 Merge pull request #4677 from anhu/oqs_to_pqc
--with-liboqs now defines HAVE_LIBOQS and HAVE_PQC
2021-12-20 13:00:30 -08:00
d8b58b8b05 Put both DigiCert Global Root CA and GlobalSign Root CA into the Google CA list. Fixes --enable-dtls --enable-ocsp ./scripts/ocsp.test`. 2021-12-20 11:47:34 -08:00
ebc64db7d0 Fix for --enable-pkcallbacks --disable-aes --disable-aesgcm. 2021-12-20 10:17:50 -08:00
b290e8089c Merge pull request #4672 from SparkiDev/sp_c_mont_red
SP C: specific Montgomery reduction code for P256 and P384
2021-12-20 09:50:54 -08:00
79f6301521 Add error for case of user defining HAVE_PQC without HAVE_LIBOQS. 2021-12-20 12:42:09 -05:00
7d4c13b9a4 --with-liboqs now defines HAVE_LIBOQS and HAVE_PQC
AKA: The Great Rename of December 2021
2021-12-20 11:48:03 -05:00
93712fcfbd fallback in software imp if callback not supporting operation ie: NULL salt 2021-12-20 17:34:27 +08:00
d1f850273f add hkdf-extract to iotsafe implementation + sample application 2021-12-20 17:33:24 +08:00
6d2da74c21 Merge pull request #4625 from dgarske/zd13208
Fix for PKCS7 verify to handle content type OID with indef BER encoding
2021-12-20 14:49:59 +10:00
ce4f436d0f Merge pull request #4587 from SparkiDev/dis_algs_fix_1
Disable algorithms: fixes
2021-12-19 20:12:30 -08:00
2477574a69 Fix for PKCS7 verify to handle pkcs7-data content type OID with indef BER encoding. ZD13208 2021-12-17 14:24:35 -08:00
ab9eda636a Merge pull request #4671 from lealem47/remove-n
Removing extra \n from WOLFSSL_LEAVE and WOLFSSL_ENTER
2021-12-17 14:04:42 -08:00
b45f1ed761 KCAPI ECDSA Memory
Use page aligned memory when using ECDSA signing and verify.
2021-12-17 11:11:16 -08:00
97830b81d6 Merge pull request #4674 from anhu/uninitialized
Fix unitialized usage
2021-12-17 10:51:43 -08:00
771647615a Merge pull request #4669 from douzzer/rehab-configure-fips
FIPS configure cleanup
2021-12-17 08:58:44 -08:00
9cc1624023 Fix unitialized usage 2021-12-17 11:55:08 -05:00
2f0b451545 Merge pull request #4673 from julek-wolfssl/should-retry-fix
Fix `test_wolfSSL_BIO_should_retry` test
2021-12-17 08:16:16 -07:00
21a5a571e8 Fix test_wolfSSL_BIO_should_retry test
When `OPENSSL_COMPATIBLE_DEFAULTS` is defined then `SSL_MODE_AUTO_RETRY` is set on context creation. For this test we need to clear this mode so that the `WOLFSSL_CBIO_ERR_WANT_READ` can propagate up to the user.
2021-12-17 12:32:25 +01:00
bd515cd3a6 Merge pull request #4637 from SparkiDev/sp_c32_rsa
SP C RSA: normalize tmpa after conditionally adding p
2021-12-16 18:54:28 -08:00
6cac0ea5a9 SP C: specific Montgomery reduction code for P256 and P384
Improves performance of 32-bit and 64-bit SP C code.
2021-12-17 12:00:16 +10:00
5c6bd8c2c9 configure.ac: in fips v5 setup, consider HAVE_AES{CCM,CTR,GCM,OFB}_PORT when auto-setting -DWOLFSSL_AES_DIRECT -DHAVE_AES_ECB; refactor KCAPI options for readability and correctness. 2021-12-16 17:03:01 -06:00
0b2b218de7 ECC: better protection when using encrypted memory
Added new ECC scalar multiplication implementation.
2021-12-17 08:30:45 +10:00
a79440b95a Removing extra \n from WOLFSSL_LEAVE and WOLFSSL_ENTER 2021-12-16 13:30:43 -07:00
f889916fae ssl.c: fix C++ invalid conversion in wolfSSL_sk_X509_INFO_value(). 2021-12-16 13:29:17 -06:00
e35c3c0d71 wolfcrypt/src/wc_port.c: fix whitespace. 2021-12-16 13:01:01 -06:00
cf16480c85 configure.ac: fix hard tabs, and fix fips "v5-ready" that should have been "v5-dev". 2021-12-16 13:00:10 -06:00
b7307e0ca5 ecc.c: small stack refactor for mp_int on the stack in wc_ecc_gen_deterministic_k(). 2021-12-16 13:00:10 -06:00
fed5eb1d94 ecc.c: fix a deadcode.DeadStores warning in wc_ecc_gen_deterministic_k(). 2021-12-16 13:00:10 -06:00
b6b12fe946 configure.ac: fips cleanup: drop flavor keys "v5-REL" (confusing); drop "v3" aka "v3-ready" (no longer buildable); add flavor "v5-dev" aka "dev"; refactor the "v5*" case of the FIPS setup switch to impose feature locks for v5 and v5-ready, but allow feature overrides with the new v5-dev; fix a debugging echo in the v2 case added in 1c27654300. 2021-12-16 13:00:10 -06:00
dec78169bf Merge pull request #4658 from julek-wolfssl/apache-2.4.51
Add Apache 2.4.51 support
2021-12-16 08:52:10 -08:00
ea2245c4d1 Merge pull request #4656 from JacobBarthelmeh/SanityChecks
sanity check before reading policy constraint
2021-12-16 08:42:19 -08:00
424bd2d73d Merge pull request #4599 from julek-wolfssl/issue-4593
Add WOLFSSL_FORCE_AUTO_RETRY option: force retrying of network reads
2021-12-16 08:42:07 -08:00
3bd737b9ef Merge pull request #4665 from miyazakh/sce_fsp_update_v3p5 2021-12-16 09:39:13 -07:00
7699d92935 Merge pull request #4664 from anhu/Fix_ENCRYPT_LEN
Do not let anything override HAVE_LIBOQS when setting ENCRYPT_LEN
2021-12-16 07:51:32 -08:00
44cc9e4824 Fix - wolfSSL_init should cleanup on failure of a component 2021-12-16 09:50:50 -06:00
afa6237f56 Add WOLFSSL_FORCE_AUTO_RETRY option: force retrying of network reads 2021-12-16 15:33:30 +01:00
d5783d1eaa Missing config for krb5 1.16.1 2021-12-16 14:35:39 +01:00
017d6cf464 Simplify error queue macros 2021-12-16 12:39:58 +01:00
e78f7f734e Add Apache 2.4.51 support
- Define `OPENSSL_COMPATIBLE_DEFAULTS` and `WOLFSSL_NO_OCSP_ISSUER_CHECK` for Apache config
- Fix `SSL_set_timeout` to match OpenSSL signature
- Implement `pkey` in `X509_INFO`
- Detect attempt to connect with plain HTTP
- Implement `wolfSSL_OCSP_request_add1_nonce`
- Set `ssl->cipher.bits` when calling `wolfSSL_get_current_cipher`
- Use custom flush method in `wolfSSL_BIO_flush` when set in BIO method
- Set the TLS version options in the `ssl->options` at the end of ClientHello parsing
- Don't modify the `ssl->version` when in a handshake (`ssl->msgsReceived.got_client_hello` is set)
- `wolfSSL_get_shutdown` returns a full bidirectional return when the SSL object is cleared. `wolfSSL_get_shutdown` calls `wolfSSL_clear` on a successful shutdown so if we detect a cleared SSL object, assume full shutdown was performed.
2021-12-16 12:39:38 +01:00
fa913f797a Merge pull request #4657 from SparkiDev/sakke_cond_add
SAKKE: fixup cond add to use all words
2021-12-16 07:40:13 +01:00
63ade421c1 fix redundat #ifdef 2021-12-16 09:30:21 +09:00
bd7e19b8fe Merge pull request #4639 from JacobBarthelmeh/ECC
deterministic ECC sign edge case fix and add variant
2021-12-16 08:48:37 +10:00
abe8696852 Merge pull request #4642 from cconlon/pubKeyDerFromX509
Add wc_GetPubKeyDerFromCert()
2021-12-15 14:30:58 -08:00
7975ead1af Do not let anything override HAVE_LIBOQS when setting ENCRYPT_LEN because oqs wants biggest value. 2021-12-15 14:48:50 -05:00
e1cee463b6 Merge pull request #4662 from douzzer/20211214-fixits
20211214 fixits
2021-12-15 10:47:50 -08:00
463118005f Merge pull request #4663 from ejohnstown/revert-pr
Revert configure.ac PR
2021-12-15 12:33:19 -06:00
8688bd43f1 Revert "Swap v5-ready (exception) and v5, add the wildcard back in for all non-ready cases"
This reverts commit 23fbf2e786.
2021-12-15 10:24:05 -08:00
1b6e0c45d0 Merge pull request #4660 from kaleb-himes/FIPS_READY_KCAPI_FOLLOWUP
Swap v5-ready (exception) and v5, add the wildcard back in for all non-ready cases
2021-12-15 10:16:33 -08:00
5172130287 add wc_GetPubKeyDerFromCert(), get pub key DER from DecodedCert 2021-12-15 11:04:52 -07:00
9af9d96cc7 Update README for FSP v3.5.0
fix tyo
2021-12-15 15:46:16 +09:00
a773cdfd5d pkcs12.c wc_d2i_PKCS12_fp(): mollify Visual Studio (false positives C4701 and C4703). 2021-12-14 18:33:24 -06:00
242eb2dcf1 wolfcrypt/src/pkcs12.c: fix scan-build deadcode.DeadStores gripe. 2021-12-14 18:08:54 -06:00
eb032e0266 configure.ac: refactor changes of 7cccaa98b7 around FIPS v5*. 2021-12-14 18:08:12 -06:00
23fbf2e786 Swap v5-ready (exception) and v5, add the wildcard back in for all non-ready cases 2021-12-14 13:28:35 -07:00
a6c7d56c32 Merge pull request #4655 from haydenroche5/wc_pkcs12_from_file
Add wc_d2i_PKCS12_fp to parse a PKCS #12 file directly in wolfCrypt.
2021-12-14 08:58:57 -08:00
994e370db3 SAKKE: fixup cond add to use all words 2021-12-14 12:02:59 +10:00
2359045b28 Merge pull request #4649 from kaleb-himes/KCAPI_FIPS_READY
The minimal changes needed to add KCAPI support with fips-ready
2021-12-13 17:33:03 -08:00
92d207a1cd Add wc_d2i_PKCS12_fp to parse a PKCS #12 file directly in wolfCrypt. 2021-12-13 15:28:34 -08:00
a2cf234100 sanity check before reading policy constraint 2021-12-13 14:32:46 -08:00
f5cd61e4f9 Merge pull request #4654 from embhorn/zd13375
Fix _sp_exptmod_base_2 to init vars.
2021-12-14 07:38:20 +10:00
7fd1b7aa51 Merge pull request #4650 from anhu/changelog
Mention falcon in the changelog
2021-12-13 10:37:07 -08:00
638d00f593 Merge pull request #4634 from danielinux/iotsafe-16bit-id
IoT-SAFE module: improvements and bug fixes
2021-12-13 11:33:19 -07:00
caf9024984 Merge pull request #4652 from douzzer/no-rsa-no-dh-no-dsa
WOLFSSL_ECC_NO_SMALL_STACK etc
2021-12-13 10:12:14 -08:00
9a85638ac3 Merge pull request #4647 from anhu/evp_pkey_dummy_falcon
In d2iGenericKey(), if a falcon key is encountered, make a dummy pkey.
2021-12-13 10:12:07 -08:00
53eb5d2e5a Fix _sp_exptmod_base_2 to init vars. 2021-12-13 10:16:55 -06:00
355b779a3e feature gating tweaks to better support --disable-rsa --disable-dh --disable-dsa. also a whitespace fix in ssl.c. 2021-12-11 14:08:04 -06:00
2193df1d62 add WOLFSSL_ECC_NO_SMALL_STACK. 2021-12-10 23:57:14 -06:00
41d4aafa3f Merge pull request #4645 from haydenroche5/parse_cert_public
Make wolfCrypt ASN cert parsing functionality public.
2021-12-10 18:27:18 -08:00
eec9649049 Mention falcon in the changelog 2021-12-10 16:54:13 -05:00
7cccaa98b7 The minimal changes needed to add KCAPI support with fips-ready 2021-12-10 14:44:20 -07:00
4c12f0be95 Only one call to wc_falcon_init() and comment on 300. 2021-12-10 16:40:41 -05:00
1d8ff70900 In d2iGenericKey(), if a falcon key is encountered, make a dummy pkey.
This allows apache-httpd to work without PQ-specific patch along with a previous
pull request.
2021-12-10 14:18:42 -05:00
6764e7c15f Make wolfCrypt ASN cert parsing functionality public.
Currently, the `ParseCert` function is only available if `WOLFSSL_ASN_API` is
defined to `WOLFSSL_API`. The only way to achieve this without enabling the
compatibility layer is to define `WOLFSSL_TEST_CERT`. There are users defining
this so that they can parse certs with wolfCrypt, even though this doesn't seem
to be the original intent of the define. This commit adds the function
`wc_ParseCert` to the public wolfCrypt API. It's simply a wrapper around
`ParseCert`. Similarly, this commit adds `wc_InitDecodedCert` and
`wc_FreeDecodedCert` to the public API, which are wrappers around
`InitDecodedCert` and `FreeDecodedCert`, respectively.
2021-12-10 10:43:28 -08:00
dde8cd9039 Merge pull request #4646 from julek-wolfssl/SSL_OP_NO_COMPRESSION-redef-error
Fix redefinition error of `WOLFSSL_OP_NO_COMPRESSION`
2021-12-10 08:46:43 -08:00
65a0b71994 Merge pull request #4641 from anhu/priv_key_check
Actually do a private/public key check for FALCON.
2021-12-10 06:53:35 -08:00
e40ba00ece Fix redefinition error of WOLFSSL_OP_NO_COMPRESSION 2021-12-10 15:11:11 +01:00
6b5fa9d0ae remove consistency check; let it fail elsewhere. 2021-12-09 17:12:42 -05:00
b921161309 Merge pull request #4633 from SparkiDev/tls13_expired
TLS13: Skip if expired rather than turning off resuming
2021-12-09 14:10:42 -08:00
dd0e3d6ebf Merge pull request #4644 from kareem-wolfssl/iotsafe_class
Fix compiling Iotsafe with C++ by avoiding reserved keyword 'class'.
2021-12-09 09:10:24 -08:00
494abde3eb Better casting. 2021-12-09 09:45:28 -05:00
f02763b088 Fixes after review comments 2021-12-09 11:23:44 +01:00
4764c4d6fa Merge pull request #4636 from JacobBarthelmeh/client
print out PEM of peer cert with example client
2021-12-08 20:04:57 -08:00
32014c69fd TLS 13 session ticket timeout: fixup checks
Check difference between now and ticket seen from encrypted ticket
against timeout.
2021-12-09 12:43:30 +10:00
6da0cc1ced Merge pull request #4600 from dgarske/cust_oid
Support for Custom OID in subject and CSR request extension
2021-12-09 11:24:30 +10:00
4200cf1b4d Fix compiling Iotsafe with C++ by avoiding reserved keyword 'class'. 2021-12-08 17:17:58 -07:00
376be0f66a Fix building with OPENSSL_EXTRA defined and NO_WOLFSSL_STUB not defined. 2021-12-08 16:51:51 -07:00
7022eb6f89 Actually do a private/public key check for FALCON. 2021-12-08 18:04:11 -05:00
dac0c21989 Merge pull request #4640 from anhu/prevent_stack_corruption
Pass in pointer to a local size_t var, not word32 var to prevent stack corruption
2021-12-08 14:44:07 -08:00
cf0d3263ac Merge pull request #4628 from julek-wolfssl/issue-4623
Handle an `EPIPE` error from the socket
2021-12-09 08:08:56 +10:00
74442605fa Pass in pointer to a local size_t var, not word32 var to prevent stack corruption. 2021-12-08 16:01:52 -05:00
ad078a7358 adjust macro guard in example client 2021-12-08 13:45:37 -07:00
0446d93285 add deterministic k variant for ECC to enable all 2021-12-08 10:49:17 -07:00
dfce101b5b deterministic ECC sign edge case fix and add variant 2021-12-08 09:54:47 -07:00
dd0e1226b7 Merge pull request #4638 from miyazakh/sce_protect_iar_compiler 2021-12-08 09:50:16 -07:00
081d28f556 better handling for global index
fix function proto type definition
2021-12-08 11:42:23 +09:00
3b65a4876f SP C RSA: normalize tmpa after conditionally adding p
Numbers in a word get too big for fast mul implementation when not
normalized.
Only affects RSA keys where p < q.
2021-12-08 11:25:20 +10:00
9a07b3af9b print out PEM of peer cert with example client 2021-12-07 14:07:47 -07:00
8609d98122 Merge pull request #4635 from julek-wolfssl/PrintPubKeyEC-wrong-free
Return early on failed `key` init
2021-12-07 13:28:53 -07:00
223f25149b Return early on failed key init 2021-12-07 18:11:19 +01:00
96daf2bede Merge pull request #4632 from julek-wolfssl/PrintPubKeyEC-leak
`a` and `key` were not being freed => leak in `PrintPubKeyEC`
2021-12-07 07:20:05 -07:00
1cb8b34fba IoT-SAFE: minor fixes + doxygen for new API calls 2021-12-07 14:11:14 +01:00
9e73c324a4 iot-safe: Fixed debug printf, updated slot number for 16-bit demo 2021-12-07 14:11:14 +01:00
23982e4fb3 Fixed wolfIoT_ecc_keygen when key is stored during generation 2021-12-07 14:11:14 +01:00
b23d51ab78 Avoid looping on uart read after applet initialization fails 2021-12-07 14:11:14 +01:00
5da89c6275 Clear meaning for the return value of iotsafe_gen_keypair 2021-12-07 14:11:14 +01:00
4d483b0a28 iotsafe: allow init to continue with empty response 2021-12-07 14:11:13 +01:00
29e20eeadc Fix to rebase branch on current master 2021-12-07 14:11:13 +01:00
e551f439f4 Reworked expect_tok to fix NULL dereferences 2021-12-07 14:11:13 +01:00
0c0f36d67d IoT-SAFE: Minor fixes
- reverted length change in put public operation
- Loading CA from IoT-SAFE file slot in 16bit demo
2021-12-07 14:11:13 +01:00
2646747f2a Fixed 8bit variable overflow/useless code 2021-12-07 14:11:13 +01:00
0621ba061b Multiple fixes for IoT-SAFE
- Tested with a different SIM:
  - 16bit IDs
  - Directly retrieving public key from keygen function
  - larger response buffers (up to 256 bytes in ReadFile)
  - Fixed hardcoded length in ID buffers
2021-12-07 14:11:13 +01:00
2f17a7e626 Support longer-than-8bit IDs for IoTSAFE key/file slots 2021-12-07 14:11:13 +01:00
574d171357 Fix leak when mp_int = 0 in integer.c 2021-12-07 12:46:24 +01:00
85ec6054c6 TLS13: Skip if expired rather than turning off resuming 2021-12-07 13:58:38 +10:00
9f6aa36866 Merge pull request #4629 from dgarske/zd13337
Additional checking for side on TLS messages
2021-12-07 10:13:44 +10:00
e1b7363647 Fixes from peer review. 2021-12-06 16:12:07 -08:00
261d305b32 Merge pull request #4627 from cconlon/fipsOsSeed 2021-12-06 16:06:46 -08:00
d5c27fca7d Merge pull request #4626 from JacobBarthelmeh/certs
add human readable string of IP
2021-12-07 08:23:31 +10:00
579056a2f3 Subject raw should be populated with WOLFSSL_CERT_EXT. 2021-12-06 14:19:32 -08:00
e45c33a771 Merge pull request #4624 from miyazakh/jenkins_qt_failure 2021-12-06 09:53:34 -07:00
5107f6b752 Merge pull request #4630 from douzzer/20211204-nits
20211204 nits
2021-12-06 08:24:17 -08:00
96b8b11fba a and key were not being freed => leak in PrintPubKeyEC 2021-12-06 12:03:02 +01:00
30b68060fb configure.ac: fix whitespace; client.c: make gcc 5.4.0 -Wmaybe-uninitialized happy. 2021-12-04 00:57:49 -06:00
54c3e0ac73 Additional checking for side on TLS messages. ZD13337 2021-12-03 11:49:08 -08:00
e4bd5d9046 Handle an EPIPE error from the socket
Issue reported in https://github.com/wolfSSL/wolfssl/issues/4623
2021-12-03 17:44:53 +01:00
9eabf16ed8 fix redefinition of OS_Seed error with FIPS Ready on some compilers 2021-12-02 17:01:11 -07:00
1ec86ee4cc add human readable string of IP 2021-12-02 16:04:58 -07:00
b4c6140b64 Merge pull request #4442 from julek-wolfssl/kerberos
Add Kerberos 5 support
2021-12-02 09:07:34 -08:00
baee7bace4 Merge pull request #4584 from ethanlooney/nxp_se050_curve25519
Added curve25519 support for NXP SE050
2021-12-02 02:47:36 -08:00
a5bd6cde8d fix nigtly jenkins Qt Job failure 2021-12-02 16:37:48 +09:00
48b15b0dfb Merge pull request #4616 from SparkiDev/sp_int_mips32
SP math all: MIPS asm fix
2021-12-01 16:16:14 -08:00
9f611e8b80 Merge pull request #4589 from JacobBarthelmeh/native-lwip
Native LwIP support update
2021-12-01 10:37:13 -08:00
5c172ca955 Merge pull request #4622 from douzzer/fix-wolfsentry-build
wolfsentry fixes re HAVE_EX_DATA and wolfsentry_sockaddr
2021-12-01 08:16:07 -08:00
d06ada2ccc Merge pull request #4610 from julek-wolfssl/nginx-1.21.4
Add support for Nginx 1.21.4
2021-12-01 22:27:12 +10:00
aac1b406df Add support for Nginx 1.21.4
- Add KEYGEN to Nginx config
- Check for name length in `wolfSSL_X509_get_subject_name`
- Refactor `wolfSSL_CONF_cmd`
- Implement `wolfSSL_CONF_cmd_value_type`
- Don't forecfully overwrite side
- `issuerName` should be `NULL` since the name is empty
2021-12-01 09:49:52 +01:00
32db20143c wolfssl/test.h: fix --enable-wolfsentry CFLAGS=-pedantic. 2021-11-30 23:40:30 -06:00
3f65916f3a HAVE_EX_DATA: fix wolfssl/ssl.h and tests/api.c to build -DHAVE_EX_DATA but -UOPENSSL_EXTRA. 2021-11-30 23:39:16 -06:00
7b5b4015f6 Merge pull request #4621 from dgarske/zd13303 2021-11-30 21:04:41 -06:00
43ac0d3684 adjust test file for pritnf and test_pass 2021-11-30 16:41:02 -07:00
b69a1c860c Merge pull request #3996 from cconlon/pkcs7_detachedhash
adjust PKCS7_VerifySignedData to correctly verify precomputed content hash with detached signature
2021-11-30 12:46:46 -08:00
a0300f7ab0 Fixes for ECDSA_Size. If group is unknown set to -1, otherwise defaults to first ECC index. Fix the signature size calculation to use our existing enum and calculation logic. ZD13303 2021-11-30 12:33:49 -08:00
1e74c6f38d Merge pull request #4620 from JacobBarthelmeh/Testing
do not load example CA if not verifying peer
2021-11-30 12:17:58 -08:00
29517fd617 Merge pull request #4609 from danielinux/tls13_hkdf_callback
TLS 1.3: Add HKDF extract callback
2021-11-30 10:59:44 -08:00
6d4c067b72 Merge pull request #4607 from anhu/wolfcrypt_pq_benchmarks
Use wolfCrypt's benchmarking app to run the PQ algorithms.
2021-11-30 10:09:48 -08:00
0340b49ff9 do not load example CA if not verifying peer 2021-11-30 10:44:05 -07:00
d32f26de64 Merge pull request #4619 from kojo1/early_data
OpneSSL compat for SSL_read/write_early_data
2021-11-30 08:36:14 -08:00
d3d73f7a4e Merge pull request #4614 from SparkiDev/sp_exp_nct
SP math all: fix exponent bit count
2021-11-30 08:26:41 -08:00
37df78b082 Merge pull request #4615 from SparkiDev/mp_mulx
TFM: fix Intel MULX multiply
2021-11-30 08:26:17 -08:00
5a55baddad Merge pull request #4617 from SparkiDev/ecc_point_on_curve
ECC wc_ecc_point_is_on_curve: validate oridinates against prime
2021-11-30 08:25:47 -08:00
7a41089b12 Merge pull request #4618 from douzzer/wc-port-h-linuxkm-XSNPRINTF-XATOI
linuxkm wc_port.h macro scoping fix
2021-11-30 08:25:06 -08:00
78f4c84ee0 Merge pull request #4586 from SparkiDev/sp_gen_ecc_order
SP: fix range of k to be 1..n-1
2021-11-30 08:23:46 -08:00
c3b1d9f9e7 Cosmetic and prototypes changes after reviewer's comments 2021-11-30 10:06:54 +01:00
6af38a9f5b OpneSSL compat for SSL_read/write_early_data 2021-11-30 17:38:01 +09:00
a33ae21801 whitespace cleanups and portability/pedantic fixes 2021-11-29 23:58:39 -06:00
5fbdd2a2c0 wc_port.h: for linuxkm, move definitions of XSNPRINTF and XATOI macros outside the defined(BUILDING_WOLFSSL) gate, to prevent inclusion of stdio.h and stdlib.h from types.h when building application code. 2021-11-29 23:23:23 -06:00
567cd155ea ECC wc_ecc_point_is_on_curve: validate oridinates against prime 2021-11-30 14:17:41 +10:00
a7d538a82f SP math all: MIPS asm fix
Names $lo and $hi in register list are not supported with old GCC
compiler. Newer compiler also supports %lo and %hi.
2021-11-30 12:56:08 +10:00
9f6fd6abf9 TFM: fix Intel MULX multiply
Carry wasn't being handled properly.
2021-11-30 12:07:44 +10:00
e5e280b175 SP math all: fix exponent bit count
Only when using non-constant time implementation and modulus even.
2021-11-30 10:28:42 +10:00
a3d46bee32 SP math all: div handling of length of dividend
Fail when dividend is maximum size as we may be shifting left and
overflow when divisor is not on a word boundary.
2021-11-30 09:46:11 +10:00
f7c34d22e6 add calls to user callback and adjust formating 2021-11-29 15:56:00 -07:00
7221e06ff7 Merge pull request #4588 from miyazakh/sce_protect_mode_e2studio 2021-11-29 15:32:48 -07:00
9e2e0c06dc Merge pull request #4608 from miyazakh/esp_idf
Fix compile error on the latest ESP-IDF
2021-11-29 14:13:13 -07:00
80c16745c4 Merge pull request #4602 from embhorn/zd13296
Initialize global in TSIP port
2021-11-29 13:01:03 -08:00
8a2945fe66 More braces. 2021-11-29 15:56:44 -05:00
5aa8bc2983 Drop a brace. 2021-11-29 15:47:53 -05:00
c104ab2206 Merge pull request #4572 from SparkiDev/ecc_pub_decode
mp_sqrt: TonelliShanks algorithm doesn't handle zero
2021-11-29 12:27:36 -08:00
c78256702d Merge pull request #4604 from tmael/fix_cc_ecc
Fix Cryptocell ecc build
2021-11-29 11:01:33 -08:00
57fb5453cb Support for HKDF Extract callback 2021-11-29 14:51:13 +01:00
f6893789b9 add dummy_test_paths.h to include.am 2021-11-27 14:34:23 +09:00
a25c338007 fix build failures
update README to follow the latest ESP-IDF
2021-11-27 13:14:36 +09:00
fea438d07f Use wolfCrypt's benchmarking app to run the PQ algorithms. 2021-11-26 15:15:23 -05:00
fb4e39f00a addressed review comments prt1 2021-11-26 16:03:42 +09:00
b2c0bacb06 Fix Cryptocell ecc 2021-11-24 19:22:40 -08:00
ae0cefc48d Merge pull request #4603 from anhu/stop_OPENSSLEXTRA
Stop needlessly enabling ENABLED_OPENSSLEXTRA when enabling liboqs.
2021-11-24 13:46:31 -07:00
ffe7a84e3d Stop needlessly enabling ENABLED_OPENSSLEXTRA when enabling liboqs. 2021-11-24 14:09:19 -05:00
6d7e50d2ae Initialize global in TSIP port 2021-11-24 09:22:14 -06:00
be870e742d Edge case build fixes (cert gen only). 2021-11-23 15:12:48 -08:00
7396a0cb3a Resolves all peer review comments. Fixes to get Curve25519 working on real hardware. Regression testing fixes for ECC. 2021-11-23 15:03:53 -08:00
7524ededd3 Support for Custom OID in subject and CSR request extension:
* Adds new build option `WOLFSSL_CUSTOM_OID` for supplying a custom OID in a CSR
* Fixes in ASN template CSR generation.
* Fix to allow calling `wc_Ed25519PublicKeyToDer` and `wc_Ed448PublicKeyToDer` with NULL output buffer to get length only.
* Refactor of the certificate subject name encoding.
* Refactor of the OID's to consolidate.
* Improvements to the Domain Component API unit test.
ZD 12943
2021-11-23 09:51:13 -08:00
dcc2a2852c Merge pull request #4590 from JacobBarthelmeh/fuzzing
sanity check on pem size
2021-11-22 16:09:13 -08:00
f5239cc57e Merge pull request #4597 from cconlon/removeSwig
Remove swig wrapper
2021-11-22 15:31:40 -08:00
23e722be27 Merge pull request #4595 from masap/fix-linuxkm
Fix failure of make distclean when linuxkm is enabled
2021-11-22 12:01:21 -08:00
84be329ffb remove swig wrapper, now that we have dedicated Java and Python wrappers 2021-11-22 11:32:37 -07:00
89ed811e23 fix compile error when disabled SCEPROTECT 2021-11-22 21:36:02 +09:00
0de4136ad6 Rebase fixes 2021-11-22 13:10:55 +01:00
5fc2dadde1 Fix issue in wolfSSL_BN_rand_range causing random errors 2021-11-22 11:48:31 +01:00
1d7b2de074 Code review changes 2021-11-22 11:48:31 +01:00
3da810cb1b Implement OpenSSL API's
- `OBJ_DUP`
- `i2d_PKCS7`
- `BN_rshift1
- `BN_rshift` testing
- Add `--enable-krb`
2021-11-22 11:47:58 +01:00
e7c5f137be Implement BN_rand_range 2021-11-22 11:45:27 +01:00
82a9f74476 Compat updates
- implement `wolfSSL_PEM_X509_INFO_read`
- `wolfSSL_EVP_CipherUpdate` no-ops on `NULL` input
- add md4 support to `wolfSSL_EVP_MD_block_size` and `wolfSSL_EVP_MD_size`
2021-11-22 11:45:27 +01:00
ccbe184434 Implement CTS
Ciphertext stealing on top of CBC is implemented with `wolfSSL_CRYPTO_cts128_encrypt` and `wolfSSL_CRYPTO_cts128_decrypt` APIs
2021-11-22 11:45:27 +01:00
fa662c2ab1 AES_cbc_encrypt enc parameter flipped. 1 = encrypt 0 = decrypt
This change makes the `enc` parameter of `AES_cbc_encrypt` consistent with OpenSSL. This commit flips the meaning of this parameter now.
2021-11-22 11:45:27 +01:00
ace5d444a4 Fix failure of make distclean when linuxkm is enabled
$ make distclean
Making distclean in linuxkm
make[1]: Entering directory '/home/honma/git/wolfssl/linuxkm'
make[1]: *** No rule to make target 'distclean'.  Stop.
make[1]: Leaving directory '/home/honma/git/wolfssl/linuxkm'
make: *** [Makefile:6431: distclean-recursive] Error 1

Signed-off-by: Masashi Honma <masashi.honma@gmail.com>
2021-11-22 05:50:38 +09:00
30a01a0758 Fix failure of check at commiting when linuxkm is enabled
Making check in linuxkm
make[2]: Entering directory '/home/honma/git/wolfssl/linuxkm'
make[2]: warning: -j13 forced in submake: resetting jobserver mode.
make[2]: *** No rule to make target 'check'.  Stop.
make[2]: Leaving directory '/home/honma/git/wolfssl/linuxkm'
make[1]: *** [Makefile:6431: check-recursive] Error 1
make[1]: Leaving directory '/home/honma/git/wolfssl'
make: *** [Makefile:6901: check] Error 2

Signed-off-by: Masashi Honma <masashi.honma@gmail.com>
2021-11-22 05:50:38 +09:00
82eb23b300 addressed jenkins failures 2021-11-20 10:15:57 +09:00
5182e2a8c8 Merge pull request #4580 from kareem-wolfssl/minor_fixes
Check ssl->arrays in SendClientHello to avoid null dereference.  Allow building with fallthrough defined.
2021-11-19 16:55:01 -08:00
d00c7641ae addressed jenkins failure 2021-11-20 09:14:21 +09:00
f6c48bf7dc Merge pull request #4560 from kaleb-himes/OE30-OE31-non-fips-changes
OE30 and OE31 changes external to FIPS module for NetBSD builds
2021-11-19 15:49:30 -08:00
34346bab4f Merge pull request #4579 from JacobBarthelmeh/PKCS7
BER size adjustment with PKCS7
2021-11-19 14:49:03 -08:00
8de281c1d4 Fix minimum clang version for FALL_THROUGH. Not working properly before clang 11. 2021-11-19 15:16:56 -07:00
617668b9aa Merge pull request #4585 from kareem-wolfssl/encryptMacFix
Fix building Import/ExportOptions with HAVE_ENCRYPT_THEN_MAC undefined.
2021-11-19 13:45:16 -08:00
fd6d479888 Rework ssl and ssl->arrays NULL checks, and add to SendTls13ClientHello as well. 2021-11-19 14:19:27 -07:00
72d4dcce0f Fix updated FALL_THROUGH macro. Fix a couple of case statements and remove a trailing whitespace. 2021-11-19 14:13:02 -07:00
0772635972 Rework FALL_THROUGH definition to use fallthrough if defined. 2021-11-19 14:06:54 -07:00
930e1ac473 Check ssl->arrays in SendClientHello to avoid null dereference. Allow building with fallthrough defined. 2021-11-19 14:06:54 -07:00
5d49847147 sanity check on pem size 2021-11-19 13:55:03 -07:00
c3500fa24e Merge pull request #4581 from miyazakh/max_earlydata
add get_max_eraly_data
2021-11-19 09:42:01 -07:00
5a72fee3df Disable algorithms: fixes
WOLFSSL_PUBLIC_MP and disable algorithms didn't work because of api.c.
 - mp_cond_copy not available unless ECC compiled in
 - wc_export_int not available unless ECC compiled in
Enabling only DH and using SP with SP Math didn't work as the DH
parameters were too small.
sp_cmp is needed when only DH.
mp_set_int is was not available in SP math when RSA is not defined.
mp_set is close enough for the use cases.
Configure with SP and SP math but not RSA, DH and ECC didn't configure -
now default to small maths.
2021-11-19 16:56:33 +10:00
9a331d7072 update Readme 2021-11-19 15:35:06 +09:00
7e2fab6f4a warning with keil build and native lwip want read case 2021-11-18 22:58:50 -07:00
c84194ffc8 include renesas_cmn.h to am file 2021-11-19 14:44:45 +09:00
f50fcd918e support Renesas RA SCE protect mode on RA6M4 evaluation board 2021-11-19 14:22:16 +09:00
7e81372131 Merge pull request #4583 from dgarske/zd13242
Improve `ret` handling in the `ProcessPeerCerts` verify step.
2021-11-19 10:22:08 +10:00
af097401f2 SP: fix range of k to be 1..n-1
Was checking less than order - 2 then adding one.
i.e. 0..order-3 => 1..order-2
2021-11-19 09:40:26 +10:00
757f3b8105 Fix building Import/ExportOptions with HAVE_ENCRYPT_THEN_MAC undefined. 2021-11-18 16:06:22 -07:00
3054f20c6a Improve ret handling in the ProcessPeerCerts verify step. 2021-11-18 14:51:09 -08:00
2841b5c93b Merge pull request #3010 from kaleb-himes/ZD10203
Consistency in PP checking on use of WOLFSSL_CRYPTO_EX_DATA
2021-11-18 14:47:25 -08:00
9bc159a5ec addressed review comment 2021-11-19 07:24:46 +09:00
4324cf8f0a Correct cast from uint to uchar 2021-11-18 10:18:25 -07:00
5a85d63543 Added curve25519 support for NXP SE050
Reverted commented out lines from se050_port.h
2021-11-18 09:23:59 -07:00
e33156d0dc Merge pull request #4578 from kaleb-himes/OE33_NON_FIPS_CHANGES
OE33: Fix issues found by XCODE and add user_settings.h
2021-11-18 06:59:43 -08:00
d02e819e4c Merge pull request #4575 from SparkiDev/dh_enc_fix_2
ASN: DH private key encoding
2021-11-18 06:57:40 -08:00
618b9619c5 Merge pull request #4571 from anhu/init_sig_algs
Uninitialized var.
2021-11-18 22:46:37 +10:00
db3c0f7829 Merge pull request #4574 from masap/fix-asn1-integer-get
Fix invalid return value of ASN1_INTEGER_get()
2021-11-18 17:20:15 +10:00
483be08b1f add definition for early_data_status compat 2021-11-18 14:21:47 +09:00
6ba00f66cd Merge pull request #4573 from ejohnstown/fips-check-fix
Fix FIPS Check Script
2021-11-17 21:30:45 -06:00
b42a0d9712 native lwip update 2021-11-17 17:36:44 -07:00
7da0d524ff add get_max_eraly_data
support set/get_max_eraly_data compatibility layer
2021-11-18 09:07:32 +09:00
370570d19b ASN: DH private key encoding
Proper fix for sequence length when small keys.
2021-11-18 08:28:49 +10:00
4800db1f9d Enable max/min int test even when non 64bit platform
Signed-off-by: Masashi Honma <masashi.honma@gmail.com>
2021-11-18 06:58:21 +09:00
cb3fc0c7ce Fix invalid return value of ASN1_INTEGER_get()
When DIGIT_BIT is less than SIZEOF_LONG * CHAR_BIT, ASN1_INTEGER_get() can
return invalid value. For example, with trailing program, ASN1_INTEGER_get()
unexpectedly returns -268435449 (0xf0000007) on i386.

On the i386 platform (DIGIT_BIT=28), the input value 0x7fffffff is separated
into 0xfffffff and 0x7 and stored in the dp array of mp_int. Previously,
wolfSSL_BN_get_word_1() returned 0xfffffff shifted by 28 bits plus 0x7, so this
patch fixed it to return 0xfffffff plus 0x7 shifted by 28 bits.

int main(void)
{
    ASN1_INTEGER *a;
    long val;
    int ret;

    a = ASN1_INTEGER_new();
    val = 0x7fffffff;
    ret = ASN1_INTEGER_set(a, val);
    if (ret != 1) {
        printf("ret=%d\n", ret);
    }

    if (ASN1_INTEGER_get(a) != val) {
        printf("ASN1_INTEGER_get=%ld\n", ASN1_INTEGER_get(a));
    }

    ASN1_INTEGER_free(a);

    return 0;
}

Signed-off-by: Masashi Honma <masashi.honma@gmail.com>
2021-11-18 06:58:21 +09:00
ab0654bb64 remove something that slipped in 2021-11-17 16:38:30 -05:00
39edf8d206 pulled up a line. 2021-11-17 16:38:30 -05:00
49c7abb875 Changes suggested by SparkiDev. 2021-11-17 16:38:30 -05:00
5c48e74c7f 0xFF 2021-11-17 16:38:30 -05:00
0ae0b31509 The following config:
./configure --with-liboqs --enable-all --disable-psk --enable-intelasm --enable-aesni --enable-sp-math-all --enable-sp-asm CFLAGS="-O3"

Yeilds the following erorr:

src/internal.c: In function ‘DoServerKeyExchange’:
src/internal.c:24487:28: error: ‘sigAlgo’ may be used uninitialized in this function [-Werror=maybe-uninitialized]
24487 |                         if (sigAlgo == ed448_sa_algo &&
      |                            ^

This fixes it.
2021-11-17 16:38:30 -05:00
38ec0bb31f Merge branch 'master' of github.com:wolfssl/wolfssl into OE33_NON_FIPS_CHANGES 2021-11-17 14:02:56 -07:00
995ef60ff1 Merge pull request #4577 from kaleb-himes/WINDOWS_AES_OFB_ON
Turn on AES-OFB mode in windows for FIPS=v5
2021-11-17 12:20:19 -08:00
37db5a9ab3 Add include.am(s) for new file(s) 2021-11-17 12:05:05 -07:00
ddf06b8161 BER size adjustment with PKCS7 2021-11-17 12:03:32 -07:00
f638df3575 Fix issues found by XCODE and add user_settings.h
Disable internal test settings by default
2021-11-17 11:00:56 -07:00
ef62fab4ea Update
1. WIN10 FIPS build should use version 5,2 now.
2. Update the v5-ready build ot use version 5,2.
3. Remove eol-whitespace from the benchmark source.
2021-11-17 09:19:34 -08:00
c7c682ba2a Move up to avoid breaking the patch applied for windows 2021-11-17 09:37:26 -07:00
dc6ec2b849 Turn on AES-OFB mode in windows for FIPS=v5 2021-11-17 09:22:58 -07:00
158ebcaa0a Add v5-RC10 to the list of allowed versions 2021-11-16 16:36:38 -08:00
a5e581506e Merge pull request #4570 from dgarske/android_keystore
Fixes for building wolfSSL with Android WPA Supplicant and KeyStore
2021-11-17 08:30:01 +10:00
e8e0bc0d49 Merge pull request #4552 from SparkiDev/sp_mod_exp_zero
SP: mod_exp with exponent of 0 is invalid
2021-11-16 08:29:13 -08:00
2b3ab855dd Fixes for building wolfSSL with Android WPA Supplicant and KeyStore. 2021-11-16 08:27:30 -08:00
33a6b8c779 Merge pull request #4531 from dgarske/cryptocb_aesccm
Added crypto callback support for AES CCM
2021-11-16 22:45:11 +10:00
8606788198 SP: mod_exp with exponent of 0 is invalid
Don't allow exponenetiation by 0 as it is cryptographically invalid and
not supported by the implementation.
Also check for even modulus in mod_exp.
2021-11-16 11:27:26 +10:00
1559e92dca Add crypto callback AES CCM test case. 2021-11-15 16:22:10 -08:00
d3fc8c229a mp_sqrt: TonelliShanks algorithm doesn't handle zero
(0 * 0) mod p = 0.
Modular reduce n and shortcut when 0.
2021-11-16 09:23:07 +10:00
6547bcb44c Consistency in PP checking on use of WOLFSSL_CRYPTO_EX_DATA 2021-11-11 17:47:17 -07:00
6bb86cf4da OE30 and OE31 changes external to FIPS module for NetBSD builds 2021-11-10 15:16:21 -07:00
ff3179012d SP: fix when mont_mul_order is defined
Customer configuration that failed:
./configure --enable-cryptonly --enable-ecc --enable-sp=yes,asm
--disable-rsa --disable-dh --disable-sha3 --disable-sha224 --disable-md5
--disable-sha --disable-pkcs12 --disable-memory --disable-chacha
--disable-poly1305 --disable-sha512 --disable-sha384 --disable-aesgcm
--disable-aescbc --disable-aes --disable-rng CFLAGS="-DNO_SIG_WRAPPER
-DWOLFSSL_PUBLIC_MP -DECC_USER_CURVES -DNO_ECC_SIGN -DNO_ECC_DHE
-DNO_ECC_KEY_EXPORT"
2021-11-09 17:50:21 +10:00
82c106be80 Added crypto callback support for AES CCM. 2021-11-02 09:53:55 -07:00
a8b6304e19 add unit test for wc_PKCS7_VerifySignedData_ex() with detached signature and content digest only 2021-10-25 15:52:19 -06:00
322cb05852 adjust PKCS7_VerifySignedData to correctly verify precomputed content hash with detached signature 2021-10-25 14:46:10 -06:00
1572 changed files with 596781 additions and 177309 deletions

58
.github/ISSUE_TEMPLATE/bug_report.yaml vendored Normal file
View File

@ -0,0 +1,58 @@
name: Bug Report
description: File a bug report
title: "[Bug]: "
labels: ["bug", "triage"]
body:
- type: markdown
attributes:
value: >
Thanks for reporting an bug. If you would prefer a private method,
please email support@wolfssl.com
- type: input
id: contact
attributes:
label: Contact Details
description: How can we get in touch with you if we need more info?
placeholder: ex. email@example.com
validations:
required: false
- type: input
id: version
attributes:
label: Version
description: What version were you using?
validations:
required: true
- type: textarea
id: details
attributes:
label: Description
description: |
Describe the issue in detail
Please include:
* Specific `./configure` options or `user_settings.h`
* Target and build environment
placeholder: |
Blinded by the light!
Code runs too fast. It's gone plaid!
...
validations:
required: true
- type: textarea
id: reproduce
attributes:
label: Reproduction steps
description: If possible please give instructions on how to reproduce.
placeholder: |
1. `./configure --enable-42`
2. `make question`
3.
...
validations:
required: false
- type: textarea
id: logs
attributes:
label: Relevant log output
description: Please copy and paste any relevant log output. This will be automatically formatted into code, so no need for backticks.
render: shell

28
.github/ISSUE_TEMPLATE/other.yaml vendored Normal file
View File

@ -0,0 +1,28 @@
name: General Issue
description: Request support with an issue
labels: ["triage"]
body:
- type: markdown
attributes:
value: >
Thanks for reporting an issue. If you would prefer a private method,
please email support@wolfssl.com
- type: input
id: version
attributes:
label: Version
description: What version were you using?
validations:
required: true
- type: textarea
id: details
attributes:
label: Description
description: |
Describe the issue in detail.
Please include specific configuration options or user_settings.h
placeholder: |
`./configure --enable-world-domination` fails
...
validations:
required: true

16
.github/PULL_REQUEST_TEMPLATE.md vendored Normal file
View File

@ -0,0 +1,16 @@
# Description
Please describe the scope of the fix or feature addition.
Fixes zd#
# Testing
How did you test?
# Checklist
- [ ] added tests
- [ ] updated/added doxygen
- [ ] updated appropriate READMEs
- [ ] Updated manual and documentation

12
.github/SECURITY.md vendored Normal file
View File

@ -0,0 +1,12 @@
# Security Policy
## Reporting a Vulnerability
If you discover a vulnerability, please report it to support@wolfssl.com
1. Include a detailed description
2. Include method to reproduce and/or method of discovery
3. We will evaulate the report promptly and respond to you with findings.
4. We will credit you with the report if you would like.
**Please keep the vulnerability private** until a fix has been released.

35
.gitignore vendored
View File

@ -208,14 +208,6 @@ TAGS
support/cyassl.pc
support/wolfssl.pc
cyassl/ctaocrypt/stamp-h1
swig/_cyassl.so
swig/_wolfssl.so
swig/cyassl.py
swig/wolfssl.py
swig/cyassl.pyc
swig/wolfssl.pyc
swig/cyassl_wrap.c
swig/wolfssl_wrap.c
stamp-h1
clang_output_*
internal.plist
@ -235,6 +227,7 @@ IDE/MDK-ARM/LPC43xx/LPC43xx/
!linuxkm/Makefile
/Kbuild
linuxkm/*.ko
linuxkm/*.ko.signed
linuxkm/Module.symvers
linuxkm/built-in.a
linuxkm/modules.order
@ -362,6 +355,24 @@ IDE/XCODE/Index
/IDE/Renesas/e2studio/Projects/test/*.launch
/IDE/Renesas/e2studio/Projects/test/*.scfg
/IDE/Renesas/e2studio/RX65N/GR-ROSE/.metadata
/IDE/Renesas/e2studio/RX65N/GR-ROSE/smc/src
/IDE/Renesas/e2studio/RX65N/GR-ROSE/smc/trash
/IDE/Renesas/e2studio/RX65N/GR-ROSE/test/src/smc_gen
/IDE/Renesas/e2studio/RX65N/GR-ROSE/test/generate
/IDE/Renesas/e2studio/RX65N/RSK/.metadata
/IDE/Renesas/e2studio/RX65N/RSK/smc/src
/IDE/Renesas/e2studio/RX65N/RSK/smc/trash
/IDE/Renesas/e2studio/RX65N/RSK/test/src/smc_gen
/IDE/Renesas/e2studio/RX65N/RSK/test/generate
/IDE/Renesas/e2studio/RX72N/EnvisionKit/.metadata
/IDE/Renesas/e2studio/RX72N/EnvisionKit/smc/src
/IDE/Renesas/e2studio/RX72N/EnvisionKit/smc/trash
/IDE/Renesas/e2studio/RX72N/EnvisionKit/test/src/smc_gen
/IDE/Renesas/e2studio/RX72N/EnvisionKit/test/generate
# QNX CAAM
/IDE/QNX/example-server/server-tls
/IDE/QNX/example-client/client-tls
@ -379,3 +390,11 @@ cmake_install.cmake
# GDB Settings
\.gdbinit
# Pycharm and other IDEs
\.idea
# FIPS
XXX-fips-test
# ASYNC
async

File diff suppressed because it is too large Load Diff

View File

@ -1,3 +1,644 @@
# wolfSSL Release 5.5.1 (Sep 28, 2022)
Release 5.5.1 of wolfSSL embedded TLS has bug fixes and new features including:
## Vulnerabilities
* [Med] Denial of service attack and buffer overflow against TLS 1.3 servers using session ticket resumption. When built with --enable-session-ticket and making use of TLS 1.3 server code in wolfSSL, there is the possibility of a malicious client to craft a malformed second ClientHello packet that causes the server to crash. This issue is limited to when using both --enable-session-ticket and TLS 1.3 on the server side. Users with TLS 1.3 servers, and having --enable-session-ticket, should update to the latest version of wolfSSL. Thanks to Max at Trail of Bits for the report and "LORIA, INRIA, France" for research on tlspuffin.
## New Feature Additions
* Add support for non-blocking ECC key gen and shared secret gen for P-256/384/521
* Add support for non-blocking ECDHE/ECDSA in TLS/DTLS layer.
* Port to NXP RT685 with FreeRTOS
* Add option to build post quantum Kyber API (--enable-kyber)
* Add post quantum algorithm sphincs to wolfCrypt
* Config. option to force no asm with SP build (--enable-sp=noasm)
* Allow post quantum keyshare for DTLS 1.3
## Enhancements
* DTLSv1.3: Do HRR Cookie exchange by default
* Add wolfSSL_EVP_PKEY_new_CMAC_key to OpenSSL compatible API
* Update ide win10 build files to add missing sp source files
* Improve Workbench docs
* Improve EVP support for CHACHA20_POLY1305
* Improve `wc_SetCustomExtension` documentation
* RSA-PSS with OCSP and add simple OCSP response DER verify test case
* Clean up some FIPS versioning logic in configure.ac and WIN10 user_settings.h
* Don't over-allocate memory for DTLS fragments
* Add WOLFSSL_ATECC_TFLXTLS for Atmel port
* SHA-3 performance improvements with x86_64 assembly
* Add code to fallback to S/W if TSIP cannot handle
* Improves entropy with VxWorks
* Make time in milliseconds 64-bits for longer session ticket lives
* Support for setting cipher list with bytes
* wolfSSL_set1_curves_list(), wolfSSL_CTX_set1_curves_list() improvements
* Add to RSAES-OAEP key parsing for pkcs7
* Add missing DN nid to work with PrintName()
* SP int: default to 16 bit word size when NO_64BIT defined
* Limit the amount of fragments we store per a DTLS connection and error out when max limit is reached
* Detect when certificate's RSA public key size is too big and fail on loading of certificate
## Fixes
* Fix for async with OCSP non-blocking in `ProcessPeerCerts`
* Fixes for building with 32-bit and socket size sign/unsigned mismatch
* Fix Windows CMakeList compiler options
* TLS 1.3 Middle-Box compat: fix missing brace
* Configuration consistency fixes for RSA keys and way to force disable of private keys
* Fix for Aarch64 Mac M1 SP use
* Fix build errors and warnings for MSVC with DTLS 1.3
* Fix HMAC compat layer function for SHA-1
* Fix DTLS 1.3 do not negotiate ConnectionID in HelloRetryRequest
* Check return from call to wc_Time
* SP math: fix build configuration with opensslall
* Fix for async session tickets
* SP int mp_init_size fixes when SP_WORD_SIZE == 8
* Ed. function to make public key now checks for if the private key flag is set
* Fix HashRaw WC_SHA256_DIGEST_SIZE for wc_Sha256GetHash
* Fix for building with PSK only
* Set correct types in wolfSSL_sk_*_new functions
* Sanity check that size passed to mp_init_size() is no more than SP_INT_DIGITS
# wolfSSL Release 5.5.0 (Aug 30, 2022)
Note:
** If not freeing FP_ECC caches per thread by calling wc_ecc_fp_free there is a possible memory leak during TLS 1.3 handshakes which use ECC. Users are urged to confirm they are freeing FP_ECC caches per thread if enabled to avoid this issue.
Release 5.5.0 of wolfSSL embedded TLS has bug fixes and new features including:
## Vulnerabilities
* [Low] Fault injection attack on RAM via Rowhammer leads to ECDSA key disclosure. Users doing operations with private ECC keys such as server side TLS connections and creating ECC signatures, who also have hardware that could be targeted with a sophisticated Rowhammer attack should update the version of wolfSSL and compile using the macro WOLFSSL_CHECK_SIG_FAULTS. Thanks to Yarkin Doroz, Berk Sunar, Koksal Must, Caner Tol, and Kristi Rahman all affiliated with the Vernam Applied Cryptography and Cybersecurity Lab at Worcester Polytechnic Institute for the report.
* [Low] In wolfSSL version 5.3.0 if compiled with --enable-session-ticket and the client has non-empty session cache, with TLS 1.2 there is the possibility of a man in the middle passing a large session ticket to the client and causing a crash due to an invalid free. There is also the potential for a malicious TLS 1.3 server to crash a client in a similar manner except in TLS 1.3 it is not susceptible to a man in the middle attack. Users on the client side with enable-session-ticket compiled in and using wolfSSL version 5.3.0 should update their version of wolfSSL. Thanks to Max at Trail of Bits for the report and "LORIA, INRIA, France" for research on tlspuffin.
* [Low] If using wolfSSL_clear to reset a WOLFSSL object (vs the normal wolfSSL_free/wolfSSL_new) it can result in runtime issues. This exists with builds using the wolfSSL compatibility layer (--enable-opnesslextra) and only when the application is making use of wolfSSL_clear instead of SSL_free/SSL_new. In the case of a TLS 1.3 resumption, after continuing to use the WOLFSSH object after having called wolfSSL_clear, an application could crash. It is suggested that users calling wolfSSL_clear update the version of wolfSSL used. Thanks to Max at Trail of Bits for the report and "LORIA, INRIA, France" for research on tlspuffin.
* Potential DoS attack on DTLS 1.2. In the case of receiving a malicious plaintext handshake message at epoch 0 the connection will enter an error state reporting a duplicate message. This affects both server and client side. Users that have DTLS enabled and in use should update their version of wolfSSL to mitigate the potential for a DoS attack.
## New Feature Additions
* QUIC support added, for using wolfSSL with QUIC implementations like ngtcp2
* SE050 port additions and fixes
* Added support for Dilithium post quantum algorithm use with TLS
* Support for RSA-PSS signed certificates
* Support for Infineon AURIX IDE
* Add Zephyr support for nRF5340 with CryptoCell-312
## Enhancements
* Expanded ABI support by 50 APIs to include wolfCrypt and Certificates making a total of 113 ABIs controlled and maintained
* DTLS 1.3 partial support for ConnectionID as described by RFC9146 and RFC9147
* Added support for X509_CRL_print function
* Remove deprecated algorithms in Renesas cs+ project
* Support more build options disable/enable with i.MX CAAM build
* wolfSSL_CTX_set_options and wolfSSL_CTX_get_options functions added to non compatibility layer builds
* TFM: change inline x86 asm code to compile with clang
* Improvements to error queue and fix for behavior of wolfSSL_ERR_get_error
* scripts/makedistsmall.sh script added for creating a small source/header only package
* TLS 1.3: restrict extension validity by message, Extensions ServerName, SupportedGroups and ALPN must not appear in server_hello
* Add liboqs integration to CMake build system
* Adds wolfSSL_PEM_read_RSAPrivateKey() to the OpenSSL compatible API
* Added support for P384 pre-share in bundled example server
* Replace clz assembly instruction in ARM 32 builds when not supported
* Integrate chacha20-poly1305 into the EVP interface
* Additional validation that extensions appear in correct messages
* Allow SAN to be critical with ASN template build
* Support wolfSSL_CTX_set1_curves_list being available when X25519 and/or X448 only defined
* Adds wolfSSL_PEM_read_RSA_PUBKEY() to the OpenSSL compatible API
* Match OpenSSL self signed error return with compatibility layer build
* Added wolfSSL_dtls_create_peer and wolfSSL_dtls_free_peer to help with Python and Go wrappers for DTLS
## Fixes
* DTLS 1.3 asynchronous use case fixes
* Fix handling of counter to support incrementing across all bytes in ARM crypto asm
* Fixes for ED25519/ED448 private key with public key export (RFC8410)
* Fix for build with NO_TLS macro
* Fix for write dup function to copy over TLS version
* Fix to handle path lengths of 0 when checking certificate CA path lengths
* Fix for CMake not installing sp_int.h for SP math all
* When WOLFSSL_VALIDATE_ECC_IMPORT is defined ECC import validates private key value is less than order
* PSA crypto fixes
* Fix for not having default pkcs7 signed attributes
* DTLS socket and timeout fixes
* SP int: exptmod ensure base is less than modulus
* Fix for AddPacketInfo with WOLFSSL_CALLBACKS to not pass encrypted TLS 1.3 handshake messages to callbacks
* Fix for sniffer to ensure the session was polled before trying to reprocess it
# wolfSSL Release 5.4.0 (July 11, 2022)
Note:
** Future releases of wolfSSL will turn off TLS 1.1 by default
** Release 5.4.0 made SP math the default math implementation. To make an equivalent build as disable-fastmath from previous versions of wolfSSL, now requires using the configure option enable-heapmath instead.
Release 5.4.0 of wolfSSL embedded TLS has bug fixes and new features including:
## Vulnerabilities
* [High] Potential for DTLS DoS attack. In wolfSSL versions before 5.4.0 the return-routability check is wrongly skipped in a specific edge case. The check on the return-routability is there for stopping attacks that either consume excessive resources on the server, or try to use the server as an amplifier sending an excessive amount of messages to a victim IP. If using DTLS 1.0/1.2 on the server side users should update to avoid the potential DoS attack. CVE-2022-34293
* [Medium] Ciphertext side channel attack on ECC and DH operations. Users on systems where rogue agents can monitor memory use should update the version of wolfSSL and change private ECC keys. Thanks to Sen Deng from Southern University of Science and Technology (SUSTech) for the report.
* [Medium] Public disclosure of a side channel vulnerability that has been fixed since wolfSSL version 5.1.0. When running on AMD there is the potential to leak private key information with ECDSA operations due to a ciphertext side channel attack. Users on AMD doing ECDSA operations with wolfSSL versions less than 5.1.0 should update their wolfSSL version used. Thanks to professor Yinqian Zhang from Southern University of Science and Technology (SUSTech), his Ph.D. student Mengyuan Li from The Ohio State University, and his M.S students Sen Deng and Yining Tang from SUStech along with other collaborators; Luca Wilke, Jan Wichelmann and Professor Thomas Eisenbarth from the University of Lubeck, Professor Shuai Wang from Hong Kong University of Science and Technology, Professor Radu Teodorescu from The Ohio State University, Huibo Wang, Kang Li and Yueqiang Cheng from Baidu Security and Shoumeng Yang from Ant Financial Services Group.
CVE-2020-12966 https://www.amd.com/en/corporate/product-security/bulletin/amd-sb-1013 CVE-2021-46744 https://www.amd.com/en/corporate/product-security/bulletin/amd-sb-1033
## New Feature Additions
### DTLS 1.3
* Support for using the new DTLSv1.3 protocol was added
* Enhancements to bundled examples for an event driven server with DTLS 1.3 was added
### Ports
* Update for the version of VxWorks supported, adding in support for version 6.x
* Support for new DPP and EAP-TEAP/EAP-FAST in wpa_supplicant
* Update for TSIP version support, adding support for version 1.15 for RX65N and RX72N
* Improved TSIP build to handle having the options WOLFSSL_AEAD_ONLY defined or NO_AES_CBC defined
* Added support for offloading TLS1.3 operations to Renesas RX boards with TSIP
### Misc.
* Constant time improvements due to development of new constant time tests
* Initial translation of API headers to Japanese and expansion of Japanese help message support in example applications
* Add support for some FPKI (Federal PKI) certificate cases, UUID, FASC-N, PIV extension for use with smart cards
* Add support for parsing additional CSR attributes such as unstructured name and content type
* Add support for Linux getrandom() when defining the macro WOLFSSL_GETRANDOM
* Add TLS 1.2 ciphersuite ECDHE_PSK_WITH_AES_128_GCM_SHA256 from RFC 8442
* Expand CAAM support with QNX to include i.MX8 boards and add AES-CTR support
* Enhanced glitching protection by hardening the TLS encrypt operations
## Math and Performance
### SP Math Additions
* Support for ARMv3, ARMv6 and ARMv7a
- Changes and improvements to get SP building for armv7-a
- Updated assembly for moving large immediate values on ARMv6
- Support for architectures with no ldrd/strd and clz
* Reworked generation using common asm ruby code for 32bit ARM
* Enable wolfSSL SP math all by default (sp_int.c)
* Update SP math all to not use sp_int_word when SQR_MUL_ASM is available
### SP Math Fixes
* Fixes for constant time with div function
* Fix casting warnings for Windows builds and assembly changes to support XMM6-15 being non-volatile
* Fix for div_word when not using div function
* Fixes for user settings with SP ASM and ED/Curve25519 small
* Additional Wycheproof tests ran and fixes
* Fix for SP math ECC non-blocking to always check `hashLen`
* Fix for SP math handling edge case with submod
## Improvements and Optimizations
### Compatibility Layer
* Provide access to "Finished" messages outside of compatibility layer builds
* Remove unneeded FIPS guard on wolfSSL_EVP_PKEY_derive
* Fix control command issues with AES-GCM, control command EVP_CTRL_GCM_IV_GEN
* Add support for importing private only EC key to a WOLFSSL_EVP_PKEY struct
* Add support for more extensions to wolfSSL_X509_print_ex
* Update for internal to DER (i2d) AIPs to move the buffer pointer when passed in and the operation is successful
* Return subject and issuer X509_NAME object even when not set
### Ports
* Renesas RA6M4 example update and fixes
* Support multi-threaded use cases with Renesas SCE protected mode and TSIP
* Add a global variable for heap-hint for use with TSIP
* Changes to support v5.3.0 cube pack for STM32
* Use the correct mutex type for embOS
* ESP-IDF build cleanup and enhancements, adding in note regarding ESP-IDF Version
* Support for SEGGER embOS and emNET
* Fix to handle WOLFSSL_DTLS macro in Micrium build
### Build Options
* Support for verify only and no-PSS builds updated
* Add the enable options wolfssh (mapped to the existing enable-ssh)
* Remove WOLFSSL_ALT_NAMES restriction on notBefore/notAfter use in Cert struct
* Move several more definitions outside the BUILDING_WOLFSSL gate with linux kernel module build
* Modify --enable-openssh to not enable non-FIPS algos for FIPS builds
* Remove the Python wrappers from wolfSSL source (use pip install instead of using wolfSSL with Python and our separate Python repository)
* Add --enable-openldap option to configure.ac for building the OpenLDAP port
* Resolve DTLS build to handle not having enable-hrrcookie when not needed
* Add an --enable-strongswan option to configure.ac for building the Strongswan port
* Improve defaults for 64-bit BSDs in configure
* Crypto only build can now be used openssl extra
* Update ASN template build to properly handle WOLFSSL_CERT_EXT and HAVE_OID_ENCODING
* Allow using 3DES and MD5 with FIPS 140-3, as they fall outside of the FIPS boundary
* Add the build option --enable-dh=const which replaces setting the macro WOLFSSL_DH_CONST and now conditionally link to -lm as needed
* Add the macro WOLFSSL_HOSTNAME_VERIFY_ALT_NAME_ONLY which is used to verify hostname/ip address using alternate name (SAN) only and does not use the common name
* WOLFSSL_DTLS_NO_HVR_ON_RESUME macro added (off by default to favor more security). If defined, a DTLS server will not do a cookie exchange on successful client resumption: the resumption will be faster (one RTT less) and will consume less bandwidth (one ClientHello and one HelloVerifyRequest less). On the other hand, if a valid SessionID is collected, forged clientHello messages will consume resources on the server.
* Misc.
* Refactoring of some internal TLS functions to reduce the memory usage
* Make old less secure TimingPadVerify implementation available
* Add support for aligned data with clang LLVM
* Remove subject/issuer email from the list of alt. Email names in the DecodedCerts struct
* Zeroizing of pre-master secret buffer in TLS 1.3
* Update to allow TLS 1.3 application server to send session ticket
* Improve the sniffer asynchronous test case to support multiple concurrent streams
* Clean up wolfSSL_clear() and add more logging
* Update to not error out on bad CRL next date if using NO_VERIFY when parsing
* Add an example C# PSK client
* Add ESP-IDF WOLFSSL_ESP8266 setting for ESP8266 devices
* Support longer sigalg list for post quantum use cases and inter-op with OQS's OpenSSL fork
* Improve AES-GCM word implementation of GMULT to be constant time
* Additional sanity check with Ed25519/Ed448, now defaults to assume public key is not trusted
* Support PSK ciphersuites in benchmark apps
* FIPS in core hash using SHA2-256 and SHA2-384
* Add ability to store issuer name components when parsing a certificate
* Make the critical extension flags in DecodedCert always available
* Updates to the default values for basic constraint with X509s
* Support using RSA OAEP with no malloc and add additional sanity checks
* Leverage async code paths to support WANT_WRITE while sending packet fragments
* New azsphere example for continuous integration testing
* Update RSA key generation function to handle pairwise consistency tests with static memory pools used
* Resolve build time warning by passing in and checking output length with internal SetCurve function
* Support DTLS bidirectional shutdown in the examples
* Improve DTLS version negotiation and downgrade capability
### General Fixes
* Fixes for STM32 Hash/PKA, add some missing mutex frees, and add an additional benchmark
* Fix missing return checks in KSDK ED25519 code
* Fix compilation warnings from IAR
* Fixes for STM32U5/H7 hash/crypto support
* Fix for using track memory feature with FreeRTOS
* Fixup XSTR processing for MICRIUM
* Update Zephyr fs.h path
* DTLS fixes with WANT_WRITE simulations
* Fixes for BER use with PKCS7 to have additional sanity checks and guards on edge cases
* Fix to handle exceptional edge case with TFM mp_exptmod_ex
* Fix for stack and heap measurements of a 32-bit build
* Fix to allow enabling AES key wrap (direct) with KCAPI
* Fix --enable-openssh FIPS detection syntax in configure.ac
* Fix to move wolfSSL_ERR_clear_error outside gate for OPENSSL_EXTRA
* Remove MCAPI project's dependency on zlib version
* Only use __builtin_offset on supported GCC versions (4+)
* Fix for c89 builds with using WOLF_C89
* Fix 64bit postfix for constants building with powerpc
* Fixed async Sniffer with TLS v1.3, async removal of `WC_HW_WAIT_E` and sanitize leak
* Fix for QAT ECC to gate use of HW based on marker
* Fix the supported version extension to always check minDowngrade
* Fix for TLS v1.1 length sanity check for large messages
* Fixes for loading a long DER/ASN.1 certificate chain
* Fix to expose the RSA public DER export functions with certgen
* Fixes for building with small version of SHA3
* Fix configure with WOLFSSL_WPAS_SMALL
* Fix to free PKCS7 recipient list in error cases
* Sanity check to confirm ssl->hsHashes is not NULL before attempting to dereference it
* Clear the leftover byte count in Aes struct when setting IV
# wolfSSL Release 5.3.0 (May 3rd, 2022)
Release 5.3.0 of wolfSSL embedded TLS has bug fixes and new features including:
## New Feature Additions
### Ports
* Updated support for Stunnel to version 5.61
* Add i.MX8 NXP SECO use for secure private ECC keys and expand cryptodev-linux for use with the RSA/Curve25519 with the Linux CAAM driver
* Allow encrypt then mac with Apache port
* Update Renesas TSIP version to 1.15 on GR-ROSE and certificate signature data for TSIP / SCE example
* Add IAR MSP430 example, located in IDE/IAR-MSP430 directory
* Add support for FFMPEG with the enable option `--enable-ffmpeg`, FFMPEG is used for recording and converting video and audio (https://ffmpeg.org/)
* Update the bind port to version 9.18.0
### Post Quantum
* Add Post-quantum KEM benchmark for STM32
* Enable support for using post quantum algorithms with embedded STM32 boards and port to STM32U585
### Compatibility Layer Additions
* Add port to support libspdm (https://github.com/DMTF/libspdm/blob/main/README.md), compatibility functions added for the port were:
- ASN1_TIME_compare
- DH_new_by_nid
- OBJ_length, OBJ_get0_data,
- EVP layer ChaCha20-Poly1305, HKDF
- EC_POINT_get_affine_coordinates
- EC_POINT_set_affine_coordinates
* Additional functions added were:
- EC_KEY_print_fp
- EVP_PKEY_paramgen
- EVP_PKEY_sign/verify functionality
- PEM_write_RSAPublicKey
- PEM_write_EC_PUBKEY
- PKCS7_sign
- PKCS7_final
- SMIME_write_PKCS7
- EC_KEY/DH_up_ref
- EVP_DecodeBlock
- EVP_EncodeBlock
- EC_KEY_get_conv_form
- BIO_eof
- Add support for BIO_CTRL_SET and BIO_CTRL_GET
* Add compile time support for the type SSL_R_NULL_SSL_METHOD_PASSED
* Enhanced X509_NAME_print_ex() to support RFC5523 basic escape
* More checks on OPENSSL_VERSION_NUMBER for API prototype differences
* Add extended key usage support to wolfSSL_X509_set_ext
* SSL_VERIFY_FAIL_IF_NO_PEER_CERT now can also connect with compatibility layer enabled and a TLS 1.3 PSK connection is used
* Improve wolfSSL_BN_rand to handle non byte boundaries and top/bottom parameters
* Changed X509_V_ERR codes to better match OpenSSL values used
* Improve wolfSSL_i2d_X509_name to allow for a NULL input in order to get the expected resulting size
* Enhance the smallstack build to reduce stack size farther when built with compatibility layer enabled
### Misc.
* Sniffer asynchronous support addition, handling of DH shared secret and tested with Intel QuickAssist
* Added in support for OCSP with IPv6
* Enhance SP (single precision) optimizations for use with the ECC P521
* Add new public API wc_CheckCertSigPubKey() for use to easily check the signature of a certificate given a public key buffer
* Add CSR (Certificate Signing Request) userId support in subject name
* Injection and parsing of custom extensions in X.509 certificates
* Add WOLF_CRYPTO_CB_ONLY_RSA and WOLF_CRYPTO_CB_ONLY_ECC to reduce code size if using only crypto callback functions with RSA and ECC
* Created new --enable-engine configure flag used to build wolfSSL for use with wolfEngine
* With TLS 1.3 PSK, when WOLFSSL_PSK_MULTI_ID_PER_CS is defined multiple IDs for a cipher suite can be handled
* Added private key id/label support with improving the PK (Public Key) callbacks
* Support for Intel QuickAssist ECC KeyGen acceleration
* Add the function wolfSSL_CTX_SetCertCbCtx to set user context for certificate call back
* Add the functions wolfSSL_CTX_SetEccSignCtx(WOLFSSL_CTX* ctx, void *userCtx) and wolfSSL_CTX_GetEccSignCtx(WOLFSSL_CTX* ctx) for setting and getting a user context
* wolfRand for AMD --enable-amdrand
## Fixes
### PORT Fixes
* KCAPI memory optimizations and page alignment fixes for ECC, AES mode fixes and reduction to memory usage
* Add the new kdf.c file to the TI-RTOS build
* Fix wait-until-done in RSA hardware primitive acceleration of ESP-IDF port
* IOTSafe workarounds when reading files with ending 0s and for ECC signatures
### Math Library Fixes
* Sanity check with SP math that ECC points ordinates are not greater than modulus length
* Additional sanity checks that _sp_add_d does not error due to overflow
* Wycheproof fixes, testing integration, and fixes for AVX / AArch64 ASM edge case tests
* TFM fp_div_2_ct rework to avoid potential overflow
### Misc.
* Fix for PKCS#7 with Crypto Callbacks
* Fix for larger curve sizes with deterministic ECC sign
* Fixes for building wolfSSL alongside openssl using --enable-opensslcoexist
* Fix for compatibility layer handling of certificates with SHA256 SKID (Subject Key ID)
* Fix for wolfSSL_ASN1_TIME_diff erroring out on a return value of 0 from mktime
* Remove extra padding when AES-CBC encrypted with PemToDer
* Fixes for TLS v1.3 early data with async.
* Fixes for async disables around the DevCopy calls
* Fixes for Windows AES-NI with clang compiler
* Fix for handling the detection of processing a plaintext TLS alert packet
* Fix for potential memory leak in an error case with TLSX supported groups
* Sanity check on `input` size in `DecodeNsCertType`
* AES-GCM stack alignment fixes with assembly code written for AVX/AVX2
* Fix for PK callbacks with server side and setting a public key
## Improvements/Optimizations
### Build Options and Warnings
* Added example user settings template for FIPS v5 ready
* Automake file touch cleanup for use with Yocto devtool
* Allow disabling forced 'make clean' at the end of ./configure by using --disable-makeclean
* Enable TLS 1.3 early data when specifying `--enable-all` option
* Disable PK Callbacks with JNI FIPS builds
* Add a FIPS cert 3389 ready option, this is the fips-ready build
* Support (no)inline with Wind River Diab compiler
* ECDH_compute_key allow setting of globalRNG with FIPS 140-3
* Add logic equivalent to configure.ac in settings.h for Poly1305
* Fixes to support building opensslextra with SP math
* CPP protection for extern references to x86_64 asm code
* Updates and enhancements for Espressif ESP-IDF wolfSSL setup_win.bat
* Documentation improvements with auto generation
* Fix reproducible-build for working an updated version of libtool, version 2.4.7
* Fixes for Diab C89 and armclang
* Fix `mcapi_test.c` to include the settings.h before crypto.h
* Update and handle builds with NO_WOLFSSL_SERVER and NO_WOLFSSL_CLIENT
* Fix for some macro defines with FIPS 140-3 build so that RSA_PKCS1_PSS_PADDING can be used with RSA sign/verify functions
### Math Libraries
* Add RSA/DH check for even modulus
* Enhance TFM math to handle more alloc failure cases gracefully
* SP ASM performance improvements mostly around AArch64
* SP ASM improvements for additional cache attack resistance
* Add RSA check for small difference between p and q
* 6-8% performance increase with ECC operations using SP int by improving the Montgomery Reduction
### Testing and Validation
* All shell scripts in source tree now tested for correctness using shellcheck and bash -n
* Added build testing under gcc-12 and -std=c++17 and fixed warnings
* TLS 1.3 script test improvement to wait for server to write file
* Unit tests for ECC r/s zeroness handling
* CI server was expanded with a very “quiet” machine that can support multiple ContantTime tests ensuring ongoing mitigation against side-channel timing based attacks. Algorithms being assessed on this machine are: AES-CBC, AES-GCM, CHACHA20, ECC, POLY1305, RSA, SHA256, SHA512, CURVE25519.
* Added new multi configuration windows builds to CI testing for greater testing coverage of windows use-cases
### Misc.
* Support for ECC import to check validity of key on import even if one of the coordinates (x or y) is 0
* Modify example app to work with FreeRTOS+IoT
* Ease of access for cert used for verifying a PKCS#7 bundle
* Clean up Visual Studio output and intermediate directories
* With TLS 1.3 fail immediately if a server sends empty certificate message
* Enhance the benchmark application to support multi-threaded testing
* Improvement for `wc_EccPublicKeyToDer` to not overestimate the buffer size required
* Fix to check if `wc_EccPublicKeyToDer` has enough output buffer space
* Fix year 2038 problem in wolfSSL_ASN1_TIME_diff
* Various portability improvements (Time, DTLS epoch size, IV alloc)
* Prefer status_request_v2 over status_request when both are present
* Add separate "struct stat" definition XSTATSTRUCT to make overriding XSTAT easier for portability
* With SipHash replace gcc specific ASM instruction with generic
* Don't force a ECC CA when a custom CA is passed with `-A`
* Add peer authentication failsafe for TLS 1.2 and below
* Improve parsing of UID from subject and issuer name with the compatibility layer by
* Fallback to full TLS handshake if session ticket fails
* Internal refactoring of code to reduce ssl.c file size
# wolfSSL Release 5.2.0 (Feb 21, 2022)
## Vulnerabilities
* \[High\] A TLS v1.3 server who requires mutual authentication can be
bypassed. If a malicious client does not send the certificate_verify
message a client can connect without presenting a certificate even
if the server requires one. Thank you to Aina Toky Rasoamanana and
Olivier Levillain of Télécom SudParis.
* \[High\] A TLS v1.3 client attempting to authenticate a TLS v1.3
server can have its certificate check bypassed. If the sig_algo in
the certificate_verify message is different than the certificate
message checking may be bypassed. Thank you to Aina Toky Rasoamanana and
Olivier Levillain of Télécom SudParis.
## New Feature Additions
* Example applications for Renesas RX72N with FreeRTOS+IoT
* Renesas FSP 3.5.0 support for RA6M3
* For TLS 1.3, improved checks on order of received messages.
* Support for use of SHA-3 cryptography instructions available in
ARMv8.2-A architecture extensions. (For Apple M1)
* Support for use of SHA-512 cryptography instructions available in
ARMv8.2-A architecture extensions. (For Apple M1)
* Fixes for clang -Os on clang >= 12.0.0
* Expose Sequence Numbers so that Linux TLS (kTLS) can be configured
* Fix bug in TLSX_ALPN_ParseAndSet when using ALPN select callback.
* Allow DES3 with FIPS v5-dev.
* Include HMAC for deterministic ECC sign build
* Add --enable-chrony configure option. This sets build options needed
to build the Chrony NTP (Network Time Protocol) service.
* Add support for STM32U575xx boards.
* Fixes for NXPs SE050 Ed25519/Curve25519.
* TLS: Secure renegotiation info on by default for compatibility.
* Inline C code version of ARM32 assembly for cryptographic algorithms
available and compiling for improved performance on ARM platforms
* Configure HMAC: define NO_HMAC to disable HMAC (default: enabled)
* ISO-TP transport layer support added to wolfio for TLS over CAN Bus
* Fix initialization bug in SiLabs AES support
* Domain and IP check is only performed on leaf certificates
## ARM PSA Support (Platform Security Architecture) API
* Initial support added for ARMs Platform Security Architecture (PSA)
API in wolfCrypt which allows support of ARM PSA enabled devices by
wolfSSL, wolfSSH, and wolfBoot and wolfCrypt FIPS.
* Included algorithms: ECDSA, ECDH, HKDF, AES, SHA1, SHA256, SHA224, RNG
## ECICE Updates
* Support for more encryption algorithms: AES-256-CBC, AES-128-CTR,
AES-256-CTR
* Support for compressed public keys in messages.
## Math Improvements
* Improved performance of X448 and Ed448 through inlining Karatsuba in
square and multiplication operations for 128-bit implementation
(64-bit platforms with 128-bit type support).
* SP Math C implementation: fix for corner case in curve specific
implementations of Montgomery Reduction (P-256, P-384).
* SP math all: assembly snippets added for ARM Thumb. Performance
improvement on platform.
* SP math all: ARM64/32 sp_div_word assembly snippets added to remove
dependency on __udiv3.
* SP C implementation: multiplication of two signed types with overflow
is undefined in C. Now cast to unsigned type before multiplication is
performed.
* SP C implementation correctly builds when using CFLAG: -m32
## OpenSSL Compatibility Layer
* Added DH_get_2048_256 to compatibility layer.
* wolfSSLeay_version now returns the version of wolfSSL
* Added C++ exports for APIs in wolfssl/openssl/crypto.h. This allows
better compatibility when building with a C++ compiler.
* Fix for OpenSSL x509_NAME_hash mismatch
* Implement FIPS_mode and FIPS_mode_set in the compat layer.
* Fix for certreq and certgen options with openssl compatibility
* wolfSSL_BIO_dump() and wolfSSL_OBJ_obj2txt() rework
* Fix IV length bug in EVP AES-GCM code.
* Add new ASN1_INTEGER compatibility functions.
* Fix wolfSSL_PEM_X509_INFO_read with NO_FILESYSTEM
## CMake Updates
* Check for valid override values.
* Add `KEYGEN` option.
* Cleanup help messages.
* Add options to support wolfTPM.
## VisualStudio Updates
* Remove deprecated VS solution
* Fix VS unreachable code warning
## New Algorithms and Protocols
* AES-SIV (RFC 5297)
* DTLS SRTP (RFC 5764), used with WebRTC to agree on profile for new
real-time session keys
* SipHash MAC/PRF for hash tables. Includes inline assembly for
x86_64 and Aarch64.
## Remove Obsolete Algorithms
* IDEA
* Rabbit
* HC-128
# wolfSSL Release 5.1.1 (Jan 3rd, 2022)
Release 5.1.1 of wolfSSL embedded TLS has a high vulnerability fix:
### Vulnerabilities
* \[High\] In connections using AES-CBC or DES3 with TLS/DTLS 1.2 or 1.1 the IV being used is not random. Users using wolfSSL version 5.0.0 or 5.1.0 doing TLS/DTLS 1.2 or 1.1 connections, without AEAD only, should update the version of wolfSSL used. (CVE-2022-23408)
# wolfSSL Release 5.1.0 (Dec 27, 2021)
Release 5.1.0 of wolfSSL embedded TLS has bug fixes and new features including:
### Vulnerabilities
* \[Low\] Potential for DoS attack on a wolfSSL client due to processing hello packets of the incorrect side. This affects only connections using TLS v1.2 or less that have also been compromised by a man in the middle attack. Thanks to James Henderson, Mathy Vanhoef, Chris M. Stone, Sam L. Thomas, Nicolas Bailleut, and Tom Chothia (University of Birmingham, KU Leuven, ENS Rennes for the report.
* \[Low\] Client side session resumption issue once the session resumption cache has been filled up. The hijacking of a session resumption has been demonstrated so far with only non verified peer connections. That is where the client is not verifying the servers CA that it is connecting to. There is the potential though for other cases involving proxies that are verifying the server to be at risk, if using wolfSSL in a case involving proxies use wolfSSL_get1_session and then wolfSSL_SESSION_free when done where possible. If not adding in the session get/free function calls we recommend that users of wolfSSL that are resuming sessions update to the latest version (wolfSSL version 5.1.0 or later). Thanks to the UK's National Cyber Security Centre (NCSC) for the report.
### New Feature Additions
###### Ports
* Curve25519 support with NXP SE050 added
* Renesas RA6M4 support with SCE Protected Mode and FSP 3.5.0
* Renesas TSIP 1.14 support for RX65N/RX72N
###### Post Quantum
* Post quantum resistant algorithms used with Apache port
* NIST round 3 FALCON Signature Scheme support added to TLS 1.3 connections
* FALCON added to the benchmarking application
* Testing of cURL with wolfSSL post quantum resistant build
###### Compatibility Layer Additions
* Updated NGINX port to NGINX version 1.21.4
* Updated Apache port to Apache version 2.4.51
* Add support for SSL_OP_NO_TLSv1_2 flag with wolfSSL_CTX_set_options function
* Support added for the functions
- SSL_CTX_get_max_early_data
- SSL_CTX_set_max_early_data
- SSL_set_max_early_data
- SSL_get_max_early_data
- SSL_CTX_clear_mode
- SSL_CONF_cmd_value_type
- SSL_read_early_data
- SSL_write_early_data
###### Misc.
* Crypto callback support for AES-CCM added. A callback function can be registered and used instead of the default AES-CCM implementation in wolfSSL.
* Added AES-OFB to the FIPS boundary for future FIPS validations.
* Add support for custom OIDs used with CSR (certificate signing request) generation using the macro WOLFSSL_CUSTOM_OID
* Added HKDF extract callback function for use with TLS 1.3
* Add variant from RFC6979 of deterministic ECC signing that can be enabled using the macro WOLFSSL_ECDSA_DETERMINISTIC_K_VARIANT
* Added the function wc_GetPubKeyDerFromCert to get the public key from a DecodedCert structure
* Added the functions wc_InitDecodedCert, wc_ParseCert and wc_FreeDecodedCert for access to decoding a certificate into a DecodedCert structure
* Added the macro WOLFSSL_ECC_NO_SMALL_STACK for hybrid builds where the numerous malloc/free with ECC is undesired but small stack use is desired throughout the rest of the library
* Added the function wc_d2i_PKCS12_fp for reading a PKCS12 file and parsing it
### Fixes
###### PORT Fixes
* Building with Android wpa_supplicant and KeyStore
* Setting initial value of CA certificate with TSIP enabled
* Cryptocell ECC build fix and fix with RSA disabled
* IoT-SAFE improvement for Key/File slot ID size, fix for C++ compile, and fixes for retrieving the public key after key generation
###### Math Library Fixes
* Check return values on TFM library montgomery function in case the system runs out of memory. This resolves an edge case of invalid ECC signatures being created.
* SP math library sanity check on size of values passed to sp_gcd.
* SP math library sanity check on exponentiation by 0 with mod_exp
* Update base ECC mp_sqrtmod_prime function to handle an edge case of zero
* TFM math library with Intel MULX multiply fix for carry in assembly code
###### Misc.
* Fix for potential heap buffer overflow with compatibility layer PEM parsing
* Fix for edge memory leak case with an error encountered during TLS resumption
* Fix for length on inner sequence created with wc_DhKeyToDer when handling small DH keys
* Fix for sanity check on input argument to DSA sign and verify
* Fix for setting of the return value with ASN1 integer get on an i386 device
* Fix for BER to DER size checks with PKCS7 decryption
* Fix for memory leak with PrintPubKeyEC function in compatibility layer
* Edge case with deterministic ECC key generation when the private key has leading 0s
* Fix for build with OPENSSL_EXTRA and NO_WOLFSSL_STUB both defined
* Use page aligned memory with ECDSA signing and KCAPI
* Skip expired sessions for TLS 1.3 rather than turning off the resume behavior
* Fix for DTLS handling dropped or retransmitted messages
### Improvements/Optimizations
###### Build Options and Warnings
* Bugfix: could not build with liboqs and without DH enabled
* Build with macro NO_ECC_KEY_EXPORT fixed
* Fix for building with the macro HAVE_ENCRYPT_THEN_MAC when session export is enabled
* Building with wolfSentry and HAVE_EX_DATA macro set
###### Math Libraries
* Improvement for performance with SP C implementation of montgomery reduction for ECC (P256 and P384) and SP ARM64 implementation for ECC (P384)
* With SP math handle case of dividing by length of dividend
* SP math improvement for lo/hi register names to be used with older GCC compilers
###### Misc.
* ASN name constraints checking code refactor for better efficiency and readability
* Refactor of compatibility layer stack freeing calls to simplify and reduce code
* Scrubbed code for trailing spaces, hard tabs, and any control characters
* Explicit check that leaf certificate's public key type match cipher suite signature algorithm
* Additional NULL sanity checks on WOLFSSL struct internally and improve switch statement fallthrough
* Retain OCSP error value when CRL is enabled with certificate parsing
* Update to NATIVE LwIP support for TCP use
* Sanity check on PEM size when parsing a PEM with OpenSSL compatibility layer API.
* SWIG wrapper was removed from the codebase in favor of dedicated Java and Python wrappers.
* Updates to bundled example client for when to load the CA, handling print out of IP alt names, and printing out the peers certificate in PEM format
* Handling BER encoded inner content type with PKCS7 verify
* Checking for SOCKET_EPIPE errors from low level socket
* Improvements to cleanup in the case that wolfSSL_Init fails
* Update test and example certificates expiration dates
# wolfSSL Release 5.0.0 (Nov 01, 2021)
Release 5.0.0 of wolfSSL embedded TLS has bug fixes and new features including:

View File

@ -1,6 +1,6 @@
/* wolfssl_client.ino
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* wolfssl_server.ino
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

151
IDE/AURIX/Cpu0_Main.c Normal file
View File

@ -0,0 +1,151 @@
/* Cpu0_Main.c
*
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
* wolfSSL is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* wolfSSL is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
*/
/* Infineon includes */
#include "Ifx_Types.h"
#include "IfxCpu.h"
#include "IfxScuWdt.h"
#include "IfxAsclin_Asc.h"
#include "IfxCpu_Irq.h"
#include "IfxPort.h"
#include "SysSe/Bsp/Bsp.h"
/* For mapping stdio printf */
#include <stdio.h>
#include <string.h>
/* used to wait for CPU sync event */
IFX_ALIGN(4) IfxCpu_syncEvent g_cpuSyncEvent = 0;
#define SERIAL_BAUDRATE 115200 /* Baud rate in bit/s */
#define SERIAL_PIN_RX IfxAsclin0_RXA_P14_1_IN /* RX pin of the board */
#define SERIAL_PIN_TX IfxAsclin0_TX_P14_0_OUT /* TX pin of the board */
#define INTPRIO_ASCLIN0_TX 19 /* Priority of the ISR */
#define ASC_TX_BUFFER_SIZE 128 /* Definition of the buffer size */
/* Declaration of the ASC handle */
static IfxAsclin_Asc g_asc;
/* Declaration of the FIFOs parameters:
* The transfer buffers allocate memory for the data itself and for FIFO runtime
* variables. 8 more bytes have to be added to ensure a proper circular buffer
* handling independent from the address to which the buffers have been located.
*/
static uint8 g_ascTxBuffer[ASC_TX_BUFFER_SIZE + sizeof(Ifx_Fifo) + 8];
/******************************************************************************/
/*----Function Implementations------------------------------------------------*/
/******************************************************************************/
/* Re-target the C library printf function to the asc lin. */
int fputc(int ch, FILE *f)
{
Ifx_SizeT count;
/* convert to CRLF */
if (ch == (int)'\n') {
int chcr = (int)'\r';
count = 1;
IfxAsclin_Asc_write(&g_asc, &chcr, &count, TIME_INFINITE);
}
count = 1;
IfxAsclin_Asc_write(&g_asc, &ch, &count, TIME_INFINITE);
return ch;
}
/* Add the Interrupt Service Routine */
IFX_INTERRUPT(asclin0_Tx_ISR, 0, INTPRIO_ASCLIN0_TX);
void asclin0_Tx_ISR(void)
{
IfxAsclin_Asc_isrTransmit(&g_asc);
}
static void init_UART(void)
{
IfxAsclin_Asc_Config ascConfig;
/* Port pins configuration */
const IfxAsclin_Asc_Pins pins = {
NULL_PTR, IfxPort_InputMode_pullUp, /* CTS pin not used */
&SERIAL_PIN_RX, IfxPort_InputMode_pullUp, /* RX pin */
NULL_PTR, IfxPort_OutputMode_pushPull, /* RTS pin not used */
&SERIAL_PIN_TX, IfxPort_OutputMode_pushPull, /* TX pin */
IfxPort_PadDriver_cmosAutomotiveSpeed1
};
/* Initialize an instance of IfxAsclin_Asc_Config with default values */
IfxAsclin_Asc_initModuleConfig(&ascConfig, SERIAL_PIN_TX.module);
/* Set the desired baud rate */
ascConfig.baudrate.baudrate = SERIAL_BAUDRATE;
/* ISR priorities and interrupt target */
ascConfig.interrupt.txPriority = INTPRIO_ASCLIN0_TX;
ascConfig.interrupt.typeOfService = IfxCpu_Irq_getTos(IfxCpu_getCoreIndex());
/* FIFO configuration */
ascConfig.txBuffer = &g_ascTxBuffer;
ascConfig.txBufferSize = ASC_TX_BUFFER_SIZE;
ascConfig.pins = &pins;
/* Initialize module with above parameters */
IfxAsclin_Asc_initModule(&g_asc, &ascConfig);
/* Turn off buffers, so I/O occurs immediately */
setvbuf(stdin, NULL, _IONBF, 0);
setvbuf(stdout, NULL, _IONBF, 0);
setvbuf(stderr, NULL, _IONBF, 0);
}
int send_UART(const char* str)
{
Ifx_SizeT count = (Ifx_SizeT)strlen(str);
IfxAsclin_Asc_write(&g_asc, str, &count, TIME_INFINITE);
return (int)count;
}
void core0_main(void)
{
IfxCpu_enableInterrupts();
/* !!WATCHDOG0 AND SAFETY WATCHDOG ARE DISABLED HERE!!
* Enable the watchdogs and service them periodically if it is required
*/
IfxScuWdt_disableCpuWatchdog(IfxScuWdt_getCpuWatchdogPassword());
IfxScuWdt_disableSafetyWatchdog(IfxScuWdt_getSafetyWatchdogPassword());
/* Wait for CPU sync event */
IfxCpu_emitEvent(&g_cpuSyncEvent);
IfxCpu_waitEvent(&g_cpuSyncEvent, 1);
/* Initialize the UART to board VCOM */
init_UART();
/* bare metal loop */
while(1)
{
extern void run_wolf_tests(void);
run_wolf_tests();
/* wait 5 seconds */
waitTime(IfxStm_getTicksFromMilliseconds(BSP_DEFAULT_TIMER, 5 * 1000));
} /* while */
}

114
IDE/AURIX/README.md Normal file
View File

@ -0,0 +1,114 @@
# Infineon AURIX Development Studio
An Eclipse based IDE for developing software for the Infineon TriCore AURIX TX3XX.
Tested Platform:
* Infineon AURIX™ Development Studio 1.7.2 (Build 20220617-0730)
* Infineon TriBoard TC399 v2.0
* wolfSSL v5.4.0 (with PR 5419)
## Running wolfCrypt on TriCore
1) Add the wolfSSL source and headers to `Libraries/wolfssl`.
- Only the following folders are required: `src`, `wolfcrypt` and `wolfssl`.
- See script to help with producing bundle here: https://github.com/wolfSSL/wolfssl/blob/master/scripts/makedistsmall.sh
2) Add `WOLFSSL_USER_SETTINGS` to the Preprocessing symbols list. C/C++ Build -> Settings -> TASKING C/C++ Compiler -> Preprocessing.
3) Add `Libraries/wolfssl` to the include path. C/C++ General -> Paths and Symbols -> Includes -> GNU C
4) Add ignores for the following warnings. Unused static function (553) and switch missing break (536). C/C++ Build -> Settings -> TASKING C/C++ Compiler -> Diagnostics
5) Copy `Cpu0_Main.c`, `user_settings.h` and `wolf_main.c` into the project folder.
6) Increase the stack by modifying `Lcf_Tasking_Tricore_Tc.lsl` to adjusting the USTACK0-4 (`LCF_USTACK#_SIZE`) from 2k to 12k.
6) Build and run/debug.
### Example output from wolfCrypt test and benchmark
Benchmark Configuration:
* TriCore (TC1.6.2P) 32-bit super-scalar running at 300MHz:
* Release build: `-O2`
* SP Math SMALL: sp_c32.c for RSA/ECC/DH
* AES GCM SMALL
```
Running wolfCrypt Tests...
------------------------------------------------------------------------------
wolfSSL version 5.4.0
------------------------------------------------------------------------------
error test passed!
MEMORY test passed!
base64 test passed!
asn test passed!
RANDOM test passed!
SHA test passed!
SHA-256 test passed!
Hash test passed!
HMAC-SHA test passed!
HMAC-SHA256 test passed!
HMAC-KDF test passed!
TLSv1.3 KDF test passed!
GMAC test passed!
Chacha test passed!
POLY1305 test passed!
ChaCha20-Poly1305 AEAD test passed!
AES test passed!
AES192 test passed!
AES256 test passed!
AES-GCM test passed!
RSA test passed!
ECC test passed!
ECC buffer test passed!
CMAC test passed!
logging test passed!
time test passed!
mutex test passed!
memcb test passed!
Test complete
Crypt Test: Return code 0
Running wolfCrypt Benchmarks...
wolfCrypt Benchmark (block bytes 1024, min 1.0 sec each)
RNG 725 KB took 1.023 seconds, 708.703 KB/s
AES-128-CBC-enc 2 MB took 1.002 seconds, 2.071 MB/s
AES-128-CBC-dec 2 MB took 1.005 seconds, 2.065 MB/s
AES-192-CBC-enc 2 MB took 1.002 seconds, 1.779 MB/s
AES-192-CBC-dec 2 MB took 1.013 seconds, 1.783 MB/s
AES-256-CBC-enc 2 MB took 1.003 seconds, 1.558 MB/s
AES-256-CBC-dec 2 MB took 1.009 seconds, 1.573 MB/s
AES-128-GCM-enc 225 KB took 1.013 seconds, 222.112 KB/s
AES-128-GCM-dec 225 KB took 1.014 seconds, 221.892 KB/s
AES-192-GCM-enc 225 KB took 1.046 seconds, 215.107 KB/s
AES-192-GCM-dec 225 KB took 1.046 seconds, 215.104 KB/s
AES-256-GCM-enc 225 KB took 1.070 seconds, 210.279 KB/s
AES-256-GCM-dec 225 KB took 1.069 seconds, 210.477 KB/s
GMAC Small 251 KB took 1.000 seconds, 251.000 KB/s
AES-128-ECB-enc 2 MB took 1.000 seconds, 2.000 MB/s
AES-128-ECB-dec 2 MB took 1.000 seconds, 2.049 MB/s
AES-192-ECB-enc 2 MB took 1.000 seconds, 1.727 MB/s
AES-192-ECB-dec 2 MB took 1.000 seconds, 1.772 MB/s
AES-256-ECB-enc 2 MB took 1.000 seconds, 1.518 MB/s
AES-256-ECB-dec 2 MB took 1.000 seconds, 1.563 MB/s
CHACHA 3 MB took 1.007 seconds, 3.322 MB/s
CHA-POLY 2 MB took 1.011 seconds, 2.028 MB/s
POLY1305 6 MB took 1.003 seconds, 6.012 MB/s
SHA 3 MB took 1.004 seconds, 3.380 MB/s
SHA-256 2 MB took 1.003 seconds, 1.558 MB/s
AES-128-CMAC 2 MB took 1.010 seconds, 2.055 MB/s
AES-256-CMAC 2 MB took 1.010 seconds, 1.547 MB/s
HMAC-SHA 3 MB took 1.004 seconds, 3.356 MB/s
HMAC-SHA256 2 MB took 1.010 seconds, 1.547 MB/s
RSA 2048 public 50 ops took 1.020 sec, avg 20.400 ms, 49.019 ops/sec
RSA 2048 private 2 ops took 2.377 sec, avg 1188.492 ms, 0.841 ops/sec
ECC [ SECP256R1] 256 key gen 16 ops took 1.061 sec, avg 66.313 ms, 15.080 ops/sec
ECDHE [ SECP256R1] 256 agree 16 ops took 1.059 sec, avg 66.187 ms, 15.109 ops/sec
ECDSA [ SECP256R1] 256 sign 14 ops took 1.058 sec, avg 75.570 ms, 13.233 ops/sec
ECDSA [ SECP256R1] 256 verify 8 ops took 1.080 sec, avg 135.002 ms, 7.407 ops/sec
Benchmark complete
Benchmark Test: Return code 0
```
## Running wolfCrypt on the HSM (Cortex M3)
Coming soon
## Support
For questions please email facts@wolfssl.com

8
IDE/AURIX/include.am Normal file
View File

@ -0,0 +1,8 @@
# vim:ft=automake
# included from Top Level Makefile.am
# All paths should be given relative to the root
EXTRA_DIST+= IDE/AURIX/Cpu0_Main.c
EXTRA_DIST+= IDE/AURIX/README.md
EXTRA_DIST+= IDE/AURIX/user_settings.h
EXTRA_DIST+= IDE/AURIX/wolf_main.c

461
IDE/AURIX/user_settings.h Normal file
View File

@ -0,0 +1,461 @@
/* user_settings.h
*
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
* wolfSSL is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* wolfSSL is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
*/
/* Template for the Infineon AURIX Development Studio and TC3XX
* Example wolfSSL user settings with #if 0/1 gates to enable/disable algorithms and features.
* This file is included with wolfssl/wolfcrypt/settings.h when WOLFSSL_USER_SETTINGS is defined.
*/
#ifndef WOLFSSL_USER_SETTINGS_H
#define WOLFSSL_USER_SETTINGS_H
#ifdef __cplusplus
extern "C" {
#endif
/* ------------------------------------------------------------------------- */
/* Platform */
/* ------------------------------------------------------------------------- */
/* Alignment and sizeof 64-bit */
#define WOLFSSL_GENERAL_ALIGNMENT 4
#define SIZEOF_LONG_LONG 8
/* disable threading - mutex locking */
#define SINGLE_THREADED
/* ignore file include warnings */
#define WOLFSSL_IGNORE_FILE_WARN
/* disable the built-in socket support and use the IO callbacks.
* Set with wolfSSL_CTX_SetIORecv/wolfSSL_CTX_SetIOSend
*/
#define WOLFSSL_USER_IO
/* Disable file system */
#define NO_FILESYSTEM
/* ------------------------------------------------------------------------- */
/* Port */
/* ------------------------------------------------------------------------- */
/* Override Current Time */
/* Allows custom "custom_time()" function to be used for benchmark */
#define WOLFSSL_USER_CURRTIME
#define WOLFSSL_GMTIME
#define USER_TICKS
extern unsigned long my_time(unsigned long* timer);
#define XTIME my_time
/* Use built-in P-RNG (SHA256 based) with HW RNG */
#undef HAVE_HASHDRBG
#define HAVE_HASHDRBG
/* Custom Seed Source */
#define CUSTOM_RAND_TYPE unsigned int
extern unsigned int my_rng_seed_gen(void);
#undef CUSTOM_RAND_GENERATE
#define CUSTOM_RAND_GENERATE my_rng_seed_gen
/* Standard Lib - C89 */
#define XSTRCASECMP(s1,s2) strcmp((s1),(s2))
/* ------------------------------------------------------------------------- */
/* Math Configuration */
/* ------------------------------------------------------------------------- */
#undef USE_FAST_MATH
#undef WOLFSSL_SP
#if 1
/* Wolf Single Precision Math */
#define WOLFSSL_HAVE_SP_RSA
//#define WOLFSSL_HAVE_SP_DH
#define WOLFSSL_HAVE_SP_ECC
#define WOLFSSL_SP_4096 /* Enable RSA/RH 4096-bit support */
#define WOLFSSL_SP_384 /* Enable ECC 384-bit SECP384R1 support */
#define WOLFSSL_SP_MATH /* only SP math - disables integer.c/tfm.c */
//#define WOLFSSL_SP_MATH_ALL /* use SP math for all key sizes and curves */
#define WOLFSSL_SP_NO_MALLOC
//#define WOLFSSL_SP_DIV_32 /* do not use 64-bit divides */
//#define WOLFSSL_SP_CACHE_RESISTANT
/* use smaller version of code */
#define WOLFSSL_SP_SMALL
/* SP Assembly Speedups - specific to chip type */
//#define WOLFSSL_SP_ASM
//#define WOLFSSL_SP_ARM32_ASM
//#define WOLFSSL_SP_ARM64_ASM
//#define WOLFSSL_SP_ARM_THUMB_ASM
//#define WOLFSSL_SP_ARM_CORTEX_M_ASM
#endif
#ifndef WOLFSSL_SP_MATH
#if 0
/* fast math (tfmc.) (stack based and timing resistant) */
#define USE_FAST_MATH
#define TFM_TIMING_RESISTANT
#else
/* normal heap based integer.c (not timing resistant) */
#define USE_INTEGER_HEAP_MATH
#endif
#endif
/* ------------------------------------------------------------------------- */
/* Crypto */
/* ------------------------------------------------------------------------- */
/* RSA */
#undef NO_RSA
#if 1
#ifdef USE_FAST_MATH
/* Maximum math bits (Max RSA key bits * 2) */
#define FP_MAX_BITS 4096
#endif
/* half as much memory but twice as slow */
//#define RSA_LOW_MEM
/* Enables blinding mode, to prevent timing attacks */
#define WC_RSA_BLINDING
/* RSA PSS Support */
#define WC_RSA_PSS
#else
#define NO_RSA
#endif
/* DH */
#undef NO_DH
#if 0
/* Use table for DH instead of -lm (math) lib dependency */
#if 1
#define WOLFSSL_DH_CONST
#define HAVE_FFDHE_2048
//#define HAVE_FFDHE_4096
//#define HAVE_FFDHE_6144
//#define HAVE_FFDHE_8192
#endif
#else
#define NO_DH
#endif
/* ECC */
#undef HAVE_ECC
#if 1
#define HAVE_ECC
/* Manually define enabled curves */
#define ECC_USER_CURVES
#ifdef ECC_USER_CURVES
/* Manual Curve Selection */
//#define HAVE_ECC192
//#define HAVE_ECC224
#undef NO_ECC256
#define HAVE_ECC384
//#define HAVE_ECC521
#endif
/* Fixed point cache (speeds repeated operations against same private key) */
//#define FP_ECC
#ifdef FP_ECC
/* Bits / Entries */
#define FP_ENTRIES 2
#define FP_LUT 4
#endif
/* Optional ECC calculation method */
/* Note: doubles heap usage, but slightly faster */
#define ECC_SHAMIR
/* Reduces heap usage, but slower */
#define ECC_TIMING_RESISTANT
/* Compressed ECC Key Support */
//#define HAVE_COMP_KEY
/* Use alternate ECC size for ECC math */
#ifdef USE_FAST_MATH
/* MAX ECC BITS = ROUND8(MAX ECC) * 2 */
#if defined(NO_RSA) && defined(NO_DH)
/* Custom fastmath size if not using RSA/DH */
#define FP_MAX_BITS (256 * 2)
#else
/* use heap allocation for ECC points */
#define ALT_ECC_SIZE
/* wolfSSL will compute the FP_MAX_BITS_ECC, but it can be overriden */
//#define FP_MAX_BITS_ECC (256 * 2)
#endif
/* Speedups specific to curve */
#ifndef NO_ECC256
#define TFM_ECC256
#endif
#endif
#endif
/* AES */
#undef NO_AES
#if 1
#define HAVE_AES_CBC
/* GCM Method: GCM_TABLE_4BIT, GCM_SMALL, GCM_WORD32 or GCM_TABLE */
#define HAVE_AESGCM
#define GCM_SMALL
#define WOLFSSL_AES_DIRECT
#define HAVE_AES_ECB
#else
#define NO_AES
#endif
/* DES3 */
#undef NO_DES3
#if 0
#else
#define NO_DES3
#endif
/* ChaCha20 / Poly1305 */
#undef HAVE_CHACHA
#undef HAVE_POLY1305
#if 1
#define HAVE_CHACHA
#define HAVE_POLY1305
/* Needed for Poly1305 */
#define HAVE_ONE_TIME_AUTH
#endif
/* Ed25519 / Curve25519 */
#undef HAVE_CURVE25519
#undef HAVE_ED25519
#if 0
#define HAVE_CURVE25519
#define HAVE_ED25519 /* ED25519 Requires SHA512 */
/* Optionally use small math (less flash usage, but much slower) */
#if 1
#define CURVED25519_SMALL
#endif
#endif
/* ------------------------------------------------------------------------- */
/* Hashing */
/* ------------------------------------------------------------------------- */
/* Sha */
#undef NO_SHA
#if 1
/* on by default */
/* 1k smaller, but 25% slower */
//#define USE_SLOW_SHA
#else
#define NO_SHA
#endif
/* Sha256 */
#undef NO_SHA256
#if 1
/* not unrolled - ~2k smaller and ~25% slower */
//#define USE_SLOW_SHA256
/* Sha224 */
#if 0
#define WOLFSSL_SHA224
#endif
#else
#define NO_SHA256
#endif
/* Sha512 */
#undef WOLFSSL_SHA512
#if 0
#define WOLFSSL_SHA512
/* Sha384 */
#undef WOLFSSL_SHA384
#if 0
#define WOLFSSL_SHA384
#endif
/* over twice as small, but 50% slower */
//#define USE_SLOW_SHA512
#endif
/* Sha3 */
#undef WOLFSSL_SHA3
#if 0
#define WOLFSSL_SHA3
#endif
/* MD5 */
#undef NO_MD5
#if 0
/* on by default */
#else
#define NO_MD5
#endif
/* HKDF */
#undef HAVE_HKDF
#if 1
#define HAVE_HKDF
#endif
/* CMAC */
#undef WOLFSSL_CMAC
#if 1
#define WOLFSSL_CMAC
/* Note: requires WOLFSSL_AES_DIRECT */
#endif
/* HMAC - on by default */
#undef NO_HMAC
#if 1
/* on by default */
#else
#define NO_HMAC
#endif
/* ------------------------------------------------------------------------- */
/* ASN */
/* ------------------------------------------------------------------------- */
#if 0
/* Use the newer ASN template code */
#define WOLFSSL_ASN_TEMPLATE
//#define WOLFSSL_CUSTOM_OID
//#define HAVE_OID_ENCODING
//#define HAVE_OID_DECODING
#else
/* Use the original custom ASN code */
#endif
/* Optionally disable time checking for ASN */
//#define NO_ASN_TIME
/* ------------------------------------------------------------------------- */
/* Benchmark / Test */
/* ------------------------------------------------------------------------- */
/* Use reduced benchmark / test sizes */
#define BENCH_EMBEDDED
/* Use test buffers from array (not filesystem) */
#ifndef NO_FILESYSTEM
#define USE_CERT_BUFFERS_256
#define USE_CERT_BUFFERS_2048
#endif
/* ------------------------------------------------------------------------- */
/* Debugging */
/* ------------------------------------------------------------------------- */
#undef DEBUG_WOLFSSL
#undef NO_ERROR_STRINGS
#if 0
#define DEBUG_WOLFSSL
#define WOLFSSL_LOG_PRINTF
#else
#if 0
#define NO_ERROR_STRINGS
#endif
#endif
/* ------------------------------------------------------------------------- */
/* Memory */
/* ------------------------------------------------------------------------- */
#if 0
/* Static memory requires fast math or SP math with no malloc */
#define WOLFSSL_STATIC_MEMORY
/* Disable fallback malloc/free */
#define WOLFSSL_NO_MALLOC
#if 1
#define WOLFSSL_MALLOC_CHECK /* trap malloc failure */
#endif
#endif
/* ------------------------------------------------------------------------- */
/* Enable Features */
/* ------------------------------------------------------------------------- */
#define WOLFSSL_TLS13
#define WOLFSSL_OLD_PRIME_CHECK /* Use faster DH prime checking */
#define HAVE_TLS_EXTENSIONS
#define HAVE_SUPPORTED_CURVES
#define WOLFSSL_BASE64_ENCODE
//#define WOLFSSL_KEY_GEN /* For RSA Key gen only */
//#define KEEP_PEER_CERT
//#define HAVE_COMP_KEY
/* TLS Session Cache */
#if 0
#define SMALL_SESSION_CACHE
#else
#define NO_SESSION_CACHE
#endif
/* ------------------------------------------------------------------------- */
/* Disable Features */
/* ------------------------------------------------------------------------- */
//#define NO_WOLFSSL_SERVER
//#define NO_WOLFSSL_CLIENT
//#define NO_CRYPT_TEST
//#define NO_CRYPT_BENCHMARK
//#define WOLFCRYPT_ONLY
/* In-lining of misc.c functions */
/* If defined, must include wolfcrypt/src/misc.c in build */
/* Slower, but about 1k smaller */
//#define NO_INLINE
#define NO_WRITEV
#define NO_MAIN_DRIVER
//#define NO_DEV_RANDOM
#define NO_OLD_TLS
#define NO_PSK
#define NO_DSA
#define NO_RC4
#define NO_MD4
#define NO_PWDBASED
//#define NO_CODING
//#define NO_CERTS
//#define NO_SIG_WRAPPER
#ifdef __cplusplus
}
#endif
#endif /* WOLFSSL_USER_SETTINGS_H */

150
IDE/AURIX/wolf_main.c Normal file
View File

@ -0,0 +1,150 @@
/* wolf_main.c
*
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
* wolfSSL is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* wolfSSL is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
*/
/* wolfSSL includes */
#ifndef WOLFSSL_USER_SETTINGS
#include <wolfssl/options.h>
#endif
#include <wolfssl/wolfcrypt/settings.h>
#include <wolfssl/wolfcrypt/error-crypt.h>
#include <wolfssl/wolfcrypt/random.h> /* for CUSTOM_RAND_TYPE */
#include <wolfcrypt/test/test.h>
#include <wolfcrypt/benchmark/benchmark.h>
#include <stdint.h>
#include <stdio.h>
#include <stdarg.h>
#include <string.h>
/* Infineon Includes */
#include "Ifx_Types.h"
#include "IfxStm.h"
extern int send_UART(const char* str);
static void my_logging_cb(const int logLevel, const char *const logMessage)
{
send_UART(logMessage);
send_UART("\r\n");
(void)logLevel; /* not used */
}
/* TIME CODE */
/* Optionally you can define NO_ASN_TIME to disable all cert time checks */
static int hw_get_time_sec(void)
{
/* get time in seconds */
return IfxStm_get(&MODULE_STM0) / IfxStm_getFrequency(&MODULE_STM0);
}
/* This is used by wolfCrypt asn.c for cert time checking */
unsigned long my_time(unsigned long* timer)
{
(void)timer;
return hw_get_time_sec();
}
#ifndef WOLFCRYPT_ONLY
/* This is used by TLS only */
unsigned int LowResTimer(void)
{
return hw_get_time_sec();
}
#endif
#ifndef NO_CRYPT_BENCHMARK
/* This is used by wolfCrypt benchmark tool only */
double current_time(int reset)
{
double timeNow;
uint64_t timeMs, ticks = IfxStm_get(&MODULE_STM0);
(void)reset;
timeMs = ticks / (IfxStm_getFrequency(&MODULE_STM0) / 1000);
timeNow = (timeMs / 1000); // sec
timeNow += (double)(timeMs % 1000) / 1000; // ms
return timeNow;
}
#endif
/* RNG CODE */
/* TODO: Implement real RNG */
static unsigned int gCounter;
unsigned int hw_rand(void)
{
//#warning Must implement your own random source
return ++gCounter;
}
unsigned int my_rng_seed_gen(void)
{
return hw_rand();
}
typedef struct func_args {
int argc;
char** argv;
int return_code;
} func_args;
void run_wolf_tests(void)
{
func_args args;
#ifdef DEBUG_WOLFSSL
wolfSSL_Debugging_ON();
#endif
wolfSSL_SetLoggingCb(my_logging_cb);
/* initialize wolfSSL */
#ifdef WOLFCRYPT_ONLY
wolfCrypt_Init();
#else
wolfSSL_Init();
#endif
memset(&args, 0, sizeof(args));
args.return_code = NOT_COMPILED_IN; /* default */
printf("Running wolfCrypt Tests...\n");
#ifndef NO_CRYPT_TEST
args.return_code = 0;
wolfcrypt_test(&args);
printf("Crypt Test: Return code %d\n", args.return_code);
#else
args.return_code = NOT_COMPILED_IN;
#endif
printf("Running wolfCrypt Benchmarks...\n");
#ifndef NO_CRYPT_BENCHMARK
args.return_code = 0;
benchmark_test(&args);
#else
args.return_code = NOT_COMPILED_IN;
#endif
printf("Benchmark Test: Return code %d\n", args.return_code);
#ifdef WOLFCRYPT_ONLY
wolfCrypt_Cleanup();
#else
wolfSSL_Cleanup();
#endif
}

View File

@ -17,6 +17,11 @@ cc_library_shared {
"-DWOLFSSL_USER_SETTINGS",
"-Os",
"-fomit-frame-pointer",
/* If using WOLFSSL_ARMASM then add these cflags for ARM crypto extensions */
/* "-mcpu=cortex-a73+crypto", */
/* "-march=armv8-a", */
/* "-mstrict-align", */
],
include_dirs: [
"external/wolfssl/wolfssl",
@ -68,10 +73,9 @@ cc_library_shared {
"./wolfcrypt/src/ge_operations.c",
"./wolfcrypt/src/hash.c",
"./wolfcrypt/src/kdf.c",
"./wolfcrypt/src/hc128.c",
"./wolfcrypt/src/hmac.c",
"./wolfcrypt/src/idea.c",
"./wolfcrypt/src/integer.c",
"./wolfcrypt/src/kdf.c",
"./wolfcrypt/src/logging.c",
"./wolfcrypt/src/md2.c",
"./wolfcrypt/src/md4.c",
@ -81,7 +85,6 @@ cc_library_shared {
"./wolfcrypt/src/pkcs7.c",
"./wolfcrypt/src/poly1305.c",
"./wolfcrypt/src/pwdbased.c",
"./wolfcrypt/src/rabbit.c",
"./wolfcrypt/src/random.c",
"./wolfcrypt/src/rc2.c",
"./wolfcrypt/src/ripemd.c",

View File

@ -8,12 +8,32 @@
#define HAVE_FIPS
#endif
#ifdef __aarch64__
#if !defined(__clang__) || \
(defined(__clang__) && defined(__clang_major__) && __clang_major__ >= 5)
/* older clang v4 has issue with inline assembly constraints */
#define WOLFSSL_ARMASM
#endif
#endif
#if 1 /* SP Assembly Speedups (wPAA) */
#define WOLFSSL_SP
#define WOLFSSL_SP_SMALL /* use smaller version of code */
#define WOLFSSL_HAVE_SP_RSA
#define WOLFSSL_HAVE_SP_DH
#define WOLFSSL_HAVE_SP_ECC
#ifdef WOLFSSL_ARMASM
#define WOLFSSL_SP_ARM64_ASM
#endif
#endif
/* WPA Supplicant Support */
#define WOLFSSL_WPAS_SMALL
#define OPENSSL_ALL
#define HAVE_THREAD_LS
#define USE_FAST_MATH
#define FP_MAX_BITS (4096*2) /* Maximum math bits (Max RSA key bits * 2) */
#define TFM_TIMING_RESISTANT
#define ECC_TIMING_RESISTANT
#define WC_RSA_BLINDING
@ -22,8 +42,8 @@
#if 1
#define WOLFSSL_TLS13
#define WC_RSA_PSS
#endif
#define WC_RSA_PSS
#define HAVE_SESSION_TICKET
#define HAVE_TLS_EXTENSIONS
#define HAVE_SUPPORTED_CURVES
@ -38,7 +58,7 @@
#define HAVE_PK_CALLBACKS
/* crypto callback support is not in FIPS 3389 */
#ifndef HAVE_FIPS
#define WOLF_CRYPTO_CB
#define WOLF_CRYPTO_CB
#endif
#define KEEP_OUR_CERT
@ -58,7 +78,10 @@
#define WOLFSSL_KEY_GEN
#define WC_RSA_NO_PADDING
#define WOLFSSL_DH_CONST
#define HAVE_FFDHE_2048
#define HAVE_FFDHE_3072
#define HAVE_FFDHE_4096
#define HAVE_DH_DEFAULT_PARAMS
#ifdef HAVE_FIPS
#define WOLFSSL_VALIDATE_FFC_IMPORT
@ -68,6 +91,9 @@
#define WOLFSSL_SHA224
#define WOLFSSL_SHA512
#define WOLFSSL_SHA384
#define WOLFSSL_NOSHA512_256
#define WOLFSSL_NOSHA512_224
#define WOLFSSL_SHA3
#define HAVE_HKDF
#define HAVE_PKCS8
@ -80,6 +106,9 @@
#define HAVE_ECC_CDH
#define WOLFSSL_VALIDATE_ECC_IMPORT
#endif
#ifdef __i386
#define TFM_NO_ASM
#endif
#define HAVE_AESGCM
#define HAVE_AESCCM
@ -93,9 +122,6 @@
#define NO_DSA
#define NO_RC4
#define NO_HC128
#define NO_RABBIT
#define NO_RC4
#define NO_PSK
#define WOLFSSL_NO_SHAKE256
#define NO_MD4

View File

@ -1,6 +1,6 @@
/* main.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
@ -19,6 +19,7 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
*/
#include <wolfssl/wolfcrypt/settings.h>
#include <wolfcrypt/test/test.h>
#include <wolfcrypt/benchmark/benchmark.h>

View File

@ -1,6 +1,6 @@
/* user_settings.h
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
@ -558,12 +558,6 @@ extern "C" {
#undef NO_OLD_TLS
#define NO_OLD_TLS
#undef NO_HC128
#define NO_HC128
#undef NO_RABBIT
#define NO_RABBIT
#undef NO_PSK
#define NO_PSK

View File

@ -1,6 +1,6 @@
/* deos_malloc.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -424,21 +424,11 @@
<type>1</type>
<locationURI>WOLFSSL_ROOT/wolfcrypt/src/hash.c</locationURI>
</link>
<link>
<name>wolfcrypt/src/hc128.c</name>
<type>1</type>
<locationURI>WOLFSSL_ROOT/wolfcrypt/src/hc128.c</locationURI>
</link>
<link>
<name>wolfcrypt/src/hmac.c</name>
<type>1</type>
<locationURI>WOLFSSL_ROOT/wolfcrypt/src/hmac.c</locationURI>
</link>
<link>
<name>wolfcrypt/src/idea.c</name>
<type>1</type>
<locationURI>WOLFSSL_ROOT/wolfcrypt/src/idea.c</locationURI>
</link>
<link>
<name>wolfcrypt/src/integer.c</name>
<type>1</type>
@ -489,11 +479,6 @@
<type>1</type>
<locationURI>WOLFSSL_ROOT/wolfcrypt/src/pwdbased.c</locationURI>
</link>
<link>
<name>wolfcrypt/src/rabbit.c</name>
<type>1</type>
<locationURI>WOLFSSL_ROOT/wolfcrypt/src/rabbit.c</locationURI>
</link>
<link>
<name>wolfcrypt/src/random.c</name>
<type>1</type>

View File

@ -1,6 +1,6 @@
/* tls_wolfssl.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
@ -31,19 +31,19 @@ int setupTransport(clientConnectionHandleType* connectionHandle,
char* connectionId) {
int ret, error;
void * sendBuffer;
DWORD bufferSizeInBytes;
size_t bufferSizeInBytes;
if ((ret = socketTransportInitialize("mailbox-transport.config",
"transportConfigurationId",
(DWORD)waitIndefinitely,&error)) != transportSuccess)
waitIndefinitely,&error)) != transportSuccess)
printf("Initialize 0x%x, error=%d\n", ret, error);
else if ((ret = socketTransportClientInitialize((DWORD)waitIndefinitely,
else if ((ret = socketTransportClientInitialize(waitIndefinitely,
&error)) != transportSuccess)
printf("ClientInitialize 0x%x, error=%d\n", ret, error);
else if ((ret = socketTransportCreateConnection(connectionId,
(DWORD)waitIndefinitely,
waitIndefinitely,
COMPATIBILITY_ID_2,
connectionHandle,
&sendBuffer,
@ -53,7 +53,7 @@ int setupTransport(clientConnectionHandleType* connectionHandle,
else if ((ret = socketTransportSetConnectionForThread(currentThreadHandle(),
*connectionHandle,
(DWORD)waitIndefinitely,
waitIndefinitely,
&error)) != transportSuccess)
printf("SetConnectionForThread 0x%x, error=%d\n", ret, error);
@ -162,7 +162,7 @@ void wolfssl_client_test(uintData_t statusPtr) {
TCP_SERVER_IP_ADDR, TCP_SERVER_PORT);
server_addr.sin_family = AF_INET;
server_addr.sin_addr = inet_addr(TCP_SERVER_IP_ADDR);
server_addr.sin_addr.s_addr = inet_addr(TCP_SERVER_IP_ADDR);
server_addr.sin_port = htons(TCP_SERVER_PORT);
printf("Calling connect on socket\n");
@ -407,7 +407,7 @@ void wolfssl_server_test(uintData_t statusPtr)
printf("Setting up server_addr struct\n");
server_addr.sin_family = AF_INET;
server_addr.sin_addr = INADDR_ANY;
server_addr.sin_addr.s_addr = INADDR_ANY;
server_addr.sin_port = htons(TLS_SERVER_PORT);
bindStatus = bind(sock_listen, (sockaddr *) &server_addr, sizeof(server_addr));
@ -510,7 +510,7 @@ void wolfssl_server_test(uintData_t statusPtr)
wolfSSL_CTX_free(ctx);
return;
}
/* goToSleep() for 500 milli sec*/
/* goToSleep() for 500 milliseconds */
}
} while ((ret != SSL_SUCCESS) && (error == SSL_ERROR_WANT_READ));
@ -580,14 +580,14 @@ int wolfsslRunTests (void)
ts = createThread("TCPclient", "TCPThreadTemplate", wolfssl_client_test,
0, &TCPhandle );
if (ts != threadSuccess) {
printf("Unable to create TCP client thread, %i ", (DWORD)ts);
printf("Unable to create TCP client thread, %i ", (size_t)ts);
}
#endif
#if !defined(NO_WOLFSSL_SERVER)
ts = createThread("TCPserver", "TCPThreadTemplate", wolfssl_server_test,
0, &TCPhandle );
if (ts != threadSuccess) {
printf("Unable to create TCP server thread, %i ", (DWORD)ts);
printf("Unable to create TCP server thread, %i ", (size_t)ts);
}
#endif

View File

@ -1,6 +1,6 @@
/* tls_wolfssl.h
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* user_setting.h
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
@ -26,75 +26,141 @@
extern "C" {
#endif
#define WOLFSSL_DEOS
#if 0
/* RTEMS */
#define WOLFSSL_DEOS_RTEMS
/* You can select none or all of the following tests
using #define instead of #undef.
By default, all four tests run*/
#include <stdio.h>
#include <string.h>
#include <netinet/in.h>
#include <sys/socket.h>
#include <pthread.h>
#include <stdint.h>
#include <stddef.h> /* for size_t */
#include <stdlib.h> /* for malloc/free */
#undef NO_CRYPT_TEST
#undef NO_CRYPT_BENCHMARK
#undef NO_WOLFSSL_CLIENT
#undef NO_WOLFSSL_SERVER
#if (__BYTE_ORDER__ == __ORDER_BIG_ENDIAN__)
#define BIG_ENDIAN_ORDER
#else
#undef BIG_ENDIAN_ORDER
#define LITTLE_ENDIAN_ORDER
#endif
#else
/* DEOS Native */
#define WOLFSSL_DEOS
#include <deos.h>
#include <timeout.h>
#include <socketapi.h>
#include <lwip-socket.h>
#include <mem.h>
#include <string.h>
#include <stdlib.h> /* for rand_r: pseudo-random number generator */
#include <stdio.h> /* for snprintf */
#endif
/* Porting */
/* adjust CURRENT_UNIX_TIMESTAMP to seconds since Jan 01 1970. (UTC)
You can get the current time from https://www.unixtimestamp.com/
*/
#define CURRENT_UNIX_TIMESTAMP 1545864916
You can get the current time from https://www.unixtimestamp.com/ */
#define CURRENT_UNIX_TIMESTAMP 1663020069
#define NO_FILESYSTEM
#define BENCH_EMBEDDED /* use kB instead of mB for embedded benchmarking */
#define WOLFSSL_IGNORE_FILE_WARN /* ignore warning for include of files not required */
/* Math */
#define USE_FAST_MATH
#define FP_MAX_BITS (4096*2)
#define SIZEOF_LONG_LONG 8
#define TFM_TIMING_RESISTANT
#define ECC_TIMING_RESISTANT
#define WC_RSA_BLINDING
/* prevents from including multiple definition of main() */
#define NO_MAIN_DRIVER
#define NO_TESTSUITE_MAIN_DRIVER
/* Wolf Single Precision Math */
#undef WOLFSSL_SP
#if 1
#define WOLFSSL_HAVE_SP_RSA
#define WOLFSSL_HAVE_SP_DH
#define WOLFSSL_HAVE_SP_ECC
#define WOLFSSL_SP_4096 /* Enable RSA/RH 4096-bit support */
#define WOLFSSL_SP_384 /* Enable ECC 384-bit SECP384R1 support */
/* includes certificate test buffers via header files */
#define USE_CERT_BUFFERS_2048
//#define WOLFSSL_SP_CACHE_RESISTANT
#define WOLFSSL_SP_MATH /* only SP math - disables integer.c/tfm.c */
//#define WOLFSSL_SP_MATH_ALL /* use SP math for all key sizes and curves */
/*use kB instead of mB for embedded benchmarking*/
#define BENCH_EMBEDDED
#define WOLFSSL_SP_NO_MALLOC
//#define WOLFSSL_SP_DIV_32 /* do not use 64-bit divides */
#define NO_WRITE_TEMP_FILES
/* use smaller version of code */
#define WOLFSSL_SP_SMALL
#endif
#define HAVE_AESGCM
#define WOLFSSL_SHA512
/* Algorithms */
#undef NO_RSA
#undef NO_DH
#define WOLFSSL_DH_CONST
#define HAVE_ECC
#define HAVE_CURVE25519
#define CURVE25519_SMALL
#define HAVE_ED25519
#define ED25519_SMALL
#define ECC_USER_CURVES
#define HAVE_ECC384
#define WOLFSSL_DTLS
#if 1
#define HAVE_CURVE25519
#define HAVE_ED25519
#define CURVED25519_SMALL
#endif
#undef NO_SHA
#undef NO_MD5
#undef NO_SHA256
#define HAVE_AESGCM
#define WOLFSSL_SHA384
#define WOLFSSL_SHA512
/* TLS */
#define HAVE_TLS_EXTENSIONS
#define HAVE_SUPPORTED_CURVES
#define HAVE_EXTENDED_MASTER
#define HAVE_ENCRYPT_THEN_MAC
//#define WOLFSSL_DTLS
//#define WOLFSSL_DTLS13
//#define WOLFSSL_NO_TLS12
/* TLS 1.3 */
#if 0
/* TLS 1.3 */
#define WOLFSSL_TLS13
#define WC_RSA_PSS
#define HAVE_HKDF
#define HAVE_FFDHE_2048
#define HAVE_AEAD
#define HAVE_FFDHE_3072
#define HAVE_FFDHE_4096
#endif
/* wolfSentry */
#if 0
/* You can use your own custom random generator function with
no input parameters and a `CUSTOM_RAND_TYPE` return type*/
#ifndef CUSTOM_RAND_GENERATE
#define CUSTOM_RAND_TYPE int
#define CUSTOM_RAND_GENERATE yourRandGenFunc
#endif
#define WOLFSSL_WOLFSENTRY_HOOKS
#define HAVE_EX_DATA
#define HAVE_EX_DATA_CLEANUP_HOOKS
#endif
#if 1
#undef XMALLOC_OVERRIDE
/* compatibility layer */
#if 0
#define OPENSSL_EXTRA
#endif
/* Random */
#ifdef WOLFSSL_DEOS_RTEMS
extern int rtems_wolf_seed(unsigned char* output, unsigned int sz);
#define CUSTOM_RAND_GENERATE_SEED rtems_wolf_seed
#endif
/* custom heap handling */
#ifdef WOLFSSL_DEOS
#define WOLFSSL_NO_MALLOC
#define XMALLOC_OVERRIDE
/* prototypes for user heap override functions */
#include <stddef.h> /* for size_t */
extern void *malloc_deos(size_t size);
extern void free_deos(void *ptr);
extern void *realloc_deos(void *ptr, size_t size);
@ -102,9 +168,40 @@ You can get the current time from https://www.unixtimestamp.com/
#define XMALLOC(n, h, t) malloc_deos(n)
#define XFREE(p, h, t) free_deos(p)
#define XREALLOC(p, n, h, t) realloc_deos(p, n)
#endif
#if 0
#define DEBUG_WOLFSSL
#endif
/* You can select none or all of the following tests
* using #define instead of #undef.
* By default, all four tests run*/
#define NO_CRYPT_TEST
#define NO_CRYPT_BENCHMARK
#undef NO_WOLFSSL_CLIENT
#undef NO_WOLFSSL_SERVER
/* file system has not been ported since it is a separate product */
#define NO_FILESYSTEM
#define NO_WOLFSSL_DIR
#define NO_WRITEV
#define NO_WRITE_TEMP_FILES
/* disable old protocols and algorithms */
#define NO_OLD_TLS
#define NO_PSK
#define NO_DSA
#define NO_RC4
#define NO_MD4
#define NO_PWDBASED
/* prevents from including multiple definition of main() */
#define NO_MAIN_DRIVER
#define NO_TESTSUITE_MAIN_DRIVER
#ifdef __cplusplus
} /* extern "C" */
#endif

View File

@ -93,8 +93,6 @@ HMAC-SHA test passed!
HAC-SHA256 test passed!
HMAC-SHA512 test passed!
GMC test passed!
HC-128 test passed!
Rabbit test passed!
DS test passed!
DS3 test passed!
AES test passed!

View File

@ -1,6 +1,6 @@
/* client_wolfssl.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* client_wolfssl.h
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* server_wolfssl.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* server_wolfssl.h
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* user_setting.h
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* wolfsslRunTests.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -93,8 +93,6 @@ HMAC-SHA512 test passed!
X963-KDF test passed!
GMAC test passed!
ARC4 test passed!
HC-128 test passed!
Rabbit test passed!
DES test passed!
DES3 test passed!
AES test passed!
@ -172,4 +170,4 @@ ED 25519 verify 2 ops took 1.000 sec, avg 500.000 ms, 2.000 ops/sec
## References
For more information please contact info@wolfssl.com.
For more information please contact info@wolfssl.com.

View File

@ -1,6 +1,6 @@
/* user_setting.h
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* wolfsslRunTests.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,10 +1,16 @@
# ESP-IDF port
NOTICE: These Espressif examples have been created and tested with the latest stable release branch of
[ESP-IDF V4](https://docs.espressif.com/projects/esp-idf/en/v4.4.1/esp32/get-started/index.html)
and have not yet been upgraded to the master branch V5.
See the latest [migration guides](https://docs.espressif.com/projects/esp-idf/en/latest/esp32/migration-guides/index.html).
## Overview
ESP-IDF development framework with wolfSSL by setting *WOLFSSL_ESPIDF* definition
Including the following examples:
* Simple [tls_client](./examples/wolfssl_client/)/[server](./examples/wolfssl_server/)
* Simple [TLS client](./examples/wolfssl_client/)/[server](./examples/wolfssl_server/)
* Cryptographic [test](./examples/wolfssl_test/)
* Cryptographic [benchmark](./examples/wolfssl_benchmark/)
@ -13,21 +19,16 @@ Including the following examples:
## Requirements
1. [ESP-IDF development framework](https://docs.espressif.com/projects/esp-idf/en/latest/get-started/)
Note: This expects to use Linux version.
## Setup for Linux
1. Run `setup.sh` at _/path/to_`/wolfssl/IDE/Espressif/ESP-IDF/` to deploy files into ESP-IDF tree
For Windows : Run `setup_win.bat` at `.\IDE\Espressif\ESP-IDF\`
2. Find Wolfssl files at _/path/to/esp_`/esp-idf/components/wolfssl/`
3. Find [Example programs](https://github.com/wolfSSL/wolfssl/tree/master/IDE/Espressif/ESP-IDF/examples) under _/path/to/esp_`/esp-idf/examples/protocols/wolfssl_xxx` (where xxx is the project name)
4. Uncomment out `#define WOLFSSL_ESPIDF` in _/path/to/esp_`/esp-idf/components/wolfssl/wolfssl/wolfcrypt/settings.h`
Uncomment out `#define WOLFSSL_ESPWROOM32` in _/path/to/esp_`/esp-idf/components/wolfssl/wolfssl/wolfcrypt/settings.h`
for example the default:
`~/esp/esp-idf/components/wolfssl/wolfssl/wolfcrypt/settings.h`
## Setup for Windows
1. Run ESP-IDF Command Prompt (cmd.exe) or Run ESP-IDF PowerShell Environment
2. Run `setup_win.bat` at `.\IDE\Espressif\ESP-IDF\`
3. Find Wolfssl files at _/path/to/esp_`/esp-idf/components/wolfssl/`
4. Find [Example programs](https://github.com/wolfSSL/wolfssl/tree/master/IDE/Espressif/ESP-IDF/examples) under _/path/to/esp_`/esp-idf/examples/protocols/wolfssl_xxx` (where xxx is the project name)
## Configuration
1. The `user_settings.h` can be found in _/path/to/esp_`/esp-idf/components/wolfssl/include/user_settings.h`
@ -39,7 +40,6 @@ Including the following examples:
For question please email [support@wolfssl.com]
Note: This is tested with :
- OS: Ubuntu 18.04.1 LTS and Microsoft Windows 10 Pro 10.0.19041 and well as WSL Ubuntu
- ESP-IDF: v4.1 and v4.0.1
- OS: Ubuntu 20.04.3 LTS and Microsoft Windows 10 Pro 10.0.19041 and well as WSL Ubuntu
- ESP-IDF: ESP-IDF v4.3.2
- Module : ESP32-WROOM-32

View File

@ -4,7 +4,7 @@
Including the following examples:
* simple `tls_client`/`tls_server`
* simple `TLS client`/`server`
* crypt benchmark
The `user_settings.h` file enables some of the hardened settings.
@ -15,11 +15,11 @@ Including the following examples:
2. Microchip CryptoAuthentication Library: https://github.com/MicrochipTech/cryptoauthlib
## Setup
1. wolfSSL under ESP-IDF. Please see [README.md](https://github.com/wolfSSL/wolfssl/blob/master/IDE/Espressif/ESP-IDF/README.md)
2. CryptoAuthentication Library under ESP-IDF. Please see [README.md](https://github.com/miyazakh/cryptoauthlib_esp_idf/blob/master/README.md)
3. Uncomment out `#define WOLFSSL_ESPWROOM32SE` in `/path/to/wolfssl/wolfssl/wolfcrypt/settings.h`
* **Note:** Need to enable `WOLFSSL_ESPIDF`
1. Comment out `#define WOLFSSL_ESPWROOM32` in `/path/to/wolfssl/IDE/Espressif/ESP-IDF/user_settings.h`\
Uncomment out `#define WOLFSSL_ESPWROOM32SE` in `/path/to/wolfssl/IDE/Espressif/ESP-IDF/user_settings.h`
* **Note:** crypt test will fail if enabled `WOLFSSL_ESPWROOM32SE`
3. wolfSSL under ESP-IDF. Please see [README.md](https://github.com/wolfSSL/wolfssl/blob/master/IDE/Espressif/ESP-IDF/README.md)
4. CryptoAuthentication Library under ESP-IDF. Please see [README.md](https://github.com/miyazakh/cryptoauthlib_esp_idf/blob/master/README.md)
## Configuration
1. The `user_settings.h` can be found in `/path/to/esp-idf/components/wolfssl/include/user_settings.h`

View File

@ -1,6 +1,6 @@
/* config.h - dummy
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -0,0 +1,25 @@
/* wolfcrypt/test/test_paths.h
*
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
* wolfSSL is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* wolfSSL is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
*/
#ifndef NO_FILESYSTEM
#define CERT_PREFIX "@abs_top_srcdir@/"
#define CERT_WRITE_TEMP_DIR "@abs_top_builddir@/"
#endif /* NO_FILESYSTEM */

View File

@ -1,8 +1,8 @@
#wolfSSL Example
# wolfSSL Benchmark Example
The Example contains of wolfSSL benchmark program.
1. "make menuconfig" to configure the program.
1. `idf.py menuconfig` to configure the program.
1-1. Example Configuration ->
BENCH_ARG : argument that you want to use. Default is "-lng 0"
@ -10,7 +10,7 @@ The Example contains of wolfSSL benchmark program.
When you want to run the benchmark program
1. "make flash" to compile and load the firmware
2. "make monitor" to see the message
1. `idf.py -p <PORT> flash` to compile and load the firmware
2. `idf.py monitor` to see the message
See the README.md file in the upper level 'examples' directory for more information about examples.

View File

@ -1,6 +1,6 @@
/* helper.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
@ -23,6 +23,7 @@
#include <string.h>
#include <wolfssl/wolfcrypt/settings.h>
#include <wolfssl/wolfcrypt/types.h>
#include <wolfcrypt/benchmark/benchmark.h>
#include "sdkconfig.h"
@ -32,6 +33,7 @@
/* proto-type */
extern void wolf_benchmark_task();
extern void wolf_crypt_task();
static const char* const TAG = "wolfbenchmark";
char* __argv[22];
@ -151,7 +153,6 @@ int construct_argv()
void app_main(void)
{
(void) TAG;
#ifndef NO_CRYPT_BENCHMARK
/* when using atecc608a on esp32-wroom-32se */
#if defined(WOLFSSL_ESPWROOM32SE) && defined(HAVE_PK_CALLBACKS) \
@ -166,7 +167,11 @@ void app_main(void)
atmel_set_slot_allocator(my_atmel_alloc, my_atmel_free);
#endif
#endif
#ifndef NO_CRYPT_TEST
wolf_crypt_task();
#endif
#ifndef NO_CRYPT_BENCHMARK
wolf_benchmark_task();
#else
#endif /* NO_CRYPT_BENCHMARK */
#endif
}

View File

@ -2,21 +2,26 @@
The Example contains of wolfSSL tls client demo.
1. "make menuconfig" to config the project
1-1. Example Configuration ->
1. `idf.py menuconfig` to config the project
1-1. Example Configuration ->
WIFI SSID: your own WIFI, which is connected to the Internet.(default is "myssid")
WIFI Password: WIFI password, and default is "mypassword"
Target host ip address : the host that you want to connect to.(default is 127.0.0.1)
1-2. Example Connection Configuration ->
WIFI SSID: your own WIFI, which is connected to the Internet.(default is "myssid")
WIFI Password: WIFI password, and default is "mypassword"
Note: the example program uses 11111 port. If you want to use different port
, you need to modify DEFAULT_PORT definition in the code.
When you want to test the wolfSSL client
1. "make flash monitor" to load the firmware and see the context
1. `idf.py -p <PORT> flash` and then `idf.py monitor` to load the firmware and see the context
2. You can use <wolfssl>/examples/server/server program for test.
e.g. Launch ./examples/server/server -v 4 -b -i
e.g. Launch ./examples/server/server -v 4 -b -i -d
See the README.md file in the upper level 'examples' directory for more information about examples.

View File

@ -1,17 +1,5 @@
menu "Example Configuration"
config WIFI_SSID
string "WiFi SSID"
default "myssid"
help
SSID (network name) for the example to connect to.
config WIFI_PASSWORD
string "WiFi Password"
default "mypassword"
help
WiFi password (WPA or WPA2) for the example to use.
config TARGET_HOST
string "Target host"
default "127.0.01.1"

View File

@ -1,6 +1,6 @@
/* client-tls-callback.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* user_settings.h
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* wifi_connect.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
@ -54,7 +54,7 @@ static void set_time()
/* please update the time if seeing unknown failure when loading cert. */
/* this could cause TLS communication failure due to time expiration */
/* incleasing 31536000 seconds is close to spend 356 days. */
utctime.tv_sec = 1619650800; /* dummy time: Wed April 28 23:00:00 2021 */
utctime.tv_sec = 1645797600; /* dummy time: Fri 25 Feb 2022 02:00:00 2022 */
utctime.tv_usec = 0;
tz.tz_minuteswest = 0;
tz.tz_dsttime = 0;
@ -102,8 +102,13 @@ static esp_err_t wifi_event_handler(void *ctx, system_event_t *event)
esp_wifi_connect();
break;
case SYSTEM_EVENT_STA_GOT_IP:
#if ESP_IDF_VERSION_MAJOR >= 4
ESP_LOGI(TAG, "got ip:" IPSTR "\n",
IP2STR(&event->event_info.got_ip.ip_info.ip));
#else
ESP_LOGI(TAG, "got ip:%s",
ip4addr_ntoa(&event->event_info.got_ip.ip_info.ip));
#endif
/* http://esp32.info/docs/esp_idf/html/dd/d08/group__xEventGroupSetBits.html */
xEventGroupSetBits(wifi_event_group, CONNECTED_BIT);
break;
@ -123,7 +128,8 @@ void app_main(void)
ESP_ERROR_CHECK(nvs_flash_init());
ESP_LOGI(TAG, "Initialize wifi");
#if ESP_IDF_VERSION_MAJOR >= 4 && ESP_IDF_VERSION_MINOR >= 1
#if (ESP_IDF_VERSION_MAJOR >= 4 && ESP_IDF_VERSION_MINOR >= 1) || \
(ESP_IDF_VERSION_MAJOR > 5)
esp_netif_init();
#else
tcpip_adapter_init();

View File

@ -1,17 +1,18 @@
#wolfSSL Example
# wolfSSL Server Example
The Example contains a wolfSSL simple server.
1. "make menuconfigure" to configure the project
1. `idf.py menuconfigure` to configure the project
1-1. Example Configuration ->
1-1. Example Connection Configuration ->
WIFI SSID : your own WIFI, which is connected to the Internet.(default is "myssid")
WIFI Password : WIFI password, and default is "mypassword"
When you want to test the wolfSSL simple server demo
1. "make flash" to compile the code and load the firmware
2. "make monitor" to see the context. The assigned IP address can be found in output message.
1. `idf.py -p <PORT> flash` to compile the code and load the firmware
2. `idf.py monitor` to see the context. The assigned IP address can be found in output message.
3. Once the server connects to the wifi, it is waiting for client request.
("Waiting for a connection..." message will be displayed.)
@ -19,4 +20,3 @@ When you want to test the wolfSSL simple server demo
e.g ./example/client/client -h xx.xx.xx
See the README.md file in the upper level 'examples' directory for more information about examples.

View File

@ -1,15 +0,0 @@
menu "Example Configuration"
config WIFI_SSID
string "WiFi SSID"
default "myssid"
help
SSID (network name) for the example to connect to.
config WIFI_PASSWORD
string "WiFi Password"
default "mypassword"
help
WiFi password (WPA or WPA2) for the example to use.
endmenu

View File

@ -1,6 +1,6 @@
/* wifi_connect.h
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* server-tls-callback.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* wifi_connect.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
@ -51,7 +51,7 @@ static void set_time()
/* please update the time if seeing unknown failure when loading cert. */
/* this could cause TLS communication failure due to time expiration */
/* incleasing 31536000 seconds is close to spend 356 days. */
utctime.tv_sec = 1619650800; /* dummy time: Wed April 28 23:00:00 2021 */
utctime.tv_sec = 1645797600; /* dummy time: Fri 25 Feb 2022 02:00:00 2022 */
utctime.tv_usec = 0;
tz.tz_minuteswest = 0;
tz.tz_dsttime = 0;
@ -126,7 +126,8 @@ void app_main(void)
ESP_LOGI(TAG, "Initialize wifi");
/* TCP/IP adapter initialization */
#if ESP_IDF_VERSION_MAJOR >= 4 && ESP_IDF_VERSION_MINOR >= 1
#if (ESP_IDF_VERSION_MAJOR >= 4 && ESP_IDF_VERSION_MINOR >= 1) || \
(ESP_IDF_VERSION_MAJOR > 5)
esp_netif_init();
#else
tcpip_adapter_init();

View File

@ -1,10 +1,10 @@
#wolfSSL Example
# wolfSSL Crypt Test Example
The Example contains of wolfSSL test program.
When you want to run the benchmark program
1. "make menuconfig" to configure the program,first
2. "make flash" to compile and load the firmware
3. "make monitor" to see the message
1. `idf.py menuconfig` to configure the program,first
2. `idf.py build` to compile and `idf.py -p <PORT> flash` to load the firmware
3. `idf.py monitor` to see the message
See the README.md file in the upper level 'examples' directory for more information about examples.

View File

@ -1,6 +1,24 @@
#
# Copyright (C) 2006-2022 wolfSSL Inc.
#
# This file is part of wolfSSL.
#
# wolfSSL is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# wolfSSL is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
#
# cmake for wolfssl
#
#
cmake_minimum_required(VERSION 3.5)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DWOLFSSL_USER_SETTINGS")
@ -12,26 +30,57 @@ set(COMPONENT_SRCDIRS "./src/"
"./wolfcrypt/src/"
"./wolfcrypt/src/port/Espressif/"
"./wolfcrypt/src/port/atmel/"
# "$ENV{IDF_PATH}/components/soc/esp32s3/include/soc"
)
set(COMPONENT_REQUIRES lwip)
set(COMPONENT_ADD_INCLUDEDIRS
"."
"./include"
"../freertos/include/freertos"
"${WOLFSSL_ROOT}"
)
# RTOS_IDF_PATH is typically:
# "/Users/{username}/Desktop/esp-idf/components/freertos/include/freertos"
# depending on the environment, we may need to swap backslashes with forward slashes
string(REPLACE "\\" "/" RTOS_IDF_PATH "$ENV{IDF_PATH}/components/freertos/include/freertos")
# ESP-IDF after version 4.4x has a different RTOS directory structure
string(REPLACE "\\" "/" RTOS_IDF_PATH5 "$ENV{IDF_PATH}/components/freertos/FreeRTOS-Kernel/include/freertos")
if(IS_DIRECTORY ${IDF_PATH}/components/freertos/FreeRTOS-Kernel/)
set(COMPONENT_ADD_INCLUDEDIRS
"."
"./include"
"${RTOS_IDF_PATH5}"
"${WOLFSSL_ROOT}"
)
else()
set(COMPONENT_ADD_INCLUDEDIRS
"."
"./include"
"${RTOS_IDF_PATH}"
"${WOLFSSL_ROOT}"
)
endif()
if(IS_DIRECTORY ${IDF_PATH}/components/cryptoauthlib)
list(APPEND COMPONENT_ADD_INCLUDEDIRS "../cryptoauthlib/lib")
endif()
set(COMPONENT_SRCEXCLUDE
"wolfcrypt/src/aes_asm.S"
"wolfcrypt/src/evp.c"
"wolfcrypt/src/misc.c"
"src/bio.c"
"./src/bio.c"
"./src/conf.c"
"./src/misc.c"
"./src/pk.c"
"./src/x509.c"
"./src/x509_str.c"
"./wolfcrypt/src/evp.c"
"./wolfcrypt/src/misc.c"
)
register_component()
# check to see if there's both a local copy and EDP-IDF copy of the wolfssl components
if( EXISTS "${CMAKE_HOME_DIRECTORY}/components/wolfssl/" AND EXISTS "$ENV{IDF_PATH}/components/wolfssl/" )
message(STATUS "")
message(STATUS "WARNING: Found components/wolfssl in both local project and IDF_PATH")
message(STATUS "")
endif()
# end multiple component check

View File

@ -1,17 +1,38 @@
#
# Component Makefile
#
COMPONENT_ADD_INCLUDEDIRS := . ./include
COMPONENT_ADD_INCLUDEDIRS += ../freertos/include/freertos/
COMPONENT_SRCDIRS := src wolfcrypt/src
COMPONENT_SRCDIRS += wolfcrypt/src/port/Espressif
COMPONENT_SRCDIRS += wolfcrypt/src/port/atmel
CFLAGS +=-DWOLFSSL_USER_SETTINGS
COMPONENT_OBJEXCLUDE := wolfcrypt/src/aes_asm.o
COMPONENT_OBJEXCLUDE += wolfcrypt/src/evp.o
COMPONENT_OBJEXCLUDE += wolfcrypt/src/misc.o
COMPONENT_OBJEXCLUDE += src/bio.o
#
# Copyright (C) 2006-2022 wolfSSL Inc.
#
# This file is part of wolfSSL.
#
# wolfSSL is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# wolfSSL is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
#
#
# Component Makefile
#
COMPONENT_ADD_INCLUDEDIRS := . ./include
COMPONENT_ADD_INCLUDEDIRS += "$ENV{IDF_PATH}/components/freertos/include/freertos"
# COMPONENT_ADD_INCLUDEDIRS += "$ENV{IDF_PATH}/soc/esp32s3/include/soc"
COMPONENT_SRCDIRS := src wolfcrypt/src
COMPONENT_SRCDIRS += wolfcrypt/src/port/Espressif
COMPONENT_SRCDIRS += wolfcrypt/src/port/atmel
CFLAGS +=-DWOLFSSL_USER_SETTINGS
COMPONENT_OBJEXCLUDE := wolfcrypt/src/aes_asm.o
COMPONENT_OBJEXCLUDE += wolfcrypt/src/evp.o
COMPONENT_OBJEXCLUDE += wolfcrypt/src/misc.o
COMPONENT_OBJEXCLUDE += src/bio.o

View File

@ -23,10 +23,10 @@ WOLFSSLLIB_TRG_DIR=${IDF_PATH}/components/wolfssl
WOLFSSLEXP_TRG_DIR=${IDF_PATH}/examples/protocols
if [ "$1" == "--verbose" ]; then
WOLFSSSL_SETUP_VERBOSE=true
WOLFSSL_SETUP_VERBOSE=true
fi
if [ "${WOLFSSSL_SETUP_VERBOSE}" == "true" ]; then
if [ "${WOLFSSL_SETUP_VERBOSE}" == "true" ]; then
echo Verbose mode on!
echo BASEDIR=${BASEDIR}
echo SCRIPTDIR=${SCRIPTDIR}
@ -47,7 +47,7 @@ pushd $IDF_PATH > /dev/null
echo "Copy files into $IDF_PATH"
# Remove/Create directories
if [ "${WOLFSSSL_SETUP_VERBOSE}" == "true" ]; then
if [ "${WOLFSSL_SETUP_VERBOSE}" == "true" ]; then
echo "Remove/Create directories..."
fi
@ -58,6 +58,7 @@ ${MKDCMD} ${WOLFSSLLIB_TRG_DIR}/src
${MKDCMD} ${WOLFSSLLIB_TRG_DIR}/wolfcrypt
${MKDCMD} ${WOLFSSLLIB_TRG_DIR}/wolfcrypt/src
${MKDCMD} ${WOLFSSLLIB_TRG_DIR}/wolfssl
${MKDCMD} ${WOLFSSLLIB_TRG_DIR}/wolfssl/openssl
${MKDCMD} ${WOLFSSLLIB_TRG_DIR}/test
${MKDCMD} ${WOLFSSLLIB_TRG_DIR}/include
@ -66,7 +67,7 @@ pushd ${BASEDIR} > /dev/null # WOLFSSL TOP DIR
# copying ... files in src/ into $WOLFSSLLIB_TRG_DIR/src
if [ "${WOLFSSSL_SETUP_VERBOSE}" == "true" ]; then
if [ "${WOLFSSL_SETUP_VERBOSE}" == "true" ]; then
echo "Copying ... files in src/ into \$WOLFSSLLIB_TRG_DIR/srcs ..."
fi
@ -76,13 +77,16 @@ ${CPDCMD} ./src/*.c ${WOLFSSLLIB_TRG_DIR}/src/
${CPDCMD} -r ./wolfcrypt/src/*.{c,i} ${WOLFSSLLIB_TRG_DIR}/wolfcrypt/src/
${CPDCMD} -r ./wolfcrypt/src/port ${WOLFSSLLIB_TRG_DIR}/wolfcrypt/src/port/
${CPDCMD} -r ./wolfcrypt/test ${WOLFSSLLIB_TRG_DIR}/wolfcrypt/
# Copy dummy test_paths.h to handle the case configure hasn't yet executed
${CPDCMD} -r ${WOLFSSL_ESPIDFDIR}/dummy_test_paths.h ${WOLFSSLLIB_TRG_DIR}/wolfcrypt/test/test_paths.h
${CPDCMD} -r ./wolfcrypt/benchmark ${WOLFSSLLIB_TRG_DIR}/wolfcrypt/
${CPDCMD} -r ./wolfssl/*.h ${WOLFSSLLIB_TRG_DIR}/wolfssl/
${CPDCMD} -r ./wolfssl/openssl/*.h ${WOLFSSLLIB_TRG_DIR}/wolfssl/openssl/
${CPDCMD} -r ./wolfssl/wolfcrypt ${WOLFSSLLIB_TRG_DIR}/wolfssl/
# user_settings.h
if [ "${WOLFSSSL_SETUP_VERBOSE}" == "true" ]; then
if [ "${WOLFSSL_SETUP_VERBOSE}" == "true" ]; then
echo "Copying user_settings.h to ${WOLFSSLLIB_TRG_DIR}/include/"
fi
@ -100,7 +104,7 @@ ${CPDCMD} ./libs/component.mk ${WOLFSSLLIB_TRG_DIR}/
pushd ${BASEDIR} > /dev/null # WOLFSSL TOP DIR
# Benchmark program
if [ "${WOLFSSSL_SETUP_VERBOSE}" == "true" ]; then
if [ "${WOLFSSL_SETUP_VERBOSE}" == "true" ]; then
echo ""
fi
${RMDCMD} ${WOLFSSLEXP_TRG_DIR}/wolfssl_benchmark/
@ -115,7 +119,7 @@ ${CPDCMD} -r ${WOLFSSL_ESPIDFDIR}/examples/wolfssl_benchmark/* ${WOLFSSLEXP_TRG_
${CPDCMD} -r ${WOLFSSL_ESPIDFDIR}/examples/wolfssl_benchmark/main/* ${WOLFSSLEXP_TRG_DIR}/wolfssl_benchmark/main/
# Crypt Test program
if [ "${WOLFSSSL_SETUP_VERBOSE}" == "true" ]; then
if [ "${WOLFSSL_SETUP_VERBOSE}" == "true" ]; then
echo "Copying wolfssl_test to ${WOLFSSLEXP_TRG_DIR}/wolfssl_test/main/"
fi
${RMDCMD} ${WOLFSSLEXP_TRG_DIR}/wolfssl_test/
@ -127,7 +131,7 @@ ${CPDCMD} -r ${WOLFSSL_ESPIDFDIR}/examples/wolfssl_test/* ${WOLFSSLEXP_TRG_DIR}/
${CPDCMD} -r ${WOLFSSL_ESPIDFDIR}/examples/wolfssl_test/main/* ${WOLFSSLEXP_TRG_DIR}/wolfssl_test/main/
# TLS Client program
if [ "${WOLFSSSL_SETUP_VERBOSE}" == "true" ]; then
if [ "${WOLFSSL_SETUP_VERBOSE}" == "true" ]; then
echo "Copying TLS Client program to ${WOLFSSLEXP_TRG_DIR}/wolfssl_client/..."
fi
${RMDCMD} ${WOLFSSLEXP_TRG_DIR}/wolfssl_client/
@ -140,7 +144,7 @@ ${CPDCMD} -r ${WOLFSSL_ESPIDFDIR}/examples/wolfssl_client/main/* ${WOLFSSLEXP_TR
${CPDCMD} -r ${WOLFSSL_ESPIDFDIR}/examples/wolfssl_client/main/include/* ${WOLFSSLEXP_TRG_DIR}/wolfssl_client/main/include/
# TLS Server program
if [ "${WOLFSSSL_SETUP_VERBOSE}" == "true" ]; then
if [ "${WOLFSSL_SETUP_VERBOSE}" == "true" ]; then
echo "Copying TLS Server program to ${WOLFSSLEXP_TRG_DIR}/wolfssl_server/..."
fi
${RMDCMD} ${WOLFSSLEXP_TRG_DIR}/wolfssl_server/
@ -154,7 +158,7 @@ ${CPDCMD} -r ${WOLFSSL_ESPIDFDIR}/examples/wolfssl_server/main/include/* ${WOLFS
popd > /dev/null #
if [ "${WOLFSSSL_SETUP_VERBOSE}" == "true" ]; then
if [ "${WOLFSSL_SETUP_VERBOSE}" == "true" ]; then
echo "Copy complete!"
fi

View File

@ -1,77 +1,398 @@
@echo off
REM Expect the script at /path/to/wolfssl/IDE/Espressif/ESP-IDF/
if NOT EXIST "setup.sh" (
echo "Please run this script at /path/to/wolfssl/IDE/Espressif/ESP-IDF/
goto exit
::******************************************************************************************************
::******************************************************************************************************
echo;
echo wolfSSL Windows Setup. Version 1.0a
echo;
echo This utility will copy a static snapshot of wolfSSL files to the ESP32-IDF component directory.
echo;
echo If you wish to keep your component library fresh with git pull, consider hard link with mklink.
echo;
echo "mklink [[/d] | [/h] | [/j]] <link> <target>"
echo;
::******************************************************************************************************
::******************************************************************************************************
SET COPYERROR=false
:: if there's a setup.sh, we are probably starting in the right place.
if NOT EXIST "setup.sh" (
echo Please run this script at /path/to/wolfssl/IDE/Espressif/ESP-IDF/
goto :ERR
)
if "%IDF_PATH%" == "" (
echo "Please launch the script from ESP-IDF command prompt."
goto exit
:: if there's also a default user_settings.h, we are very likely starting in the right place.
if NOT EXIST "user_settings.h" (
echo Please run this script at /path/to/wolfssl/IDE/Espressif/ESP-IDF/
goto :ERR
)
:: see if there was a parameter passed for a specific EDP-IDF directory
:: this may be different than the standard ESP-IDF environment (e.g. VisualGDB)
if not "%1" == "" (
if not exist "%1" (
echo "ERROR: optional directory was specified, but not found: %1"
goto :ERR
)
SET IDF_PATH=%1
echo Using specified IDF_PATH: %IDF_PATH%
)
:: if no IDF_PATH is found, we don't know what to do. Go exit with error.
if "%IDF_PATH%" == "" (
echo Please launch the script from ESP-IDF command prompt,
echo or set your desired IDF_PATH environment variable,
echo or pass a parameter to your directory, such as for VisualGDB with ESP-IDF 4.4:
echo;
echo .\setup_win.bat C:\SysGCC\esp32\esp-idf\v4.4
echo;
goto :ERR
)
:: Here we go!
:: setup some path variables
echo;
set SCRIPTDIR=%CD%
set BASEDIR=%SCRIPTDIR%\..\..\..\
set BASEDIR=%SCRIPTDIR%\..\..\..
set WOLFSSL_ESPIDFDIR=%BASEDIR%\IDE\Espressif\ESP-IDF
set WOLFSSLLIB_TRG_DIR=%IDF_PATH%\components\wolfssl
set WOLFSSLEXP_TRG_DIR=%IDF_PATH%\examples\protocols
echo Copy files into $IDF_PATH%
rem Remove/Create directories
rmdir /S/Q %WOLFSSLLIB_TRG_DIR%
mkdir %WOLFSSLLIB_TRG_DIR%
mkdir %WOLFSSLLIB_TRG_DIR%\src
mkdir %WOLFSSLLIB_TRG_DIR%\wolfcrypt\src
mkdir %WOLFSSLLIB_TRG_DIR%\wolfssl
mkdir %WOLFSSLLIB_TRG_DIR%\test
mkdir %WOLFSSLLIB_TRG_DIR%\include
echo Using SCRIPTDIR = %SCRIPTDIR%
echo Using BASEDIR = %BASEDIR%
echo Using WOLFSSL_ESPIDFDIR = %WOLFSSL_ESPIDFDIR%
echo Using WOLFSSLLIB_TRG_DIR = %WOLFSSLLIB_TRG_DIR%
echo Using WOLFSSLEXP_TRG_DIR = %WOLFSSLEXP_TRG_DIR%
echo;
echo Equivalalent destination path:
dir %WOLFSSL_ESPIDFDIR%\*.xyzzy 2> nul | findstr \
echo;
echo Equivalalent source directory paths:
:: show the path of the equivalent %VALUE% (search for files that don't exist, supress error, and look for string with "\")
dir %BASEDIR%\*.xyzzy 2> nul | findstr \
dir %WOLFSSLLIB_TRG_DIR%\*.xyzzy 2> nul | findstr \
dir %WOLFSSLEXP_TRG_DIR%\*.xyzzy 2> nul | findstr \
:: set the FileStamp variable to the current date: YYMMYY_HHMMSS
:: the simplest method, to use existing TIME ad DATE variables:
:: date = Thu 09/17/2015
:: time = 11:13:15.47
:: 012345678901234567890
::
:: There is no leading zero for single digit hours (e.g. 9:00am), so we need to manually include the zero
:: here |
if "%TIME:~0,1%" == " " set FileStamp=%DATE:~12,2%%DATE:~7,2%%DATE:~4,2%_0%TIME:~1,1%%TIME:~3,2%%TIME:~6,2%
:: otherwise, if a space not found before the digit, it is a 2 digit hour, so no extract zero is needed
if NOT "%TIME:~0,1%" == " " set FileStamp=%DATE:~12,2%%DATE:~7,2%%DATE:~4,2%_%TIME:~0,2%%TIME:~3,2%%TIME:~6,2%
:: Backup existing user settings
if exist %WOLFSSLLIB_TRG_DIR%\include\config.h (
echo;
echo Saving: %WOLFSSLLIB_TRG_DIR%\include\config.h
echo to: %SCRIPTDIR%\config_h_%FileStamp%.bak
copy %WOLFSSLLIB_TRG_DIR%\include\config.h %SCRIPTDIR%\config_h_%FileStamp%.bak
echo;
)
if exist %WOLFSSL_ESPIDFDIR%\user_settings.h (
echo Saving: %WOLFSSLLIB_TRG_DIR%\include\user_settings.h
echo to: %SCRIPTDIR%\user_settings_h_%FileStamp%.bak
copy %WOLFSSLLIB_TRG_DIR%\include\user_settings.h %SCRIPTDIR%\user_settings_h_%FileStamp%.bak
echo;
)
::******************************************************************************************************
:: check if there's already an existing %WOLFSSLLIB_TRG_DIR% and confirm removal
::******************************************************************************************************
if exist %WOLFSSLLIB_TRG_DIR% (
echo;
echo WARNING: Existing files found in %WOLFSSLLIB_TRG_DIR%
echo;
:: clear any prior errorlevel
call;
choice /c YN /m "Delete files and proceed with install in %WOLFSSLLIB_TRG_DIR% "
if errorlevel 2 GOTO :NODELETE
GOTO :PURGE
echo;
echo Ready to copy files into %IDF_PATH%
::******************************************************************************************************
:NODELETE
::******************************************************************************************************
:: clear any prior errorlevel
echo;
call;
choice /c YN /m "Refresh files %WOLFSSLLIB_TRG_DIR% (there will be a prompt to keep or overwrite user_settings and config) "
if errorlevel 2 GOTO :NOCOPY
GOTO :REFRESH
)
::******************************************************************************************************
:PURGE
::******************************************************************************************************
:: purge existing directory
if exist %WOLFSSLLIB_TRG_DIR% (
echo;
echo Removing %WOLFSSLLIB_TRG_DIR%
rmdir %WOLFSSLLIB_TRG_DIR% /S /Q
if exist %WOLFSSLLIB_TRG_DIR% (
SET COPYERROR=true
echo;
echo WARNING: Failed to remove %WOLFSSLLIB_TRG_DIR%
echo;
echo Check permissions, open files, read-only attributes, etc.
echo;
)
echo;
) else (
echo;
echo Prior %WOLFSSLLIB_TRG_DIR% not found, installing fresh.
echo;
)
::******************************************************************************************************
:REFRESH
::******************************************************************************************************
if not exist %WOLFSSLLIB_TRG_DIR% mkdir %WOLFSSLLIB_TRG_DIR%
if not exist %WOLFSSLLIB_TRG_DIR%\src mkdir %WOLFSSLLIB_TRG_DIR%\src
if not exist %WOLFSSLLIB_TRG_DIR%\wolfcrypt\src mkdir %WOLFSSLLIB_TRG_DIR%\wolfcrypt\src
if not exist %WOLFSSLLIB_TRG_DIR%\wolfssl mkdir %WOLFSSLLIB_TRG_DIR%\wolfssl
if not exist %WOLFSSLLIB_TRG_DIR%\wolfssl\openssl mkdir %WOLFSSLLIB_TRG_DIR%\wolfssl\openssl
if not exist %WOLFSSLLIB_TRG_DIR%\test mkdir %WOLFSSLLIB_TRG_DIR%\test
if not exist %WOLFSSLLIB_TRG_DIR%\include mkdir %WOLFSSLLIB_TRG_DIR%\include
rem copying ... files in src/ into $WOLFSSLLIB_TRG_DIR%/src
xcopy /Y/Q %BASEDIR%\src\*.c %WOLFSSLLIB_TRG_DIR%\src\
xcopy /Y/Q %BASEDIR%\wolfcrypt\src\*.c %WOLFSSLLIB_TRG_DIR%\wolfcrypt\src
xcopy /Y/Q %BASEDIR%\wolfcrypt\src\*.i %WOLFSSLLIB_TRG_DIR%\wolfcrypt\src
xcopy /E/Y/Q %BASEDIR%\wolfcrypt\src\port %WOLFSSLLIB_TRG_DIR%\wolfcrypt\src\port\
xcopy /E/Y/Q %BASEDIR%\wolfcrypt\test %WOLFSSLLIB_TRG_DIR%\wolfcrypt\test\
xcopy /E/Y/Q %BASEDIR%\wolfcrypt\benchmark %WOLFSSLLIB_TRG_DIR%\wolfcrypt\benchmark\
xcopy /Y/Q %BASEDIR%\wolfssl\*.h %WOLFSSLLIB_TRG_DIR%\wolfssl\
xcopy /E/Y/Q %BASEDIR%\wolfssl\wolfcrypt %WOLFSSLLIB_TRG_DIR%\wolfssl\wolfcrypt\
echo;
echo Copying files to %WOLFSSLLIB_TRG_DIR%\src\
xcopy %BASEDIR%\src\*.c %WOLFSSLLIB_TRG_DIR%\src\ /S /E /Q /Y
if %errorlevel% NEQ 0 SET COPYERROR=true
rem user_settings.h
xcopy /F/Q %WOLFSSL_ESPIDFDIR%\user_settings.h %WOLFSSLLIB_TRG_DIR%\include\
echo F |xcopy /F/Q %WOLFSSL_ESPIDFDIR%\dummy_config_h %WOLFSSLLIB_TRG_DIR%\include\config.h
echo;
echo Copying src\*.c files to %WOLFSSLLIB_TRG_DIR%\wolfcrypt\src
xcopy %BASEDIR%\wolfcrypt\src\*.c %WOLFSSLLIB_TRG_DIR%\wolfcrypt\src /S /E /Q /Y
if %errorlevel% NEQ 0 SET COPYERROR=true
rem unit test app
xcopy /E/Y/Q %WOLFSSL_ESPIDFDIR%\test %WOLFSSLLIB_TRG_DIR%\test\
xcopy /F/Q %WOLFSSL_ESPIDFDIR%\libs\CMakeLists.txt %WOLFSSLLIB_TRG_DIR%\
xcopy /F/Q %WOLFSSL_ESPIDFDIR%\libs\component.mk %WOLFSSLLIB_TRG_DIR%\
echo;
echo Copying src\*.i files to %WOLFSSLLIB_TRG_DIR%\wolfcrypt\src
xcopy %BASEDIR%\wolfcrypt\src\*.i %WOLFSSLLIB_TRG_DIR%\wolfcrypt\src /S /E /Q /Y
if %errorlevel% NEQ 0 SET COPYERROR=true
rem Benchmark program
rmdir /S/Q %WOLFSSLEXP_TRG_DIR%\wolfssl_benchmark\
mkdir %WOLFSSLEXP_TRG_DIR%\wolfssl_benchmark\main\
echo;
echo Copying files to %WOLFSSLLIB_TRG_DIR%\wolfcrypt\src\port\
xcopy %BASEDIR%\wolfcrypt\src\port %WOLFSSLLIB_TRG_DIR%\wolfcrypt\src\port\ /S /E /Q /Y
if %errorlevel% NEQ 0 SET COPYERROR=true
xcopy %BASEDIR%\wolfcrypt\benchmark\benchmark.h %BASEDIR%\IDE\Espressif\ESP-IDF\examples\wolfssl_benchmark\main\benchmark.h
xcopy %BASEDIR%\wolfcrypt\benchmark\benchmark.c %BASEDIR%\IDE\Espressif\ESP-IDF\examples\wolfssl_benchmark\main\benchmark.c
echo;
echo Copying files to %WOLFSSLLIB_TRG_DIR%\wolfcrypt\test\
xcopy %BASEDIR%\wolfcrypt\test %WOLFSSLLIB_TRG_DIR%\wolfcrypt\test\ /S /E /Q /Y
if %errorlevel% NEQ 0 SET COPYERROR=true
xcopy /F/Q %BASEDIR%\wolfcrypt\benchmark\benchmark.c %WOLFSSLEXP_TRG_DIR%\wolfssl_benchmark\main\
xcopy /E/F/Q %WOLFSSL_ESPIDFDIR%\examples\wolfssl_benchmark %WOLFSSLEXP_TRG_DIR%\wolfssl_benchmark\
:: Copy dummy test_paths.h to handle the case configure hasn't yet executed
echo;
echo Copying dummy_test_paths.h to %WOLFSSLLIB_TRG_DIR%\wolfcrypt\test\test_paths.h
echo new config > %WOLFSSLLIB_TRG_DIR%\wolfcrypt\test\test_paths.h
if %errorlevel% NEQ 0 SET COPYERROR=true
xcopy %WOLFSSL_ESPIDFDIR%\dummy_test_paths.h %WOLFSSLLIB_TRG_DIR%\wolfcrypt\test\test_paths.h /S /E /Y
if %errorlevel% NEQ 0 SET COPYERROR=true
rem Crypt Test program
rmdir /S/Q %WOLFSSLEXP_TRG_DIR%\wolfssl_test\
mkdir %WOLFSSLEXP_TRG_DIR%\wolfssl_test\main\
xcopy /F/Q %BASEDIR%\wolfcrypt\test\test.c %WOLFSSLEXP_TRG_DIR%\wolfssl_test\main\
xcopy /E/F/Q %WOLFSSL_ESPIDFDIR%\examples\wolfssl_test %WOLFSSLEXP_TRG_DIR%\wolfssl_test\
echo;
echo Copying files to %WOLFSSLLIB_TRG_DIR%\wolfcrypt\benchmark\
xcopy %BASEDIR%\wolfcrypt\benchmark %WOLFSSLLIB_TRG_DIR%\wolfcrypt\benchmark\ /S /E /Q /Y
if %errorlevel% NEQ 0 SET COPYERROR=true
rem TLS Client program
rmdir /S/Q %WOLFSSLEXP_TRG_DIR%\wolfssl_client\
mkdir %WOLFSSLEXP_TRG_DIR%\wolfssl_client\main\
xcopy /E/F/Q %WOLFSSL_ESPIDFDIR%\examples\wolfssl_client %WOLFSSLEXP_TRG_DIR%\wolfssl_client\
echo;
echo Copying files to %WOLFSSLLIB_TRG_DIR%\wolfssl\
xcopy %BASEDIR%\wolfssl\*.h %WOLFSSLLIB_TRG_DIR%\wolfssl\ /S /E /Q /Y
if %errorlevel% NEQ 0 SET COPYERROR=true
rem TLS Server program
rmdir /S/Q %WOLFSSLEXP_TRG_DIR%\wolfssl_server\
mkdir %WOLFSSLEXP_TRG_DIR%\wolfssl_server\main\
xcopy /E/F/Q %WOLFSSL_ESPIDFDIR%\examples\wolfssl_server %WOLFSSLEXP_TRG_DIR%\wolfssl_server\
echo;
echo Copying files to%WOLFSSLLIB_TRG_DIR%\wolfssl\openssl\
xcopy %BASEDIR%\wolfssl\openssl\*.h %WOLFSSLLIB_TRG_DIR%\wolfssl\openssl\ /S /E /Q /Y
if %errorlevel% NEQ 0 SET COPYERROR=true
:exit
echo completed
echo;
echo Copying files to %WOLFSSLLIB_TRG_DIR%\wolfssl\wolfcrypt\
xcopy %BASEDIR%\wolfssl\wolfcrypt %WOLFSSLLIB_TRG_DIR%\wolfssl\wolfcrypt\ /S /E /Q /Y
if %errorlevel% NEQ 0 SET COPYERROR=true
::******************************************************************************************************
:: user_settings and config defaults
::******************************************************************************************************
:: user_settings.h (default, may be overwritten by prior file)
echo;
echo Copying default user_settings.h to %WOLFSSLLIB_TRG_DIR%\include\
xcopy %WOLFSSL_ESPIDFDIR%\user_settings.h %WOLFSSLLIB_TRG_DIR%\include\ /F
if %errorlevel% NEQ 0 SET COPYERROR=true
:: echo Creating new config file: %WOLFSSLLIB_TRG_DIR%\include\config.h (default, may be overwritten by prior file)
echo new config > %WOLFSSLLIB_TRG_DIR%\include\config.h
xcopy %WOLFSSL_ESPIDFDIR%\dummy_config_h. %WOLFSSLLIB_TRG_DIR%\include\config.h /F /Y
if %errorlevel% NEQ 0 SET COPYERROR=true
:: Check if operator wants to keep prior config.h
if EXIST config_h_%FileStamp%.bak (
echo;
:: clear any prior errorlevel
call;
choice /c YN /m "Use your prior config.h "
if errorlevel 2 GOTO :NO_CONFIG_RESTORE
xcopy config_h_%FileStamp%.bak %WOLFSSLLIB_TRG_DIR%\include\config.h /Y
if %errorlevel% NEQ 0 SET COPYERROR=true
) else (
echo;
echo Prior config.h not found. Using default file.
)
::******************************************************************************************************
:NO_CONFIG_RESTORE
::******************************************************************************************************
:: Check if operator wants to keep prior config.h
if EXIST user_settings_h_%FileStamp%.bak (
echo;
:: clear any prior errorlevel
call;
choice /c YN /m "User your prior user_settings.h "
if errorlevel 2 GOTO :NO_USER_SETTINGS_RESTORE
xcopy user_settings_h_%FileStamp%.bak %WOLFSSLLIB_TRG_DIR%\include\user_settings.h /Y
if %errorlevel% NEQ 0 SET COPYERROR=true
) else (
echo;
echo Prior user_settings.h not found. Using default file.
)
::******************************************************************************************************
:NO_USER_SETTINGS_RESTORE
::******************************************************************************************************
:: unit test app
echo;
echo Copying unit files to %WOLFSSLLIB_TRG_DIR%\test\
xcopy %WOLFSSL_ESPIDFDIR%\test %WOLFSSLLIB_TRG_DIR%\test\ /S /E /Q /Y
if %errorlevel% NEQ 0 GOTO :COPYERR
echo;
echo Copying CMakeLists.txt to %WOLFSSLLIB_TRG_DIR%\
xcopy %WOLFSSL_ESPIDFDIR%\libs\CMakeLists.txt %WOLFSSLLIB_TRG_DIR%\ /F
if %errorlevel% NEQ 0 GOTO :COPYERR
echo;
echo Copying component.mk to %WOLFSSLLIB_TRG_DIR%\
xcopy %WOLFSSL_ESPIDFDIR%\libs\component.mk %WOLFSSLLIB_TRG_DIR%\ /F
if %errorlevel% NEQ 0 GOTO :COPYERR
:: Benchmark program
echo;
echo Removing %WOLFSSLEXP_TRG_DIR%\wolfssl_benchmark\
rmdir %WOLFSSLEXP_TRG_DIR%\wolfssl_benchmark\ /S /Q
if %errorlevel% NEQ 0 GOTO :COPYERR
echo;
echo Copying %WOLFSSLEXP_TRG_DIR%\wolfssl_benchmark\main\
mkdir %WOLFSSLEXP_TRG_DIR%\wolfssl_benchmark\main\
xcopy %BASEDIR%\wolfcrypt\benchmark\benchmark.h %BASEDIR%\IDE\Espressif\ESP-IDF\examples\wolfssl_benchmark\main\benchmark.h /F /Y
if %errorlevel% NEQ 0 GOTO :COPYERR
xcopy %BASEDIR%\wolfcrypt\benchmark\benchmark.c %BASEDIR%\IDE\Espressif\ESP-IDF\examples\wolfssl_benchmark\main\benchmark.c /F /Y
if %errorlevel% NEQ 0 GOTO :COPYERR
xcopy %BASEDIR%\wolfcrypt\benchmark\benchmark.c %WOLFSSLEXP_TRG_DIR%\wolfssl_benchmark\main\ /F /Y
if %errorlevel% NEQ 0 GOTO :COPYERR
xcopy %WOLFSSL_ESPIDFDIR%\examples\wolfssl_benchmark %WOLFSSLEXP_TRG_DIR%\wolfssl_benchmark\ /Q /Y
if %errorlevel% NEQ 0 GOTO :COPYERR
:: Crypt Test program
echo;
echo Copying %WOLFSSLEXP_TRG_DIR%\wolfssl_test\
rmdir %WOLFSSLEXP_TRG_DIR%\wolfssl_test\ /S /Q
mkdir %WOLFSSLEXP_TRG_DIR%\wolfssl_test\main\
xcopy %BASEDIR%\wolfcrypt\test\test.c %WOLFSSLEXP_TRG_DIR%\wolfssl_test\main\ /S /E /Q /Y
if %errorlevel% NEQ 0 GOTO :COPYERR
xcopy %WOLFSSL_ESPIDFDIR%\examples\wolfssl_test %WOLFSSLEXP_TRG_DIR%\wolfssl_test\ /S /E /Q /Y
if %errorlevel% NEQ 0 GOTO :COPYERR
:: TLS Client program
echo;
echo Copying %WOLFSSLEXP_TRG_DIR%\wolfssl_client\
rmdir %WOLFSSLEXP_TRG_DIR%\wolfssl_client\ /S /Q
mkdir %WOLFSSLEXP_TRG_DIR%\wolfssl_client\main\
xcopy %WOLFSSL_ESPIDFDIR%\examples\wolfssl_client %WOLFSSLEXP_TRG_DIR%\wolfssl_client\ /S /E /Q /Y
if %errorlevel% NEQ 0 GOTO :COPYERR
:: TLS Server program
echo;
echo Copying %WOLFSSLEXP_TRG_DIR%\wolfssl_server\
rmdir %WOLFSSLEXP_TRG_DIR%\wolfssl_server\ /S /Q
mkdir %WOLFSSLEXP_TRG_DIR%\wolfssl_server\main\
xcopy %WOLFSSL_ESPIDFDIR%\examples\wolfssl_server %WOLFSSLEXP_TRG_DIR%\wolfssl_server\ /S /E /Q /Y
if %errorlevel% NEQ 0 GOTO :COPYERR
goto :DONE
:: error during copy encountered
::******************************************************************************************************
:COPYERR
::******************************************************************************************************
echo;
echo Error during copy.
echo
echo Please ensure none of the target files are flagged as read-only, open, etc.
goto :ERR
:: abort at user request
::******************************************************************************************************
:NOCOPY
::******************************************************************************************************
echo;
echo Setup did not copy any files.
goto :ERR
:: ERROR
::******************************************************************************************************
:ERR
::******************************************************************************************************
exit /B 1
:: Success
::******************************************************************************************************
:DONE
::******************************************************************************************************
echo;
echo;
echo Edit config file in "%WOLFSSLLIB_TRG_DIR%\include\user_settings.h" before trying to compile.
echo;
echo See Component files for wolfSSL in %WOLFSSLLIB_TRG_DIR%
echo;
echo See additional examples at https://github.com/wolfSSL/wolfssl-examples
echo;
echo REMINDER: Ensure any wolfSSL #include definitions occur BEFORE include files in your source code.
echo;
if "%COPYERROR%" == "true" (
echo;
echo WARNING: Copy completed with errors! Check for files in use, permissions, symbolic links, etc.
echo;
)
echo setup_win.bat for ESP-IDF completed.

View File

@ -4,7 +4,7 @@ The test contains of wolfSSL unit-test app on Unity.
When you want to run the app
1. Go to /esp-idf/tools/unit-test-app/ folder
2. "idf.py menuconfig" to configure unit test app.
3. "idf.py -T wolfssl build" to build wolfssl unit test app.
2. `idf.py menuconfig` to configure unit test app.
3. `idf.py -T wolfssl build` to build wolfssl unit test app.
See [https://docs.espressif.com/projects/esp-idf/en/latest/api-guides/unit-tests.html] for more information about unit test app.

View File

@ -1,6 +1,6 @@
/* user_settings.h
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
@ -18,6 +18,25 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
*/
#undef WOLFSSL_ESPIDF
#undef WOLFSSL_ESPWROOM32
#undef WOLFSSL_ESPWROOM32SE
#undef WOLFSSL_ESPWROOM32
#undef WOLFSSL_ESP8266
#define WOLFSSL_ESPIDF
/*
* choose ONE of these Espressif chips to define:
*
* WOLFSSL_ESPWROOM32
* WOLFSSL_ESPWROOM32SE
* WOLFSSL_ESP8266
*/
#define WOLFSSL_ESPWROOM32
/* #define DEBUG_WOLFSSL_VERBOSE */
#define BENCH_EMBEDDED
#define USE_CERT_BUFFERS_2048
@ -71,7 +90,7 @@
/* Define USE_FAST_MATH and SMALL_STACK */
#define ESP32_USE_RSA_PRIMITIVE
/* threshold for performance adjustment for hw primitive use */
/* X bits of G^X mod P greater than */
/* X bits of G^X mod P greater than */
#define EPS_RSA_EXPT_XBTIS 36
/* X and Y of X * Y mod P greater than */
#define ESP_RSA_MULM_BITS 2000
@ -93,3 +112,6 @@
/* #define NO_WOLFSSL_ESP32WROOM32_CRYPT_HASH*/
/* #define NO_WOLFSSL_ESP32WROOM32_CRYPT_AES */
/* #define NO_WOLFSSL_ESP32WROOM32_CRYPT_RSA_PRI */
/* adjust wait-timeout count if you see timeout in rsa hw acceleration */
#define ESP_RSA_TIMEOUT_CNT 0x249F00

View File

@ -1,6 +1,6 @@
/* user_settings.h
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
@ -610,12 +610,6 @@ extern unsigned int my_rng_seed_gen(void);
#undef NO_OLD_TLS
#define NO_OLD_TLS
#undef NO_HC128
#define NO_HC128
#undef NO_RABBIT
#define NO_RABBIT
#undef NO_PSK
#define NO_PSK

View File

@ -182,11 +182,8 @@ SRC_C += ../../wolfcrypt/src/arc4.c
SRC_C += ../../wolfcrypt/src/blake2b.c
SRC_C += ../../wolfcrypt/src/camellia.c
SRC_C += ../../wolfcrypt/src/dsa.c
SRC_C += ../../wolfcrypt/src/hc128.c
SRC_C += ../../wolfcrypt/src/idea.c
SRC_C += ../../wolfcrypt/src/md2.c
SRC_C += ../../wolfcrypt/src/md4.c
SRC_C += ../../wolfcrypt/src/rabbit.c
SRC_C += ../../wolfcrypt/src/ripemd.c

View File

@ -1,6 +1,6 @@
/* armtarget.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* benchmark_main.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* test_main.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* tls_client.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* tls_server.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* wolf_main.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
# Makefile
#
# Copyright (C) 2006-2021 wolfSSL Inc.
# Copyright (C) 2006-2022 wolfSSL Inc.
#
# This file is part of wolfSSL.
#
@ -17,7 +17,6 @@
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
#/
ENVI=hexagon

View File

@ -1,6 +1,6 @@
# Makefile
#
# Copyright (C) 2006-2021 wolfSSL Inc.
# Copyright (C) 2006-2022 wolfSSL Inc.
#
# This file is part of wolfSSL.
#
@ -17,7 +17,6 @@
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
#/
ENVI=UbuntuARM
@ -82,7 +81,6 @@ libwolfssl_C_SRCS += \
../../wolfcrypt/src/chacha20_poly1305 \
../../wolfcrypt/src/pwdbased \
../../wolfcrypt/src/chacha \
../../wolfcrypt/src/rabbit \
../../wolfcrypt/src/cmac \
../../wolfcrypt/src/random \
../../wolfcrypt/src/coding \
@ -118,11 +116,9 @@ libwolfssl_C_SRCS += \
../../wolfcrypt/src/wc_encrypt \
../../wolfcrypt/src/hash \
../../wolfcrypt/src/wc_pkcs11 \
../../wolfcrypt/src/hc128 \
../../wolfcrypt/src/wc_port \
../../wolfcrypt/src/hmac \
../../wolfcrypt/src/wolfcrypt_first \
../../wolfcrypt/src/idea \
../../wolfcrypt/src/wolfcrypt_last \
../../wolfcrypt/src/wolfevent \
../../wolfcrypt/src/logging \

View File

@ -1,7 +1,7 @@
#!/bin/bash
if [ -z $1 ]; then
echo "./build <Debug | Release>"
exit -1
exit 1
fi
printf "Erasing previous hexagon_$1_dynamic_toolv83_v65 and UbuntuARM_$1_aarch64\n"

View File

@ -1,6 +1,6 @@
/* ecc-verify-benchmark.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* ecc-verify.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* benchmark-main.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* current-time.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* minimum-startup.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1978,15 +1978,9 @@
<file>
<name>$PROJ_DIR$\..\..\..\..\wolfcrypt\src\kdf.c</name>
</file>
<file>
<name>$PROJ_DIR$\..\..\..\..\wolfcrypt\src\hc128.c</name>
</file>
<file>
<name>$PROJ_DIR$\..\..\..\..\wolfcrypt\src\hmac.c</name>
</file>
<file>
<name>$PROJ_DIR$\..\..\..\..\wolfcrypt\src\idea.c</name>
</file>
<file>
<name>$PROJ_DIR$\..\..\..\..\wolfcrypt\src\integer.c</name>
</file>
@ -2017,9 +2011,6 @@
<file>
<name>$PROJ_DIR$\..\..\..\..\wolfcrypt\src\pwdbased.c</name>
</file>
<file>
<name>$PROJ_DIR$\..\..\..\..\wolfcrypt\src\rabbit.c</name>
</file>
<file>
<name>$PROJ_DIR$\..\..\..\..\wolfcrypt\src\random.c</name>
</file>

View File

@ -1,6 +1,6 @@
/* test-main.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1980,9 +1980,6 @@
<file>
<name>$PROJ_DIR$\..\..\..\..\..\wolfcrypt\src\pwdbased.c</name>
</file>
<file>
<name>$PROJ_DIR$\..\..\..\..\..\wolfcrypt\src\rabbit.c</name>
</file>
<file>
<name>$PROJ_DIR$\..\..\..\..\..\wolfcrypt\src\random.c</name>
</file>

View File

@ -2370,9 +2370,6 @@
<file>
<name>$PROJ_DIR$\..\..\..\..\..\wolfcrypt\src\pwdbased.c</name>
</file>
<file>
<name>$PROJ_DIR$\..\..\..\..\..\wolfcrypt\src\rabbit.c</name>
</file>
<file>
<name>$PROJ_DIR$\..\..\..\..\..\wolfcrypt\src\random.c</name>
</file>

View File

@ -36,15 +36,15 @@ wolfssl (latest version)
# asn.c misc.c #
# chacha.c poly1305.c #
# chacha20_poly1305.c pwdbased.c #
# coding.c rabbit.c #
# des3.c random.c #
# dh.c rsa.c #
# dsa.c sha.c #
# ecc.c sha256.c #
# hash.c sha512.c #
# hmac.c tfm.c #
# md4.c wc_encrypt.c #
# md5.c wc_port.c #
# coding.c random.c #
# des3.c rsa.c #
# dh.c sha.c #
# dsa.c sha256.c #
# ecc.c sha512.c #
# hash.c tfm.c #
# hmac.c wc_encrypt.c #
# md4.c wc_port.c #
# md5.c #
# kdf.c #
#---------------------------------------------#
@ -173,8 +173,6 @@ HMAC-SHA256 test passed!
HMAC-SHA384 test passed!
HMAC-SHA512 test passed!
GMAC test passed!
HC-128 test passed!
Rabbit test passed!
Chacha test passed!
POLY1305 test passed!
ChaCha20-Poly1305 AEAD test passed!

27
IDE/IAR-MSP430/Makefile Normal file
View File

@ -0,0 +1,27 @@
PROGRAM = wolfcrypt
WOLFSSL_SRC_DIR = ../..
TI_COMPILER_PATH = /opt/ti/msp430-gcc/bin
WOLFSSL_CFLAGS += -I$(WOLFSSL_SRC_DIR) -I. -DWOLFSSL_USER_SETTINGS
SRC_FILES = $(wildcard $(WOLFSSL_SRC_DIR)/src/*.c)
SRC_FILES += $(wildcard $(WOLFSSL_SRC_DIR)/wolfcrypt/src/*.c)
SRC_FILES := $(filter-out %bio.c %misc.c %evp.c, $(SRC_FILES))
SRC = main.c \
$(SRC_FILES)
CFLAGS += $(WOLFSSL_CFLAGS) -O3 -mmcu=msp430f5659 -I/opt/ti/msp430-gcc/include -L/opt/ti/msp430-gcc/include -mlarge -mcode-region=either -fdata-sections -ffunction-sections -Wl,--gc-sections
CC = $(TI_COMPILER_PATH)/msp430-elf-gcc
STRIP = $(TI_COMPILER_PATH)/msp430-elf-strip
$(PROGRAM): $(SRC)
$(CC) $(CFLAGS) $(SRC) $(LDFLAGS) $(LDLIBS) -o $@
$(STRIP) $@
clean:
rm -f $(PROGRAM)
install:
mspdebug tilib "prog $(PROGRAM)" --allow-fw-update

88
IDE/IAR-MSP430/README.md Normal file
View File

@ -0,0 +1,88 @@
# MSP430 Example
This example was designed to be used with the MSP430F5359/MSP430F5659 but can be ported to any similar MSP platform. It will take ~50KB of ROM space and a 8KB of statically allocated RAM (nearly half for constants).
The example runs at 8MHz and executes a benchmark of ECC key generations, shared secrets and 1KB ChaCha20/Poly1305 encryption.
At 8MHz the ECC steps will take 13-15 seconds each and 1000 iterations of ChaCha20/Poly1305 will take about 45 seconds.
## Hardware Setup
A basic development board / ISP combination will work fine, such as the MSP-TS430PZ100 series with the MSP-FET430 series programmer.
The example will output text via UART 1, on the MSP430 which is port 8 bits 2&3 (pins 60/61) on the MSP430F5359. The UART will run at 57600 baud.
In addition every second port 1 bit 1 will be toggled on/off (typically an LED would be here).
## IDE setup
When setting up the IDE, copy the wolfSSL source code to your project's directory and add all the .c and .h files from `wolfcrypt/src` to your project.
Use the `main.c` provided here and copy the `user_settings.h` file to the `wolfssl/wolfcrypt` subdirectory of wolfSSL.
You will need to set at least 700 bytes of stack, no heap is required. You will also need to change the "Library Configuration" to "Full DLIB" so the `printf()` functions work correctly.
Make sure to add the definition `WOLFSSL_USER_SETTINGS` to the preprocessor settings in your project to that `user_settings.h` is loaded in. You will also need to add the wolfSSL root directory to the "Additional include directories".
From here you can set any optimizer settings you need.
## MSP430 GCC Makefile
Also included is a `Makefile` for TI's GCC, when compiling with GCC the code size will be larger and the application will be ~2x slower.
To use this Makefile you will need [TI's MSP430 GCC](https://www.ti.com/tool/MSP430-GCC-OPENSOURCE) installed as well as `mspdebug` with the `libmsp430.so` accessible to it. You will need to edit the `Makefile` to set the `TI_COMPILER_PATH` to where you have installed this.
Once everything is in place you can run `make` to build it and `make install` to flash the MSP430 with it.
**Note**: this will not work with the much older version of MSP430 GCC that comes in Linux distribution repositories.
## Example Output
This is an example output for the demo application when compiled with IAR.
```
START!
Rand generated: 2317
Rand generated: -31901
Rand generated: 13538
Rand generated: -24035
Rand generated: 18849
Rand generated: -1593
Rand generated: 29653
Rand generated: -8148
Rand generated: -27438
Rand generated: 618
Rand generated: -17119
Rand generated: 4668
Rand generated: -26289
Rand generated: 28126
Rand generated: -15749
Rand generated: 22041
Rand generated: 8710
Rand generated: -22039
Rand generated: 1781
Rand generated: -32168
Rand generated: 6187
Rand generated: -7650
Rand generated: 30268
Rand generated: -13585
Rand generated: 24388
Rand generated: 8520
RNG init
Alice init
Bob init
.............Alice keygen 13 seconds
..............Bob keygen 14 seconds
.............Bob secret 13 seconds
..............Alice secret 14 seconds
Successfully generated a common secret
Alices' Secret: 85f3c7f599620c768e6dbb77dc2f8f764254cc1821aeb0a30503632dbc9bdb54
Bobs' Secret: 85f3c7f599620c768e6dbb77dc2f8f764254cc1821aeb0a30503632dbc9bdb54
ChaCha20/Poly1305 Encryption Start, 1000 itterations, 1024 bytes
............................................
End 44 seconds
ChaCha20/Poly1305 Decryption Start, 1000 itterations
............................................
End 44 seconds
end
```

View File

@ -0,0 +1,9 @@
# vim:ft=automake
# included from Top Level Makefile.am
# All paths should be given relative to the root
EXTRA_DIST+= IDE/IAR-MSP430/Makefile
EXTRA_DIST+= IDE/IAR-MSP430/README.md
EXTRA_DIST+= IDE/IAR-MSP430/main.c
EXTRA_DIST+= IDE/IAR-MSP430/user_settings.h

358
IDE/IAR-MSP430/main.c Normal file
View File

@ -0,0 +1,358 @@
/* MSP430 example main.c
*
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
* wolfSSL is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* wolfSSL is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
*/
#include <wolfssl/wolfcrypt/settings.h>
#include <wolfssl/wolfcrypt/wc_port.h>
#include <wolfssl/wolfcrypt/types.h>
#include <wolfssl/wolfcrypt/random.h>
#include <wolfssl/wolfcrypt/ecc.h>
#include <wolfssl/wolfcrypt/curve25519.h>
#include <wolfssl/wolfcrypt/chacha20_poly1305.h>
#include <stdio.h>
#include <stdlib.h>
#include <stdint.h>
#include <msp430f5659.h>
/* Without __root on some of the functions, IAR's "Discard Unused Publics"
will optimze out some of the functions
*/
#if defined(__IAR_SYSTEMS_ICC__)
#define IAR_KEEP __root
#else
#define IAR_KEEP
#endif
#define ECC_256_BIT_FIELD 32 /* 256-bit curve field */
#define WOLF_GEN_MEM (2*1024)
#define CHACHA_TEST_LEN 1024
static byte gWolfMem[WOLF_GEN_MEM];
static byte generatedCiphertext[CHACHA_TEST_LEN];
static byte generatedPlaintext[CHACHA_TEST_LEN];
#define MCLK_FREQ_MHZ 8 /* MCLK = 8MHz */
static const byte key[] = {
0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87,
0x88, 0x89, 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f,
0x90, 0x91, 0x92, 0x93, 0x94, 0x95, 0x96, 0x97,
0x98, 0x99, 0x9a, 0x9b, 0x9c, 0x9d, 0x9e, 0x9f
};
static const byte plaintext[] = "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras lacus odio, pretium vel sagittis ac, facilisis quis diam. Vivamus condimentum velit sed dolor consequat interdum. Etiam eleifend ornare felis, eleifend egestas odio vulputate eu. Sed nec orci nunc. Etiam quis mi augue. Donec ullamcorper suscipit lorem, vel luctus augue cursus fermentum. Etiam a porta arcu, in convallis sem. Integer efficitur elementum diam, vel scelerisque felis posuere placerat. Donec vestibulum sit amet leo sit amet tincidunt. Etiam et vehicula turpis. Phasellus quis finibus sapien. Sed et tristique turpis. Nullam vitae sagittis tortor, et aliquet lorem. Cras a leo scelerisque, convallis lacus ut, fermentum urna. Mauris quis urna diam. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Nam aliquam vehicula orci id pulvinar. Proin mollis, libero sollicitudin tempor ultrices, massa augue tincidunt turpis, sit amet aliquam neque nibh nec dui. Fusce finibus massa quis rutrum suscipit cras amet";
static const byte iv[] = {
0x07, 0x00, 0x00, 0x00, 0x40, 0x41, 0x42, 0x43,
0x44, 0x45, 0x46, 0x47
};
static const byte aad[] = { /* additional data */
0x50, 0x51, 0x52, 0x53, 0xc0, 0xc1, 0xc2, 0xc3,
0xc4, 0xc5, 0xc6, 0xc7
};
volatile unsigned int seconds;
IAR_KEEP unsigned int msp430_time(long *x)
{
return seconds;
}
static void print_secret(char* who, byte* s, int sLen)
{
int i;
printf("%ss' Secret: ", who);
for (i = 0; i < sLen; i++) {
printf("%02x", s[i]);
}
printf("\r\n");
}
/* This is a very crude RNG, do not use in production */
IAR_KEEP unsigned int msp430_rnd(void)
{
unsigned int result = TA0R ^ TA2R;
printf("Rand generated: %d\r\n", result);
return result;
}
static void uart_init()
{
P8SEL |= BIT3 + BIT2;
UCA1CTLW0 = UCSWRST; /* Put eUSCI in reset */
UCA1CTLW0 |= UCSSEL__SMCLK; /* CLK = SMCLK */
/* Baud Rate calculation
This was calculated to produce 115200 for a 16MHz clock, so it produces
57600 at 8MHz
16000000/(16*115200) = 8.6805
Fractional portion = 0.6805
Use Table 24-5 in Family User Guide
*/
UCA1BR0 = 8;
UCA1BR1 = 0x00;
UCA1MCTL |= UCOS16 | UCBRF_11 | UCBRS_0;
UCA1CTLW0 &= ~UCSWRST; /* Initialize eUSCI */
UCA1IE |= UCRXIE; /* Enable USCI_A0 RX interrupt */
}
#if defined(__IAR_SYSTEMS_ICC__)
IAR_KEEP size_t __write(int fd, const unsigned char *_ptr, size_t len)
#else
int write(int fd, const char *_ptr, int len)
#endif
{
size_t i;
for(i=0 ; i<len ; i++) {
while(!(UCA1IFG&UCTXIFG));
UCA1TXBUF = (unsigned char) _ptr[i];
}
return len;
}
static void SetVcoreUp (unsigned int level)
{
/* Change VCORE voltage level */
PMMCTL0_H = PMMPW_H; /* Open PMM registers for write */
SVSMHCTL = SVSHE /* Set SVS/SVM high side new level */
+ SVSHRVL0 * level
+ SVMHE
+ SVSMHRRL0 * level;
SVSMLCTL = SVSLE /* Set SVM low side to new level */
+ SVMLE
+ SVSMLRRL0 * level;
while ((PMMIFG & SVSMLDLYIFG) == 0); /* Wait till SVM is settled */
PMMIFG &= ~(SVMLVLRIFG + SVMLIFG); /* Clear already set flags */
PMMCTL0_L = PMMCOREV0 * level; /* Set VCore to new level */
if ((PMMIFG & SVMLIFG)) /* Wait till new level reached */
while ((PMMIFG & SVMLVLRIFG) == 0);
SVSMLCTL = SVSLE /* Set SVS/SVM low side to new level */
+ SVSLRVL0 * level
+ SVMLE
+ SVSMLRRL0 * level;
PMMCTL0_H = 0x00; /* Lock PMM registers for write access */
}
/* Stop WDT
We need to do this before main() because when there is ~4K of data to
initialize the watchdog will fire before initialization completes, sending
it into an endless loop of nothing.
See: https://www.iar.com/knowledge/support/technical-notes/general/my-msp430-does-not-start-up/
*/
#if defined(__IAR_SYSTEMS_ICC__)
int __low_level_init()
{
WDTCTL = WDTPW | WDTHOLD;
return 1;
}
#else
static void __attribute__((naked, used, section(".crt_0042")))
disable_watchdog (void)
{
WDTCTL = WDTPW | WDTHOLD;
}
#endif
int main(void)
{
byte generatedAuthTag[16];
WOLFSSL_HEAP_HINT* HEAP_HINT = NULL;
int ret;
int start;
/* NOTE: Change core voltage one level at a time.. */
SetVcoreUp (0x01);
SetVcoreUp (0x02);
SetVcoreUp (0x03);
/* USC module configuration, Fdcoclockdiv = Fmclk = 8MHz */
UCSCTL8 &= ~SMCLKREQEN; /* disable SMCLK clock requests */
UCSCTL3 = (0*FLLREFDIV0) /* FLL ref divider 1 */
+ SELREF2; /* set REFOCLK as FLL reference clock source */
UCSCTL4 = SELA__REFOCLK /* ACLK = REFO */
+ SELM__DCOCLKDIV /* MCLK = DCOCLKDIV */
+ SELS__DCOCLKDIV; /* SMCLK = DCOCLKDIV */
__bis_SR_register(SCG0); /* disable FLL operation */
UCSCTL0 = 0x0000; /* lowest possible DCO, MOD */
UCSCTL1 = DISMOD_L /* modulation disabled */
+ DCORSEL_6; /* DCO range for 8MHz operation */
UCSCTL2 = FLLD_0 /* D=FLLD=1, so that Fdco=8MHz */
+ 243; /* DCO multiplier for 8MHz */
/* (N + 1) * FLLRef = Fdcodiv */
/* (243 + 1) * 32768 = 8MHz (multiplier N = 243) */
__bic_SR_register(SCG0); /* re-enable FLL operation */
/* worst-case settling time for the DCO when the DCO range bits have been
32 x 32 x 8 MHz / 32,768 Hz = 250000 = MCLK cycles for DCO to settle
*/
__delay_cycles(250000);
TA0CCR0 = 32768-1;
TA0CCTL0 |= CCIE;
TA0CTL = TASSEL_1 + ID_0 + MC_1;
TA2CTL = TASSEL_2 | MC_2;
P1DIR = 1;
P1OUT = 0;
uart_init();
#if defined(__IAR_SYSTEMS_ICC__)
__enable_interrupt();
#else
_enable_interrupts();
#endif
printf("START!\r\n");
#ifdef HAVE_ECC
WC_RNG rng;
ecc_key AliceKey, BobKey;
byte AliceSecret[ECC_256_BIT_FIELD] = {0};
byte BobSecret[ECC_256_BIT_FIELD] = {0};
word32 secretLen = 0;
if (wc_LoadStaticMemory(&HEAP_HINT, gWolfMem, sizeof(gWolfMem),
WOLFMEM_GENERAL, 10) != 0) {
printf("unable to load static memory");
}
ret = wc_InitRng_ex(&rng, HEAP_HINT, INVALID_DEVID);
if (ret != 0) {
printf("RNG init fail: %d\r\n", ret);
return ret;
}
printf("RNG init\r\n");
ret = wc_ecc_init(&AliceKey);
if (ret != 0) {
printf("Alice init fail\r\n");
goto only_rng;
}
printf("Alice init\r\n");
ret = wc_ecc_init(&BobKey);
if (ret != 0) {
printf("Bob init fail\r\n");
goto alice_and_rng;
}
printf("Bob init\r\n");
start = seconds;
ret = wc_ecc_make_key(&rng, ECC_256_BIT_FIELD, &AliceKey);
if (ret != 0) {
printf("Alice keygen fail\r\n");
goto all_three;
}
printf("Alice keygen %d seconds\r\n", seconds - start);
start = seconds;
ret = wc_ecc_make_key(&rng, ECC_256_BIT_FIELD, &BobKey);
if (ret != 0) {
printf("Bob keygen fail\r\n");
goto all_three;
}
printf("Bob keygen %d seconds\r\n", seconds - start);
start = seconds;
secretLen = ECC_256_BIT_FIELD; /* explicit set */
ret = wc_ecc_shared_secret(&AliceKey, &BobKey, AliceSecret, &secretLen);
if (ret != 0) {
printf("Shared secret fail\r\n");
goto all_three;
}
printf("Bob secret %d seconds\r\n", seconds - start);
start = seconds;
secretLen = ECC_256_BIT_FIELD; /* explicit reset for best practice */
ret = wc_ecc_shared_secret(&BobKey, &AliceKey, BobSecret, &secretLen);
if (ret == 0) {
if (XMEMCMP(AliceSecret, BobSecret, secretLen))
printf("Failed to generate a common secret\n");
} else {
goto all_three;
}
printf("Alice secret %d seconds\r\n", seconds - start);
printf("Successfully generated a common secret\r\n");
print_secret("Alice", AliceSecret, (int) secretLen);
print_secret("Bob", BobSecret, (int) secretLen);
all_three:
wc_ecc_free(&BobKey);
alice_and_rng:
wc_ecc_free(&AliceKey);
only_rng:
wc_FreeRng(&rng);
printf(
"ChaCha20/Poly1305 Encryption Start, 1000 itterations, %d bytes\r\n",
(int)strlen((const char*)plaintext));
start = seconds;
for (int i=0; i <= 1000; i++) {
ret = wc_ChaCha20Poly1305_Encrypt(key, iv, aad, sizeof(aad), plaintext,
strlen((const char*)plaintext), generatedCiphertext,
generatedAuthTag);
if (ret) {
printf("ChaCha error: %d\r\n", ret);
break;
}
}
printf("\r\nEnd %d seconds\r\n", seconds - start);
start = seconds;
printf("ChaCha20/Poly1305 Decryption Start, 1000 itterations\r\n");
start = seconds;
for (int i=0; i <= 1000; i++) {
ret = wc_ChaCha20Poly1305_Decrypt(key, iv, aad, sizeof(aad),
generatedCiphertext, strlen((const char*)plaintext),
generatedAuthTag, generatedPlaintext);
if (ret) {
printf("ChaCha error: %d\r\n", ret);
break;
}
}
printf("\r\nEnd %d seconds\r\n", seconds - start);
#else
printf("Configure wolfSSL with --enable-ecc and try again\n");
ret = -1;
#endif
printf("end\r\n");
while(1) {
__delay_cycles(8000000);
}
return ret;
}
/* Timer ISR */
#if defined(__TI_COMPILER_VERSION__) || defined(__IAR_SYSTEMS_ICC__)
#pragma vector=TIMER0_A0_VECTOR
__interrupt void TIMER0_A0_ISR(void)
#elif defined(__GNUC__)
void __attribute__ ((interrupt(TIMER0_A0_VECTOR))) TIMER0_A0_ISR (void)
#else
#error Compiler not supported!
#endif
{
seconds++;
P1OUT = seconds ^ 2;
fprintf(stderr, ".");
}

View File

@ -0,0 +1,135 @@
/* user_settings.h
*
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
* wolfSSL is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* wolfSSL is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
*/
#ifndef WOLFSSL_USER_SETTINGS_H
#define WOLFSSL_USER_SETTINGS_H
#ifdef __cplusplus
extern "C" {
#endif
#undef SINGLE_THREADED
#define SINGLE_THREADED
#undef WOLFSSL_STATIC_MEMORY
#define WOLFSSL_STATIC_MEMORY
#undef WOLFSSL_NO_MALLOC
#define WOLFSSL_NO_MALLOC
#undef NO_FILESYSTEM
#define NO_FILESYSTEM
/* WolfCrypt Only (no TLS) */
#define WOLFCRYPT_ONLY
/* 16 bit */
#define WC_16BIT_CPU
/* Endianness - defaults to little endian */
#ifdef __BIG_ENDIAN__
#define BIG_ENDIAN_ORDER
#endif
/* Expose the math mp_ API's */
#define WOLFSSL_PUBLIC_MP
/* Use single precision math only */
#define WOLFSSL_SP_MATH
#define WOLFSSL_SP_NO_MALLOC
#define WOLFSSL_SP_SMALL
#define WOLFSSL_SP_NO_DYN_STACK
#define WOLFSSL_HAVE_SP_ECC
#define SP_WORD_SIZE 32
#define FP_MAX_BITS (2*256)
#define USE_SLOW_SHA
#define USE_SLOW_SHA256
#define USE_SLOW_SHA512
/* Enable Timing Resistance */
#define TFM_TIMING_RESISTANT
#define ECC_TIMING_RESISTANT
/* Enable ECC */
#define HAVE_ECC
#define ECC_USER_CURVES /* Only 256-Bit Curves */
//#define ECC_SHAMIR
/* Optional Feature Disables */
#define NO_SIG_WRAPPER
//#define NO_ECC_KEY_EXPORT
//#define NO_ECC_DHE
//#define NO_ECC_SIGN
//#define NO_ECC_VERIFY
/* Disable Algorithms */
#define NO_AES
#define NO_AES_CBC
#define NO_DES3
#define NO_DSA
#define NO_RSA
#define NO_DH
#define NO_RC4
#define NO_MD4
#define NO_MD5
#define NO_SHA
#define NO_PWDBASED
#define NO_PKCS12
#define NO_PKCS8
#define HAVE_CHACHA
#define HAVE_POLY1305
#define SIZEOF_LONG_LONG 8
/* Disable Features */
//#define NO_ASN
//#define NO_CERTS
//#define NO_WOLFSSL_MEMORY
#define WOLFSSL_NO_PEM
//#define NO_CODING
#define NO_PSK
#ifndef DEBUG_WOLFSSL
#define DEBUG_WOLFSSL
#define NO_ERROR_STRINGS
#endif
#define CUSTOM_RAND_TYPE unsigned int
extern unsigned int msp430_rnd(void);
#undef CUSTOM_RAND_GENERATE
#define CUSTOM_RAND_GENERATE msp430_rnd
extern unsigned int msp430_time(long *x);
#undef XTIME
#define XTIME msp430_time
#undef NO_CRYPT_TEST
#define NO_CRYPT_TEST
#undef NO_CRYPT_BENCHMARK
#define NO_CRYPT_BENCHMARK
#ifdef __cplusplus
}
#endif
#endif /* WOLFSSL_USER_SETTINGS_H */

View File

@ -47,9 +47,7 @@
<ClCompile Include="..\..\wolfcrypt\src\ge_operations.c" />
<ClCompile Include="..\..\wolfcrypt\src\hash.c" />
<ClCompile Include="..\..\wolfcrypt\src\kdf.c" />
<ClCompile Include="..\..\wolfcrypt\src\hc128.c" />
<ClCompile Include="..\..\wolfcrypt\src\hmac.c" />
<ClCompile Include="..\..\wolfcrypt\src\idea.c" />
<ClCompile Include="..\..\wolfcrypt\src\integer.c" />
<ClCompile Include="..\..\wolfcrypt\src\logging.c" />
<ClCompile Include="..\..\wolfcrypt\src\md2.c" />
@ -60,7 +58,6 @@
<ClCompile Include="..\..\wolfcrypt\src\pkcs7.c" />
<ClCompile Include="..\..\wolfcrypt\src\poly1305.c" />
<ClCompile Include="..\..\wolfcrypt\src\pwdbased.c" />
<ClCompile Include="..\..\wolfcrypt\src\rabbit.c" />
<ClCompile Include="..\..\wolfcrypt\src\random.c" />
<ClCompile Include="..\..\wolfcrypt\src\ripemd.c" />
<ClCompile Include="..\..\wolfcrypt\src\rsa.c" />
@ -114,9 +111,7 @@
<ClInclude Include="..\..\wolfssl\wolfcrypt\fips_test.h" />
<ClInclude Include="..\..\wolfssl\wolfcrypt\ge_operations.h" />
<ClInclude Include="..\..\wolfssl\wolfcrypt\hash.h" />
<ClInclude Include="..\..\wolfssl\wolfcrypt\hc128.h" />
<ClInclude Include="..\..\wolfssl\wolfcrypt\hmac.h" />
<ClInclude Include="..\..\wolfssl\wolfcrypt\idea.h" />
<ClInclude Include="..\..\wolfssl\wolfcrypt\integer.h" />
<ClInclude Include="..\..\wolfssl\wolfcrypt\logging.h" />
<ClInclude Include="..\..\wolfssl\wolfcrypt\md2.h" />
@ -131,7 +126,6 @@
<ClInclude Include="..\..\wolfssl\wolfcrypt\pkcs7.h" />
<ClInclude Include="..\..\wolfssl\wolfcrypt\poly1305.h" />
<ClInclude Include="..\..\wolfssl\wolfcrypt\pwdbased.h" />
<ClInclude Include="..\..\wolfssl\wolfcrypt\rabbit.h" />
<ClInclude Include="..\..\wolfssl\wolfcrypt\random.h" />
<ClInclude Include="..\..\wolfssl\wolfcrypt\ripemd.h" />
<ClInclude Include="..\..\wolfssl\wolfcrypt\rsa.h" />

View File

@ -418,12 +418,6 @@ extern "C" {
#undef NO_RC4
#define NO_RC4
#undef NO_HC128
#define NO_HC128
#undef NO_RABBIT
#define NO_RABBIT
#undef NO_MD4
#define NO_MD4

View File

@ -170,21 +170,11 @@
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/wolfcrypt/src/kdf.c</locationURI>
</link>
<link>
<name>src/wolfcrypt-src/hc128.c</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/wolfcrypt/src/hc128.c</locationURI>
</link>
<link>
<name>src/wolfcrypt-src/hmac.c</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/wolfcrypt/src/hmac.c</locationURI>
</link>
<link>
<name>src/wolfcrypt-src/idea.c</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/wolfcrypt/src/idea.c</locationURI>
</link>
<link>
<name>src/wolfcrypt-src/integer.c</name>
<type>1</type>
@ -235,11 +225,6 @@
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/wolfcrypt/src/pwdbased.c</locationURI>
</link>
<link>
<name>src/wolfcrypt-src/rabbit.c</name>
<type>1</type>
<locationURI>PARENT-2-PROJECT_LOC/wolfcrypt/src/rabbit.c</locationURI>
</link>
<link>
<name>src/wolfcrypt-src/random.c</name>
<type>1</type>

View File

@ -62,7 +62,6 @@ Wolfssl_C_Files :=$(WOLFSSL_ROOT)/wolfcrypt/src/aes.c\
$(WOLFSSL_ROOT)/wolfcrypt/src/error.c\
$(WOLFSSL_ROOT)/wolfcrypt/src/hash.c\
$(WOLFSSL_ROOT)/wolfcrypt/src/kdf.c\
$(WOLFSSL_ROOT)/wolfcrypt/src/hc128.c\
$(WOLFSSL_ROOT)/wolfcrypt/src/hmac.c\
$(WOLFSSL_ROOT)/wolfcrypt/src/integer.c\
$(WOLFSSL_ROOT)/src/internal.c\
@ -79,7 +78,6 @@ Wolfssl_C_Files :=$(WOLFSSL_ROOT)/wolfcrypt/src/aes.c\
$(WOLFSSL_ROOT)/wolfcrypt/src/wc_port.c\
$(WOLFSSL_ROOT)/wolfcrypt/src/wolfmath.c\
$(WOLFSSL_ROOT)/wolfcrypt/src/pwdbased.c\
$(WOLFSSL_ROOT)/wolfcrypt/src/rabbit.c\
$(WOLFSSL_ROOT)/wolfcrypt/src/random.c\
$(WOLFSSL_ROOT)/wolfcrypt/src/ripemd.c\
$(WOLFSSL_ROOT)/wolfcrypt/src/rsa.c\

View File

@ -1,6 +1,6 @@
/* lpc_18xx_port.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -45,8 +45,6 @@
#define NO_WOLFSSL_MEMORY
#define NO_DEV_RANDOM
#define NO_MD4
#define NO_RABBIT
#define NO_HC128
#define NO_DSA
#define NO_PWDBASED
#define NO_PSK

View File

@ -1,6 +1,6 @@
/* lpc_18xx_startup.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* main.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -1,6 +1,6 @@
/* main.c
*
* Copyright (C) 2006-2021 wolfSSL Inc.
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*

View File

@ -48,8 +48,6 @@
#define NO_ASN_TIME
#define NO_PWDBASED
#define NO_HC128
#define NO_RABBIT
#define NO_RC4
#define NO_DSA
#define NO_DES3

10
IDE/MCUEXPRESSO/README.md Normal file
View File

@ -0,0 +1,10 @@
- Open MCUEXPRESSO and set the workspace to wolfssl/IDE/MCUEXPRESSO
- File -> Open Projects From File System... -> Directory : and set the browse to wolfssl/IDE/MCUEXPROSSO directory then click "select directory"
- Select MCUEXPRESSO\wolfssl, MCUEXPRESSO\benchmark and MCUEXPRESSO\wolfcrypt_test then click "Finish"
- Right click the projects -> SDK Management -> Refresh SDK Components and click "yes"
- MCUEXPRESSO fails to generate the fils for wolfssl/MIMXRT685S, just copy the files from either benchmark or wolfcrypt_test into the directory
- increase the size of configTOTAL_HEAP_SIZE in FreeRTOSConfig.h to be 200000 for wolfcrypt_test and benchmark projects
- (note board files need to be recreated .... this can be done by creating a new project that has the same settings and copying over the generated board/* files)
- Build the projects

View File

@ -0,0 +1,744 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<?fileVersion 4.0.0?><cproject storage_type_id="org.eclipse.cdt.core.XmlProjectDescriptionStorage">
<storageModule moduleId="org.eclipse.cdt.core.settings">
<cconfiguration id="com.crt.advproject.config.exe.debug.1655056797">
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="com.crt.advproject.config.exe.debug.1655056797" moduleId="org.eclipse.cdt.core.settings" name="Debug">
<externalSettings/>
<extensions>
<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
<extension id="org.eclipse.cdt.core.GNU_ELF" point="org.eclipse.cdt.core.BinaryParser"/>
<extension id="org.eclipse.cdt.core.GmakeErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GASErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GLDErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.CWDLocator" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GCCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
</extensions>
</storageModule>
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
<configuration artifactExtension="axf" artifactName="${ProjName}" buildArtefactType="org.eclipse.cdt.build.core.buildArtefactType.exe" buildProperties="org.eclipse.cdt.build.core.buildArtefactType=org.eclipse.cdt.build.core.buildArtefactType.exe" cleanCommand="rm -rf" description="Debug build" errorParsers="org.eclipse.cdt.core.CWDLocator;org.eclipse.cdt.core.GmakeErrorParser;org.eclipse.cdt.core.GCCErrorParser;org.eclipse.cdt.core.GLDErrorParser;org.eclipse.cdt.core.GASErrorParser" id="com.crt.advproject.config.exe.debug.1655056797" name="Debug" parent="com.crt.advproject.config.exe.debug" postannouncebuildStep="Performing post-build steps" postbuildStep="arm-none-eabi-size &quot;${BuildArtifactFileName}&quot;; # arm-none-eabi-objcopy -v -O binary &quot;${BuildArtifactFileName}&quot; &quot;${BuildArtifactFileBaseName}.bin&quot; ; # checksum -p ${TargetChip} -d &quot;${BuildArtifactFileBaseName}.bin&quot;; ">
<folderInfo id="com.crt.advproject.config.exe.debug.1655056797." name="/" resourcePath="">
<toolChain id="com.crt.advproject.toolchain.exe.debug.1742817115" name="NXP MCU Tools" superClass="com.crt.advproject.toolchain.exe.debug">
<targetPlatform binaryParser="org.eclipse.cdt.core.ELF;org.eclipse.cdt.core.GNU_ELF" id="com.crt.advproject.platform.exe.debug.624190059" name="ARM-based MCU (Debug)" superClass="com.crt.advproject.platform.exe.debug"/>
<builder buildPath="${workspace_loc:/benchmark}/Debug" id="com.crt.advproject.builder.exe.debug.476544042" keepEnvironmentInBuildfile="false" managedBuildOn="true" name="Gnu Make Builder" superClass="com.crt.advproject.builder.exe.debug"/>
<tool id="com.crt.advproject.cpp.exe.debug.67513661" name="MCU C++ Compiler" superClass="com.crt.advproject.cpp.exe.debug">
<option id="com.crt.advproject.cpp.hdrlib.1100251953" name="Library headers" superClass="com.crt.advproject.cpp.hdrlib" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.fpu.529695337" name="Floating point" superClass="com.crt.advproject.cpp.fpu" useByScannerDiscovery="true" value="com.crt.advproject.cpp.fpu.fpv5sp.hard" valueType="enumerated"/>
<option id="com.crt.advproject.cpp.arch.491019386" name="Architecture" superClass="com.crt.advproject.cpp.arch" useByScannerDiscovery="true" value="com.crt.advproject.cpp.target.cm33" valueType="enumerated"/>
<option id="com.crt.advproject.cpp.misc.dialect.1008797000" name="Language standard" superClass="com.crt.advproject.cpp.misc.dialect" useByScannerDiscovery="true"/>
<option id="gnu.cpp.compiler.option.dialect.flags.310088209" name="Other dialect flags" superClass="gnu.cpp.compiler.option.dialect.flags" useByScannerDiscovery="true"/>
<option id="gnu.cpp.compiler.option.preprocessor.nostdinc.337557687" name="Do not search system directories (-nostdinc)" superClass="gnu.cpp.compiler.option.preprocessor.nostdinc" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.preprocessor.preprocess.105687278" name="Preprocess only (-E)" superClass="gnu.cpp.compiler.option.preprocessor.preprocess" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.preprocessor.def.1512593730" name="Defined symbols (-D)" superClass="gnu.cpp.compiler.option.preprocessor.def" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.preprocessor.undef.1204850869" name="Undefined symbols (-U)" superClass="gnu.cpp.compiler.option.preprocessor.undef" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.include.paths.375437545" name="Include paths (-I)" superClass="gnu.cpp.compiler.option.include.paths" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.include.files.1660246429" name="Include files (-include)" superClass="gnu.cpp.compiler.option.include.files" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.exe.debug.option.optimization.level.1687564158" name="Optimization Level" superClass="com.crt.advproject.cpp.exe.debug.option.optimization.level" useByScannerDiscovery="true"/>
<option id="gnu.cpp.compiler.option.optimization.flags.1437494088" name="Other optimization flags" superClass="gnu.cpp.compiler.option.optimization.flags" useByScannerDiscovery="false" value="-fno-common" valueType="string"/>
<option id="com.crt.advproject.cpp.exe.debug.option.debugging.level.68455038" name="Debug Level" superClass="com.crt.advproject.cpp.exe.debug.option.debugging.level" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.other.420329752" name="Other debugging flags" superClass="gnu.cpp.compiler.option.debugging.other" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.prof.32208165" name="Generate prof information (-p)" superClass="gnu.cpp.compiler.option.debugging.prof" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.gprof.928931102" name="Generate gprof information (-pg)" superClass="gnu.cpp.compiler.option.debugging.gprof" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.codecov.981582299" name="Generate gcov information (-ftest-coverage -fprofile-arcs)" superClass="gnu.cpp.compiler.option.debugging.codecov" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.sanitaddress.525113096" name="Sanitize address (-fsanitize=address)" superClass="gnu.cpp.compiler.option.debugging.sanitaddress" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.sanitpointers.310664848" name="Sanitize pointer operations (-fsanitize=pointer-compare -fsanitize=pointer-subtract)" superClass="gnu.cpp.compiler.option.debugging.sanitpointers" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.sanitthread.46061549" name="Sanitize data race in multi-thread (-fsanitize=thread)" superClass="gnu.cpp.compiler.option.debugging.sanitthread" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.sanitleak.1721454606" name="Sanitize memory leak (-fsanitize=leak)" superClass="gnu.cpp.compiler.option.debugging.sanitleak" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.sanitundef.1372767809" name="Sanitize undefined behavior (-fsanitize=undefined)" superClass="gnu.cpp.compiler.option.debugging.sanitundef" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.syntax.1798088686" name="Check syntax only (-fsyntax-only)" superClass="gnu.cpp.compiler.option.warnings.syntax" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.pedantic.1251450958" name="Pedantic (-pedantic)" superClass="gnu.cpp.compiler.option.warnings.pedantic" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.pedantic.error.275269726" name="Pedantic warnings as errors (-pedantic-errors)" superClass="gnu.cpp.compiler.option.warnings.pedantic.error" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.nowarn.1920260899" name="Inhibit all warnings (-w)" superClass="gnu.cpp.compiler.option.warnings.nowarn" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.allwarn.1175089512" name="All warnings (-Wall)" superClass="gnu.cpp.compiler.option.warnings.allwarn" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.extrawarn.1223278805" name="Extra warnings (-Wextra)" superClass="gnu.cpp.compiler.option.warnings.extrawarn" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.toerrors.147465511" name="Warnings as errors (-Werror)" superClass="gnu.cpp.compiler.option.warnings.toerrors" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wconversion.1492235801" name="Implicit conversion warnings (-Wconversion)" superClass="gnu.cpp.compiler.option.warnings.wconversion" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wcastalign.1228001774" name="Pointer cast with different alignment (-Wcast-align)" superClass="gnu.cpp.compiler.option.warnings.wcastalign" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wcastqual.1829700747" name="Removing type qualifier from cast target type (-Wcast-qual)" superClass="gnu.cpp.compiler.option.warnings.wcastqual" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wctordtorprivacy.1703660869" name="All ctor and dtor private (-Wctor-dtor-privacy)" superClass="gnu.cpp.compiler.option.warnings.wctordtorprivacy" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wdisabledopt.1581102527" name="Requested optimization pass is disabled (-Wdisabled-optimization)" superClass="gnu.cpp.compiler.option.warnings.wdisabledopt" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wlogicalop.1199752437" name="Suspicious uses of logical operators (-Wlogical-op)" superClass="gnu.cpp.compiler.option.warnings.wlogicalop" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wmissingdecl.1200044165" name="Global function without previous declaration (-Wmissing-declarations)" superClass="gnu.cpp.compiler.option.warnings.wmissingdecl" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wmissingincdir.1468133471" name="User-supplied include directory does not exist (-Wmissing-include-dirs)" superClass="gnu.cpp.compiler.option.warnings.wmissingincdir" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wnoexccept.1809240449" name="Noexcept false but never throw exception (-Wnoexcept)" superClass="gnu.cpp.compiler.option.warnings.wnoexccept" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.woldstylecast.81998190" name="C-style cast used (-Wold-style-cast)" superClass="gnu.cpp.compiler.option.warnings.woldstylecast" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.woverloadedvirtual.738186915" name="Function hides virtual functions from base class (-Woverloaded-virtual)" superClass="gnu.cpp.compiler.option.warnings.woverloadedvirtual" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wredundantdecl.2119054557" name="More than one declaration in the same scope (-Wredundant-decls)" superClass="gnu.cpp.compiler.option.warnings.wredundantdecl" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wshadow.459677219" name="Local symbol shadows upper scope symbol (-Wshadow)" superClass="gnu.cpp.compiler.option.warnings.wshadow" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wsignconv.847632167" name="Implicit conversions that may change the sign (-Wsign-conversion)" superClass="gnu.cpp.compiler.option.warnings.wsignconv" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wsignpromo.692373891" name="Overload resolution promotes unsigned to signed type (-Wsign-promo)" superClass="gnu.cpp.compiler.option.warnings.wsignpromo" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wstrictnullsent.63325306" name="Use of an uncasted NULL as sentinel (-Wstrict-null-sentinel)" superClass="gnu.cpp.compiler.option.warnings.wstrictnullsent" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wswitchdef.1343187722" name="A switch statement does not have a default case (-Wswitch-default)" superClass="gnu.cpp.compiler.option.warnings.wswitchdef" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wundef.1217552459" name="An undefined identifier is evaluated in an #if directive (-Wundef)" superClass="gnu.cpp.compiler.option.warnings.wundef" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.weffcpp.314771363" name="Effective C++ guidelines (-Weffc++)" superClass="gnu.cpp.compiler.option.warnings.weffcpp" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wfloatequal.1324913128" name="Direct float equal check (-Wfloat-equal)" superClass="gnu.cpp.compiler.option.warnings.wfloatequal" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.other.other.640301474" name="Other flags" superClass="gnu.cpp.compiler.option.other.other" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.other.verbose.1109771148" name="Verbose (-v)" superClass="gnu.cpp.compiler.option.other.verbose" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.other.pic.284983836" name="Position Independent Code (-fPIC)" superClass="gnu.cpp.compiler.option.other.pic" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.misc.hardening.2124946868" name="Hardening options (-fstack-protector-all -Wformat=2 -Wformat-security -Wstrict-overflow)" superClass="gnu.cpp.compiler.option.misc.hardening" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.misc.randomization.1785573403" name="Address randomization (-fPIE)" superClass="gnu.cpp.compiler.option.misc.randomization" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.lto.1725719976" name="Enable Link-time optimization (-flto)" superClass="com.crt.advproject.cpp.lto" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.lto.fat.187378683" name="Fat lto objects (-ffat-lto-objects)" superClass="com.crt.advproject.cpp.lto.fat" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.merge.constants.877337417" name="Merge Identical Constants (-fmerge-constants)" superClass="com.crt.advproject.cpp.merge.constants" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.prefixmap.1147948789" name="Remove path from __FILE__ (-fmacro-prefix-map)" superClass="com.crt.advproject.cpp.prefixmap" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.thumb.1782032456" name="Thumb mode" superClass="com.crt.advproject.cpp.thumb" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.thumbinterwork.983193792" name="Enable Thumb interworking" superClass="com.crt.advproject.cpp.thumbinterwork" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.securestate.1084975955" name="TrustZone Project Type" superClass="com.crt.advproject.cpp.securestate" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.stackusage.1917616851" name="Generate Stack Usage Info (-fstack-usage)" superClass="com.crt.advproject.cpp.stackusage" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.specs.1295006576" name="Specs" superClass="com.crt.advproject.cpp.specs" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.config.623406117" name="Obsolete (Config)" superClass="com.crt.advproject.cpp.config" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.store.1756700912" name="Obsolete (Store)" superClass="com.crt.advproject.cpp.store" useByScannerDiscovery="false"/>
</tool>
<tool id="com.crt.advproject.gcc.exe.debug.1638968152" name="MCU C Compiler" superClass="com.crt.advproject.gcc.exe.debug">
<option id="com.crt.advproject.gcc.hdrlib.1933653070" name="Library headers" superClass="com.crt.advproject.gcc.hdrlib" useByScannerDiscovery="false"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.compiler.option.preprocessor.def.symbols.1549427980" name="Defined symbols (-D)" superClass="gnu.c.compiler.option.preprocessor.def.symbols" useByScannerDiscovery="false" valueType="definedSymbols">
<listOptionValue builtIn="false" value="__REDLIB__"/>
<listOptionValue builtIn="false" value="WOLFSSL_USER_SETTINGS"/>
<listOptionValue builtIn="false" value="CPU_MIMXRT685SFVKB"/>
<listOptionValue builtIn="false" value="CPU_MIMXRT685SFVKB_cm33"/>
<listOptionValue builtIn="false" value="SDK_OS_BAREMETAL"/>
<listOptionValue builtIn="false" value="FSL_SDK_DRIVER_QUICK_ACCESS_ENABLE=1"/>
<listOptionValue builtIn="false" value="SDK_DEBUGCONSOLE=1"/>
<listOptionValue builtIn="false" value="PRINTF_FLOAT_ENABLE=1"/>
<listOptionValue builtIn="false" value="SDK_OS_FREE_RTOS"/>
<listOptionValue builtIn="false" value="SERIAL_PORT_TYPE_UART=1"/>
<listOptionValue builtIn="false" value="BOOT_HEADER_ENABLE=1"/>
<listOptionValue builtIn="false" value="__MCUXPRESSO"/>
<listOptionValue builtIn="false" value="__USE_CMSIS"/>
<listOptionValue builtIn="false" value="DEBUG"/>
</option>
<option id="com.crt.advproject.gcc.fpu.1115915114" name="Floating point" superClass="com.crt.advproject.gcc.fpu" useByScannerDiscovery="true" value="com.crt.advproject.gcc.fpu.fpv5sp.hard" valueType="enumerated"/>
<option id="com.crt.advproject.gcc.thumb.1394059319" name="Thumb mode" superClass="com.crt.advproject.gcc.thumb" useByScannerDiscovery="false" value="true" valueType="boolean"/>
<option id="com.crt.advproject.gcc.arch.1665129431" name="Architecture" superClass="com.crt.advproject.gcc.arch" useByScannerDiscovery="true" value="com.crt.advproject.gcc.target.cm33" valueType="enumerated"/>
<option id="com.crt.advproject.c.misc.dialect.1408112315" name="Language standard" superClass="com.crt.advproject.c.misc.dialect" useByScannerDiscovery="true"/>
<option id="gnu.c.compiler.option.dialect.flags.1687962482" name="Other dialect flags" superClass="gnu.c.compiler.option.dialect.flags" useByScannerDiscovery="true"/>
<option id="gnu.c.compiler.option.preprocessor.nostdinc.69915039" name="Do not search system directories (-nostdinc)" superClass="gnu.c.compiler.option.preprocessor.nostdinc" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.preprocessor.preprocess.828997020" name="Preprocess only (-E)" superClass="gnu.c.compiler.option.preprocessor.preprocess" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.preprocessor.undef.symbol.134031417" name="Undefined symbols (-U)" superClass="gnu.c.compiler.option.preprocessor.undef.symbol" useByScannerDiscovery="false"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.compiler.option.include.paths.886238104" name="Include paths (-I)" superClass="gnu.c.compiler.option.include.paths" useByScannerDiscovery="false" valueType="includePath">
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/board}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/source/benchmark}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc}/../../&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/source}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/freertos/freertos_kernel/include}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/drivers}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/device}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/CMSIS}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/component/uart}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/utilities}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/component/serial_manager}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/flash_config}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/component/lists}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/freertos/freertos_kernel/portable/GCC/ARM_CM33_NTZ/non_secure}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/MIMXRT685S}&quot;"/>
</option>
<option id="gnu.c.compiler.option.include.files.196459660" name="Include files (-include)" superClass="gnu.c.compiler.option.include.files" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.exe.debug.option.optimization.level.775064898" name="Optimization Level" superClass="com.crt.advproject.gcc.exe.debug.option.optimization.level" useByScannerDiscovery="true"/>
<option id="gnu.c.compiler.option.optimization.flags.1952465704" name="Other optimization flags" superClass="gnu.c.compiler.option.optimization.flags" useByScannerDiscovery="false" value="-fno-common" valueType="string"/>
<option id="com.crt.advproject.gcc.exe.debug.option.debugging.level.2022779295" name="Debug Level" superClass="com.crt.advproject.gcc.exe.debug.option.debugging.level" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.other.1501044114" name="Other debugging flags" superClass="gnu.c.compiler.option.debugging.other" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.prof.907856738" name="Generate prof information (-p)" superClass="gnu.c.compiler.option.debugging.prof" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.gprof.1731179986" name="Generate gprof information (-pg)" superClass="gnu.c.compiler.option.debugging.gprof" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.codecov.272210356" name="Generate gcov information (-ftest-coverage -fprofile-arcs)" superClass="gnu.c.compiler.option.debugging.codecov" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.sanitaddress.1381270570" name="Sanitize address (-fsanitize=address)" superClass="gnu.c.compiler.option.debugging.sanitaddress" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.sanitpointers.274885478" name="Sanitize pointer operations (-fsanitize=pointer-compare -fsanitize=pointer-subtract)" superClass="gnu.c.compiler.option.debugging.sanitpointers" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.sanitthread.1728404666" name="Sanitize data race in multi-thread (-fsanitize=thread)" superClass="gnu.c.compiler.option.debugging.sanitthread" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.sanitleak.698642782" name="Sanitize memory leak (-fsanitize=leak)" superClass="gnu.c.compiler.option.debugging.sanitleak" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.sanitundef.1014129765" name="Sanitize undefined behavior (-fsanitize=undefined)" superClass="gnu.c.compiler.option.debugging.sanitundef" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.syntax.758306230" name="Check syntax only (-fsyntax-only)" superClass="gnu.c.compiler.option.warnings.syntax" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.pedantic.2122857398" name="Pedantic (-pedantic)" superClass="gnu.c.compiler.option.warnings.pedantic" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.pedantic.error.1164782882" name="Pedantic warnings as errors (-pedantic-errors)" superClass="gnu.c.compiler.option.warnings.pedantic.error" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.nowarn.1321648891" name="Inhibit all warnings (-w)" superClass="gnu.c.compiler.option.warnings.nowarn" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.allwarn.676647919" name="All warnings (-Wall)" superClass="gnu.c.compiler.option.warnings.allwarn" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.extrawarn.1530084465" name="Extra warnings (-Wextra)" superClass="gnu.c.compiler.option.warnings.extrawarn" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.toerrors.388132769" name="Warnings as errors (-Werror)" superClass="gnu.c.compiler.option.warnings.toerrors" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wconversion.1349717666" name="Implicit conversion warnings (-Wconversion)" superClass="gnu.c.compiler.option.warnings.wconversion" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wcastalign.1029844013" name="Pointer cast with different alignment (-Wcast-align)" superClass="gnu.c.compiler.option.warnings.wcastalign" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wcastqual.896706854" name="Removing type qualifier from cast target type (-Wcast-qual)" superClass="gnu.c.compiler.option.warnings.wcastqual" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wdisabledopt.418459364" name="Requested optimization pass is disabled (-Wdisabled-optimization)" superClass="gnu.c.compiler.option.warnings.wdisabledopt" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wlogicalop.953697628" name="Suspicious uses of logical operators (-Wlogical-op)" superClass="gnu.c.compiler.option.warnings.wlogicalop" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wmissingdecl.1135408644" name="Global function without previous declaration (-Wmissing-declarations)" superClass="gnu.c.compiler.option.warnings.wmissingdecl" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wmissingincdir.63895246" name="User-supplied include directory does not exist (-Wmissing-include-dirs)" superClass="gnu.c.compiler.option.warnings.wmissingincdir" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wredundantdecl.1942311937" name="More than one declaration in the same scope (-Wredundant-decls)" superClass="gnu.c.compiler.option.warnings.wredundantdecl" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wshadow.8220331" name="Local symbol shadows upper scope symbol (-Wshadow)" superClass="gnu.c.compiler.option.warnings.wshadow" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wsignconv.581479856" name="Implicit conversions that may change the sign (-Wsign-conversion)" superClass="gnu.c.compiler.option.warnings.wsignconv" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wswitchdef.1458509345" name="A switch statement does not have a default case (-Wswitch-default)" superClass="gnu.c.compiler.option.warnings.wswitchdef" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wundef.1695266677" name="An undefined identifier is evaluated in an #if directive (-Wundef)" superClass="gnu.c.compiler.option.warnings.wundef" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wwritestrings.1911496737" name="Treat strings always as const (-Wwrite-strings)" superClass="gnu.c.compiler.option.warnings.wwritestrings" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wfloatequal.1837317624" name="Direct float equal check (-Wfloat-equal)" superClass="gnu.c.compiler.option.warnings.wfloatequal" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.misc.other.1220777106" name="Other flags" superClass="gnu.c.compiler.option.misc.other" useByScannerDiscovery="false" value="-c -ffunction-sections -fdata-sections -ffreestanding -fno-builtin" valueType="string"/>
<option id="gnu.c.compiler.option.misc.verbose.301574652" name="Verbose (-v)" superClass="gnu.c.compiler.option.misc.verbose" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.misc.ansi.1952098098" name="Support ANSI programs (-ansi)" superClass="gnu.c.compiler.option.misc.ansi" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.misc.pic.2065063964" name="Position Independent Code (-fPIC)" superClass="gnu.c.compiler.option.misc.pic" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.misc.hardening.1493747298" name="Hardening options (-fstack-protector-all -Wformat=2 -Wformat-security -Wstrict-overflow)" superClass="gnu.c.compiler.option.misc.hardening" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.misc.randomization.298940243" name="Address randomization (-fPIE)" superClass="gnu.c.compiler.option.misc.randomization" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.lto.1107142906" name="Enable Link-time optimization (-flto)" superClass="com.crt.advproject.gcc.lto" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.lto.fat.1421529879" name="Fat lto objects (-ffat-lto-objects)" superClass="com.crt.advproject.gcc.lto.fat" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.merge.constants.1331884997" name="Merge Identical Constants (-fmerge-constants)" superClass="com.crt.advproject.gcc.merge.constants" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.prefixmap.64954952" name="Remove path from __FILE__ (-fmacro-prefix-map)" superClass="com.crt.advproject.gcc.prefixmap" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.thumbinterwork.1306255807" name="Enable Thumb interworking" superClass="com.crt.advproject.gcc.thumbinterwork" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.securestate.1559432298" name="TrustZone Project Type" superClass="com.crt.advproject.gcc.securestate" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.stackusage.1088449650" name="Generate Stack Usage Info (-fstack-usage)" superClass="com.crt.advproject.gcc.stackusage" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.specs.769131747" name="Specs" superClass="com.crt.advproject.gcc.specs" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.config.1324002390" name="Obsolete (Config)" superClass="com.crt.advproject.gcc.config" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.store.496143366" name="Obsolete (Store)" superClass="com.crt.advproject.gcc.store" useByScannerDiscovery="false"/>
<inputType id="com.crt.advproject.compiler.input.1066742766" superClass="com.crt.advproject.compiler.input"/>
</tool>
<tool id="com.crt.advproject.gas.exe.debug.1830211151" name="MCU Assembler" superClass="com.crt.advproject.gas.exe.debug">
<option id="com.crt.advproject.gas.hdrlib.464138753" name="Library headers" superClass="com.crt.advproject.gas.hdrlib"/>
<option id="com.crt.advproject.gas.fpu.2110532338" name="Floating point" superClass="com.crt.advproject.gas.fpu" value="com.crt.advproject.gas.fpu.fpv5sp.hard" valueType="enumerated"/>
<option id="com.crt.advproject.gas.thumb.1369606929" name="Thumb mode" superClass="com.crt.advproject.gas.thumb" value="true" valueType="boolean"/>
<option id="com.crt.advproject.gas.arch.1101309206" name="Architecture" superClass="com.crt.advproject.gas.arch" value="com.crt.advproject.gas.target.cm33" valueType="enumerated"/>
<option id="gnu.both.asm.option.flags.crt.94791494" name="Assembler flags" superClass="gnu.both.asm.option.flags.crt" value="-c -x assembler-with-cpp -D__REDLIB__" valueType="string"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.both.asm.option.include.paths.1900227282" name="Include paths (-I)" superClass="gnu.both.asm.option.include.paths" valueType="includePath">
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/board}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/source}&quot;"/>
</option>
<option id="gnu.both.asm.option.warnings.nowarn.620369249" name="Suppress warnings (-W)" superClass="gnu.both.asm.option.warnings.nowarn"/>
<option id="gnu.both.asm.option.version.447486535" name="Announce version (-v)" superClass="gnu.both.asm.option.version"/>
<option id="com.crt.advproject.gas.exe.debug.option.debugging.level.1789039369" name="Debug level" superClass="com.crt.advproject.gas.exe.debug.option.debugging.level"/>
<option id="com.crt.advproject.gas.thumbinterwork.532017431" name="Enable Thumb interworking" superClass="com.crt.advproject.gas.thumbinterwork"/>
<option id="com.crt.advproject.gas.specs.2012447120" name="Specs" superClass="com.crt.advproject.gas.specs"/>
<option id="com.crt.advproject.gas.config.144217724" name="Obsolete (Config)" superClass="com.crt.advproject.gas.config"/>
<option id="com.crt.advproject.gas.store.245609686" name="Obsolete (Store)" superClass="com.crt.advproject.gas.store"/>
<inputType id="cdt.managedbuild.tool.gnu.assembler.input.1243530846" superClass="cdt.managedbuild.tool.gnu.assembler.input"/>
<inputType id="com.crt.advproject.assembler.input.803991339" name="Additional Assembly Source Files" superClass="com.crt.advproject.assembler.input"/>
</tool>
<tool id="com.crt.advproject.link.cpp.exe.debug.1253914770" name="MCU C++ Linker" superClass="com.crt.advproject.link.cpp.exe.debug">
<option id="com.crt.advproject.link.cpp.hdrlib.705182432" name="Library" superClass="com.crt.advproject.link.cpp.hdrlib"/>
<option id="com.crt.advproject.link.cpp.fpu.1596322294" name="Floating point" superClass="com.crt.advproject.link.cpp.fpu" value="com.crt.advproject.link.cpp.fpu.fpv5sp.hard" valueType="enumerated"/>
<option id="com.crt.advproject.link.cpp.arch.589259730" name="Architecture" superClass="com.crt.advproject.link.cpp.arch" value="com.crt.advproject.link.cpp.target.cm33" valueType="enumerated"/>
<option id="gnu.cpp.link.option.nostart.1288606715" name="Do not use standard start files (-nostartfiles)" superClass="gnu.cpp.link.option.nostart"/>
<option id="gnu.cpp.link.option.nodeflibs.858950444" name="Do not use default libraries (-nodefaultlibs)" superClass="gnu.cpp.link.option.nodeflibs"/>
<option id="gnu.cpp.link.option.nostdlibs.45831573" name="No startup or default libs (-nostdlib)" superClass="gnu.cpp.link.option.nostdlibs" value="true" valueType="boolean"/>
<option id="gnu.cpp.link.option.strip.1520911036" name="Omit all symbol information (-s)" superClass="gnu.cpp.link.option.strip"/>
<option id="gnu.cpp.link.option.libs.491456898" name="Libraries (-l)" superClass="gnu.cpp.link.option.libs"/>
<option id="gnu.cpp.link.option.paths.1469225151" name="Library search path (-L)" superClass="gnu.cpp.link.option.paths"/>
<option id="gnu.cpp.link.option.flags.1250964568" name="Linker flags" superClass="gnu.cpp.link.option.flags"/>
<option id="gnu.cpp.link.option.other.1746740285" name="Other options (-Xlinker [option])" superClass="gnu.cpp.link.option.other"/>
<option id="gnu.cpp.link.option.userobjs.1028717516" name="Other objects" superClass="gnu.cpp.link.option.userobjs"/>
<option id="gnu.cpp.link.option.shared.1642092194" name="Shared (-shared)" superClass="gnu.cpp.link.option.shared"/>
<option id="gnu.cpp.link.option.soname.1486385357" name="Shared object name (-Wl,-soname=)" superClass="gnu.cpp.link.option.soname"/>
<option id="gnu.cpp.link.option.implname.980150930" name="Import Library name (-Wl,--out-implib=)" superClass="gnu.cpp.link.option.implname"/>
<option id="gnu.cpp.link.option.defname.1750316464" name="DEF file name (-Wl,--output-def=)" superClass="gnu.cpp.link.option.defname"/>
<option id="gnu.cpp.link.option.debugging.prof.287841331" name="Generate prof information (-p)" superClass="gnu.cpp.link.option.debugging.prof"/>
<option id="gnu.cpp.link.option.debugging.gprof.1757455157" name="Generate gprof information (-pg)" superClass="gnu.cpp.link.option.debugging.gprof"/>
<option id="gnu.cpp.link.option.debugging.codecov.667469372" name="Generate gcov information (-ftest-coverage -fprofile-arcs)" superClass="gnu.cpp.link.option.debugging.codecov"/>
<option id="com.crt.advproject.link.cpp.lto.320707398" name="Enable Link-time optimization (-flto)" superClass="com.crt.advproject.link.cpp.lto"/>
<option id="com.crt.advproject.link.cpp.lto.optmization.level.895305267" name="Link-time optimization level" superClass="com.crt.advproject.link.cpp.lto.optmization.level"/>
<option id="com.crt.advproject.link.cpp.thumb.389961363" name="Thumb mode" superClass="com.crt.advproject.link.cpp.thumb"/>
<option id="com.crt.advproject.link.cpp.manage.1203310256" name="Manage linker script" superClass="com.crt.advproject.link.cpp.manage"/>
<option id="com.crt.advproject.link.cpp.script.2033738361" name="Linker script" superClass="com.crt.advproject.link.cpp.script"/>
<option id="com.crt.advproject.link.cpp.scriptdir.1763713142" name="Script path" superClass="com.crt.advproject.link.cpp.scriptdir"/>
<option id="com.crt.advproject.link.cpp.crpenable.420071128" name="Enable automatic placement of Code Read Protection field in image" superClass="com.crt.advproject.link.cpp.crpenable"/>
<option id="com.crt.advproject.link.cpp.flashconfigenable.2102469469" name="Enable automatic placement of Flash Configuration field in image" superClass="com.crt.advproject.link.cpp.flashconfigenable" value="true" valueType="boolean"/>
<option id="com.crt.advproject.link.cpp.ecrp.1513523258" name="Enhanced CRP" superClass="com.crt.advproject.link.cpp.ecrp"/>
<option id="com.crt.advproject.link.cpp.nanofloat.854667217" name="Enable printf float " superClass="com.crt.advproject.link.cpp.nanofloat"/>
<option id="com.crt.advproject.link.cpp.nanofloat.scanf.330489151" name="Enable scanf float " superClass="com.crt.advproject.link.cpp.nanofloat.scanf"/>
<option id="com.crt.advproject.link.cpp.toram.2015567559" name="Link application to RAM" superClass="com.crt.advproject.link.cpp.toram"/>
<option id="com.crt.advproject.link.memory.load.image.cpp.1095330627" name="Plain load image" superClass="com.crt.advproject.link.memory.load.image.cpp"/>
<option id="com.crt.advproject.link.memory.heapAndStack.style.cpp.883079383" name="Heap and Stack placement" superClass="com.crt.advproject.link.memory.heapAndStack.style.cpp"/>
<option id="com.crt.advproject.link.cpp.stackOffset.648081670" name="Stack offset" superClass="com.crt.advproject.link.cpp.stackOffset"/>
<option id="com.crt.advproject.link.memory.heapAndStack.cpp.443686001" name="Heap and Stack options" superClass="com.crt.advproject.link.memory.heapAndStack.cpp"/>
<option id="com.crt.advproject.link.memory.data.cpp.455693854" name="Global data placement" superClass="com.crt.advproject.link.memory.data.cpp"/>
<option id="com.crt.advproject.link.memory.sections.cpp.799443001" name="Extra linker script input sections" superClass="com.crt.advproject.link.memory.sections.cpp"/>
<option id="com.crt.advproject.link.cpp.multicore.slave.443810318" name="Multicore configuration" superClass="com.crt.advproject.link.cpp.multicore.slave"/>
<option id="com.crt.advproject.link.cpp.multicore.master.785867506" name="Multicore master" superClass="com.crt.advproject.link.cpp.multicore.master"/>
<option id="com.crt.advproject.link.cpp.multicore.empty.920385802" name="No Multicore options for this project" superClass="com.crt.advproject.link.cpp.multicore.empty"/>
<option id="com.crt.advproject.link.cpp.multicore.master.userobjs.962643621" name="Slave Objects (not visible)" superClass="com.crt.advproject.link.cpp.multicore.master.userobjs"/>
<option id="com.crt.advproject.link.cpp.config.666035078" name="Obsolete (Config)" superClass="com.crt.advproject.link.cpp.config"/>
<option id="com.crt.advproject.link.cpp.store.941946453" name="Obsolete (Store)" superClass="com.crt.advproject.link.cpp.store"/>
<option id="com.crt.advproject.link.cpp.securestate.402138634" name="TrustZone Project Type" superClass="com.crt.advproject.link.cpp.securestate"/>
<option id="com.crt.advproject.link.cpp.sgstubs.placement.2109775676" name="Secure Gateway Placement" superClass="com.crt.advproject.link.cpp.sgstubs.placement"/>
<option id="com.crt.advproject.link.cpp.sgstubenable.1181195873" name="Enable generation of Secure Gateway Import Library" superClass="com.crt.advproject.link.cpp.sgstubenable"/>
<option id="com.crt.advproject.link.cpp.nonsecureobject.41916017" name="Secure Gateway Import Library" superClass="com.crt.advproject.link.cpp.nonsecureobject"/>
<option id="com.crt.advproject.link.cpp.inimplib.1934052223" name="Input Secure Gateway Import Library" superClass="com.crt.advproject.link.cpp.inimplib"/>
</tool>
<tool id="com.crt.advproject.link.exe.debug.2142294434" name="MCU Linker" superClass="com.crt.advproject.link.exe.debug">
<option id="com.crt.advproject.link.gcc.hdrlib.1625256664" name="Library" superClass="com.crt.advproject.link.gcc.hdrlib" value="com.crt.advproject.gcc.link.hdrlib.codered.nohost_nf" valueType="enumerated"/>
<option id="com.crt.advproject.link.fpu.1678118098" name="Floating point" superClass="com.crt.advproject.link.fpu" value="com.crt.advproject.link.fpu.fpv5sp.hard" valueType="enumerated"/>
<option id="com.crt.advproject.link.thumb.1949972923" name="Thumb mode" superClass="com.crt.advproject.link.thumb" value="true" valueType="boolean"/>
<option id="com.crt.advproject.link.memory.load.image.949002685" name="Plain load image" superClass="com.crt.advproject.link.memory.load.image" useByScannerDiscovery="false" value="false;" valueType="string"/>
<option defaultValue="com.crt.advproject.heapAndStack.mcuXpressoStyle" id="com.crt.advproject.link.memory.heapAndStack.style.1111910272" name="Heap and Stack placement" superClass="com.crt.advproject.link.memory.heapAndStack.style" useByScannerDiscovery="false" valueType="enumerated"/>
<option id="com.crt.advproject.link.memory.heapAndStack.1649862729" name="Heap and Stack options" superClass="com.crt.advproject.link.memory.heapAndStack" useByScannerDiscovery="false" value="&amp;Heap:Default;Post Data;0x30d40&amp;Stack:Default;End;0x3d090" valueType="string"/>
<option id="com.crt.advproject.link.memory.data.946070639" name="Global data placement" superClass="com.crt.advproject.link.memory.data" useByScannerDiscovery="false" value="Default" valueType="string"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="true" id="com.crt.advproject.link.memory.sections.1538167157" name="Extra linker script input sections" superClass="com.crt.advproject.link.memory.sections" useByScannerDiscovery="false" valueType="stringList"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="true" id="com.crt.advproject.link.gcc.multicore.master.userobjs.316327266" name="Slave Objects (not visible)" superClass="com.crt.advproject.link.gcc.multicore.master.userobjs" useByScannerDiscovery="false" valueType="userObjs"/>
<option id="com.crt.advproject.link.gcc.multicore.slave.646593994" name="Multicore configuration" superClass="com.crt.advproject.link.gcc.multicore.slave"/>
<option id="com.crt.advproject.link.arch.987641782" name="Architecture" superClass="com.crt.advproject.link.arch" value="com.crt.advproject.link.target.cm33" valueType="enumerated"/>
<option id="gnu.c.link.option.nostart.1546042917" name="Do not use standard start files (-nostartfiles)" superClass="gnu.c.link.option.nostart"/>
<option id="gnu.c.link.option.nodeflibs.330096677" name="Do not use default libraries (-nodefaultlibs)" superClass="gnu.c.link.option.nodeflibs"/>
<option id="gnu.c.link.option.nostdlibs.1810828126" name="No startup or default libs (-nostdlib)" superClass="gnu.c.link.option.nostdlibs" value="true" valueType="boolean"/>
<option id="gnu.c.link.option.strip.46849199" name="Omit all symbol information (-s)" superClass="gnu.c.link.option.strip"/>
<option id="gnu.c.link.option.noshared.1683374198" name="No shared libraries (-static)" superClass="gnu.c.link.option.noshared"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.link.option.libs.962554866" name="Libraries (-l)" superClass="gnu.c.link.option.libs" valueType="libs">
<listOptionValue builtIn="false" value="wolfssl"/>
</option>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.link.option.paths.2080196780" name="Library search path (-L)" superClass="gnu.c.link.option.paths" valueType="libPaths">
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/wolfssl/Debug}&quot;"/>
</option>
<option id="gnu.c.link.option.ldflags.872641067" name="Linker flags" superClass="gnu.c.link.option.ldflags"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.link.option.other.1751084095" name="Other options (-Xlinker [option])" superClass="gnu.c.link.option.other" valueType="stringList">
<listOptionValue builtIn="false" value="-Map=&quot;${BuildArtifactFileBaseName}.map&quot;"/>
<listOptionValue builtIn="false" value="--gc-sections"/>
<listOptionValue builtIn="false" value="-print-memory-usage"/>
<listOptionValue builtIn="false" value="--sort-section=alignment"/>
<listOptionValue builtIn="false" value="--cref"/>
</option>
<option id="gnu.c.link.option.userobjs.776647065" name="Other objects" superClass="gnu.c.link.option.userobjs"/>
<option id="gnu.c.link.option.shared.737800008" name="Shared (-shared)" superClass="gnu.c.link.option.shared"/>
<option id="gnu.c.link.option.soname.579585514" name="Shared object name (-Wl,-soname=)" superClass="gnu.c.link.option.soname"/>
<option id="gnu.c.link.option.implname.1607261316" name="Import Library name (-Wl,--out-implib=)" superClass="gnu.c.link.option.implname"/>
<option id="gnu.c.link.option.defname.1228422873" name="DEF file name (-Wl,--output-def=)" superClass="gnu.c.link.option.defname"/>
<option id="gnu.c.link.option.debugging.prof.1216175131" name="Generate prof information (-p)" superClass="gnu.c.link.option.debugging.prof"/>
<option id="gnu.c.link.option.debugging.gprof.1412158379" name="Generate gprof information (-pg)" superClass="gnu.c.link.option.debugging.gprof"/>
<option id="gnu.c.link.option.debugging.codecov.1016629624" name="Generate gcov information (-ftest-coverage -fprofile-arcs)" superClass="gnu.c.link.option.debugging.codecov"/>
<option id="com.crt.advproject.link.gcc.lto.1200071222" name="Enable Link-time optimization (-flto)" superClass="com.crt.advproject.link.gcc.lto"/>
<option id="com.crt.advproject.link.gcc.lto.optmization.level.1298504847" name="Link-time optimization level" superClass="com.crt.advproject.link.gcc.lto.optmization.level"/>
<option id="com.crt.advproject.link.manage.891555673" name="Manage linker script" superClass="com.crt.advproject.link.manage" value="true" valueType="boolean"/>
<option id="com.crt.advproject.link.script.228722563" name="Linker script" superClass="com.crt.advproject.link.script" useByScannerDiscovery="false" value="benchmark_Debug.ld" valueType="string"/>
<option id="com.crt.advproject.link.scriptdir.893827770" name="Script path" superClass="com.crt.advproject.link.scriptdir" useByScannerDiscovery="false" value="" valueType="string"/>
<option id="com.crt.advproject.link.crpenable.1338899499" name="Enable automatic placement of Code Read Protection field in image" superClass="com.crt.advproject.link.crpenable"/>
<option id="com.crt.advproject.link.flashconfigenable.264454903" name="Enable automatic placement of Flash Configuration field in image" superClass="com.crt.advproject.link.flashconfigenable" value="true" valueType="boolean"/>
<option id="com.crt.advproject.link.ecrp.149738131" name="Enhanced CRP" superClass="com.crt.advproject.link.ecrp"/>
<option id="com.crt.advproject.link.gcc.nanofloat.1637667668" name="Enable printf float " superClass="com.crt.advproject.link.gcc.nanofloat"/>
<option id="com.crt.advproject.link.gcc.nanofloat.scanf.1439788829" name="Enable scanf float " superClass="com.crt.advproject.link.gcc.nanofloat.scanf"/>
<option id="com.crt.advproject.link.toram.2110082262" name="Link application to RAM" superClass="com.crt.advproject.link.toram"/>
<option id="com.crt.advproject.link.stackOffset.772419928" name="Stack offset" superClass="com.crt.advproject.link.stackOffset"/>
<option id="com.crt.advproject.link.gcc.multicore.master.1327985432" name="Multicore master" superClass="com.crt.advproject.link.gcc.multicore.master"/>
<option id="com.crt.advproject.link.gcc.multicore.empty.406463450" name="No Multicore options for this project" superClass="com.crt.advproject.link.gcc.multicore.empty"/>
<option id="com.crt.advproject.link.config.1186065033" name="Obsolete (Config)" superClass="com.crt.advproject.link.config"/>
<option id="com.crt.advproject.link.store.1847009870" name="Obsolete (Store)" superClass="com.crt.advproject.link.store"/>
<option id="com.crt.advproject.link.securestate.1336154988" name="TrustZone Project Type" superClass="com.crt.advproject.link.securestate"/>
<option id="com.crt.advproject.link.sgstubs.placement.301197582" name="Secure Gateway Placement" superClass="com.crt.advproject.link.sgstubs.placement"/>
<option id="com.crt.advproject.link.sgstubenable.659712548" name="Enable generation of Secure Gateway Import Library" superClass="com.crt.advproject.link.sgstubenable"/>
<option id="com.crt.advproject.link.nonsecureobject.96526573" name="Secure Gateway Import Library" superClass="com.crt.advproject.link.nonsecureobject"/>
<option id="com.crt.advproject.link.inimplib.481974787" name="Input Secure Gateway Import Library" superClass="com.crt.advproject.link.inimplib"/>
<inputType id="cdt.managedbuild.tool.gnu.c.linker.input.274410118" superClass="cdt.managedbuild.tool.gnu.c.linker.input">
<additionalInput kind="additionalinputdependency" paths="$(USER_OBJS)"/>
<additionalInput kind="additionalinput" paths="$(LIBS)"/>
</inputType>
</tool>
<tool id="com.crt.advproject.tool.debug.debug.513236231" name="MCU Debugger" superClass="com.crt.advproject.tool.debug.debug">
<option id="com.crt.advproject.linkserver.debug.prevent.debug.1991854507" name="Prevent Debugging" superClass="com.crt.advproject.linkserver.debug.prevent.debug"/>
<option id="com.crt.advproject.miscellaneous.end_of_heap.1905162588" name="Last used address of the heap" superClass="com.crt.advproject.miscellaneous.end_of_heap"/>
<option id="com.crt.advproject.miscellaneous.pvHeapStart.1877580926" name="First address of the heap" superClass="com.crt.advproject.miscellaneous.pvHeapStart"/>
<option id="com.crt.advproject.miscellaneous.pvHeapLimit.1613722550" name="Maximum extent of heap" superClass="com.crt.advproject.miscellaneous.pvHeapLimit"/>
<option id="com.crt.advproject.debugger.security.nonsecureimageenable.1557056464" name="Enable pre-programming of Non-Secure Image" superClass="com.crt.advproject.debugger.security.nonsecureimageenable"/>
<option id="com.crt.advproject.debugger.security.nonsecureimage.1885154096" name="Non-Secure Project" superClass="com.crt.advproject.debugger.security.nonsecureimage"/>
</tool>
</toolChain>
</folderInfo>
<sourceEntries>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="component"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="CMSIS"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="MIMXRT685S"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="source"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="utilities"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="drivers"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="device"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="board"/>
<entry excluding="freertos_kernel/portable/MemMang/heap_1.c|freertos_kernel/portable/MemMang/heap_2.c|freertos_kernel/portable/MemMang/heap_3.c|freertos_kernel/portable/MemMang/heap_5.c" flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="freertos"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="flash_config"/>
</sourceEntries>
</configuration>
</storageModule>
<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
</cconfiguration>
<cconfiguration id="com.crt.advproject.config.exe.release.1666559984">
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="com.crt.advproject.config.exe.release.1666559984" moduleId="org.eclipse.cdt.core.settings" name="Release">
<externalSettings/>
<extensions>
<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
<extension id="org.eclipse.cdt.core.GNU_ELF" point="org.eclipse.cdt.core.BinaryParser"/>
<extension id="org.eclipse.cdt.core.GmakeErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GASErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GLDErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.CWDLocator" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GCCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
</extensions>
</storageModule>
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
<configuration artifactExtension="axf" artifactName="${ProjName}" buildArtefactType="org.eclipse.cdt.build.core.buildArtefactType.exe" buildProperties="org.eclipse.cdt.build.core.buildArtefactType=org.eclipse.cdt.build.core.buildArtefactType.exe" cleanCommand="rm -rf" description="Release build" errorParsers="org.eclipse.cdt.core.CWDLocator;org.eclipse.cdt.core.GmakeErrorParser;org.eclipse.cdt.core.GCCErrorParser;org.eclipse.cdt.core.GLDErrorParser;org.eclipse.cdt.core.GASErrorParser" id="com.crt.advproject.config.exe.release.1666559984" name="Release" parent="com.crt.advproject.config.exe.release" postannouncebuildStep="Performing post-build steps" postbuildStep="arm-none-eabi-size &quot;${BuildArtifactFileName}&quot;; # arm-none-eabi-objcopy -v -O binary &quot;${BuildArtifactFileName}&quot; &quot;${BuildArtifactFileBaseName}.bin&quot; ; # checksum -p ${TargetChip} -d &quot;${BuildArtifactFileBaseName}.bin&quot;; ">
<folderInfo id="com.crt.advproject.config.exe.release.1666559984." name="/" resourcePath="">
<toolChain id="com.crt.advproject.toolchain.exe.release.1200166302" name="NXP MCU Tools" superClass="com.crt.advproject.toolchain.exe.release">
<targetPlatform binaryParser="org.eclipse.cdt.core.ELF;org.eclipse.cdt.core.GNU_ELF" id="com.crt.advproject.platform.exe.release.1720699906" name="ARM-based MCU (Release)" superClass="com.crt.advproject.platform.exe.release"/>
<builder buildPath="${workspace_loc:/benchmark}/Release" id="com.crt.advproject.builder.exe.release.157935292" keepEnvironmentInBuildfile="false" managedBuildOn="true" name="Gnu Make Builder" superClass="com.crt.advproject.builder.exe.release"/>
<tool id="com.crt.advproject.cpp.exe.release.1681250539" name="MCU C++ Compiler" superClass="com.crt.advproject.cpp.exe.release">
<option id="com.crt.advproject.cpp.arch.369730869" name="Architecture" superClass="com.crt.advproject.cpp.arch" useByScannerDiscovery="true" value="com.crt.advproject.cpp.target.cm33" valueType="enumerated"/>
<option id="com.crt.advproject.cpp.misc.dialect.1951031536" name="Language standard" superClass="com.crt.advproject.cpp.misc.dialect" useByScannerDiscovery="true"/>
<option id="gnu.cpp.compiler.option.dialect.flags.610476094" name="Other dialect flags" superClass="gnu.cpp.compiler.option.dialect.flags" useByScannerDiscovery="true"/>
<option id="gnu.cpp.compiler.option.preprocessor.nostdinc.340349660" name="Do not search system directories (-nostdinc)" superClass="gnu.cpp.compiler.option.preprocessor.nostdinc" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.preprocessor.preprocess.1861742763" name="Preprocess only (-E)" superClass="gnu.cpp.compiler.option.preprocessor.preprocess" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.preprocessor.def.1771243916" name="Defined symbols (-D)" superClass="gnu.cpp.compiler.option.preprocessor.def" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.preprocessor.undef.1793606316" name="Undefined symbols (-U)" superClass="gnu.cpp.compiler.option.preprocessor.undef" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.include.paths.480139893" name="Include paths (-I)" superClass="gnu.cpp.compiler.option.include.paths" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.include.files.473381014" name="Include files (-include)" superClass="gnu.cpp.compiler.option.include.files" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.optimization.flags.1565490090" name="Other optimization flags" superClass="gnu.cpp.compiler.option.optimization.flags" useByScannerDiscovery="false" value="-fno-common" valueType="string"/>
<option id="gnu.cpp.compiler.option.debugging.other.2122600727" name="Other debugging flags" superClass="gnu.cpp.compiler.option.debugging.other" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.prof.754309234" name="Generate prof information (-p)" superClass="gnu.cpp.compiler.option.debugging.prof" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.gprof.764455369" name="Generate gprof information (-pg)" superClass="gnu.cpp.compiler.option.debugging.gprof" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.codecov.632606938" name="Generate gcov information (-ftest-coverage -fprofile-arcs)" superClass="gnu.cpp.compiler.option.debugging.codecov" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.sanitaddress.619281113" name="Sanitize address (-fsanitize=address)" superClass="gnu.cpp.compiler.option.debugging.sanitaddress" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.sanitpointers.1373995033" name="Sanitize pointer operations (-fsanitize=pointer-compare -fsanitize=pointer-subtract)" superClass="gnu.cpp.compiler.option.debugging.sanitpointers" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.sanitthread.1608478861" name="Sanitize data race in multi-thread (-fsanitize=thread)" superClass="gnu.cpp.compiler.option.debugging.sanitthread" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.sanitleak.1128394173" name="Sanitize memory leak (-fsanitize=leak)" superClass="gnu.cpp.compiler.option.debugging.sanitleak" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.sanitundef.1496980635" name="Sanitize undefined behavior (-fsanitize=undefined)" superClass="gnu.cpp.compiler.option.debugging.sanitundef" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.syntax.438355810" name="Check syntax only (-fsyntax-only)" superClass="gnu.cpp.compiler.option.warnings.syntax" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.pedantic.591905085" name="Pedantic (-pedantic)" superClass="gnu.cpp.compiler.option.warnings.pedantic" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.pedantic.error.129927136" name="Pedantic warnings as errors (-pedantic-errors)" superClass="gnu.cpp.compiler.option.warnings.pedantic.error" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.nowarn.1060724094" name="Inhibit all warnings (-w)" superClass="gnu.cpp.compiler.option.warnings.nowarn" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.allwarn.927567109" name="All warnings (-Wall)" superClass="gnu.cpp.compiler.option.warnings.allwarn" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.extrawarn.1159122189" name="Extra warnings (-Wextra)" superClass="gnu.cpp.compiler.option.warnings.extrawarn" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.toerrors.1819247307" name="Warnings as errors (-Werror)" superClass="gnu.cpp.compiler.option.warnings.toerrors" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wconversion.1779705666" name="Implicit conversion warnings (-Wconversion)" superClass="gnu.cpp.compiler.option.warnings.wconversion" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wcastalign.143940814" name="Pointer cast with different alignment (-Wcast-align)" superClass="gnu.cpp.compiler.option.warnings.wcastalign" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wcastqual.439067159" name="Removing type qualifier from cast target type (-Wcast-qual)" superClass="gnu.cpp.compiler.option.warnings.wcastqual" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wctordtorprivacy.2094011350" name="All ctor and dtor private (-Wctor-dtor-privacy)" superClass="gnu.cpp.compiler.option.warnings.wctordtorprivacy" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wdisabledopt.654230214" name="Requested optimization pass is disabled (-Wdisabled-optimization)" superClass="gnu.cpp.compiler.option.warnings.wdisabledopt" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wlogicalop.1815306810" name="Suspicious uses of logical operators (-Wlogical-op)" superClass="gnu.cpp.compiler.option.warnings.wlogicalop" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wmissingdecl.1729418253" name="Global function without previous declaration (-Wmissing-declarations)" superClass="gnu.cpp.compiler.option.warnings.wmissingdecl" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wmissingincdir.185924875" name="User-supplied include directory does not exist (-Wmissing-include-dirs)" superClass="gnu.cpp.compiler.option.warnings.wmissingincdir" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wnoexccept.1878055190" name="Noexcept false but never throw exception (-Wnoexcept)" superClass="gnu.cpp.compiler.option.warnings.wnoexccept" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.woldstylecast.457648019" name="C-style cast used (-Wold-style-cast)" superClass="gnu.cpp.compiler.option.warnings.woldstylecast" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.woverloadedvirtual.1045946724" name="Function hides virtual functions from base class (-Woverloaded-virtual)" superClass="gnu.cpp.compiler.option.warnings.woverloadedvirtual" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wredundantdecl.1244798711" name="More than one declaration in the same scope (-Wredundant-decls)" superClass="gnu.cpp.compiler.option.warnings.wredundantdecl" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wshadow.369412473" name="Local symbol shadows upper scope symbol (-Wshadow)" superClass="gnu.cpp.compiler.option.warnings.wshadow" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wsignconv.2040300034" name="Implicit conversions that may change the sign (-Wsign-conversion)" superClass="gnu.cpp.compiler.option.warnings.wsignconv" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wsignpromo.1792401758" name="Overload resolution promotes unsigned to signed type (-Wsign-promo)" superClass="gnu.cpp.compiler.option.warnings.wsignpromo" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wstrictnullsent.1245260859" name="Use of an uncasted NULL as sentinel (-Wstrict-null-sentinel)" superClass="gnu.cpp.compiler.option.warnings.wstrictnullsent" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wswitchdef.694053113" name="A switch statement does not have a default case (-Wswitch-default)" superClass="gnu.cpp.compiler.option.warnings.wswitchdef" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wundef.1116691008" name="An undefined identifier is evaluated in an #if directive (-Wundef)" superClass="gnu.cpp.compiler.option.warnings.wundef" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.weffcpp.109401632" name="Effective C++ guidelines (-Weffc++)" superClass="gnu.cpp.compiler.option.warnings.weffcpp" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wfloatequal.571238280" name="Direct float equal check (-Wfloat-equal)" superClass="gnu.cpp.compiler.option.warnings.wfloatequal" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.other.other.952125919" name="Other flags" superClass="gnu.cpp.compiler.option.other.other" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.other.verbose.4338259" name="Verbose (-v)" superClass="gnu.cpp.compiler.option.other.verbose" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.other.pic.265101434" name="Position Independent Code (-fPIC)" superClass="gnu.cpp.compiler.option.other.pic" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.misc.hardening.63128023" name="Hardening options (-fstack-protector-all -Wformat=2 -Wformat-security -Wstrict-overflow)" superClass="gnu.cpp.compiler.option.misc.hardening" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.misc.randomization.2043577608" name="Address randomization (-fPIE)" superClass="gnu.cpp.compiler.option.misc.randomization" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.lto.536749997" name="Enable Link-time optimization (-flto)" superClass="com.crt.advproject.cpp.lto" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.lto.fat.1098699030" name="Fat lto objects (-ffat-lto-objects)" superClass="com.crt.advproject.cpp.lto.fat" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.merge.constants.718312606" name="Merge Identical Constants (-fmerge-constants)" superClass="com.crt.advproject.cpp.merge.constants" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.prefixmap.1538942862" name="Remove path from __FILE__ (-fmacro-prefix-map)" superClass="com.crt.advproject.cpp.prefixmap" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.fpu.1599015499" name="Floating point" superClass="com.crt.advproject.cpp.fpu" useByScannerDiscovery="true" value="com.crt.advproject.cpp.fpu.fpv5sp.hard" valueType="enumerated"/>
<option id="com.crt.advproject.cpp.thumb.1398251677" name="Thumb mode" superClass="com.crt.advproject.cpp.thumb" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.thumbinterwork.1124574259" name="Enable Thumb interworking" superClass="com.crt.advproject.cpp.thumbinterwork" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.securestate.1893575195" name="TrustZone Project Type" superClass="com.crt.advproject.cpp.securestate" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.hdrlib.300613759" name="Library headers" superClass="com.crt.advproject.cpp.hdrlib" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.stackusage.1114994285" name="Generate Stack Usage Info (-fstack-usage)" superClass="com.crt.advproject.cpp.stackusage" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.specs.1028195161" name="Specs" superClass="com.crt.advproject.cpp.specs" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.config.1358046381" name="Obsolete (Config)" superClass="com.crt.advproject.cpp.config" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.store.1238212737" name="Obsolete (Store)" superClass="com.crt.advproject.cpp.store" useByScannerDiscovery="false"/>
</tool>
<tool id="com.crt.advproject.gcc.exe.release.1164942886" name="MCU C Compiler" superClass="com.crt.advproject.gcc.exe.release">
<option id="com.crt.advproject.gcc.thumb.321216132" name="Thumb mode" superClass="com.crt.advproject.gcc.thumb" useByScannerDiscovery="false" value="true" valueType="boolean"/>
<option id="com.crt.advproject.gcc.arch.697820477" name="Architecture" superClass="com.crt.advproject.gcc.arch" useByScannerDiscovery="true" value="com.crt.advproject.gcc.target.cm33" valueType="enumerated"/>
<option id="com.crt.advproject.c.misc.dialect.1598236766" name="Language standard" superClass="com.crt.advproject.c.misc.dialect" useByScannerDiscovery="true"/>
<option id="gnu.c.compiler.option.dialect.flags.499501877" name="Other dialect flags" superClass="gnu.c.compiler.option.dialect.flags" useByScannerDiscovery="true"/>
<option id="gnu.c.compiler.option.preprocessor.nostdinc.1894186839" name="Do not search system directories (-nostdinc)" superClass="gnu.c.compiler.option.preprocessor.nostdinc" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.preprocessor.preprocess.1649307310" name="Preprocess only (-E)" superClass="gnu.c.compiler.option.preprocessor.preprocess" useByScannerDiscovery="false"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.compiler.option.preprocessor.def.symbols.1654504418" name="Defined symbols (-D)" superClass="gnu.c.compiler.option.preprocessor.def.symbols" useByScannerDiscovery="false" valueType="definedSymbols">
<listOptionValue builtIn="false" value="__REDLIB__"/>
<listOptionValue builtIn="false" value="WOLFSSL_USER_SETTINGS"/>
<listOptionValue builtIn="false" value="CPU_MIMXRT685SFVKB"/>
<listOptionValue builtIn="false" value="CPU_MIMXRT685SFVKB_cm33"/>
<listOptionValue builtIn="false" value="SDK_OS_BAREMETAL"/>
<listOptionValue builtIn="false" value="FSL_SDK_DRIVER_QUICK_ACCESS_ENABLE=1"/>
<listOptionValue builtIn="false" value="SDK_DEBUGCONSOLE=1"/>
<listOptionValue builtIn="false" value="PRINTF_FLOAT_ENABLE=1"/>
<listOptionValue builtIn="false" value="SDK_OS_FREE_RTOS"/>
<listOptionValue builtIn="false" value="SERIAL_PORT_TYPE_UART=1"/>
<listOptionValue builtIn="false" value="BOOT_HEADER_ENABLE=1"/>
<listOptionValue builtIn="false" value="__MCUXPRESSO"/>
<listOptionValue builtIn="false" value="__USE_CMSIS"/>
<listOptionValue builtIn="false" value="DEBUG"/>
</option>
<option id="gnu.c.compiler.option.preprocessor.undef.symbol.479511110" name="Undefined symbols (-U)" superClass="gnu.c.compiler.option.preprocessor.undef.symbol" useByScannerDiscovery="false"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.compiler.option.include.paths.1885085591" name="Include paths (-I)" superClass="gnu.c.compiler.option.include.paths" useByScannerDiscovery="false" valueType="includePath">
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/board}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/source/benchmark}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc}/../../&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/source}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/freertos/freertos_kernel/include}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/drivers}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/device}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/CMSIS}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/component/uart}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/utilities}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/component/serial_manager}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/flash_config}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/component/lists}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/freertos/freertos_kernel/portable/GCC/ARM_CM33_NTZ/non_secure}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/MIMXRT685S}&quot;"/>
</option>
<option id="gnu.c.compiler.option.include.files.154836193" name="Include files (-include)" superClass="gnu.c.compiler.option.include.files" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.optimization.flags.436259571" name="Other optimization flags" superClass="gnu.c.compiler.option.optimization.flags" useByScannerDiscovery="false" value="-fno-common" valueType="string"/>
<option id="gnu.c.compiler.option.debugging.other.1556613087" name="Other debugging flags" superClass="gnu.c.compiler.option.debugging.other" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.prof.160206055" name="Generate prof information (-p)" superClass="gnu.c.compiler.option.debugging.prof" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.gprof.1807507313" name="Generate gprof information (-pg)" superClass="gnu.c.compiler.option.debugging.gprof" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.codecov.742660834" name="Generate gcov information (-ftest-coverage -fprofile-arcs)" superClass="gnu.c.compiler.option.debugging.codecov" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.sanitaddress.355654396" name="Sanitize address (-fsanitize=address)" superClass="gnu.c.compiler.option.debugging.sanitaddress" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.sanitpointers.967164359" name="Sanitize pointer operations (-fsanitize=pointer-compare -fsanitize=pointer-subtract)" superClass="gnu.c.compiler.option.debugging.sanitpointers" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.sanitthread.351493737" name="Sanitize data race in multi-thread (-fsanitize=thread)" superClass="gnu.c.compiler.option.debugging.sanitthread" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.sanitleak.1516067298" name="Sanitize memory leak (-fsanitize=leak)" superClass="gnu.c.compiler.option.debugging.sanitleak" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.sanitundef.1986887722" name="Sanitize undefined behavior (-fsanitize=undefined)" superClass="gnu.c.compiler.option.debugging.sanitundef" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.syntax.476520514" name="Check syntax only (-fsyntax-only)" superClass="gnu.c.compiler.option.warnings.syntax" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.pedantic.1745181518" name="Pedantic (-pedantic)" superClass="gnu.c.compiler.option.warnings.pedantic" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.pedantic.error.1964786959" name="Pedantic warnings as errors (-pedantic-errors)" superClass="gnu.c.compiler.option.warnings.pedantic.error" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.nowarn.244979818" name="Inhibit all warnings (-w)" superClass="gnu.c.compiler.option.warnings.nowarn" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.allwarn.1831693389" name="All warnings (-Wall)" superClass="gnu.c.compiler.option.warnings.allwarn" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.extrawarn.1390571674" name="Extra warnings (-Wextra)" superClass="gnu.c.compiler.option.warnings.extrawarn" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.toerrors.1912041438" name="Warnings as errors (-Werror)" superClass="gnu.c.compiler.option.warnings.toerrors" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wconversion.115479045" name="Implicit conversion warnings (-Wconversion)" superClass="gnu.c.compiler.option.warnings.wconversion" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wcastalign.761219473" name="Pointer cast with different alignment (-Wcast-align)" superClass="gnu.c.compiler.option.warnings.wcastalign" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wcastqual.963206139" name="Removing type qualifier from cast target type (-Wcast-qual)" superClass="gnu.c.compiler.option.warnings.wcastqual" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wdisabledopt.869445852" name="Requested optimization pass is disabled (-Wdisabled-optimization)" superClass="gnu.c.compiler.option.warnings.wdisabledopt" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wlogicalop.1135115747" name="Suspicious uses of logical operators (-Wlogical-op)" superClass="gnu.c.compiler.option.warnings.wlogicalop" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wmissingdecl.1734363639" name="Global function without previous declaration (-Wmissing-declarations)" superClass="gnu.c.compiler.option.warnings.wmissingdecl" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wmissingincdir.1554160996" name="User-supplied include directory does not exist (-Wmissing-include-dirs)" superClass="gnu.c.compiler.option.warnings.wmissingincdir" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wredundantdecl.1694758444" name="More than one declaration in the same scope (-Wredundant-decls)" superClass="gnu.c.compiler.option.warnings.wredundantdecl" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wshadow.1533146979" name="Local symbol shadows upper scope symbol (-Wshadow)" superClass="gnu.c.compiler.option.warnings.wshadow" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wsignconv.416622348" name="Implicit conversions that may change the sign (-Wsign-conversion)" superClass="gnu.c.compiler.option.warnings.wsignconv" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wswitchdef.1751356714" name="A switch statement does not have a default case (-Wswitch-default)" superClass="gnu.c.compiler.option.warnings.wswitchdef" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wundef.1900048974" name="An undefined identifier is evaluated in an #if directive (-Wundef)" superClass="gnu.c.compiler.option.warnings.wundef" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wwritestrings.1223814403" name="Treat strings always as const (-Wwrite-strings)" superClass="gnu.c.compiler.option.warnings.wwritestrings" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wfloatequal.1609174937" name="Direct float equal check (-Wfloat-equal)" superClass="gnu.c.compiler.option.warnings.wfloatequal" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.misc.other.1308478342" name="Other flags" superClass="gnu.c.compiler.option.misc.other" useByScannerDiscovery="false" value="-c -ffunction-sections -fdata-sections -ffreestanding -fno-builtin" valueType="string"/>
<option id="gnu.c.compiler.option.misc.verbose.29064477" name="Verbose (-v)" superClass="gnu.c.compiler.option.misc.verbose" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.misc.ansi.1578324438" name="Support ANSI programs (-ansi)" superClass="gnu.c.compiler.option.misc.ansi" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.misc.pic.116473177" name="Position Independent Code (-fPIC)" superClass="gnu.c.compiler.option.misc.pic" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.misc.hardening.1089744398" name="Hardening options (-fstack-protector-all -Wformat=2 -Wformat-security -Wstrict-overflow)" superClass="gnu.c.compiler.option.misc.hardening" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.misc.randomization.483212188" name="Address randomization (-fPIE)" superClass="gnu.c.compiler.option.misc.randomization" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.lto.829713864" name="Enable Link-time optimization (-flto)" superClass="com.crt.advproject.gcc.lto" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.lto.fat.285192601" name="Fat lto objects (-ffat-lto-objects)" superClass="com.crt.advproject.gcc.lto.fat" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.merge.constants.1238831013" name="Merge Identical Constants (-fmerge-constants)" superClass="com.crt.advproject.gcc.merge.constants" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.prefixmap.868299909" name="Remove path from __FILE__ (-fmacro-prefix-map)" superClass="com.crt.advproject.gcc.prefixmap" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.fpu.1103915369" name="Floating point" superClass="com.crt.advproject.gcc.fpu" useByScannerDiscovery="true" value="com.crt.advproject.gcc.fpu.fpv5sp.hard" valueType="enumerated"/>
<option id="com.crt.advproject.gcc.thumbinterwork.476311046" name="Enable Thumb interworking" superClass="com.crt.advproject.gcc.thumbinterwork" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.securestate.312896928" name="TrustZone Project Type" superClass="com.crt.advproject.gcc.securestate" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.hdrlib.594636953" name="Library headers" superClass="com.crt.advproject.gcc.hdrlib" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.stackusage.1145137318" name="Generate Stack Usage Info (-fstack-usage)" superClass="com.crt.advproject.gcc.stackusage" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.specs.1782270310" name="Specs" superClass="com.crt.advproject.gcc.specs" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.config.192450418" name="Obsolete (Config)" superClass="com.crt.advproject.gcc.config" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.store.703648640" name="Obsolete (Store)" superClass="com.crt.advproject.gcc.store" useByScannerDiscovery="false"/>
<inputType id="com.crt.advproject.compiler.input.2094778942" superClass="com.crt.advproject.compiler.input"/>
</tool>
<tool id="com.crt.advproject.gas.exe.release.1218309413" name="MCU Assembler" superClass="com.crt.advproject.gas.exe.release">
<option id="com.crt.advproject.gas.thumb.1078790699" name="Thumb mode" superClass="com.crt.advproject.gas.thumb" value="true" valueType="boolean"/>
<option id="com.crt.advproject.gas.arch.344960874" name="Architecture" superClass="com.crt.advproject.gas.arch" value="com.crt.advproject.gas.target.cm33" valueType="enumerated"/>
<option id="gnu.both.asm.option.flags.crt.627319845" name="Assembler flags" superClass="gnu.both.asm.option.flags.crt" value="-c -x assembler-with-cpp -D__REDLIB__" valueType="string"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.both.asm.option.include.paths.2016655786" name="Include paths (-I)" superClass="gnu.both.asm.option.include.paths" valueType="includePath">
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/board}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/source}&quot;"/>
</option>
<option id="gnu.both.asm.option.warnings.nowarn.1087334326" name="Suppress warnings (-W)" superClass="gnu.both.asm.option.warnings.nowarn"/>
<option id="gnu.both.asm.option.version.2024505490" name="Announce version (-v)" superClass="gnu.both.asm.option.version"/>
<option id="com.crt.advproject.gas.fpu.570479878" name="Floating point" superClass="com.crt.advproject.gas.fpu" value="com.crt.advproject.gas.fpu.fpv5sp.hard" valueType="enumerated"/>
<option id="com.crt.advproject.gas.thumbinterwork.1567057513" name="Enable Thumb interworking" superClass="com.crt.advproject.gas.thumbinterwork"/>
<option id="com.crt.advproject.gas.hdrlib.533486674" name="Library headers" superClass="com.crt.advproject.gas.hdrlib"/>
<option id="com.crt.advproject.gas.specs.1619172759" name="Specs" superClass="com.crt.advproject.gas.specs"/>
<option id="com.crt.advproject.gas.config.1786181454" name="Obsolete (Config)" superClass="com.crt.advproject.gas.config"/>
<option id="com.crt.advproject.gas.store.65900240" name="Obsolete (Store)" superClass="com.crt.advproject.gas.store"/>
<inputType id="cdt.managedbuild.tool.gnu.assembler.input.1837614781" superClass="cdt.managedbuild.tool.gnu.assembler.input"/>
<inputType id="com.crt.advproject.assembler.input.238072700" name="Additional Assembly Source Files" superClass="com.crt.advproject.assembler.input"/>
</tool>
<tool id="com.crt.advproject.link.cpp.exe.release.664758455" name="MCU C++ Linker" superClass="com.crt.advproject.link.cpp.exe.release">
<option id="com.crt.advproject.link.cpp.arch.2049709521" name="Architecture" superClass="com.crt.advproject.link.cpp.arch" value="com.crt.advproject.link.cpp.target.cm33" valueType="enumerated"/>
<option id="gnu.cpp.link.option.nostart.1854221575" name="Do not use standard start files (-nostartfiles)" superClass="gnu.cpp.link.option.nostart"/>
<option id="gnu.cpp.link.option.nodeflibs.2129253795" name="Do not use default libraries (-nodefaultlibs)" superClass="gnu.cpp.link.option.nodeflibs"/>
<option id="gnu.cpp.link.option.nostdlibs.1045415602" name="No startup or default libs (-nostdlib)" superClass="gnu.cpp.link.option.nostdlibs" value="true" valueType="boolean"/>
<option id="gnu.cpp.link.option.strip.2085021142" name="Omit all symbol information (-s)" superClass="gnu.cpp.link.option.strip"/>
<option id="gnu.cpp.link.option.libs.1491771172" name="Libraries (-l)" superClass="gnu.cpp.link.option.libs"/>
<option id="gnu.cpp.link.option.paths.943240560" name="Library search path (-L)" superClass="gnu.cpp.link.option.paths"/>
<option id="gnu.cpp.link.option.flags.562921366" name="Linker flags" superClass="gnu.cpp.link.option.flags"/>
<option id="gnu.cpp.link.option.other.1707864033" name="Other options (-Xlinker [option])" superClass="gnu.cpp.link.option.other"/>
<option id="gnu.cpp.link.option.userobjs.1542391113" name="Other objects" superClass="gnu.cpp.link.option.userobjs"/>
<option id="gnu.cpp.link.option.shared.889655587" name="Shared (-shared)" superClass="gnu.cpp.link.option.shared"/>
<option id="gnu.cpp.link.option.soname.1040407234" name="Shared object name (-Wl,-soname=)" superClass="gnu.cpp.link.option.soname"/>
<option id="gnu.cpp.link.option.implname.115930837" name="Import Library name (-Wl,--out-implib=)" superClass="gnu.cpp.link.option.implname"/>
<option id="gnu.cpp.link.option.defname.686518254" name="DEF file name (-Wl,--output-def=)" superClass="gnu.cpp.link.option.defname"/>
<option id="gnu.cpp.link.option.debugging.prof.1986614868" name="Generate prof information (-p)" superClass="gnu.cpp.link.option.debugging.prof"/>
<option id="gnu.cpp.link.option.debugging.gprof.935822311" name="Generate gprof information (-pg)" superClass="gnu.cpp.link.option.debugging.gprof"/>
<option id="gnu.cpp.link.option.debugging.codecov.1834499418" name="Generate gcov information (-ftest-coverage -fprofile-arcs)" superClass="gnu.cpp.link.option.debugging.codecov"/>
<option id="com.crt.advproject.link.cpp.lto.488943705" name="Enable Link-time optimization (-flto)" superClass="com.crt.advproject.link.cpp.lto"/>
<option id="com.crt.advproject.link.cpp.lto.optmization.level.1850819563" name="Link-time optimization level" superClass="com.crt.advproject.link.cpp.lto.optmization.level"/>
<option id="com.crt.advproject.link.cpp.fpu.1159606868" name="Floating point" superClass="com.crt.advproject.link.cpp.fpu" value="com.crt.advproject.link.cpp.fpu.fpv5sp.hard" valueType="enumerated"/>
<option id="com.crt.advproject.link.cpp.thumb.468284214" name="Thumb mode" superClass="com.crt.advproject.link.cpp.thumb"/>
<option id="com.crt.advproject.link.cpp.manage.1337653797" name="Manage linker script" superClass="com.crt.advproject.link.cpp.manage"/>
<option id="com.crt.advproject.link.cpp.script.496883915" name="Linker script" superClass="com.crt.advproject.link.cpp.script"/>
<option id="com.crt.advproject.link.cpp.scriptdir.121988691" name="Script path" superClass="com.crt.advproject.link.cpp.scriptdir"/>
<option id="com.crt.advproject.link.cpp.crpenable.1776809668" name="Enable automatic placement of Code Read Protection field in image" superClass="com.crt.advproject.link.cpp.crpenable"/>
<option id="com.crt.advproject.link.cpp.flashconfigenable.791633804" name="Enable automatic placement of Flash Configuration field in image" superClass="com.crt.advproject.link.cpp.flashconfigenable" value="true" valueType="boolean"/>
<option id="com.crt.advproject.link.cpp.ecrp.662136864" name="Enhanced CRP" superClass="com.crt.advproject.link.cpp.ecrp"/>
<option id="com.crt.advproject.link.cpp.hdrlib.734534729" name="Library" superClass="com.crt.advproject.link.cpp.hdrlib"/>
<option id="com.crt.advproject.link.cpp.nanofloat.755003074" name="Enable printf float " superClass="com.crt.advproject.link.cpp.nanofloat"/>
<option id="com.crt.advproject.link.cpp.nanofloat.scanf.1515853069" name="Enable scanf float " superClass="com.crt.advproject.link.cpp.nanofloat.scanf"/>
<option id="com.crt.advproject.link.cpp.toram.1889267342" name="Link application to RAM" superClass="com.crt.advproject.link.cpp.toram"/>
<option id="com.crt.advproject.link.memory.load.image.cpp.1434521191" name="Plain load image" superClass="com.crt.advproject.link.memory.load.image.cpp"/>
<option id="com.crt.advproject.link.memory.heapAndStack.style.cpp.303868326" name="Heap and Stack placement" superClass="com.crt.advproject.link.memory.heapAndStack.style.cpp"/>
<option id="com.crt.advproject.link.cpp.stackOffset.1714700654" name="Stack offset" superClass="com.crt.advproject.link.cpp.stackOffset"/>
<option id="com.crt.advproject.link.memory.heapAndStack.cpp.587618362" name="Heap and Stack options" superClass="com.crt.advproject.link.memory.heapAndStack.cpp"/>
<option id="com.crt.advproject.link.memory.data.cpp.1797281296" name="Global data placement" superClass="com.crt.advproject.link.memory.data.cpp"/>
<option id="com.crt.advproject.link.memory.sections.cpp.1386617342" name="Extra linker script input sections" superClass="com.crt.advproject.link.memory.sections.cpp"/>
<option id="com.crt.advproject.link.cpp.multicore.slave.1416533504" name="Multicore configuration" superClass="com.crt.advproject.link.cpp.multicore.slave"/>
<option id="com.crt.advproject.link.cpp.multicore.master.952104188" name="Multicore master" superClass="com.crt.advproject.link.cpp.multicore.master"/>
<option id="com.crt.advproject.link.cpp.multicore.empty.502395422" name="No Multicore options for this project" superClass="com.crt.advproject.link.cpp.multicore.empty"/>
<option id="com.crt.advproject.link.cpp.multicore.master.userobjs.990891310" name="Slave Objects (not visible)" superClass="com.crt.advproject.link.cpp.multicore.master.userobjs"/>
<option id="com.crt.advproject.link.cpp.config.304675351" name="Obsolete (Config)" superClass="com.crt.advproject.link.cpp.config"/>
<option id="com.crt.advproject.link.cpp.store.1582990404" name="Obsolete (Store)" superClass="com.crt.advproject.link.cpp.store"/>
<option id="com.crt.advproject.link.cpp.securestate.1213205319" name="TrustZone Project Type" superClass="com.crt.advproject.link.cpp.securestate"/>
<option id="com.crt.advproject.link.cpp.sgstubs.placement.1044446956" name="Secure Gateway Placement" superClass="com.crt.advproject.link.cpp.sgstubs.placement"/>
<option id="com.crt.advproject.link.cpp.sgstubenable.743753967" name="Enable generation of Secure Gateway Import Library" superClass="com.crt.advproject.link.cpp.sgstubenable"/>
<option id="com.crt.advproject.link.cpp.nonsecureobject.346021936" name="Secure Gateway Import Library" superClass="com.crt.advproject.link.cpp.nonsecureobject"/>
<option id="com.crt.advproject.link.cpp.inimplib.328852368" name="Input Secure Gateway Import Library" superClass="com.crt.advproject.link.cpp.inimplib"/>
</tool>
<tool id="com.crt.advproject.link.exe.release.1651007219" name="MCU Linker" superClass="com.crt.advproject.link.exe.release">
<option id="com.crt.advproject.link.thumb.674200067" name="Thumb mode" superClass="com.crt.advproject.link.thumb" value="true" valueType="boolean"/>
<option id="com.crt.advproject.link.memory.load.image.748639352" name="Plain load image" superClass="com.crt.advproject.link.memory.load.image" useByScannerDiscovery="false" value="" valueType="string"/>
<option defaultValue="com.crt.advproject.heapAndStack.mcuXpressoStyle" id="com.crt.advproject.link.memory.heapAndStack.style.1541882987" name="Heap and Stack placement" superClass="com.crt.advproject.link.memory.heapAndStack.style" useByScannerDiscovery="false" valueType="enumerated"/>
<option id="com.crt.advproject.link.memory.heapAndStack.331391178" name="Heap and Stack options" superClass="com.crt.advproject.link.memory.heapAndStack" value="&amp;Heap:Default;Post Data;Default&amp;Stack:Default;End;Default" valueType="string"/>
<option id="com.crt.advproject.link.memory.data.614122846" name="Global data placement" superClass="com.crt.advproject.link.memory.data" useByScannerDiscovery="false" value="" valueType="string"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="true" id="com.crt.advproject.link.memory.sections.1349184007" name="Extra linker script input sections" superClass="com.crt.advproject.link.memory.sections" useByScannerDiscovery="false" valueType="stringList"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="true" id="com.crt.advproject.link.gcc.multicore.master.userobjs.324483899" name="Slave Objects (not visible)" superClass="com.crt.advproject.link.gcc.multicore.master.userobjs" useByScannerDiscovery="false" valueType="userObjs"/>
<option id="com.crt.advproject.link.gcc.multicore.slave.1112380836" name="Multicore configuration" superClass="com.crt.advproject.link.gcc.multicore.slave"/>
<option id="com.crt.advproject.link.arch.605600414" name="Architecture" superClass="com.crt.advproject.link.arch" value="com.crt.advproject.link.target.cm33" valueType="enumerated"/>
<option id="gnu.c.link.option.nostart.56815767" name="Do not use standard start files (-nostartfiles)" superClass="gnu.c.link.option.nostart"/>
<option id="gnu.c.link.option.nodeflibs.633342517" name="Do not use default libraries (-nodefaultlibs)" superClass="gnu.c.link.option.nodeflibs"/>
<option id="gnu.c.link.option.nostdlibs.2097209296" name="No startup or default libs (-nostdlib)" superClass="gnu.c.link.option.nostdlibs" value="true" valueType="boolean"/>
<option id="gnu.c.link.option.strip.1253077547" name="Omit all symbol information (-s)" superClass="gnu.c.link.option.strip"/>
<option id="gnu.c.link.option.noshared.2014015778" name="No shared libraries (-static)" superClass="gnu.c.link.option.noshared"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.link.option.libs.2048891017" name="Libraries (-l)" superClass="gnu.c.link.option.libs" useByScannerDiscovery="false" valueType="libs">
<listOptionValue builtIn="false" value="wolfssl"/>
</option>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.link.option.paths.962540792" name="Library search path (-L)" superClass="gnu.c.link.option.paths" useByScannerDiscovery="false" valueType="libPaths">
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/wolfssl/Release}&quot;"/>
</option>
<option id="gnu.c.link.option.ldflags.1814692022" name="Linker flags" superClass="gnu.c.link.option.ldflags"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.link.option.other.1777758913" name="Other options (-Xlinker [option])" superClass="gnu.c.link.option.other" valueType="stringList">
<listOptionValue builtIn="false" value="-Map=&quot;${BuildArtifactFileBaseName}.map&quot;"/>
<listOptionValue builtIn="false" value="--gc-sections"/>
<listOptionValue builtIn="false" value="-print-memory-usage"/>
<listOptionValue builtIn="false" value="--sort-section=alignment"/>
<listOptionValue builtIn="false" value="--cref"/>
</option>
<option id="gnu.c.link.option.userobjs.2073841151" name="Other objects" superClass="gnu.c.link.option.userobjs"/>
<option id="gnu.c.link.option.shared.775749252" name="Shared (-shared)" superClass="gnu.c.link.option.shared"/>
<option id="gnu.c.link.option.soname.1157749749" name="Shared object name (-Wl,-soname=)" superClass="gnu.c.link.option.soname"/>
<option id="gnu.c.link.option.implname.924195864" name="Import Library name (-Wl,--out-implib=)" superClass="gnu.c.link.option.implname"/>
<option id="gnu.c.link.option.defname.437084788" name="DEF file name (-Wl,--output-def=)" superClass="gnu.c.link.option.defname"/>
<option id="gnu.c.link.option.debugging.prof.1790660740" name="Generate prof information (-p)" superClass="gnu.c.link.option.debugging.prof"/>
<option id="gnu.c.link.option.debugging.gprof.2087285402" name="Generate gprof information (-pg)" superClass="gnu.c.link.option.debugging.gprof"/>
<option id="gnu.c.link.option.debugging.codecov.1966819755" name="Generate gcov information (-ftest-coverage -fprofile-arcs)" superClass="gnu.c.link.option.debugging.codecov"/>
<option id="com.crt.advproject.link.gcc.lto.1485599352" name="Enable Link-time optimization (-flto)" superClass="com.crt.advproject.link.gcc.lto"/>
<option id="com.crt.advproject.link.gcc.lto.optmization.level.536032995" name="Link-time optimization level" superClass="com.crt.advproject.link.gcc.lto.optmization.level"/>
<option id="com.crt.advproject.link.fpu.1355401075" name="Floating point" superClass="com.crt.advproject.link.fpu" value="com.crt.advproject.link.fpu.fpv5sp.hard" valueType="enumerated"/>
<option id="com.crt.advproject.link.manage.2031658844" name="Manage linker script" superClass="com.crt.advproject.link.manage" value="true" valueType="boolean"/>
<option id="com.crt.advproject.link.script.1155784725" name="Linker script" superClass="com.crt.advproject.link.script" value="benchmark_Release.ld" valueType="string"/>
<option id="com.crt.advproject.link.scriptdir.2146582881" name="Script path" superClass="com.crt.advproject.link.scriptdir"/>
<option id="com.crt.advproject.link.crpenable.1402901021" name="Enable automatic placement of Code Read Protection field in image" superClass="com.crt.advproject.link.crpenable"/>
<option id="com.crt.advproject.link.flashconfigenable.849305138" name="Enable automatic placement of Flash Configuration field in image" superClass="com.crt.advproject.link.flashconfigenable" value="true" valueType="boolean"/>
<option id="com.crt.advproject.link.ecrp.936568644" name="Enhanced CRP" superClass="com.crt.advproject.link.ecrp"/>
<option id="com.crt.advproject.link.gcc.hdrlib.1001828163" name="Library" superClass="com.crt.advproject.link.gcc.hdrlib" value="com.crt.advproject.gcc.link.hdrlib.codered.nohost_nf" valueType="enumerated"/>
<option id="com.crt.advproject.link.gcc.nanofloat.1417324767" name="Enable printf float " superClass="com.crt.advproject.link.gcc.nanofloat"/>
<option id="com.crt.advproject.link.gcc.nanofloat.scanf.760371803" name="Enable scanf float " superClass="com.crt.advproject.link.gcc.nanofloat.scanf"/>
<option id="com.crt.advproject.link.toram.853932638" name="Link application to RAM" superClass="com.crt.advproject.link.toram"/>
<option id="com.crt.advproject.link.stackOffset.594554018" name="Stack offset" superClass="com.crt.advproject.link.stackOffset"/>
<option id="com.crt.advproject.link.gcc.multicore.master.417747993" name="Multicore master" superClass="com.crt.advproject.link.gcc.multicore.master"/>
<option id="com.crt.advproject.link.gcc.multicore.empty.1635347828" name="No Multicore options for this project" superClass="com.crt.advproject.link.gcc.multicore.empty"/>
<option id="com.crt.advproject.link.config.1975101795" name="Obsolete (Config)" superClass="com.crt.advproject.link.config"/>
<option id="com.crt.advproject.link.store.2028642712" name="Obsolete (Store)" superClass="com.crt.advproject.link.store"/>
<option id="com.crt.advproject.link.securestate.1092465849" name="TrustZone Project Type" superClass="com.crt.advproject.link.securestate"/>
<option id="com.crt.advproject.link.sgstubs.placement.1846685434" name="Secure Gateway Placement" superClass="com.crt.advproject.link.sgstubs.placement"/>
<option id="com.crt.advproject.link.sgstubenable.285713530" name="Enable generation of Secure Gateway Import Library" superClass="com.crt.advproject.link.sgstubenable"/>
<option id="com.crt.advproject.link.nonsecureobject.2085457042" name="Secure Gateway Import Library" superClass="com.crt.advproject.link.nonsecureobject"/>
<option id="com.crt.advproject.link.inimplib.429203980" name="Input Secure Gateway Import Library" superClass="com.crt.advproject.link.inimplib"/>
<inputType id="cdt.managedbuild.tool.gnu.c.linker.input.149039172" superClass="cdt.managedbuild.tool.gnu.c.linker.input">
<additionalInput kind="additionalinputdependency" paths="$(USER_OBJS)"/>
<additionalInput kind="additionalinput" paths="$(LIBS)"/>
</inputType>
</tool>
<tool id="com.crt.advproject.tool.debug.release.465740891" name="MCU Debugger" superClass="com.crt.advproject.tool.debug.release">
<option id="com.crt.advproject.miscellaneous.end_of_heap.902679891" name="Last used address of the heap" superClass="com.crt.advproject.miscellaneous.end_of_heap"/>
<option id="com.crt.advproject.miscellaneous.pvHeapStart.530261686" name="First address of the heap" superClass="com.crt.advproject.miscellaneous.pvHeapStart"/>
<option id="com.crt.advproject.miscellaneous.pvHeapLimit.1858139259" name="Maximum extent of heap" superClass="com.crt.advproject.miscellaneous.pvHeapLimit"/>
<option id="com.crt.advproject.debugger.security.nonsecureimageenable.194966293" name="Enable pre-programming of Non-Secure Image" superClass="com.crt.advproject.debugger.security.nonsecureimageenable"/>
<option id="com.crt.advproject.debugger.security.nonsecureimage.1845332051" name="Non-Secure Project" superClass="com.crt.advproject.debugger.security.nonsecureimage"/>
</tool>
</toolChain>
</folderInfo>
<sourceEntries>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="component"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="CMSIS"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="MIMXRT685S"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="source"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="utilities"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="drivers"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="device"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="board"/>
<entry excluding="freertos_kernel/portable/MemMang/heap_1.c|freertos_kernel/portable/MemMang/heap_2.c|freertos_kernel/portable/MemMang/heap_3.c|freertos_kernel/portable/MemMang/heap_5.c" flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="freertos"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="flash_config"/>
</sourceEntries>
</configuration>
</storageModule>
<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
</cconfiguration>
</storageModule>
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
<project id="benchmark.null.393927314" name="benchmark" projectType="com.crt.advproject.projecttype.exe"/>
</storageModule>
<storageModule moduleId="scannerConfiguration">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
<scannerConfigBuildInfo instanceId="com.crt.advproject.config.exe.debug.1655056797;com.crt.advproject.config.exe.debug.1655056797.;com.crt.advproject.gcc.exe.debug.1638968152;com.crt.advproject.compiler.input.1066742766">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
</scannerConfigBuildInfo>
<scannerConfigBuildInfo instanceId="com.crt.advproject.config.exe.debug.1655056797;com.crt.advproject.config.exe.debug.1655056797.;com.crt.advproject.gas.exe.debug.1830211151;com.crt.advproject.assembler.input.803991339">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
</scannerConfigBuildInfo>
<scannerConfigBuildInfo instanceId="com.crt.advproject.config.exe.release.1666559984;com.crt.advproject.config.exe.release.1666559984.;com.crt.advproject.gcc.exe.release.1164942886;com.crt.advproject.compiler.input.2094778942">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
</scannerConfigBuildInfo>
<scannerConfigBuildInfo instanceId="com.crt.advproject.config.exe.release.1666559984;com.crt.advproject.config.exe.release.1666559984.;com.crt.advproject.gas.exe.release.1218309413;com.crt.advproject.assembler.input.238072700">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
</scannerConfigBuildInfo>
</storageModule>
<storageModule moduleId="org.eclipse.cdt.core.LanguageSettingsProviders"/>
<storageModule moduleId="com.nxp.mcuxpresso.core.datamodels">
<sdkName>SDK_2.x_EVK-MIMXRT685</sdkName>
<sdkVersion>2.12.0</sdkVersion>
<sdkComponents>middleware.freertos-kernel.MIMXRT685S;platform.drivers.lpc_iopctl.MIMXRT685S;platform.drivers.flexspi.MIMXRT685S;platform.drivers.cache_cache64.MIMXRT685S;platform.drivers.power.MIMXRT685S;platform.drivers.common.MIMXRT685S;platform.drivers.flexcomm_usart.MIMXRT685S;platform.drivers.lpc_gpio.MIMXRT685S;platform.drivers.clock.MIMXRT685S;platform.drivers.flexcomm.MIMXRT685S;platform.drivers.reset.MIMXRT685S;platform.drivers.trng.MIMXRT685S;platform.drivers.lpc_rtc.MIMXRT685S;device.MIMXRT685S_CMSIS.MIMXRT685S;CMSIS_Include_core_cm.MIMXRT685S;component.usart_adapter.MIMXRT685S;utility.debug_console.MIMXRT685S;component.serial_manager.MIMXRT685S;component.serial_manager_uart.MIMXRT685S;platform.utilities.assert.MIMXRT685S;platform.drivers.flash_config.evkmimxrt685.MIMXRT685S;component.lists.MIMXRT685S;project_template.evkmimxrt685.MIMXRT685S;middleware.freertos-kernel.template.MIMXRT685S;device.MIMXRT685S_startup.MIMXRT685S;middleware.freertos-kernel.extension.MIMXRT685S;</sdkComponents>
<boardId>evkmimxrt685</boardId>
<package>MIMXRT685SFVKB</package>
<core>cm33</core>
<coreId>cm33_MIMXRT685S</coreId>
</storageModule>
<storageModule moduleId="com.crt.config">
<projectStorage>&lt;?xml version="1.0" encoding="UTF-8"?&gt;&#13;
&lt;TargetConfig&gt;&#13;
&lt;Properties property_3="NXP" property_4="MIMXRT685S" property_count="5" version="100300"/&gt;&#13;
&lt;infoList vendor="NXP"&gt;&#13;
&lt;info chip="MIMXRT685S" name="MIMXRT685S"&gt;&#13;
&lt;chip&gt;&#13;
&lt;name&gt;MIMXRT685S&lt;/name&gt;&#13;
&lt;family&gt;MIMXRT600&lt;/family&gt;&#13;
&lt;vendor&gt;NXP&lt;/vendor&gt;&#13;
&lt;memory can_program="true" id="Flash" is_ro="true" size="0" type="Flash"/&gt;&#13;
&lt;memory id="RAM" size="4608" type="RAM"/&gt;&#13;
&lt;memoryInstance derived_from="Flash" driver="MIMXRT600_FlexSPI_B_MXIC_OPI.cfx" edited="true" id="QSPI_FLASH" location="0x8000000" size="0x800000"/&gt;&#13;
&lt;memoryInstance derived_from="RAM" edited="true" id="SRAM" location="0x80000" size="0x180000"/&gt;&#13;
&lt;memoryInstance derived_from="RAM" edited="true" id="SRAM_ROM" location="0x0" size="0x20000"/&gt;&#13;
&lt;memoryInstance derived_from="RAM" edited="true" id="SRAM_SHARED" location="0x20000" size="0x60000"/&gt;&#13;
&lt;memoryInstance derived_from="RAM" edited="true" id="SRAM_DSP" location="0x200000" size="0x280000"/&gt;&#13;
&lt;memoryInstance derived_from="RAM" edited="true" id="USB_RAM" location="0x40140000" size="0x4000"/&gt;&#13;
&lt;/chip&gt;&#13;
&lt;processor&gt;&#13;
&lt;name gcc_name="cortex-m33"&gt;Cortex-M33&lt;/name&gt;&#13;
&lt;family&gt;Cortex-M&lt;/family&gt;&#13;
&lt;/processor&gt;&#13;
&lt;/info&gt;&#13;
&lt;/infoList&gt;&#13;
&lt;/TargetConfig&gt;</projectStorage>
</storageModule>
<storageModule moduleId="org.eclipse.cdt.make.core.buildtargets"/>
<storageModule moduleId="refreshScope"/>
</cproject>

View File

@ -0,0 +1,34 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>benchmark</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.cdt.managedbuilder.core.genmakebuilder</name>
<triggers>clean,full,incremental,</triggers>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>org.eclipse.cdt.managedbuilder.core.ScannerConfigBuilder</name>
<triggers>full,incremental,</triggers>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.cdt.core.cnature</nature>
<nature>com.nxp.mcuxpresso.core.datamodels.sdkNature</nature>
<nature>org.eclipse.cdt.managedbuilder.core.managedBuildNature</nature>
<nature>org.eclipse.cdt.managedbuilder.core.ScannerConfigNature</nature>
</natures>
<linkedResources>
<link>
<name>source/benchmark</name>
<type>2</type>
<locationURI>$%7BPARENT-3-PROJECT_LOC%7D/wolfcrypt/benchmark</locationURI>
</link>
</linkedResources>
</projectDescription>

View File

@ -0,0 +1,107 @@
/* run_benchmark.c
*
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
* wolfSSL is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* wolfSSL is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
*/
#include <stdio.h>
#include "board.h"
#include "fsl_rtc.h"
#include "fsl_trng.h"
#include "FreeRTOS.h"
#include "task.h"
#include "peripherals.h"
#include "pin_mux.h"
#include "clock_config.h"
#include "MIMXRT685S_cm33.h"
#include "fsl_debug_console.h"
#include <wolfssl/wolfcrypt/wc_port.h>
#include "benchmark.h"
#define STACK_DEPTH 60000
/* start the RTC and TRNG */
static void setup()
{
rtc_datetime_t date;
trng_config_t trngConfig;
status_t status;
RTC_Init(RTC);
/* setup a default start date */
date.year = 2022U;
date.month = 8U;
date.day = 17U;
date.hour = 15U;
date.minute = 10;
date.second = 0;
RTC_EnableTimer(RTC, false);
RTC_SetDatetime(RTC, &date);
RTC_EnableTimer(RTC, true);
TRNG_GetDefaultConfig(&trngConfig);
/* Commented in example NXP TRNG as an optional, better random mode */
trngConfig.sampleMode = kTRNG_SampleModeVonNeumann;
/* Initialize TRNG */
status = TRNG_Init(TRNG0, &trngConfig);
if (status != kStatus_Success) {
PRINTF("Issues starting TRNG\n");
}
}
static void doBenchmark(void* params)
{
int ret;
/* initialize wolfCrypt and run tests */
if (wolfCrypt_Init() == 0) {
ret = benchmark_test(NULL);
PRINTF("Return of benchmark_test = %d\r\n", ret);
wolfCrypt_Cleanup();
}
else {
PRINTF("Failied to initialize wolfCrypt\r\n");
}
}
int main(void)
{
TaskHandle_t b = NULL;
/* Init board hardware. */
BOARD_InitBootPins();
BOARD_InitBootClocks();
BOARD_InitBootPeripherals();
#ifndef BOARD_INIT_DEBUG_CONSOLE_PERIPHERAL
/* Init FSL debug console. */
BOARD_InitDebugConsole();
#endif
setup(); /* set the RTC and start the TRNG */
if (xTaskCreate(doBenchmark, "wolfSSL Benchmark", STACK_DEPTH, NULL,
0, &b) != pdPASS) {
PRINTF("Error creating benchmark task\r\n");
}
vTaskStartScheduler();
TRNG_Deinit(TRNG0);
vTaskDelete(b);
return 0 ;
}

View File

@ -0,0 +1,18 @@
# vim:ft=automake
# included from Top Level Makefile.am
# All paths should be given relative to the root
EXTRA_DIST += IDE/MCUEXPRESSO/wolfssl/.cproject
EXTRA_DIST += IDE/MCUEXPRESSO/wolfssl/.project
EXTRA_DIST += IDE/MCUEXPRESSO/wolfssl/.settings
EXTRA_DIST += IDE/MCUEXPRESSO/wolfssl/liblinks.xml
EXTRA_DIST += IDE/MCUEXPRESSO/wolfcrypt_test/.cproject
EXTRA_DIST += IDE/MCUEXPRESSO/wolfcrypt_test/.project
EXTRA_DIST += IDE/MCUEXPRESSO/wolfcrypt_test/source/wolfcrypt_test.c
EXTRA_DIST += IDE/MCUEXPRESSO/benchmark/.cproject
EXTRA_DIST += IDE/MCUEXPRESSO/benchmark/.project
EXTRA_DIST += IDE/MCUEXPRESSO/benchmark/source/run_benchmark.c
EXTRA_DIST += IDE/MCUEXPRESSO/user_settings.h

View File

@ -0,0 +1,122 @@
/* user_settings.h
*
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
* wolfSSL is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* wolfSSL is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
*/
#ifndef USER_SETTINGS_H_
#define USER_SETTINGS_H_
#define FREERTOS
#define NO_WOLFSSL_DIR
#define WOLFSSL_NO_SOCK
#define WOLFSSL_LWIP
#define WOLFSSL_USER_IO
#define DEBUG_WOLFSSL
#define WOLFSSL_LOG_PRINTF
/* macros for test suite and benchmark */
//#define NO_CRYPT_TEST
#ifndef NO_CRYPT_TEST
#define NO_MAIN_DRIVER
#include <stdio.h>
#include <stdarg.h>
static void myPrintf(const char* fmt, ...)
{
int ret;
char line[150];
va_list ap;
va_start(ap, fmt);
ret = vsnprintf(line, sizeof(line), fmt, ap);
line[sizeof(line)-1] = '\0';
DbgConsole_Printf("%s", line);
/* add CR on newlines */
if (ret > 0 && line[ret-1] == '\n') {
DbgConsole_Printf("\r");
}
}
#define XPRINTF myPrintf
#define USE_CERT_BUFFERS_2048
#define USE_CERT_BUFFERS_1024
#define USE_CERT_BUFFERS_256
#define NO_WRITE_TEMP_FILES
#define BENCH_EMBEDDED
/* set high for handling wolfcrypt tests */
#define WOLFSSL_STATIC_MEMORY_TEST_SZ 350000
#endif
/* math implementation (fast math or sp math, choose one) */
#define USE_FAST_MATH
#ifdef USE_FAST_MATH
/* big enough for even 4096 bit RSA key */
#define FP_MAX_BITS 8192
#define TFM_TIMING_RESISTANT
#define ECC_TIMING_RESISTANT
#define ALT_ECC_SIZE
#endif
//#define WOLFSSL_SP_MATH_ALL
#ifdef WOLFSSL_SP_MATH_ALL
#endif
/* optimizations for common public key operations
* adds a lot of code size in exchange for performance increase */
#if 1
#define WOLFSSL_HAVE_SP_RSA
#define WOLFSSL_HAVE_SP_DH
#define WOLFSSL_HAVE_SP_ECC
#endif
/* RT685 uses the same fsl_trng API, note that the application
* needs to initialize and teardown the TRNG (TRNG_Init, TRNG_Deinit) */
#define FREESCALE_KSDK_2_0_TRNG
#define FREESCALE_RTC
/* use loaded stack as a pool of memory for allocations rather than
* using heap */
#define WOLFSSL_STATIC_MEMORY
#define WOLFSSL_SP_NO_MALLOC /* use no malloc version of SP if compiled in */
#define WOLFSSL_NO_REALLOC
/* this removes all system malloc calls, will fail on some compatibility
* layer API's and others that have no heap hint */
//#define WOLFSSL_NO_MALLOC
#define WC_RSA_BLINDING
#define HAVE_ECC
#define OPENSSL_EXTRA
#define OPENSSL_ALL
#define NO_WOLFSSL_SERVER
#define HAVE_TLS_EXTENSIONS
#define WC_RSA_PSS
#define WOLFSSL_KEY_GEN
#define HAVE_SMIME
#ifdef HAVE_SMIME
#define HAVE_PKCS7
#define HAVE_X963_KDF
#define HAVE_AES_KEYWRAP
#define WOLFSSL_AES_DIRECT
#endif
#endif /* USER_SETTINGS_H_ */

View File

@ -0,0 +1,800 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<?fileVersion 4.0.0?><cproject storage_type_id="org.eclipse.cdt.core.XmlProjectDescriptionStorage">
<storageModule moduleId="org.eclipse.cdt.core.settings">
<cconfiguration id="com.crt.advproject.config.exe.debug.468012101">
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="com.crt.advproject.config.exe.debug.468012101" moduleId="org.eclipse.cdt.core.settings" name="Debug">
<externalSettings/>
<extensions>
<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
<extension id="org.eclipse.cdt.core.GNU_ELF" point="org.eclipse.cdt.core.BinaryParser"/>
<extension id="org.eclipse.cdt.core.GmakeErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GASErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GLDErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.CWDLocator" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GCCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
</extensions>
</storageModule>
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
<configuration artifactExtension="axf" artifactName="${ProjName}" buildArtefactType="org.eclipse.cdt.build.core.buildArtefactType.exe" buildProperties="org.eclipse.cdt.build.core.buildArtefactType=org.eclipse.cdt.build.core.buildArtefactType.exe" cleanCommand="rm -rf" description="Debug build" errorParsers="org.eclipse.cdt.core.CWDLocator;org.eclipse.cdt.core.GmakeErrorParser;org.eclipse.cdt.core.GCCErrorParser;org.eclipse.cdt.core.GLDErrorParser;org.eclipse.cdt.core.GASErrorParser" id="com.crt.advproject.config.exe.debug.468012101" name="Debug" parent="com.crt.advproject.config.exe.debug" postannouncebuildStep="Performing post-build steps" postbuildStep="arm-none-eabi-size &quot;${BuildArtifactFileName}&quot;; # arm-none-eabi-objcopy -v -O binary &quot;${BuildArtifactFileName}&quot; &quot;${BuildArtifactFileBaseName}.bin&quot; ; # checksum -p ${TargetChip} -d &quot;${BuildArtifactFileBaseName}.bin&quot;; ">
<folderInfo id="com.crt.advproject.config.exe.debug.468012101." name="/" resourcePath="">
<toolChain id="com.crt.advproject.toolchain.exe.debug.67037189" name="NXP MCU Tools" superClass="com.crt.advproject.toolchain.exe.debug">
<targetPlatform binaryParser="org.eclipse.cdt.core.ELF;org.eclipse.cdt.core.GNU_ELF" id="com.crt.advproject.platform.exe.debug.1908405969" name="ARM-based MCU (Debug)" superClass="com.crt.advproject.platform.exe.debug"/>
<builder buildPath="${workspace_loc:/wolfcrypt_test}/Debug" id="com.crt.advproject.builder.exe.debug.398001039" keepEnvironmentInBuildfile="false" managedBuildOn="true" name="Gnu Make Builder" superClass="com.crt.advproject.builder.exe.debug"/>
<tool id="com.crt.advproject.cpp.exe.debug.1582745431" name="MCU C++ Compiler" superClass="com.crt.advproject.cpp.exe.debug">
<option id="com.crt.advproject.cpp.hdrlib.1425009735" name="Library headers" superClass="com.crt.advproject.cpp.hdrlib" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.fpu.168185144" name="Floating point" superClass="com.crt.advproject.cpp.fpu" useByScannerDiscovery="true" value="com.crt.advproject.cpp.fpu.fpv5sp.hard" valueType="enumerated"/>
<option id="com.crt.advproject.cpp.arch.119485104" name="Architecture" superClass="com.crt.advproject.cpp.arch" useByScannerDiscovery="true" value="com.crt.advproject.cpp.target.cm33" valueType="enumerated"/>
<option id="com.crt.advproject.cpp.misc.dialect.1281005339" name="Language standard" superClass="com.crt.advproject.cpp.misc.dialect" useByScannerDiscovery="true"/>
<option id="gnu.cpp.compiler.option.dialect.flags.539250169" name="Other dialect flags" superClass="gnu.cpp.compiler.option.dialect.flags" useByScannerDiscovery="true"/>
<option id="gnu.cpp.compiler.option.preprocessor.nostdinc.82696774" name="Do not search system directories (-nostdinc)" superClass="gnu.cpp.compiler.option.preprocessor.nostdinc" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.preprocessor.preprocess.1800760632" name="Preprocess only (-E)" superClass="gnu.cpp.compiler.option.preprocessor.preprocess" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.preprocessor.def.348454292" name="Defined symbols (-D)" superClass="gnu.cpp.compiler.option.preprocessor.def" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.preprocessor.undef.1999454908" name="Undefined symbols (-U)" superClass="gnu.cpp.compiler.option.preprocessor.undef" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.include.paths.654804912" name="Include paths (-I)" superClass="gnu.cpp.compiler.option.include.paths" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.include.files.465469438" name="Include files (-include)" superClass="gnu.cpp.compiler.option.include.files" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.exe.debug.option.optimization.level.1506322073" name="Optimization Level" superClass="com.crt.advproject.cpp.exe.debug.option.optimization.level" useByScannerDiscovery="true"/>
<option id="gnu.cpp.compiler.option.optimization.flags.1495094890" name="Other optimization flags" superClass="gnu.cpp.compiler.option.optimization.flags" useByScannerDiscovery="false" value="-fno-common" valueType="string"/>
<option id="com.crt.advproject.cpp.exe.debug.option.debugging.level.1323797502" name="Debug Level" superClass="com.crt.advproject.cpp.exe.debug.option.debugging.level" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.other.1437415705" name="Other debugging flags" superClass="gnu.cpp.compiler.option.debugging.other" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.prof.1622995235" name="Generate prof information (-p)" superClass="gnu.cpp.compiler.option.debugging.prof" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.gprof.2118050564" name="Generate gprof information (-pg)" superClass="gnu.cpp.compiler.option.debugging.gprof" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.codecov.280189550" name="Generate gcov information (-ftest-coverage -fprofile-arcs)" superClass="gnu.cpp.compiler.option.debugging.codecov" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.sanitaddress.580702892" name="Sanitize address (-fsanitize=address)" superClass="gnu.cpp.compiler.option.debugging.sanitaddress" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.sanitpointers.975533875" name="Sanitize pointer operations (-fsanitize=pointer-compare -fsanitize=pointer-subtract)" superClass="gnu.cpp.compiler.option.debugging.sanitpointers" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.sanitthread.414411965" name="Sanitize data race in multi-thread (-fsanitize=thread)" superClass="gnu.cpp.compiler.option.debugging.sanitthread" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.sanitleak.1269489620" name="Sanitize memory leak (-fsanitize=leak)" superClass="gnu.cpp.compiler.option.debugging.sanitleak" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.sanitundef.1638035105" name="Sanitize undefined behavior (-fsanitize=undefined)" superClass="gnu.cpp.compiler.option.debugging.sanitundef" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.syntax.580688457" name="Check syntax only (-fsyntax-only)" superClass="gnu.cpp.compiler.option.warnings.syntax" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.pedantic.1901382143" name="Pedantic (-pedantic)" superClass="gnu.cpp.compiler.option.warnings.pedantic" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.pedantic.error.818697578" name="Pedantic warnings as errors (-pedantic-errors)" superClass="gnu.cpp.compiler.option.warnings.pedantic.error" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.nowarn.2131193142" name="Inhibit all warnings (-w)" superClass="gnu.cpp.compiler.option.warnings.nowarn" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.allwarn.160405842" name="All warnings (-Wall)" superClass="gnu.cpp.compiler.option.warnings.allwarn" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.extrawarn.1654003215" name="Extra warnings (-Wextra)" superClass="gnu.cpp.compiler.option.warnings.extrawarn" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.toerrors.424506514" name="Warnings as errors (-Werror)" superClass="gnu.cpp.compiler.option.warnings.toerrors" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wconversion.2058636202" name="Implicit conversion warnings (-Wconversion)" superClass="gnu.cpp.compiler.option.warnings.wconversion" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wcastalign.1358686601" name="Pointer cast with different alignment (-Wcast-align)" superClass="gnu.cpp.compiler.option.warnings.wcastalign" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wcastqual.434377510" name="Removing type qualifier from cast target type (-Wcast-qual)" superClass="gnu.cpp.compiler.option.warnings.wcastqual" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wctordtorprivacy.592969326" name="All ctor and dtor private (-Wctor-dtor-privacy)" superClass="gnu.cpp.compiler.option.warnings.wctordtorprivacy" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wdisabledopt.473135479" name="Requested optimization pass is disabled (-Wdisabled-optimization)" superClass="gnu.cpp.compiler.option.warnings.wdisabledopt" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wlogicalop.273876437" name="Suspicious uses of logical operators (-Wlogical-op)" superClass="gnu.cpp.compiler.option.warnings.wlogicalop" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wmissingdecl.1205074478" name="Global function without previous declaration (-Wmissing-declarations)" superClass="gnu.cpp.compiler.option.warnings.wmissingdecl" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wmissingincdir.2040815548" name="User-supplied include directory does not exist (-Wmissing-include-dirs)" superClass="gnu.cpp.compiler.option.warnings.wmissingincdir" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wnoexccept.74710865" name="Noexcept false but never throw exception (-Wnoexcept)" superClass="gnu.cpp.compiler.option.warnings.wnoexccept" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.woldstylecast.1450357324" name="C-style cast used (-Wold-style-cast)" superClass="gnu.cpp.compiler.option.warnings.woldstylecast" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.woverloadedvirtual.520624464" name="Function hides virtual functions from base class (-Woverloaded-virtual)" superClass="gnu.cpp.compiler.option.warnings.woverloadedvirtual" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wredundantdecl.589509567" name="More than one declaration in the same scope (-Wredundant-decls)" superClass="gnu.cpp.compiler.option.warnings.wredundantdecl" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wshadow.1128444083" name="Local symbol shadows upper scope symbol (-Wshadow)" superClass="gnu.cpp.compiler.option.warnings.wshadow" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wsignconv.851101439" name="Implicit conversions that may change the sign (-Wsign-conversion)" superClass="gnu.cpp.compiler.option.warnings.wsignconv" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wsignpromo.2136361811" name="Overload resolution promotes unsigned to signed type (-Wsign-promo)" superClass="gnu.cpp.compiler.option.warnings.wsignpromo" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wstrictnullsent.1382679663" name="Use of an uncasted NULL as sentinel (-Wstrict-null-sentinel)" superClass="gnu.cpp.compiler.option.warnings.wstrictnullsent" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wswitchdef.578214758" name="A switch statement does not have a default case (-Wswitch-default)" superClass="gnu.cpp.compiler.option.warnings.wswitchdef" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wundef.2100715848" name="An undefined identifier is evaluated in an #if directive (-Wundef)" superClass="gnu.cpp.compiler.option.warnings.wundef" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.weffcpp.1610531155" name="Effective C++ guidelines (-Weffc++)" superClass="gnu.cpp.compiler.option.warnings.weffcpp" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wfloatequal.1705339990" name="Direct float equal check (-Wfloat-equal)" superClass="gnu.cpp.compiler.option.warnings.wfloatequal" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.other.other.2032067539" name="Other flags" superClass="gnu.cpp.compiler.option.other.other" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.other.verbose.1415389035" name="Verbose (-v)" superClass="gnu.cpp.compiler.option.other.verbose" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.other.pic.200721401" name="Position Independent Code (-fPIC)" superClass="gnu.cpp.compiler.option.other.pic" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.misc.hardening.366970155" name="Hardening options (-fstack-protector-all -Wformat=2 -Wformat-security -Wstrict-overflow)" superClass="gnu.cpp.compiler.option.misc.hardening" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.misc.randomization.259597814" name="Address randomization (-fPIE)" superClass="gnu.cpp.compiler.option.misc.randomization" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.lto.422793990" name="Enable Link-time optimization (-flto)" superClass="com.crt.advproject.cpp.lto" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.lto.fat.1143376979" name="Fat lto objects (-ffat-lto-objects)" superClass="com.crt.advproject.cpp.lto.fat" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.merge.constants.1300821372" name="Merge Identical Constants (-fmerge-constants)" superClass="com.crt.advproject.cpp.merge.constants" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.prefixmap.1023923086" name="Remove path from __FILE__ (-fmacro-prefix-map)" superClass="com.crt.advproject.cpp.prefixmap" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.thumb.1705999125" name="Thumb mode" superClass="com.crt.advproject.cpp.thumb" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.thumbinterwork.733719587" name="Enable Thumb interworking" superClass="com.crt.advproject.cpp.thumbinterwork" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.securestate.90652753" name="TrustZone Project Type" superClass="com.crt.advproject.cpp.securestate" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.stackusage.422548966" name="Generate Stack Usage Info (-fstack-usage)" superClass="com.crt.advproject.cpp.stackusage" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.specs.1208801983" name="Specs" superClass="com.crt.advproject.cpp.specs" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.config.610721849" name="Obsolete (Config)" superClass="com.crt.advproject.cpp.config" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.store.31899039" name="Obsolete (Store)" superClass="com.crt.advproject.cpp.store" useByScannerDiscovery="false"/>
</tool>
<tool id="com.crt.advproject.gcc.exe.debug.1640480109" name="MCU C Compiler" superClass="com.crt.advproject.gcc.exe.debug">
<option id="com.crt.advproject.gcc.hdrlib.1901765988" name="Library headers" superClass="com.crt.advproject.gcc.hdrlib" useByScannerDiscovery="false"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.compiler.option.preprocessor.def.symbols.926654229" name="Defined symbols (-D)" superClass="gnu.c.compiler.option.preprocessor.def.symbols" useByScannerDiscovery="false" valueType="definedSymbols">
<listOptionValue builtIn="false" value="__REDLIB__"/>
<listOptionValue builtIn="false" value="WOLFSSL_USER_SETTINGS"/>
<listOptionValue builtIn="false" value="CPU_MIMXRT685SFVKB"/>
<listOptionValue builtIn="false" value="CPU_MIMXRT685SFVKB_cm33"/>
<listOptionValue builtIn="false" value="SDK_OS_BAREMETAL"/>
<listOptionValue builtIn="false" value="FSL_SDK_DRIVER_QUICK_ACCESS_ENABLE=1"/>
<listOptionValue builtIn="false" value="SDK_DEBUGCONSOLE=1"/>
<listOptionValue builtIn="false" value="CR_INTEGER_PRINTF"/>
<listOptionValue builtIn="false" value="PRINTF_FLOAT_ENABLE=0"/>
<listOptionValue builtIn="false" value="SDK_OS_FREE_RTOS"/>
<listOptionValue builtIn="false" value="SERIAL_PORT_TYPE_UART=1"/>
<listOptionValue builtIn="false" value="BOOT_HEADER_ENABLE=1"/>
<listOptionValue builtIn="false" value="__MCUXPRESSO"/>
<listOptionValue builtIn="false" value="__USE_CMSIS"/>
<listOptionValue builtIn="false" value="DEBUG"/>
</option>
<option id="com.crt.advproject.gcc.fpu.1214507972" name="Floating point" superClass="com.crt.advproject.gcc.fpu" useByScannerDiscovery="true" value="com.crt.advproject.gcc.fpu.fpv5sp.hard" valueType="enumerated"/>
<option id="com.crt.advproject.gcc.thumb.2083007570" name="Thumb mode" superClass="com.crt.advproject.gcc.thumb" useByScannerDiscovery="false" value="true" valueType="boolean"/>
<option id="com.crt.advproject.gcc.arch.264035812" name="Architecture" superClass="com.crt.advproject.gcc.arch" useByScannerDiscovery="true" value="com.crt.advproject.gcc.target.cm33" valueType="enumerated"/>
<option id="com.crt.advproject.c.misc.dialect.2131343955" name="Language standard" superClass="com.crt.advproject.c.misc.dialect" useByScannerDiscovery="true"/>
<option id="gnu.c.compiler.option.dialect.flags.1505755302" name="Other dialect flags" superClass="gnu.c.compiler.option.dialect.flags" useByScannerDiscovery="true"/>
<option id="gnu.c.compiler.option.preprocessor.nostdinc.1003092082" name="Do not search system directories (-nostdinc)" superClass="gnu.c.compiler.option.preprocessor.nostdinc" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.preprocessor.preprocess.417681331" name="Preprocess only (-E)" superClass="gnu.c.compiler.option.preprocessor.preprocess" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.preprocessor.undef.symbol.129222341" name="Undefined symbols (-U)" superClass="gnu.c.compiler.option.preprocessor.undef.symbol" useByScannerDiscovery="false"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.compiler.option.include.paths.1984464231" name="Include paths (-I)" superClass="gnu.c.compiler.option.include.paths" useByScannerDiscovery="false" valueType="includePath">
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/freertos/freertos_kernel/include}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/drivers}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/device}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/CMSIS}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/component/uart}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/utilities}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/component/serial_manager}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/fatfs/source}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/fatfs/source/fsl_ram_disk}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/lwip/port}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/lwip/src}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/lwip/src/include}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/flash_config}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/component/lists}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/board}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/source}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/freertos/freertos_kernel/portable/GCC/ARM_CM33_NTZ/non_secure}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/lwip/template}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/MIMXRT685S}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc}/../../&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/board}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/source/test}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/source}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/freertos/freertos_kernel/include}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/drivers}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/device}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/CMSIS}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/component/uart}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/utilities}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/component/serial_manager}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/fatfs/source}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/fatfs/source/fsl_ram_disk}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/lwip/port}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/lwip/src}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/lwip/src/include}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/flash_config}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/component/lists}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/freertos/freertos_kernel/portable/GCC/ARM_CM33_NTZ/non_secure}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/lwip/template}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/MIMXRT685S}&quot;"/>
</option>
<option id="gnu.c.compiler.option.include.files.1798086271" name="Include files (-include)" superClass="gnu.c.compiler.option.include.files" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.exe.debug.option.optimization.level.702620765" name="Optimization Level" superClass="com.crt.advproject.gcc.exe.debug.option.optimization.level" useByScannerDiscovery="true"/>
<option id="gnu.c.compiler.option.optimization.flags.1336021846" name="Other optimization flags" superClass="gnu.c.compiler.option.optimization.flags" useByScannerDiscovery="false" value="-fno-common" valueType="string"/>
<option id="com.crt.advproject.gcc.exe.debug.option.debugging.level.107037613" name="Debug Level" superClass="com.crt.advproject.gcc.exe.debug.option.debugging.level" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.other.363891158" name="Other debugging flags" superClass="gnu.c.compiler.option.debugging.other" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.prof.1844913077" name="Generate prof information (-p)" superClass="gnu.c.compiler.option.debugging.prof" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.gprof.1902630902" name="Generate gprof information (-pg)" superClass="gnu.c.compiler.option.debugging.gprof" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.codecov.1534739067" name="Generate gcov information (-ftest-coverage -fprofile-arcs)" superClass="gnu.c.compiler.option.debugging.codecov" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.sanitaddress.909401089" name="Sanitize address (-fsanitize=address)" superClass="gnu.c.compiler.option.debugging.sanitaddress" useByScannerDiscovery="false" value="false" valueType="boolean"/>
<option id="gnu.c.compiler.option.debugging.sanitpointers.1675612699" name="Sanitize pointer operations (-fsanitize=pointer-compare -fsanitize=pointer-subtract)" superClass="gnu.c.compiler.option.debugging.sanitpointers" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.sanitthread.1244541954" name="Sanitize data race in multi-thread (-fsanitize=thread)" superClass="gnu.c.compiler.option.debugging.sanitthread" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.sanitleak.1394169868" name="Sanitize memory leak (-fsanitize=leak)" superClass="gnu.c.compiler.option.debugging.sanitleak" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.sanitundef.1849881273" name="Sanitize undefined behavior (-fsanitize=undefined)" superClass="gnu.c.compiler.option.debugging.sanitundef" useByScannerDiscovery="false" value="false" valueType="boolean"/>
<option id="gnu.c.compiler.option.warnings.syntax.1904373562" name="Check syntax only (-fsyntax-only)" superClass="gnu.c.compiler.option.warnings.syntax" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.pedantic.360937063" name="Pedantic (-pedantic)" superClass="gnu.c.compiler.option.warnings.pedantic" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.pedantic.error.1409792039" name="Pedantic warnings as errors (-pedantic-errors)" superClass="gnu.c.compiler.option.warnings.pedantic.error" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.nowarn.1496287352" name="Inhibit all warnings (-w)" superClass="gnu.c.compiler.option.warnings.nowarn" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.allwarn.1100544910" name="All warnings (-Wall)" superClass="gnu.c.compiler.option.warnings.allwarn" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.extrawarn.1789050816" name="Extra warnings (-Wextra)" superClass="gnu.c.compiler.option.warnings.extrawarn" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.toerrors.2065646172" name="Warnings as errors (-Werror)" superClass="gnu.c.compiler.option.warnings.toerrors" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wconversion.796681354" name="Implicit conversion warnings (-Wconversion)" superClass="gnu.c.compiler.option.warnings.wconversion" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wcastalign.1503828451" name="Pointer cast with different alignment (-Wcast-align)" superClass="gnu.c.compiler.option.warnings.wcastalign" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wcastqual.782800922" name="Removing type qualifier from cast target type (-Wcast-qual)" superClass="gnu.c.compiler.option.warnings.wcastqual" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wdisabledopt.1505030224" name="Requested optimization pass is disabled (-Wdisabled-optimization)" superClass="gnu.c.compiler.option.warnings.wdisabledopt" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wlogicalop.1063817591" name="Suspicious uses of logical operators (-Wlogical-op)" superClass="gnu.c.compiler.option.warnings.wlogicalop" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wmissingdecl.145383728" name="Global function without previous declaration (-Wmissing-declarations)" superClass="gnu.c.compiler.option.warnings.wmissingdecl" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wmissingincdir.1744730966" name="User-supplied include directory does not exist (-Wmissing-include-dirs)" superClass="gnu.c.compiler.option.warnings.wmissingincdir" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wredundantdecl.407886108" name="More than one declaration in the same scope (-Wredundant-decls)" superClass="gnu.c.compiler.option.warnings.wredundantdecl" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wshadow.1778748640" name="Local symbol shadows upper scope symbol (-Wshadow)" superClass="gnu.c.compiler.option.warnings.wshadow" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wsignconv.1280387001" name="Implicit conversions that may change the sign (-Wsign-conversion)" superClass="gnu.c.compiler.option.warnings.wsignconv" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wswitchdef.1812383408" name="A switch statement does not have a default case (-Wswitch-default)" superClass="gnu.c.compiler.option.warnings.wswitchdef" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wundef.1728710287" name="An undefined identifier is evaluated in an #if directive (-Wundef)" superClass="gnu.c.compiler.option.warnings.wundef" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wwritestrings.695518648" name="Treat strings always as const (-Wwrite-strings)" superClass="gnu.c.compiler.option.warnings.wwritestrings" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wfloatequal.1485487448" name="Direct float equal check (-Wfloat-equal)" superClass="gnu.c.compiler.option.warnings.wfloatequal" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.misc.other.1395959961" name="Other flags" superClass="gnu.c.compiler.option.misc.other" useByScannerDiscovery="false" value="-c -ffunction-sections -fdata-sections -ffreestanding -fno-builtin" valueType="string"/>
<option id="gnu.c.compiler.option.misc.verbose.1839123935" name="Verbose (-v)" superClass="gnu.c.compiler.option.misc.verbose" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.misc.ansi.81442538" name="Support ANSI programs (-ansi)" superClass="gnu.c.compiler.option.misc.ansi" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.misc.pic.27862826" name="Position Independent Code (-fPIC)" superClass="gnu.c.compiler.option.misc.pic" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.misc.hardening.2131497884" name="Hardening options (-fstack-protector-all -Wformat=2 -Wformat-security -Wstrict-overflow)" superClass="gnu.c.compiler.option.misc.hardening" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.misc.randomization.859047082" name="Address randomization (-fPIE)" superClass="gnu.c.compiler.option.misc.randomization" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.lto.710416440" name="Enable Link-time optimization (-flto)" superClass="com.crt.advproject.gcc.lto" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.lto.fat.1894690912" name="Fat lto objects (-ffat-lto-objects)" superClass="com.crt.advproject.gcc.lto.fat" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.merge.constants.1553200367" name="Merge Identical Constants (-fmerge-constants)" superClass="com.crt.advproject.gcc.merge.constants" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.prefixmap.1563309451" name="Remove path from __FILE__ (-fmacro-prefix-map)" superClass="com.crt.advproject.gcc.prefixmap" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.thumbinterwork.59071178" name="Enable Thumb interworking" superClass="com.crt.advproject.gcc.thumbinterwork" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.securestate.127822663" name="TrustZone Project Type" superClass="com.crt.advproject.gcc.securestate" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.stackusage.1787069817" name="Generate Stack Usage Info (-fstack-usage)" superClass="com.crt.advproject.gcc.stackusage" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.specs.1558712161" name="Specs" superClass="com.crt.advproject.gcc.specs" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.config.191623528" name="Obsolete (Config)" superClass="com.crt.advproject.gcc.config" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.store.1121013006" name="Obsolete (Store)" superClass="com.crt.advproject.gcc.store" useByScannerDiscovery="false"/>
<inputType id="com.crt.advproject.compiler.input.658443557" superClass="com.crt.advproject.compiler.input"/>
</tool>
<tool id="com.crt.advproject.gas.exe.debug.1844328890" name="MCU Assembler" superClass="com.crt.advproject.gas.exe.debug">
<option id="com.crt.advproject.gas.hdrlib.384487311" name="Library headers" superClass="com.crt.advproject.gas.hdrlib" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gas.fpu.715800085" name="Floating point" superClass="com.crt.advproject.gas.fpu" useByScannerDiscovery="false" value="com.crt.advproject.gas.fpu.fpv5sp.hard" valueType="enumerated"/>
<option id="com.crt.advproject.gas.thumb.1565291112" name="Thumb mode" superClass="com.crt.advproject.gas.thumb" useByScannerDiscovery="false" value="true" valueType="boolean"/>
<option id="com.crt.advproject.gas.arch.1364454839" name="Architecture" superClass="com.crt.advproject.gas.arch" useByScannerDiscovery="false" value="com.crt.advproject.gas.target.cm33" valueType="enumerated"/>
<option id="gnu.both.asm.option.flags.crt.259927775" name="Assembler flags" superClass="gnu.both.asm.option.flags.crt" useByScannerDiscovery="false" value="-c -x assembler-with-cpp -D__REDLIB__" valueType="string"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.both.asm.option.include.paths.114742175" name="Include paths (-I)" superClass="gnu.both.asm.option.include.paths" useByScannerDiscovery="false" valueType="includePath">
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/board}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/source}&quot;"/>
</option>
<option id="gnu.both.asm.option.warnings.nowarn.882652761" name="Suppress warnings (-W)" superClass="gnu.both.asm.option.warnings.nowarn" useByScannerDiscovery="false"/>
<option id="gnu.both.asm.option.version.891817216" name="Announce version (-v)" superClass="gnu.both.asm.option.version" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gas.exe.debug.option.debugging.level.1381526999" name="Debug level" superClass="com.crt.advproject.gas.exe.debug.option.debugging.level" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gas.thumbinterwork.1538348354" name="Enable Thumb interworking" superClass="com.crt.advproject.gas.thumbinterwork" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gas.specs.1620592402" name="Specs" superClass="com.crt.advproject.gas.specs" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gas.config.490105643" name="Obsolete (Config)" superClass="com.crt.advproject.gas.config" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gas.store.44757452" name="Obsolete (Store)" superClass="com.crt.advproject.gas.store" useByScannerDiscovery="false"/>
<inputType id="cdt.managedbuild.tool.gnu.assembler.input.934538899" superClass="cdt.managedbuild.tool.gnu.assembler.input"/>
<inputType id="com.crt.advproject.assembler.input.174322926" name="Additional Assembly Source Files" superClass="com.crt.advproject.assembler.input"/>
</tool>
<tool id="com.crt.advproject.link.cpp.exe.debug.1800889298" name="MCU C++ Linker" superClass="com.crt.advproject.link.cpp.exe.debug">
<option id="com.crt.advproject.link.cpp.hdrlib.851360579" name="Library" superClass="com.crt.advproject.link.cpp.hdrlib"/>
<option id="com.crt.advproject.link.cpp.fpu.940842262" name="Floating point" superClass="com.crt.advproject.link.cpp.fpu" value="com.crt.advproject.link.cpp.fpu.fpv5sp.hard" valueType="enumerated"/>
<option id="com.crt.advproject.link.cpp.arch.583574914" name="Architecture" superClass="com.crt.advproject.link.cpp.arch" value="com.crt.advproject.link.cpp.target.cm33" valueType="enumerated"/>
<option id="gnu.cpp.link.option.nostart.625346204" name="Do not use standard start files (-nostartfiles)" superClass="gnu.cpp.link.option.nostart"/>
<option id="gnu.cpp.link.option.nodeflibs.1297096548" name="Do not use default libraries (-nodefaultlibs)" superClass="gnu.cpp.link.option.nodeflibs"/>
<option id="gnu.cpp.link.option.nostdlibs.74153642" name="No startup or default libs (-nostdlib)" superClass="gnu.cpp.link.option.nostdlibs" value="true" valueType="boolean"/>
<option id="gnu.cpp.link.option.strip.960025806" name="Omit all symbol information (-s)" superClass="gnu.cpp.link.option.strip"/>
<option id="gnu.cpp.link.option.libs.765850521" name="Libraries (-l)" superClass="gnu.cpp.link.option.libs"/>
<option id="gnu.cpp.link.option.paths.279742503" name="Library search path (-L)" superClass="gnu.cpp.link.option.paths"/>
<option id="gnu.cpp.link.option.flags.1444858961" name="Linker flags" superClass="gnu.cpp.link.option.flags"/>
<option id="gnu.cpp.link.option.other.520163223" name="Other options (-Xlinker [option])" superClass="gnu.cpp.link.option.other"/>
<option id="gnu.cpp.link.option.userobjs.674298143" name="Other objects" superClass="gnu.cpp.link.option.userobjs"/>
<option id="gnu.cpp.link.option.shared.1527811979" name="Shared (-shared)" superClass="gnu.cpp.link.option.shared"/>
<option id="gnu.cpp.link.option.soname.857142746" name="Shared object name (-Wl,-soname=)" superClass="gnu.cpp.link.option.soname"/>
<option id="gnu.cpp.link.option.implname.600806337" name="Import Library name (-Wl,--out-implib=)" superClass="gnu.cpp.link.option.implname"/>
<option id="gnu.cpp.link.option.defname.180182046" name="DEF file name (-Wl,--output-def=)" superClass="gnu.cpp.link.option.defname"/>
<option id="gnu.cpp.link.option.debugging.prof.742326742" name="Generate prof information (-p)" superClass="gnu.cpp.link.option.debugging.prof"/>
<option id="gnu.cpp.link.option.debugging.gprof.948081937" name="Generate gprof information (-pg)" superClass="gnu.cpp.link.option.debugging.gprof"/>
<option id="gnu.cpp.link.option.debugging.codecov.906889807" name="Generate gcov information (-ftest-coverage -fprofile-arcs)" superClass="gnu.cpp.link.option.debugging.codecov"/>
<option id="com.crt.advproject.link.cpp.lto.1380125559" name="Enable Link-time optimization (-flto)" superClass="com.crt.advproject.link.cpp.lto"/>
<option id="com.crt.advproject.link.cpp.lto.optmization.level.1126738463" name="Link-time optimization level" superClass="com.crt.advproject.link.cpp.lto.optmization.level"/>
<option id="com.crt.advproject.link.cpp.thumb.1636198380" name="Thumb mode" superClass="com.crt.advproject.link.cpp.thumb"/>
<option id="com.crt.advproject.link.cpp.manage.510067730" name="Manage linker script" superClass="com.crt.advproject.link.cpp.manage"/>
<option id="com.crt.advproject.link.cpp.script.1427110886" name="Linker script" superClass="com.crt.advproject.link.cpp.script"/>
<option id="com.crt.advproject.link.cpp.scriptdir.913972735" name="Script path" superClass="com.crt.advproject.link.cpp.scriptdir"/>
<option id="com.crt.advproject.link.cpp.crpenable.667985114" name="Enable automatic placement of Code Read Protection field in image" superClass="com.crt.advproject.link.cpp.crpenable"/>
<option id="com.crt.advproject.link.cpp.flashconfigenable.1728278497" name="Enable automatic placement of Flash Configuration field in image" superClass="com.crt.advproject.link.cpp.flashconfigenable" value="true" valueType="boolean"/>
<option id="com.crt.advproject.link.cpp.ecrp.2014160419" name="Enhanced CRP" superClass="com.crt.advproject.link.cpp.ecrp"/>
<option id="com.crt.advproject.link.cpp.nanofloat.1439394838" name="Enable printf float " superClass="com.crt.advproject.link.cpp.nanofloat"/>
<option id="com.crt.advproject.link.cpp.nanofloat.scanf.511251083" name="Enable scanf float " superClass="com.crt.advproject.link.cpp.nanofloat.scanf"/>
<option id="com.crt.advproject.link.cpp.toram.43662908" name="Link application to RAM" superClass="com.crt.advproject.link.cpp.toram"/>
<option id="com.crt.advproject.link.memory.load.image.cpp.1288327806" name="Plain load image" superClass="com.crt.advproject.link.memory.load.image.cpp"/>
<option id="com.crt.advproject.link.memory.heapAndStack.style.cpp.86184907" name="Heap and Stack placement" superClass="com.crt.advproject.link.memory.heapAndStack.style.cpp"/>
<option id="com.crt.advproject.link.cpp.stackOffset.104998579" name="Stack offset" superClass="com.crt.advproject.link.cpp.stackOffset"/>
<option id="com.crt.advproject.link.memory.heapAndStack.cpp.1569327804" name="Heap and Stack options" superClass="com.crt.advproject.link.memory.heapAndStack.cpp"/>
<option id="com.crt.advproject.link.memory.data.cpp.1704927074" name="Global data placement" superClass="com.crt.advproject.link.memory.data.cpp"/>
<option id="com.crt.advproject.link.memory.sections.cpp.571845241" name="Extra linker script input sections" superClass="com.crt.advproject.link.memory.sections.cpp"/>
<option id="com.crt.advproject.link.cpp.multicore.slave.1151058689" name="Multicore configuration" superClass="com.crt.advproject.link.cpp.multicore.slave"/>
<option id="com.crt.advproject.link.cpp.multicore.master.302263115" name="Multicore master" superClass="com.crt.advproject.link.cpp.multicore.master"/>
<option id="com.crt.advproject.link.cpp.multicore.empty.786118577" name="No Multicore options for this project" superClass="com.crt.advproject.link.cpp.multicore.empty"/>
<option id="com.crt.advproject.link.cpp.multicore.master.userobjs.762410640" name="Slave Objects (not visible)" superClass="com.crt.advproject.link.cpp.multicore.master.userobjs"/>
<option id="com.crt.advproject.link.cpp.config.790989461" name="Obsolete (Config)" superClass="com.crt.advproject.link.cpp.config"/>
<option id="com.crt.advproject.link.cpp.store.98469982" name="Obsolete (Store)" superClass="com.crt.advproject.link.cpp.store"/>
<option id="com.crt.advproject.link.cpp.securestate.1472775957" name="TrustZone Project Type" superClass="com.crt.advproject.link.cpp.securestate"/>
<option id="com.crt.advproject.link.cpp.sgstubs.placement.1247225614" name="Secure Gateway Placement" superClass="com.crt.advproject.link.cpp.sgstubs.placement"/>
<option id="com.crt.advproject.link.cpp.sgstubenable.1452366892" name="Enable generation of Secure Gateway Import Library" superClass="com.crt.advproject.link.cpp.sgstubenable"/>
<option id="com.crt.advproject.link.cpp.nonsecureobject.1643300198" name="Secure Gateway Import Library" superClass="com.crt.advproject.link.cpp.nonsecureobject"/>
<option id="com.crt.advproject.link.cpp.inimplib.2030071286" name="Input Secure Gateway Import Library" superClass="com.crt.advproject.link.cpp.inimplib"/>
</tool>
<tool id="com.crt.advproject.link.exe.debug.1858357037" name="MCU Linker" superClass="com.crt.advproject.link.exe.debug">
<option id="com.crt.advproject.link.gcc.hdrlib.1408576102" name="Library" superClass="com.crt.advproject.link.gcc.hdrlib" useByScannerDiscovery="false" value="com.crt.advproject.gcc.link.hdrlib.codered.nohost_nf" valueType="enumerated"/>
<option id="com.crt.advproject.link.fpu.2078541388" name="Floating point" superClass="com.crt.advproject.link.fpu" useByScannerDiscovery="false" value="com.crt.advproject.link.fpu.fpv5sp.hard" valueType="enumerated"/>
<option id="com.crt.advproject.link.thumb.214641289" name="Thumb mode" superClass="com.crt.advproject.link.thumb" useByScannerDiscovery="false" value="true" valueType="boolean"/>
<option id="com.crt.advproject.link.memory.load.image.690220245" name="Plain load image" superClass="com.crt.advproject.link.memory.load.image" useByScannerDiscovery="false" value="false;" valueType="string"/>
<option defaultValue="com.crt.advproject.heapAndStack.mcuXpressoStyle" id="com.crt.advproject.link.memory.heapAndStack.style.1823610145" name="Heap and Stack placement" superClass="com.crt.advproject.link.memory.heapAndStack.style" useByScannerDiscovery="false" valueType="enumerated"/>
<option id="com.crt.advproject.link.memory.heapAndStack.2116674478" name="Heap and Stack options" superClass="com.crt.advproject.link.memory.heapAndStack" useByScannerDiscovery="false" value="&amp;Heap:Default;Post Data;0x30d40&amp;Stack:Default;End;0x3d090" valueType="string"/>
<option id="com.crt.advproject.link.memory.data.1409791641" name="Global data placement" superClass="com.crt.advproject.link.memory.data" useByScannerDiscovery="false" value="Default" valueType="string"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="true" id="com.crt.advproject.link.memory.sections.1985690496" name="Extra linker script input sections" superClass="com.crt.advproject.link.memory.sections" useByScannerDiscovery="false" valueType="stringList"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="true" id="com.crt.advproject.link.gcc.multicore.master.userobjs.1987752335" name="Slave Objects (not visible)" superClass="com.crt.advproject.link.gcc.multicore.master.userobjs" useByScannerDiscovery="false" valueType="userObjs"/>
<option id="com.crt.advproject.link.gcc.multicore.slave.303736991" name="Multicore configuration" superClass="com.crt.advproject.link.gcc.multicore.slave" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.link.arch.436029356" name="Architecture" superClass="com.crt.advproject.link.arch" useByScannerDiscovery="false" value="com.crt.advproject.link.target.cm33" valueType="enumerated"/>
<option id="gnu.c.link.option.nostart.1998838580" name="Do not use standard start files (-nostartfiles)" superClass="gnu.c.link.option.nostart" useByScannerDiscovery="false"/>
<option id="gnu.c.link.option.nodeflibs.1101569168" name="Do not use default libraries (-nodefaultlibs)" superClass="gnu.c.link.option.nodeflibs" useByScannerDiscovery="false"/>
<option id="gnu.c.link.option.nostdlibs.1783250265" name="No startup or default libs (-nostdlib)" superClass="gnu.c.link.option.nostdlibs" useByScannerDiscovery="false" value="true" valueType="boolean"/>
<option id="gnu.c.link.option.strip.517306114" name="Omit all symbol information (-s)" superClass="gnu.c.link.option.strip" useByScannerDiscovery="false"/>
<option id="gnu.c.link.option.noshared.997545043" name="No shared libraries (-static)" superClass="gnu.c.link.option.noshared" useByScannerDiscovery="false"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.link.option.libs.656630048" name="Libraries (-l)" superClass="gnu.c.link.option.libs" useByScannerDiscovery="false" valueType="libs">
<listOptionValue builtIn="false" value="wolfssl"/>
</option>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.link.option.paths.1689057298" name="Library search path (-L)" superClass="gnu.c.link.option.paths" useByScannerDiscovery="false" valueType="libPaths">
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/wolfssl/Debug}&quot;"/>
</option>
<option id="gnu.c.link.option.ldflags.1911120473" name="Linker flags" superClass="gnu.c.link.option.ldflags" useByScannerDiscovery="false"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.link.option.other.165633520" name="Other options (-Xlinker [option])" superClass="gnu.c.link.option.other" useByScannerDiscovery="false" valueType="stringList">
<listOptionValue builtIn="false" value="-Map=&quot;${BuildArtifactFileBaseName}.map&quot;"/>
<listOptionValue builtIn="false" value="--gc-sections"/>
<listOptionValue builtIn="false" value="-print-memory-usage"/>
<listOptionValue builtIn="false" value="--sort-section=alignment"/>
<listOptionValue builtIn="false" value="--cref"/>
</option>
<option id="gnu.c.link.option.userobjs.1661946890" name="Other objects" superClass="gnu.c.link.option.userobjs" useByScannerDiscovery="false"/>
<option id="gnu.c.link.option.shared.772260843" name="Shared (-shared)" superClass="gnu.c.link.option.shared" useByScannerDiscovery="false"/>
<option id="gnu.c.link.option.soname.582081713" name="Shared object name (-Wl,-soname=)" superClass="gnu.c.link.option.soname" useByScannerDiscovery="false"/>
<option id="gnu.c.link.option.implname.516698177" name="Import Library name (-Wl,--out-implib=)" superClass="gnu.c.link.option.implname" useByScannerDiscovery="false"/>
<option id="gnu.c.link.option.defname.231832391" name="DEF file name (-Wl,--output-def=)" superClass="gnu.c.link.option.defname" useByScannerDiscovery="false"/>
<option id="gnu.c.link.option.debugging.prof.1443558648" name="Generate prof information (-p)" superClass="gnu.c.link.option.debugging.prof" useByScannerDiscovery="false"/>
<option id="gnu.c.link.option.debugging.gprof.140139309" name="Generate gprof information (-pg)" superClass="gnu.c.link.option.debugging.gprof" useByScannerDiscovery="false"/>
<option id="gnu.c.link.option.debugging.codecov.1030206919" name="Generate gcov information (-ftest-coverage -fprofile-arcs)" superClass="gnu.c.link.option.debugging.codecov" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.link.gcc.lto.1020443094" name="Enable Link-time optimization (-flto)" superClass="com.crt.advproject.link.gcc.lto" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.link.gcc.lto.optmization.level.1642347879" name="Link-time optimization level" superClass="com.crt.advproject.link.gcc.lto.optmization.level" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.link.manage.214620152" name="Manage linker script" superClass="com.crt.advproject.link.manage" useByScannerDiscovery="false" value="true" valueType="boolean"/>
<option id="com.crt.advproject.link.script.838557779" name="Linker script" superClass="com.crt.advproject.link.script" useByScannerDiscovery="false" value="wolfcrypt_test_Debug.ld" valueType="string"/>
<option id="com.crt.advproject.link.scriptdir.1064743927" name="Script path" superClass="com.crt.advproject.link.scriptdir" useByScannerDiscovery="false" value="" valueType="string"/>
<option id="com.crt.advproject.link.crpenable.1582261920" name="Enable automatic placement of Code Read Protection field in image" superClass="com.crt.advproject.link.crpenable" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.link.flashconfigenable.1561972634" name="Enable automatic placement of Flash Configuration field in image" superClass="com.crt.advproject.link.flashconfigenable" useByScannerDiscovery="false" value="true" valueType="boolean"/>
<option id="com.crt.advproject.link.ecrp.1374573462" name="Enhanced CRP" superClass="com.crt.advproject.link.ecrp" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.link.gcc.nanofloat.1759960959" name="Enable printf float " superClass="com.crt.advproject.link.gcc.nanofloat" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.link.gcc.nanofloat.scanf.1113648666" name="Enable scanf float " superClass="com.crt.advproject.link.gcc.nanofloat.scanf" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.link.toram.1292745694" name="Link application to RAM" superClass="com.crt.advproject.link.toram" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.link.stackOffset.780234425" name="Stack offset" superClass="com.crt.advproject.link.stackOffset" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.link.gcc.multicore.master.159078418" name="Multicore master" superClass="com.crt.advproject.link.gcc.multicore.master" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.link.gcc.multicore.empty.1577283265" name="No Multicore options for this project" superClass="com.crt.advproject.link.gcc.multicore.empty" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.link.config.1652284051" name="Obsolete (Config)" superClass="com.crt.advproject.link.config" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.link.store.832202611" name="Obsolete (Store)" superClass="com.crt.advproject.link.store" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.link.securestate.1044909867" name="TrustZone Project Type" superClass="com.crt.advproject.link.securestate" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.link.sgstubs.placement.114129907" name="Secure Gateway Placement" superClass="com.crt.advproject.link.sgstubs.placement" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.link.sgstubenable.172263323" name="Enable generation of Secure Gateway Import Library" superClass="com.crt.advproject.link.sgstubenable" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.link.nonsecureobject.157296498" name="Secure Gateway Import Library" superClass="com.crt.advproject.link.nonsecureobject" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.link.inimplib.872192504" name="Input Secure Gateway Import Library" superClass="com.crt.advproject.link.inimplib" useByScannerDiscovery="false"/>
<inputType id="cdt.managedbuild.tool.gnu.c.linker.input.1049574947" superClass="cdt.managedbuild.tool.gnu.c.linker.input">
<additionalInput kind="additionalinputdependency" paths="$(USER_OBJS)"/>
<additionalInput kind="additionalinput" paths="$(LIBS)"/>
</inputType>
</tool>
<tool id="com.crt.advproject.tool.debug.debug.565406347" name="MCU Debugger" superClass="com.crt.advproject.tool.debug.debug">
<option id="com.crt.advproject.linkserver.debug.prevent.debug.628278017" name="Prevent Debugging" superClass="com.crt.advproject.linkserver.debug.prevent.debug" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.miscellaneous.end_of_heap.1700873648" name="Last used address of the heap" superClass="com.crt.advproject.miscellaneous.end_of_heap" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.miscellaneous.pvHeapStart.35778762" name="First address of the heap" superClass="com.crt.advproject.miscellaneous.pvHeapStart" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.miscellaneous.pvHeapLimit.986324885" name="Maximum extent of heap" superClass="com.crt.advproject.miscellaneous.pvHeapLimit" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.debugger.security.nonsecureimageenable.1213866409" name="Enable pre-programming of Non-Secure Image" superClass="com.crt.advproject.debugger.security.nonsecureimageenable" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.debugger.security.nonsecureimage.1169601112" name="Non-Secure Project" superClass="com.crt.advproject.debugger.security.nonsecureimage" useByScannerDiscovery="false"/>
</tool>
</toolChain>
</folderInfo>
<sourceEntries>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="component"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="CMSIS"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="MIMXRT685S"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="source"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="utilities"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="drivers"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="device"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="fatfs"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="board"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="flash_config"/>
<entry excluding="src/netif/ppp/polarssl/arc4.c|src/netif/ppp/polarssl/des.c|src/netif/ppp/polarssl/md4.c|src/netif/ppp/polarssl/md5.c|src/netif/ppp/polarssl/sha1.c" flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="lwip"/>
<entry excluding="freertos_kernel/portable/MemMang/heap_1.c|freertos_kernel/portable/MemMang/heap_2.c|freertos_kernel/portable/MemMang/heap_3.c|freertos_kernel/portable/MemMang/heap_5.c" flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="freertos"/>
</sourceEntries>
</configuration>
</storageModule>
<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
</cconfiguration>
<cconfiguration id="com.crt.advproject.config.exe.release.249423119">
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="com.crt.advproject.config.exe.release.249423119" moduleId="org.eclipse.cdt.core.settings" name="Release">
<externalSettings/>
<extensions>
<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
<extension id="org.eclipse.cdt.core.GNU_ELF" point="org.eclipse.cdt.core.BinaryParser"/>
<extension id="org.eclipse.cdt.core.GmakeErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GASErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GLDErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.CWDLocator" point="org.eclipse.cdt.core.ErrorParser"/>
<extension id="org.eclipse.cdt.core.GCCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
</extensions>
</storageModule>
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
<configuration artifactExtension="axf" artifactName="${ProjName}" buildArtefactType="org.eclipse.cdt.build.core.buildArtefactType.exe" buildProperties="org.eclipse.cdt.build.core.buildArtefactType=org.eclipse.cdt.build.core.buildArtefactType.exe" cleanCommand="rm -rf" description="Release build" errorParsers="org.eclipse.cdt.core.CWDLocator;org.eclipse.cdt.core.GmakeErrorParser;org.eclipse.cdt.core.GCCErrorParser;org.eclipse.cdt.core.GLDErrorParser;org.eclipse.cdt.core.GASErrorParser" id="com.crt.advproject.config.exe.release.249423119" name="Release" parent="com.crt.advproject.config.exe.release" postannouncebuildStep="Performing post-build steps" postbuildStep="arm-none-eabi-size &quot;${BuildArtifactFileName}&quot;; # arm-none-eabi-objcopy -v -O binary &quot;${BuildArtifactFileName}&quot; &quot;${BuildArtifactFileBaseName}.bin&quot; ; # checksum -p ${TargetChip} -d &quot;${BuildArtifactFileBaseName}.bin&quot;; ">
<folderInfo id="com.crt.advproject.config.exe.release.249423119." name="/" resourcePath="">
<toolChain id="com.crt.advproject.toolchain.exe.release.1645812542" name="NXP MCU Tools" superClass="com.crt.advproject.toolchain.exe.release">
<targetPlatform binaryParser="org.eclipse.cdt.core.ELF;org.eclipse.cdt.core.GNU_ELF" id="com.crt.advproject.platform.exe.release.1563895248" name="ARM-based MCU (Release)" superClass="com.crt.advproject.platform.exe.release"/>
<builder buildPath="${workspace_loc:/wolfcrypt_test}/Release" id="com.crt.advproject.builder.exe.release.1449176597" keepEnvironmentInBuildfile="false" managedBuildOn="true" name="Gnu Make Builder" superClass="com.crt.advproject.builder.exe.release"/>
<tool id="com.crt.advproject.cpp.exe.release.1667729139" name="MCU C++ Compiler" superClass="com.crt.advproject.cpp.exe.release">
<option id="com.crt.advproject.cpp.arch.2048761003" name="Architecture" superClass="com.crt.advproject.cpp.arch" useByScannerDiscovery="true" value="com.crt.advproject.cpp.target.cm33" valueType="enumerated"/>
<option id="com.crt.advproject.cpp.misc.dialect.505592573" name="Language standard" superClass="com.crt.advproject.cpp.misc.dialect" useByScannerDiscovery="true"/>
<option id="gnu.cpp.compiler.option.dialect.flags.389516364" name="Other dialect flags" superClass="gnu.cpp.compiler.option.dialect.flags" useByScannerDiscovery="true"/>
<option id="gnu.cpp.compiler.option.preprocessor.nostdinc.1493925046" name="Do not search system directories (-nostdinc)" superClass="gnu.cpp.compiler.option.preprocessor.nostdinc" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.preprocessor.preprocess.1821168859" name="Preprocess only (-E)" superClass="gnu.cpp.compiler.option.preprocessor.preprocess" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.preprocessor.def.656143384" name="Defined symbols (-D)" superClass="gnu.cpp.compiler.option.preprocessor.def" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.preprocessor.undef.1401448289" name="Undefined symbols (-U)" superClass="gnu.cpp.compiler.option.preprocessor.undef" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.include.paths.513408631" name="Include paths (-I)" superClass="gnu.cpp.compiler.option.include.paths" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.include.files.1574974266" name="Include files (-include)" superClass="gnu.cpp.compiler.option.include.files" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.optimization.flags.1139368202" name="Other optimization flags" superClass="gnu.cpp.compiler.option.optimization.flags" useByScannerDiscovery="false" value="-fno-common" valueType="string"/>
<option id="gnu.cpp.compiler.option.debugging.other.440615014" name="Other debugging flags" superClass="gnu.cpp.compiler.option.debugging.other" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.prof.996729796" name="Generate prof information (-p)" superClass="gnu.cpp.compiler.option.debugging.prof" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.gprof.925612743" name="Generate gprof information (-pg)" superClass="gnu.cpp.compiler.option.debugging.gprof" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.codecov.400976247" name="Generate gcov information (-ftest-coverage -fprofile-arcs)" superClass="gnu.cpp.compiler.option.debugging.codecov" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.sanitaddress.440648855" name="Sanitize address (-fsanitize=address)" superClass="gnu.cpp.compiler.option.debugging.sanitaddress" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.sanitpointers.1785639075" name="Sanitize pointer operations (-fsanitize=pointer-compare -fsanitize=pointer-subtract)" superClass="gnu.cpp.compiler.option.debugging.sanitpointers" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.sanitthread.140955800" name="Sanitize data race in multi-thread (-fsanitize=thread)" superClass="gnu.cpp.compiler.option.debugging.sanitthread" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.sanitleak.193280544" name="Sanitize memory leak (-fsanitize=leak)" superClass="gnu.cpp.compiler.option.debugging.sanitleak" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.debugging.sanitundef.2004929707" name="Sanitize undefined behavior (-fsanitize=undefined)" superClass="gnu.cpp.compiler.option.debugging.sanitundef" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.syntax.110999708" name="Check syntax only (-fsyntax-only)" superClass="gnu.cpp.compiler.option.warnings.syntax" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.pedantic.244872780" name="Pedantic (-pedantic)" superClass="gnu.cpp.compiler.option.warnings.pedantic" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.pedantic.error.1109928551" name="Pedantic warnings as errors (-pedantic-errors)" superClass="gnu.cpp.compiler.option.warnings.pedantic.error" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.nowarn.1462234369" name="Inhibit all warnings (-w)" superClass="gnu.cpp.compiler.option.warnings.nowarn" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.allwarn.1925541023" name="All warnings (-Wall)" superClass="gnu.cpp.compiler.option.warnings.allwarn" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.extrawarn.965607542" name="Extra warnings (-Wextra)" superClass="gnu.cpp.compiler.option.warnings.extrawarn" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.toerrors.791896365" name="Warnings as errors (-Werror)" superClass="gnu.cpp.compiler.option.warnings.toerrors" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wconversion.1878799088" name="Implicit conversion warnings (-Wconversion)" superClass="gnu.cpp.compiler.option.warnings.wconversion" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wcastalign.90168539" name="Pointer cast with different alignment (-Wcast-align)" superClass="gnu.cpp.compiler.option.warnings.wcastalign" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wcastqual.1721326128" name="Removing type qualifier from cast target type (-Wcast-qual)" superClass="gnu.cpp.compiler.option.warnings.wcastqual" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wctordtorprivacy.1144164747" name="All ctor and dtor private (-Wctor-dtor-privacy)" superClass="gnu.cpp.compiler.option.warnings.wctordtorprivacy" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wdisabledopt.2024294384" name="Requested optimization pass is disabled (-Wdisabled-optimization)" superClass="gnu.cpp.compiler.option.warnings.wdisabledopt" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wlogicalop.70434452" name="Suspicious uses of logical operators (-Wlogical-op)" superClass="gnu.cpp.compiler.option.warnings.wlogicalop" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wmissingdecl.1437065273" name="Global function without previous declaration (-Wmissing-declarations)" superClass="gnu.cpp.compiler.option.warnings.wmissingdecl" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wmissingincdir.1558961712" name="User-supplied include directory does not exist (-Wmissing-include-dirs)" superClass="gnu.cpp.compiler.option.warnings.wmissingincdir" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wnoexccept.1462971991" name="Noexcept false but never throw exception (-Wnoexcept)" superClass="gnu.cpp.compiler.option.warnings.wnoexccept" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.woldstylecast.350890521" name="C-style cast used (-Wold-style-cast)" superClass="gnu.cpp.compiler.option.warnings.woldstylecast" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.woverloadedvirtual.1682534740" name="Function hides virtual functions from base class (-Woverloaded-virtual)" superClass="gnu.cpp.compiler.option.warnings.woverloadedvirtual" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wredundantdecl.2017541834" name="More than one declaration in the same scope (-Wredundant-decls)" superClass="gnu.cpp.compiler.option.warnings.wredundantdecl" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wshadow.514941421" name="Local symbol shadows upper scope symbol (-Wshadow)" superClass="gnu.cpp.compiler.option.warnings.wshadow" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wsignconv.292142194" name="Implicit conversions that may change the sign (-Wsign-conversion)" superClass="gnu.cpp.compiler.option.warnings.wsignconv" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wsignpromo.1608314467" name="Overload resolution promotes unsigned to signed type (-Wsign-promo)" superClass="gnu.cpp.compiler.option.warnings.wsignpromo" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wstrictnullsent.787652795" name="Use of an uncasted NULL as sentinel (-Wstrict-null-sentinel)" superClass="gnu.cpp.compiler.option.warnings.wstrictnullsent" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wswitchdef.88894600" name="A switch statement does not have a default case (-Wswitch-default)" superClass="gnu.cpp.compiler.option.warnings.wswitchdef" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wundef.1575666030" name="An undefined identifier is evaluated in an #if directive (-Wundef)" superClass="gnu.cpp.compiler.option.warnings.wundef" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.weffcpp.1570602172" name="Effective C++ guidelines (-Weffc++)" superClass="gnu.cpp.compiler.option.warnings.weffcpp" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.warnings.wfloatequal.832306128" name="Direct float equal check (-Wfloat-equal)" superClass="gnu.cpp.compiler.option.warnings.wfloatequal" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.other.other.24577846" name="Other flags" superClass="gnu.cpp.compiler.option.other.other" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.other.verbose.451830268" name="Verbose (-v)" superClass="gnu.cpp.compiler.option.other.verbose" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.other.pic.678915869" name="Position Independent Code (-fPIC)" superClass="gnu.cpp.compiler.option.other.pic" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.misc.hardening.2047049414" name="Hardening options (-fstack-protector-all -Wformat=2 -Wformat-security -Wstrict-overflow)" superClass="gnu.cpp.compiler.option.misc.hardening" useByScannerDiscovery="false"/>
<option id="gnu.cpp.compiler.option.misc.randomization.271572108" name="Address randomization (-fPIE)" superClass="gnu.cpp.compiler.option.misc.randomization" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.lto.447497847" name="Enable Link-time optimization (-flto)" superClass="com.crt.advproject.cpp.lto" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.lto.fat.647731008" name="Fat lto objects (-ffat-lto-objects)" superClass="com.crt.advproject.cpp.lto.fat" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.merge.constants.828420236" name="Merge Identical Constants (-fmerge-constants)" superClass="com.crt.advproject.cpp.merge.constants" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.prefixmap.368492410" name="Remove path from __FILE__ (-fmacro-prefix-map)" superClass="com.crt.advproject.cpp.prefixmap" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.fpu.96113204" name="Floating point" superClass="com.crt.advproject.cpp.fpu" useByScannerDiscovery="true" value="com.crt.advproject.cpp.fpu.fpv5sp.hard" valueType="enumerated"/>
<option id="com.crt.advproject.cpp.thumb.128693939" name="Thumb mode" superClass="com.crt.advproject.cpp.thumb" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.thumbinterwork.285334505" name="Enable Thumb interworking" superClass="com.crt.advproject.cpp.thumbinterwork" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.securestate.712920473" name="TrustZone Project Type" superClass="com.crt.advproject.cpp.securestate" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.hdrlib.273589005" name="Library headers" superClass="com.crt.advproject.cpp.hdrlib" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.stackusage.175105685" name="Generate Stack Usage Info (-fstack-usage)" superClass="com.crt.advproject.cpp.stackusage" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.specs.102275152" name="Specs" superClass="com.crt.advproject.cpp.specs" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.config.936671298" name="Obsolete (Config)" superClass="com.crt.advproject.cpp.config" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.cpp.store.1959905556" name="Obsolete (Store)" superClass="com.crt.advproject.cpp.store" useByScannerDiscovery="false"/>
</tool>
<tool id="com.crt.advproject.gcc.exe.release.493869736" name="MCU C Compiler" superClass="com.crt.advproject.gcc.exe.release">
<option id="com.crt.advproject.gcc.thumb.1649918786" name="Thumb mode" superClass="com.crt.advproject.gcc.thumb" useByScannerDiscovery="false" value="true" valueType="boolean"/>
<option id="com.crt.advproject.gcc.arch.1237947729" name="Architecture" superClass="com.crt.advproject.gcc.arch" useByScannerDiscovery="true" value="com.crt.advproject.gcc.target.cm33" valueType="enumerated"/>
<option id="com.crt.advproject.c.misc.dialect.25690629" name="Language standard" superClass="com.crt.advproject.c.misc.dialect" useByScannerDiscovery="true"/>
<option id="gnu.c.compiler.option.dialect.flags.1994645999" name="Other dialect flags" superClass="gnu.c.compiler.option.dialect.flags" useByScannerDiscovery="true"/>
<option id="gnu.c.compiler.option.preprocessor.nostdinc.579712622" name="Do not search system directories (-nostdinc)" superClass="gnu.c.compiler.option.preprocessor.nostdinc" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.preprocessor.preprocess.117420900" name="Preprocess only (-E)" superClass="gnu.c.compiler.option.preprocessor.preprocess" useByScannerDiscovery="false"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.compiler.option.preprocessor.def.symbols.739089612" name="Defined symbols (-D)" superClass="gnu.c.compiler.option.preprocessor.def.symbols" useByScannerDiscovery="false" valueType="definedSymbols">
<listOptionValue builtIn="false" value="__REDLIB__"/>
<listOptionValue builtIn="false" value="WOLFSSL_USER_SETTINGS"/>
<listOptionValue builtIn="false" value="CPU_MIMXRT685SFVKB"/>
<listOptionValue builtIn="false" value="CPU_MIMXRT685SFVKB_cm33"/>
<listOptionValue builtIn="false" value="SDK_OS_BAREMETAL"/>
<listOptionValue builtIn="false" value="FSL_SDK_DRIVER_QUICK_ACCESS_ENABLE=1"/>
<listOptionValue builtIn="false" value="SDK_DEBUGCONSOLE=1"/>
<listOptionValue builtIn="false" value="CR_INTEGER_PRINTF"/>
<listOptionValue builtIn="false" value="PRINTF_FLOAT_ENABLE=0"/>
<listOptionValue builtIn="false" value="SDK_OS_FREE_RTOS"/>
<listOptionValue builtIn="false" value="SERIAL_PORT_TYPE_UART=1"/>
<listOptionValue builtIn="false" value="BOOT_HEADER_ENABLE=1"/>
<listOptionValue builtIn="false" value="__MCUXPRESSO"/>
<listOptionValue builtIn="false" value="__USE_CMSIS"/>
<listOptionValue builtIn="false" value="DEBUG"/>
</option>
<option id="gnu.c.compiler.option.preprocessor.undef.symbol.1470168315" name="Undefined symbols (-U)" superClass="gnu.c.compiler.option.preprocessor.undef.symbol" useByScannerDiscovery="false"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.compiler.option.include.paths.1732901438" name="Include paths (-I)" superClass="gnu.c.compiler.option.include.paths" useByScannerDiscovery="false" valueType="includePath">
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/freertos/freertos_kernel/include}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/drivers}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/device}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/CMSIS}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/component/uart}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/utilities}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/component/serial_manager}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/fatfs/source}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/fatfs/source/fsl_ram_disk}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/lwip/port}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/lwip/src}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/lwip/src/include}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/flash_config}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/component/lists}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/board}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/source}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/freertos/freertos_kernel/portable/GCC/ARM_CM33_NTZ/non_secure}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/lwip/template}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/MIMXRT685S}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc}/../../&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/board}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/source/test}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/source}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/freertos/freertos_kernel/include}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/drivers}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/device}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/CMSIS}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/component/uart}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/utilities}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/component/serial_manager}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/fatfs/source}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/fatfs/source/fsl_ram_disk}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/lwip/port}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/lwip/src}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/lwip/src/include}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/flash_config}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/component/lists}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/freertos/freertos_kernel/portable/GCC/ARM_CM33_NTZ/non_secure}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/lwip/template}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/MIMXRT685S}&quot;"/>
</option>
<option id="gnu.c.compiler.option.include.files.1324903267" name="Include files (-include)" superClass="gnu.c.compiler.option.include.files" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.optimization.flags.707502780" name="Other optimization flags" superClass="gnu.c.compiler.option.optimization.flags" useByScannerDiscovery="false" value="-fno-common" valueType="string"/>
<option id="gnu.c.compiler.option.debugging.other.2134939218" name="Other debugging flags" superClass="gnu.c.compiler.option.debugging.other" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.prof.1766064169" name="Generate prof information (-p)" superClass="gnu.c.compiler.option.debugging.prof" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.gprof.1395425416" name="Generate gprof information (-pg)" superClass="gnu.c.compiler.option.debugging.gprof" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.codecov.853786412" name="Generate gcov information (-ftest-coverage -fprofile-arcs)" superClass="gnu.c.compiler.option.debugging.codecov" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.sanitaddress.953948515" name="Sanitize address (-fsanitize=address)" superClass="gnu.c.compiler.option.debugging.sanitaddress" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.sanitpointers.2054029386" name="Sanitize pointer operations (-fsanitize=pointer-compare -fsanitize=pointer-subtract)" superClass="gnu.c.compiler.option.debugging.sanitpointers" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.sanitthread.1457837392" name="Sanitize data race in multi-thread (-fsanitize=thread)" superClass="gnu.c.compiler.option.debugging.sanitthread" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.sanitleak.837778599" name="Sanitize memory leak (-fsanitize=leak)" superClass="gnu.c.compiler.option.debugging.sanitleak" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.debugging.sanitundef.1969936188" name="Sanitize undefined behavior (-fsanitize=undefined)" superClass="gnu.c.compiler.option.debugging.sanitundef" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.syntax.1822548949" name="Check syntax only (-fsyntax-only)" superClass="gnu.c.compiler.option.warnings.syntax" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.pedantic.407623114" name="Pedantic (-pedantic)" superClass="gnu.c.compiler.option.warnings.pedantic" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.pedantic.error.1288294771" name="Pedantic warnings as errors (-pedantic-errors)" superClass="gnu.c.compiler.option.warnings.pedantic.error" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.nowarn.318140154" name="Inhibit all warnings (-w)" superClass="gnu.c.compiler.option.warnings.nowarn" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.allwarn.1970931285" name="All warnings (-Wall)" superClass="gnu.c.compiler.option.warnings.allwarn" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.extrawarn.876801275" name="Extra warnings (-Wextra)" superClass="gnu.c.compiler.option.warnings.extrawarn" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.toerrors.1081263757" name="Warnings as errors (-Werror)" superClass="gnu.c.compiler.option.warnings.toerrors" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wconversion.2031567662" name="Implicit conversion warnings (-Wconversion)" superClass="gnu.c.compiler.option.warnings.wconversion" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wcastalign.1953802639" name="Pointer cast with different alignment (-Wcast-align)" superClass="gnu.c.compiler.option.warnings.wcastalign" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wcastqual.1102103551" name="Removing type qualifier from cast target type (-Wcast-qual)" superClass="gnu.c.compiler.option.warnings.wcastqual" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wdisabledopt.344469284" name="Requested optimization pass is disabled (-Wdisabled-optimization)" superClass="gnu.c.compiler.option.warnings.wdisabledopt" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wlogicalop.1914173449" name="Suspicious uses of logical operators (-Wlogical-op)" superClass="gnu.c.compiler.option.warnings.wlogicalop" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wmissingdecl.249738473" name="Global function without previous declaration (-Wmissing-declarations)" superClass="gnu.c.compiler.option.warnings.wmissingdecl" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wmissingincdir.866563367" name="User-supplied include directory does not exist (-Wmissing-include-dirs)" superClass="gnu.c.compiler.option.warnings.wmissingincdir" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wredundantdecl.250452036" name="More than one declaration in the same scope (-Wredundant-decls)" superClass="gnu.c.compiler.option.warnings.wredundantdecl" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wshadow.146012654" name="Local symbol shadows upper scope symbol (-Wshadow)" superClass="gnu.c.compiler.option.warnings.wshadow" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wsignconv.1923074130" name="Implicit conversions that may change the sign (-Wsign-conversion)" superClass="gnu.c.compiler.option.warnings.wsignconv" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wswitchdef.81329178" name="A switch statement does not have a default case (-Wswitch-default)" superClass="gnu.c.compiler.option.warnings.wswitchdef" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wundef.1725600097" name="An undefined identifier is evaluated in an #if directive (-Wundef)" superClass="gnu.c.compiler.option.warnings.wundef" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wwritestrings.2074558097" name="Treat strings always as const (-Wwrite-strings)" superClass="gnu.c.compiler.option.warnings.wwritestrings" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.warnings.wfloatequal.1198098334" name="Direct float equal check (-Wfloat-equal)" superClass="gnu.c.compiler.option.warnings.wfloatequal" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.misc.other.1655520140" name="Other flags" superClass="gnu.c.compiler.option.misc.other" useByScannerDiscovery="false" value="-c -ffunction-sections -fdata-sections -ffreestanding -fno-builtin" valueType="string"/>
<option id="gnu.c.compiler.option.misc.verbose.622199588" name="Verbose (-v)" superClass="gnu.c.compiler.option.misc.verbose" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.misc.ansi.1228433184" name="Support ANSI programs (-ansi)" superClass="gnu.c.compiler.option.misc.ansi" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.misc.pic.987892380" name="Position Independent Code (-fPIC)" superClass="gnu.c.compiler.option.misc.pic" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.misc.hardening.1905317116" name="Hardening options (-fstack-protector-all -Wformat=2 -Wformat-security -Wstrict-overflow)" superClass="gnu.c.compiler.option.misc.hardening" useByScannerDiscovery="false"/>
<option id="gnu.c.compiler.option.misc.randomization.1647925559" name="Address randomization (-fPIE)" superClass="gnu.c.compiler.option.misc.randomization" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.lto.1570699403" name="Enable Link-time optimization (-flto)" superClass="com.crt.advproject.gcc.lto" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.lto.fat.238250664" name="Fat lto objects (-ffat-lto-objects)" superClass="com.crt.advproject.gcc.lto.fat" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.merge.constants.593921303" name="Merge Identical Constants (-fmerge-constants)" superClass="com.crt.advproject.gcc.merge.constants" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.prefixmap.219398517" name="Remove path from __FILE__ (-fmacro-prefix-map)" superClass="com.crt.advproject.gcc.prefixmap" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.fpu.1135926335" name="Floating point" superClass="com.crt.advproject.gcc.fpu" useByScannerDiscovery="true" value="com.crt.advproject.gcc.fpu.fpv5sp.hard" valueType="enumerated"/>
<option id="com.crt.advproject.gcc.thumbinterwork.335443393" name="Enable Thumb interworking" superClass="com.crt.advproject.gcc.thumbinterwork" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.securestate.1612744170" name="TrustZone Project Type" superClass="com.crt.advproject.gcc.securestate" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.hdrlib.723741774" name="Library headers" superClass="com.crt.advproject.gcc.hdrlib" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.stackusage.718795596" name="Generate Stack Usage Info (-fstack-usage)" superClass="com.crt.advproject.gcc.stackusage" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.specs.842164340" name="Specs" superClass="com.crt.advproject.gcc.specs" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.config.2028652183" name="Obsolete (Config)" superClass="com.crt.advproject.gcc.config" useByScannerDiscovery="false"/>
<option id="com.crt.advproject.gcc.store.500177831" name="Obsolete (Store)" superClass="com.crt.advproject.gcc.store" useByScannerDiscovery="false"/>
<inputType id="com.crt.advproject.compiler.input.1908004208" superClass="com.crt.advproject.compiler.input"/>
</tool>
<tool id="com.crt.advproject.gas.exe.release.1932729147" name="MCU Assembler" superClass="com.crt.advproject.gas.exe.release">
<option id="com.crt.advproject.gas.thumb.619437045" name="Thumb mode" superClass="com.crt.advproject.gas.thumb" value="true" valueType="boolean"/>
<option id="com.crt.advproject.gas.arch.815956877" name="Architecture" superClass="com.crt.advproject.gas.arch" value="com.crt.advproject.gas.target.cm33" valueType="enumerated"/>
<option id="gnu.both.asm.option.flags.crt.663096744" name="Assembler flags" superClass="gnu.both.asm.option.flags.crt" value="-c -x assembler-with-cpp -D__REDLIB__" valueType="string"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.both.asm.option.include.paths.421703171" name="Include paths (-I)" superClass="gnu.both.asm.option.include.paths" valueType="includePath">
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/board}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/${ProjName}/source}&quot;"/>
</option>
<option id="gnu.both.asm.option.warnings.nowarn.691242963" name="Suppress warnings (-W)" superClass="gnu.both.asm.option.warnings.nowarn"/>
<option id="gnu.both.asm.option.version.1262888856" name="Announce version (-v)" superClass="gnu.both.asm.option.version"/>
<option id="com.crt.advproject.gas.fpu.750963181" name="Floating point" superClass="com.crt.advproject.gas.fpu" value="com.crt.advproject.gas.fpu.fpv5sp.hard" valueType="enumerated"/>
<option id="com.crt.advproject.gas.thumbinterwork.1583817659" name="Enable Thumb interworking" superClass="com.crt.advproject.gas.thumbinterwork"/>
<option id="com.crt.advproject.gas.hdrlib.1517273739" name="Library headers" superClass="com.crt.advproject.gas.hdrlib"/>
<option id="com.crt.advproject.gas.specs.1151866155" name="Specs" superClass="com.crt.advproject.gas.specs"/>
<option id="com.crt.advproject.gas.config.461265307" name="Obsolete (Config)" superClass="com.crt.advproject.gas.config"/>
<option id="com.crt.advproject.gas.store.289806025" name="Obsolete (Store)" superClass="com.crt.advproject.gas.store"/>
<inputType id="cdt.managedbuild.tool.gnu.assembler.input.1673974900" superClass="cdt.managedbuild.tool.gnu.assembler.input"/>
<inputType id="com.crt.advproject.assembler.input.395725921" name="Additional Assembly Source Files" superClass="com.crt.advproject.assembler.input"/>
</tool>
<tool id="com.crt.advproject.link.cpp.exe.release.1084367739" name="MCU C++ Linker" superClass="com.crt.advproject.link.cpp.exe.release">
<option id="com.crt.advproject.link.cpp.arch.158813615" name="Architecture" superClass="com.crt.advproject.link.cpp.arch" value="com.crt.advproject.link.cpp.target.cm33" valueType="enumerated"/>
<option id="gnu.cpp.link.option.nostart.2139620622" name="Do not use standard start files (-nostartfiles)" superClass="gnu.cpp.link.option.nostart"/>
<option id="gnu.cpp.link.option.nodeflibs.173862824" name="Do not use default libraries (-nodefaultlibs)" superClass="gnu.cpp.link.option.nodeflibs"/>
<option id="gnu.cpp.link.option.nostdlibs.1467790521" name="No startup or default libs (-nostdlib)" superClass="gnu.cpp.link.option.nostdlibs" value="true" valueType="boolean"/>
<option id="gnu.cpp.link.option.strip.68575674" name="Omit all symbol information (-s)" superClass="gnu.cpp.link.option.strip"/>
<option id="gnu.cpp.link.option.libs.784022810" name="Libraries (-l)" superClass="gnu.cpp.link.option.libs"/>
<option id="gnu.cpp.link.option.paths.1386374632" name="Library search path (-L)" superClass="gnu.cpp.link.option.paths"/>
<option id="gnu.cpp.link.option.flags.1117301400" name="Linker flags" superClass="gnu.cpp.link.option.flags"/>
<option id="gnu.cpp.link.option.other.1677156345" name="Other options (-Xlinker [option])" superClass="gnu.cpp.link.option.other"/>
<option id="gnu.cpp.link.option.userobjs.435978854" name="Other objects" superClass="gnu.cpp.link.option.userobjs"/>
<option id="gnu.cpp.link.option.shared.1516606059" name="Shared (-shared)" superClass="gnu.cpp.link.option.shared"/>
<option id="gnu.cpp.link.option.soname.1880362190" name="Shared object name (-Wl,-soname=)" superClass="gnu.cpp.link.option.soname"/>
<option id="gnu.cpp.link.option.implname.702426310" name="Import Library name (-Wl,--out-implib=)" superClass="gnu.cpp.link.option.implname"/>
<option id="gnu.cpp.link.option.defname.1218973587" name="DEF file name (-Wl,--output-def=)" superClass="gnu.cpp.link.option.defname"/>
<option id="gnu.cpp.link.option.debugging.prof.1450233023" name="Generate prof information (-p)" superClass="gnu.cpp.link.option.debugging.prof"/>
<option id="gnu.cpp.link.option.debugging.gprof.1302729783" name="Generate gprof information (-pg)" superClass="gnu.cpp.link.option.debugging.gprof"/>
<option id="gnu.cpp.link.option.debugging.codecov.1579609276" name="Generate gcov information (-ftest-coverage -fprofile-arcs)" superClass="gnu.cpp.link.option.debugging.codecov"/>
<option id="com.crt.advproject.link.cpp.lto.428567541" name="Enable Link-time optimization (-flto)" superClass="com.crt.advproject.link.cpp.lto"/>
<option id="com.crt.advproject.link.cpp.lto.optmization.level.1741405087" name="Link-time optimization level" superClass="com.crt.advproject.link.cpp.lto.optmization.level"/>
<option id="com.crt.advproject.link.cpp.fpu.973836415" name="Floating point" superClass="com.crt.advproject.link.cpp.fpu" value="com.crt.advproject.link.cpp.fpu.fpv5sp.hard" valueType="enumerated"/>
<option id="com.crt.advproject.link.cpp.thumb.1316330818" name="Thumb mode" superClass="com.crt.advproject.link.cpp.thumb"/>
<option id="com.crt.advproject.link.cpp.manage.1650371500" name="Manage linker script" superClass="com.crt.advproject.link.cpp.manage"/>
<option id="com.crt.advproject.link.cpp.script.665145291" name="Linker script" superClass="com.crt.advproject.link.cpp.script"/>
<option id="com.crt.advproject.link.cpp.scriptdir.592055356" name="Script path" superClass="com.crt.advproject.link.cpp.scriptdir"/>
<option id="com.crt.advproject.link.cpp.crpenable.1725851883" name="Enable automatic placement of Code Read Protection field in image" superClass="com.crt.advproject.link.cpp.crpenable"/>
<option id="com.crt.advproject.link.cpp.flashconfigenable.1448847636" name="Enable automatic placement of Flash Configuration field in image" superClass="com.crt.advproject.link.cpp.flashconfigenable" value="true" valueType="boolean"/>
<option id="com.crt.advproject.link.cpp.ecrp.1654645775" name="Enhanced CRP" superClass="com.crt.advproject.link.cpp.ecrp"/>
<option id="com.crt.advproject.link.cpp.hdrlib.1399400737" name="Library" superClass="com.crt.advproject.link.cpp.hdrlib"/>
<option id="com.crt.advproject.link.cpp.nanofloat.675888724" name="Enable printf float " superClass="com.crt.advproject.link.cpp.nanofloat"/>
<option id="com.crt.advproject.link.cpp.nanofloat.scanf.1064640127" name="Enable scanf float " superClass="com.crt.advproject.link.cpp.nanofloat.scanf"/>
<option id="com.crt.advproject.link.cpp.toram.234660781" name="Link application to RAM" superClass="com.crt.advproject.link.cpp.toram"/>
<option id="com.crt.advproject.link.memory.load.image.cpp.910315866" name="Plain load image" superClass="com.crt.advproject.link.memory.load.image.cpp"/>
<option id="com.crt.advproject.link.memory.heapAndStack.style.cpp.536134548" name="Heap and Stack placement" superClass="com.crt.advproject.link.memory.heapAndStack.style.cpp"/>
<option id="com.crt.advproject.link.cpp.stackOffset.62187820" name="Stack offset" superClass="com.crt.advproject.link.cpp.stackOffset"/>
<option id="com.crt.advproject.link.memory.heapAndStack.cpp.909789288" name="Heap and Stack options" superClass="com.crt.advproject.link.memory.heapAndStack.cpp"/>
<option id="com.crt.advproject.link.memory.data.cpp.189601767" name="Global data placement" superClass="com.crt.advproject.link.memory.data.cpp"/>
<option id="com.crt.advproject.link.memory.sections.cpp.1613883928" name="Extra linker script input sections" superClass="com.crt.advproject.link.memory.sections.cpp"/>
<option id="com.crt.advproject.link.cpp.multicore.slave.224569959" name="Multicore configuration" superClass="com.crt.advproject.link.cpp.multicore.slave"/>
<option id="com.crt.advproject.link.cpp.multicore.master.1634714428" name="Multicore master" superClass="com.crt.advproject.link.cpp.multicore.master"/>
<option id="com.crt.advproject.link.cpp.multicore.empty.1113293229" name="No Multicore options for this project" superClass="com.crt.advproject.link.cpp.multicore.empty"/>
<option id="com.crt.advproject.link.cpp.multicore.master.userobjs.1632017749" name="Slave Objects (not visible)" superClass="com.crt.advproject.link.cpp.multicore.master.userobjs"/>
<option id="com.crt.advproject.link.cpp.config.1723472872" name="Obsolete (Config)" superClass="com.crt.advproject.link.cpp.config"/>
<option id="com.crt.advproject.link.cpp.store.1132120694" name="Obsolete (Store)" superClass="com.crt.advproject.link.cpp.store"/>
<option id="com.crt.advproject.link.cpp.securestate.259247081" name="TrustZone Project Type" superClass="com.crt.advproject.link.cpp.securestate"/>
<option id="com.crt.advproject.link.cpp.sgstubs.placement.688868732" name="Secure Gateway Placement" superClass="com.crt.advproject.link.cpp.sgstubs.placement"/>
<option id="com.crt.advproject.link.cpp.sgstubenable.436640612" name="Enable generation of Secure Gateway Import Library" superClass="com.crt.advproject.link.cpp.sgstubenable"/>
<option id="com.crt.advproject.link.cpp.nonsecureobject.1091905358" name="Secure Gateway Import Library" superClass="com.crt.advproject.link.cpp.nonsecureobject"/>
<option id="com.crt.advproject.link.cpp.inimplib.1741887818" name="Input Secure Gateway Import Library" superClass="com.crt.advproject.link.cpp.inimplib"/>
</tool>
<tool id="com.crt.advproject.link.exe.release.35646713" name="MCU Linker" superClass="com.crt.advproject.link.exe.release">
<option id="com.crt.advproject.link.thumb.1651780783" name="Thumb mode" superClass="com.crt.advproject.link.thumb" value="true" valueType="boolean"/>
<option id="com.crt.advproject.link.memory.load.image.1714613634" name="Plain load image" superClass="com.crt.advproject.link.memory.load.image" useByScannerDiscovery="false" value="" valueType="string"/>
<option defaultValue="com.crt.advproject.heapAndStack.mcuXpressoStyle" id="com.crt.advproject.link.memory.heapAndStack.style.1872766025" name="Heap and Stack placement" superClass="com.crt.advproject.link.memory.heapAndStack.style" useByScannerDiscovery="false" valueType="enumerated"/>
<option id="com.crt.advproject.link.memory.heapAndStack.1733088665" name="Heap and Stack options" superClass="com.crt.advproject.link.memory.heapAndStack" value="&amp;Heap:Default;Post Data;Default&amp;Stack:Default;End;Default" valueType="string"/>
<option id="com.crt.advproject.link.memory.data.1805190674" name="Global data placement" superClass="com.crt.advproject.link.memory.data" useByScannerDiscovery="false" value="" valueType="string"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="true" id="com.crt.advproject.link.memory.sections.538454219" name="Extra linker script input sections" superClass="com.crt.advproject.link.memory.sections" useByScannerDiscovery="false" valueType="stringList"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="true" id="com.crt.advproject.link.gcc.multicore.master.userobjs.1639009618" name="Slave Objects (not visible)" superClass="com.crt.advproject.link.gcc.multicore.master.userobjs" useByScannerDiscovery="false" valueType="userObjs"/>
<option id="com.crt.advproject.link.gcc.multicore.slave.965289756" name="Multicore configuration" superClass="com.crt.advproject.link.gcc.multicore.slave"/>
<option id="com.crt.advproject.link.arch.1712053111" name="Architecture" superClass="com.crt.advproject.link.arch" value="com.crt.advproject.link.target.cm33" valueType="enumerated"/>
<option id="gnu.c.link.option.nostart.1559661398" name="Do not use standard start files (-nostartfiles)" superClass="gnu.c.link.option.nostart"/>
<option id="gnu.c.link.option.nodeflibs.2103722833" name="Do not use default libraries (-nodefaultlibs)" superClass="gnu.c.link.option.nodeflibs"/>
<option id="gnu.c.link.option.nostdlibs.234526685" name="No startup or default libs (-nostdlib)" superClass="gnu.c.link.option.nostdlibs" value="true" valueType="boolean"/>
<option id="gnu.c.link.option.strip.1580700944" name="Omit all symbol information (-s)" superClass="gnu.c.link.option.strip"/>
<option id="gnu.c.link.option.noshared.1081202766" name="No shared libraries (-static)" superClass="gnu.c.link.option.noshared"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.link.option.libs.73493458" name="Libraries (-l)" superClass="gnu.c.link.option.libs" useByScannerDiscovery="false" valueType="libs">
<listOptionValue builtIn="false" value="wolfssl"/>
</option>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.link.option.paths.1689186880" name="Library search path (-L)" superClass="gnu.c.link.option.paths" useByScannerDiscovery="false" valueType="libPaths">
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/wolfssl/Release}&quot;"/>
</option>
<option id="gnu.c.link.option.ldflags.1272751139" name="Linker flags" superClass="gnu.c.link.option.ldflags"/>
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.link.option.other.767853350" name="Other options (-Xlinker [option])" superClass="gnu.c.link.option.other" valueType="stringList">
<listOptionValue builtIn="false" value="-Map=&quot;${BuildArtifactFileBaseName}.map&quot;"/>
<listOptionValue builtIn="false" value="--gc-sections"/>
<listOptionValue builtIn="false" value="-print-memory-usage"/>
<listOptionValue builtIn="false" value="--sort-section=alignment"/>
<listOptionValue builtIn="false" value="--cref"/>
</option>
<option id="gnu.c.link.option.userobjs.237317132" name="Other objects" superClass="gnu.c.link.option.userobjs"/>
<option id="gnu.c.link.option.shared.461787349" name="Shared (-shared)" superClass="gnu.c.link.option.shared"/>
<option id="gnu.c.link.option.soname.987631701" name="Shared object name (-Wl,-soname=)" superClass="gnu.c.link.option.soname"/>
<option id="gnu.c.link.option.implname.1687571648" name="Import Library name (-Wl,--out-implib=)" superClass="gnu.c.link.option.implname"/>
<option id="gnu.c.link.option.defname.1605212545" name="DEF file name (-Wl,--output-def=)" superClass="gnu.c.link.option.defname"/>
<option id="gnu.c.link.option.debugging.prof.2067511829" name="Generate prof information (-p)" superClass="gnu.c.link.option.debugging.prof"/>
<option id="gnu.c.link.option.debugging.gprof.618560430" name="Generate gprof information (-pg)" superClass="gnu.c.link.option.debugging.gprof"/>
<option id="gnu.c.link.option.debugging.codecov.1550237636" name="Generate gcov information (-ftest-coverage -fprofile-arcs)" superClass="gnu.c.link.option.debugging.codecov"/>
<option id="com.crt.advproject.link.gcc.lto.848592793" name="Enable Link-time optimization (-flto)" superClass="com.crt.advproject.link.gcc.lto"/>
<option id="com.crt.advproject.link.gcc.lto.optmization.level.2109611644" name="Link-time optimization level" superClass="com.crt.advproject.link.gcc.lto.optmization.level"/>
<option id="com.crt.advproject.link.fpu.1149734868" name="Floating point" superClass="com.crt.advproject.link.fpu" value="com.crt.advproject.link.fpu.fpv5sp.hard" valueType="enumerated"/>
<option id="com.crt.advproject.link.manage.1845785905" name="Manage linker script" superClass="com.crt.advproject.link.manage" value="true" valueType="boolean"/>
<option id="com.crt.advproject.link.script.828842441" name="Linker script" superClass="com.crt.advproject.link.script" value="wolfcrypt_test_Release.ld" valueType="string"/>
<option id="com.crt.advproject.link.scriptdir.1982039722" name="Script path" superClass="com.crt.advproject.link.scriptdir"/>
<option id="com.crt.advproject.link.crpenable.25663194" name="Enable automatic placement of Code Read Protection field in image" superClass="com.crt.advproject.link.crpenable"/>
<option id="com.crt.advproject.link.flashconfigenable.836250930" name="Enable automatic placement of Flash Configuration field in image" superClass="com.crt.advproject.link.flashconfigenable" value="true" valueType="boolean"/>
<option id="com.crt.advproject.link.ecrp.1182632702" name="Enhanced CRP" superClass="com.crt.advproject.link.ecrp"/>
<option id="com.crt.advproject.link.gcc.hdrlib.1616022818" name="Library" superClass="com.crt.advproject.link.gcc.hdrlib" value="com.crt.advproject.gcc.link.hdrlib.codered.nohost_nf" valueType="enumerated"/>
<option id="com.crt.advproject.link.gcc.nanofloat.425509913" name="Enable printf float " superClass="com.crt.advproject.link.gcc.nanofloat"/>
<option id="com.crt.advproject.link.gcc.nanofloat.scanf.365963866" name="Enable scanf float " superClass="com.crt.advproject.link.gcc.nanofloat.scanf"/>
<option id="com.crt.advproject.link.toram.907637220" name="Link application to RAM" superClass="com.crt.advproject.link.toram"/>
<option id="com.crt.advproject.link.stackOffset.697194939" name="Stack offset" superClass="com.crt.advproject.link.stackOffset"/>
<option id="com.crt.advproject.link.gcc.multicore.master.137069259" name="Multicore master" superClass="com.crt.advproject.link.gcc.multicore.master"/>
<option id="com.crt.advproject.link.gcc.multicore.empty.1040352495" name="No Multicore options for this project" superClass="com.crt.advproject.link.gcc.multicore.empty"/>
<option id="com.crt.advproject.link.config.325492993" name="Obsolete (Config)" superClass="com.crt.advproject.link.config"/>
<option id="com.crt.advproject.link.store.1889225279" name="Obsolete (Store)" superClass="com.crt.advproject.link.store"/>
<option id="com.crt.advproject.link.securestate.584125556" name="TrustZone Project Type" superClass="com.crt.advproject.link.securestate"/>
<option id="com.crt.advproject.link.sgstubs.placement.2082772936" name="Secure Gateway Placement" superClass="com.crt.advproject.link.sgstubs.placement"/>
<option id="com.crt.advproject.link.sgstubenable.1003657356" name="Enable generation of Secure Gateway Import Library" superClass="com.crt.advproject.link.sgstubenable"/>
<option id="com.crt.advproject.link.nonsecureobject.618455128" name="Secure Gateway Import Library" superClass="com.crt.advproject.link.nonsecureobject"/>
<option id="com.crt.advproject.link.inimplib.93553761" name="Input Secure Gateway Import Library" superClass="com.crt.advproject.link.inimplib"/>
<inputType id="cdt.managedbuild.tool.gnu.c.linker.input.1481453097" superClass="cdt.managedbuild.tool.gnu.c.linker.input">
<additionalInput kind="additionalinputdependency" paths="$(USER_OBJS)"/>
<additionalInput kind="additionalinput" paths="$(LIBS)"/>
</inputType>
</tool>
<tool id="com.crt.advproject.tool.debug.release.37498871" name="MCU Debugger" superClass="com.crt.advproject.tool.debug.release">
<option id="com.crt.advproject.miscellaneous.end_of_heap.872599437" name="Last used address of the heap" superClass="com.crt.advproject.miscellaneous.end_of_heap"/>
<option id="com.crt.advproject.miscellaneous.pvHeapStart.1704955883" name="First address of the heap" superClass="com.crt.advproject.miscellaneous.pvHeapStart"/>
<option id="com.crt.advproject.miscellaneous.pvHeapLimit.1092056183" name="Maximum extent of heap" superClass="com.crt.advproject.miscellaneous.pvHeapLimit"/>
<option id="com.crt.advproject.debugger.security.nonsecureimageenable.1231705536" name="Enable pre-programming of Non-Secure Image" superClass="com.crt.advproject.debugger.security.nonsecureimageenable"/>
<option id="com.crt.advproject.debugger.security.nonsecureimage.1285348664" name="Non-Secure Project" superClass="com.crt.advproject.debugger.security.nonsecureimage"/>
</tool>
</toolChain>
</folderInfo>
<sourceEntries>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="component"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="CMSIS"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="MIMXRT685S"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="source"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="utilities"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="drivers"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="device"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="fatfs"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="board"/>
<entry flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="flash_config"/>
<entry excluding="src/netif/ppp/polarssl/arc4.c|src/netif/ppp/polarssl/des.c|src/netif/ppp/polarssl/md4.c|src/netif/ppp/polarssl/md5.c|src/netif/ppp/polarssl/sha1.c" flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="lwip"/>
<entry excluding="freertos_kernel/portable/MemMang/heap_1.c|freertos_kernel/portable/MemMang/heap_2.c|freertos_kernel/portable/MemMang/heap_3.c|freertos_kernel/portable/MemMang/heap_5.c" flags="LOCAL|VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="freertos"/>
</sourceEntries>
</configuration>
</storageModule>
<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
</cconfiguration>
</storageModule>
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
<project id="wolfcrypt_test.null.1116336555" name="wolfcrypt_test" projectType="com.crt.advproject.projecttype.exe"/>
</storageModule>
<storageModule moduleId="scannerConfiguration">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
<scannerConfigBuildInfo instanceId="com.crt.advproject.config.exe.debug.468012101;com.crt.advproject.config.exe.debug.468012101.;com.crt.advproject.gas.exe.debug.1844328890;com.crt.advproject.assembler.input.174322926">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
</scannerConfigBuildInfo>
<scannerConfigBuildInfo instanceId="com.crt.advproject.config.exe.release.249423119;com.crt.advproject.config.exe.release.249423119.;com.crt.advproject.gas.exe.release.1932729147;com.crt.advproject.assembler.input.395725921">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
</scannerConfigBuildInfo>
<scannerConfigBuildInfo instanceId="com.crt.advproject.config.exe.debug.468012101;com.crt.advproject.config.exe.debug.468012101.;com.crt.advproject.gcc.exe.debug.1640480109;com.crt.advproject.compiler.input.658443557">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
</scannerConfigBuildInfo>
<scannerConfigBuildInfo instanceId="com.crt.advproject.config.exe.release.249423119;com.crt.advproject.config.exe.release.249423119.;com.crt.advproject.gcc.exe.release.493869736;com.crt.advproject.compiler.input.1908004208">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
</scannerConfigBuildInfo>
</storageModule>
<storageModule moduleId="org.eclipse.cdt.core.LanguageSettingsProviders"/>
<storageModule moduleId="com.nxp.mcuxpresso.core.datamodels">
<sdkName>SDK_2.x_EVK-MIMXRT685</sdkName>
<sdkVersion>2.12.0</sdkVersion>
<sdkComponents>middleware.freertos-kernel.MIMXRT685S;platform.drivers.lpc_iopctl.MIMXRT685S;platform.drivers.flexspi.MIMXRT685S;platform.drivers.cache_cache64.MIMXRT685S;platform.drivers.power.MIMXRT685S;platform.drivers.common.MIMXRT685S;platform.drivers.flexcomm_usart.MIMXRT685S;platform.drivers.lpc_gpio.MIMXRT685S;platform.drivers.clock.MIMXRT685S;platform.drivers.flexcomm.MIMXRT685S;platform.drivers.reset.MIMXRT685S;platform.drivers.trng.MIMXRT685S;device.MIMXRT685S_CMSIS.MIMXRT685S;CMSIS_Include_core_cm.MIMXRT685S;component.usart_adapter.MIMXRT685S;utility.debug_console.MIMXRT685S;component.serial_manager.MIMXRT685S;component.serial_manager_uart.MIMXRT685S;platform.utilities.assert.MIMXRT685S;middleware.fatfs.MIMXRT685S;middleware.fatfs.ram.MIMXRT685S;middleware.lwip.MIMXRT685S;middleware.lwip.empty_ethernetif.MIMXRT685S;platform.drivers.flash_config.evkmimxrt685.MIMXRT685S;component.lists.MIMXRT685S;project_template.evkmimxrt685.MIMXRT685S;middleware.freertos-kernel.template.MIMXRT685S;middleware.fatfs.template_ram.MIMXRT685S;middleware.lwip.template.MIMXRT685S;device.MIMXRT685S_startup.MIMXRT685S;middleware.freertos-kernel.extension.MIMXRT685S;platform.drivers.lpc_rtc.MIMXRT685S;</sdkComponents>
<boardId>evkmimxrt685</boardId>
<package>MIMXRT685SFVKB</package>
<core>cm33</core>
<coreId>cm33_MIMXRT685S</coreId>
</storageModule>
<storageModule moduleId="com.crt.config">
<projectStorage>&lt;?xml version="1.0" encoding="UTF-8"?&gt;&#13;
&lt;TargetConfig&gt;&#13;
&lt;Properties property_3="NXP" property_4="MIMXRT685S" property_count="5" version="100300"/&gt;&#13;
&lt;infoList vendor="NXP"&gt;&#13;
&lt;info chip="MIMXRT685S" name="MIMXRT685S"&gt;&#13;
&lt;chip&gt;&#13;
&lt;name&gt;MIMXRT685S&lt;/name&gt;&#13;
&lt;family&gt;MIMXRT600&lt;/family&gt;&#13;
&lt;vendor&gt;NXP&lt;/vendor&gt;&#13;
&lt;memory can_program="true" id="Flash" is_ro="true" size="0" type="Flash"/&gt;&#13;
&lt;memory id="RAM" size="4608" type="RAM"/&gt;&#13;
&lt;memoryInstance derived_from="Flash" driver="MIMXRT600_FlexSPI_B_MXIC_OPI.cfx" edited="true" id="QSPI_FLASH" location="0x8000000" size="0x800000"/&gt;&#13;
&lt;memoryInstance derived_from="RAM" edited="true" id="SRAM" location="0x80000" size="0x180000"/&gt;&#13;
&lt;memoryInstance derived_from="RAM" edited="true" id="SRAM_ROM" location="0x0" size="0x20000"/&gt;&#13;
&lt;memoryInstance derived_from="RAM" edited="true" id="SRAM_SHARED" location="0x20000" size="0x60000"/&gt;&#13;
&lt;memoryInstance derived_from="RAM" edited="true" id="SRAM_DSP" location="0x200000" size="0x280000"/&gt;&#13;
&lt;memoryInstance derived_from="RAM" edited="true" id="USB_RAM" location="0x40140000" size="0x4000"/&gt;&#13;
&lt;/chip&gt;&#13;
&lt;processor&gt;&#13;
&lt;name gcc_name="cortex-m33"&gt;Cortex-M33&lt;/name&gt;&#13;
&lt;family&gt;Cortex-M&lt;/family&gt;&#13;
&lt;/processor&gt;&#13;
&lt;/info&gt;&#13;
&lt;/infoList&gt;&#13;
&lt;/TargetConfig&gt;</projectStorage>
</storageModule>
<storageModule moduleId="org.eclipse.cdt.make.core.buildtargets"/>
<storageModule moduleId="refreshScope"/>
</cproject>

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>smc</name>
<name>wolfcrypt_test</name>
<comment></comment>
<projects>
</projects>
@ -17,15 +17,18 @@
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>com.renesas.cdt.managedbuild.renesas.misrachecker.builder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.cdt.core.cnature</nature>
<nature>com.nxp.mcuxpresso.core.datamodels.sdkNature</nature>
<nature>org.eclipse.cdt.managedbuilder.core.managedBuildNature</nature>
<nature>org.eclipse.cdt.managedbuilder.core.ScannerConfigNature</nature>
</natures>
<linkedResources>
<link>
<name>source/test</name>
<type>2</type>
<locationURI>$%7BPARENT-3-PROJECT_LOC%7D/wolfcrypt/test</locationURI>
</link>
</linkedResources>
</projectDescription>

Some files were not shown because too many files have changed in this diff Show More