Add a function to check if context string is supported#2142
Merged
SWilson4 merged 1 commit intoMay 28, 2025
Conversation
Signed-off-by: M-AlNoaimi <26318936+M-AlNoaimi@users.noreply.github.com>
dstebila
approved these changes
May 26, 2025
Member
|
Thanks very much! I don't think the consistency test needs to be added, so the PR looks good as is to me. |
SWilson4
approved these changes
May 26, 2025
SWilson4
left a comment
Member
There was a problem hiding this comment.
LGTM! Thanks for the contribution.
Member
|
@open-quantum-safe/liboqs-committers This adds an API call, so please do glance at it. @vsoftco, this might be of interest to you in particular given open-quantum-safe/liboqs-python#111. |
praveksharma
approved these changes
May 26, 2025
bhess
approved these changes
May 28, 2025
SWilson4
approved these changes
May 28, 2025
Member
|
Thanks for the contribution! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hi, this PR introduces a new API function:
This was done because I noticed liboqs-python's CI kept failing, due to context string-related tests running on algorithms that don't support them, there was a work-around in the pytest but that became a bit convoluted (at least more than if liboqs itself had a feature like this).
I was able to have a C-side test to check API and struct consistency for all enabled signature algorithms, I can add this in to the PR if needed, I kept it back as I'm not totally sure if there needs to be a specific test-case for this.
./build/tests/test_sig Dilithium2
OQS_SIG_supports_ctx_str API test passed for all enabled algorithms.
Testing signature algorithms using liboqs version 0.13.1-dev
...
Sample computation for signature Dilithium2
verification passes as expected