Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use MBedTLS 3.5.1 #184

Merged
merged 13 commits into from
Dec 11, 2023
Merged

Use MBedTLS 3.5.1 #184

merged 13 commits into from
Dec 11, 2023

Conversation

Skptak
Copy link
Member

@Skptak Skptak commented Nov 16, 2023

Description

Use MBedTLS 3.5.1 for the corePKCS11 MBedTLS tests
Add some new checks to account for the changes
Wrap certain sections related to crypto operations in config checks
Swap the Windows port to use WIN32_LEAN_AND_MEAN and winsock2.h for compatibility with mbedtls v3.5.1

Test Steps

Ran the FreeRTOS-Plus WinSim demos and unit tests in this repository with these changes.

Checklist:

  • I have tested my changes. No regression in existing tests.
  • I have modified and/or added unit-tests to cover the code changes in this Pull Request.

Related Issue

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Copy link

codecov bot commented Nov 16, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (6dd11e0) 94.02% compared to head (7297a7f) 94.02%.

❗ Current head 7297a7f differs from pull request most recent head 2285c93. Consider uploading reports for the commit 2285c93 to get more accurate results

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #184   +/-   ##
=======================================
  Coverage   94.02%   94.02%           
=======================================
  Files           3        3           
  Lines        1689     1690    +1     
  Branches      442      442           
=======================================
+ Hits         1588     1589    +1     
  Misses         17       17           
  Partials       84       84           
Flag Coverage Δ
unit_tests 94.02% <100.00%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@Skptak Skptak requested a review from paulbartell November 16, 2023 22:09
…A, just going to add a log message instead. Include the mbedtls config file if defined in core_pkcs11_mbedtls.c. Change the winsock2.h include method to mirror the way it's being done in the rest of the FreeRTOS repos
@@ -32,7 +32,7 @@ jobs:
make -C build/ all

- name: Integration Tests
run: ctest --test-dir build --output-on-failure | tee -a $GITHUB_STEP_SUMMARY
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you add the "| tee -a $GITHUB_STEP_SUMMARY" back to each of the unit test runs?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The tee masks the exit code of the previous command. This means that the tests can actually fail, but the exit code of the tee is read marking it as a success.
Link to a run where this happened to show what I'm talking about can be seen here

-----------------------
30 Tests 1 Failures 0 Ignored 
FAIL


67% tests passed, 1 tests failed out of 3

Total Test time (real) =   0.03 sec

The following tests FAILED:
	  3 - pkcs11_wrapper_utest (Failed)

paulbartell
paulbartell previously approved these changes Dec 4, 2023
#include <stdio.h>
#include <string.h>

#ifdef WIN32
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Recognize that as this is the "freertos_winsim" port for this file, we shouldn't really need to check for if WIN32 is defined, just did this for if the file ever gets copied somewhere else.

@Skptak Skptak merged commit 8b5ec3b into FreeRTOS:main Dec 11, 2023
12 checks passed
@Skptak Skptak deleted the mbedtls3_5_1Upgrade branch March 26, 2024 16:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants