Repository navigation
Fixes for DH parameter and key pair export, padPKCS7() block size checks, PKCS12 mapping comment - #299
Merged
Conversation
…tion so generateDhParams() returns p and g
…rtParams() so keys without q export p and g
…air() has no size query
…block sizes outside 1 to 255
… refer to PKCS12 instead of JKS
wolfSSL-Fenrir-bot
left a comment
There was a problem hiding this comment.
Fenrir Automated Review — PR #299
Scan targets checked: wolfcrypt-jni-src, wolfcrypt-jni-bugs
Coverage: 2 of 9 in-scope changed file(s) opened by the reviewer; not opened: jni/include/com_wolfssl_wolfcrypt_Aes.h, jni/include/com_wolfssl_wolfcrypt_AesEcb.h, jni/include/com_wolfssl_wolfcrypt_Des3.h, src/main/java/com/wolfssl/provider/jce/WolfCryptProvider.java, src/test/java/com/wolfssl/provider/jce/test/WolfCryptAlgorithmParameterGeneratorTest.java, src/test/java/com/wolfssl/wolfcrypt/test/AesTest.java, src/test/java/com/wolfssl/wolfcrypt/test/DhTest.java
Fenrir result: Approved ✅
No new issues found in the changed files.
Advisory only — this automated result does not count as a GitHub approval.
Review tier: Lite
rlm2002
approved these changes
Oct 23, 2026
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.
This PR fixes 5 Fenrir issues:
wc_DhExportParamsRaw()inDh.generateDhParams()so generated p and g are returned.qSzand a q buffer inDh.exportParams()so keys without q export p and g.Dh.exportKeyPair()buffers from p, sincewc_DhExportKeyPair()has no size query.padPKCS7()Javadoc for zero-length input and reject block sizes outside 1 to 255.WolfCryptProviderto refer to PKCS12.