Skip to content

[pentest] Add automatic testing for the pentest framework #27088

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

Merged
merged 3 commits into from
May 11, 2025

Conversation

nasahlpa
Copy link
Member

@nasahlpa nasahlpa commented May 1, 2025

Until now, the pentest framework was manually tested using ot-sca. However, due to the increasing number of pentests, this PR now adds a testing framework that allows automatic testing of the IbexFi pentests.

All available IbexFi tests are executed and compared against expected test vectors.

@nasahlpa nasahlpa requested review from vogelpi and andrea-caforio May 1, 2025 14:33
@nasahlpa nasahlpa requested review from cfrantz and a team as code owners May 1, 2025 14:33
@nasahlpa nasahlpa requested review from moidx and removed request for a team May 1, 2025 14:33
@nasahlpa
Copy link
Member Author

nasahlpa commented May 1, 2025

Based on #26856, only the last 3 commits are relevant for this PR.

@nasahlpa nasahlpa force-pushed the pentest_ibex_fi_test_framework branch 2 times, most recently from 9aba4ec to b6163c9 Compare May 5, 2025 16:09
@moidx moidx removed the request for review from a team May 6, 2025 06:52
@nasahlpa nasahlpa requested review from pamaury, nbdd0121 and jwnrt and removed request for cfrantz May 9, 2025 10:36
Copy link
Contributor

@jwnrt jwnrt left a comment

Choose a reason for hiding this comment

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

Reviewed the Rust part, LGTM besides a maintainability thing

nasahlpa added 3 commits May 9, 2025 16:13
This commit enables automatic testing of the IbexFi
tests of the pentest framework.

Signed-off-by: Pascal Nasahl <[email protected]>
Detected by the automatic test framework, this commit fixes two
errors in the following tests:
- char_unrolled_reg_op_loop_chain
- char_sram_write_read

As both tests use inline assembly instructions, the code needs to
be carefully structured.

Signed-off-by: Pascal Nasahl <[email protected]>
This commit updates the pentest framework doc to include:
- The general setup and interactions with ot-sca
- The automatic testing framework

Signed-off-by: Pascal Nasahl <[email protected]>
@nasahlpa nasahlpa force-pushed the pentest_ibex_fi_test_framework branch from b6163c9 to ea80b56 Compare May 9, 2025 14:15
@nasahlpa nasahlpa merged commit 5e9efa6 into lowRISC:master May 11, 2025
45 checks passed
@nasahlpa nasahlpa deleted the pentest_ibex_fi_test_framework branch May 11, 2025 05:18
@nasahlpa nasahlpa added the CherryPick:earlgrey_1.0.0 This PR should be cherry-picked to earlgrey_1.0.0 label May 23, 2025
Copy link

Backport failed for earlgrey_1.0.0, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin earlgrey_1.0.0
git worktree add -d .worktree/backport-27088-to-earlgrey_1.0.0 origin/earlgrey_1.0.0
cd .worktree/backport-27088-to-earlgrey_1.0.0
git switch --create backport-27088-to-earlgrey_1.0.0
git cherry-pick -x 2c595fe44560885fb41957571bfda037034cc78f caa78d0cfeadb6405f0918b20a0e196d305dc81f ea80b56c72b8e738e4be73ac0b2707f16ae9b41f

@github-actions github-actions bot added the Manually CherryPick This PR should be manually cherry picked. label May 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CherryPick:earlgrey_1.0.0 This PR should be cherry-picked to earlgrey_1.0.0 Manually CherryPick This PR should be manually cherry picked.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants