-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
JDK-8295405 : Add cause in a couple of IllegalArgumentException and InvalidParameterException shown by sun/security/pkcs11 tests #10726
Conversation
👋 Welcome back mbaesken! A progress list of the required criteria for merging this PR into |
Webrevs
|
There are several other files in the pkcs11 directory where cause is missing from the thrown exception. Might as well fix them all. |
Hi, I first focused on the exceptions I saw when looking into 8295343 (issues with some pkcs11 related tests on RHEL 8). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change looks good. Does it need a CSR?
@MBaesken This change now passes all automated pre-integration checks. ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details. After integration, the commit message for the final commit will be:
You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed. At the time when this comment was updated there had been 161 new commits pushed to the
As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details. ➡️ To integrate this PR with the above commit message to the |
Hi Martin , from what I read here https://wiki.openjdk.org/display/csr/CSR+FAQs no CSR is needed. But I am no expert on the topic so maybe someone else has an opinion on this ? While looking at this change, I considered adding a constructor (String,Throwable) to InvalidAlgorithmParameterException and use it in security coding to simplify coding, but I did not do this in this change; I think adding a constructor (String,Throwable) to InvalidAlgorithmParameterException would indeed need a CSR . |
src/jdk.crypto.cryptoki/share/classes/sun/security/pkcs11/P11KeyPairGenerator.java
Outdated
Show resolved
Hide resolved
It does not require a CSR.
I think you mean Note: I don't know if there is much benefit to specifying the exception message as the first argument, but I'm ok with leaving this as is if you want to avoid too many changes. For example:
Maybe we should just change these to:
I think the main benefit is that you get a localized message, if applicable. |
src/jdk.crypto.cryptoki/share/classes/sun/security/pkcs11/P11PSSSignature.java
Outdated
Show resolved
Hide resolved
Sorry I meant indeed InvalidParameterException . Thanks, Matthias |
Hi Martin and Sean, thanks for the reviews ! |
/integrate |
Going to push as commit d5d3424.
Your commit was automatically rebased without conflicts. |
We have a number of failing sun/security/pkcs11 test on RHEL 8.6, see
https://bugs.openjdk.org/browse/JDK-8295343
8295343 : sun/security/pkcs11 tests fail on Linux RHEL 8.6
The exceptions generated by these tests sometimes miss the cause (causing exception), it would be nice to have this added to get the complete exception backtrace.
Progress
Issue
Reviewers
Reviewing
Using
git
Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk pull/10726/head:pull/10726
$ git checkout pull/10726
Update a local copy of the PR:
$ git checkout pull/10726
$ git pull https://git.openjdk.org/jdk pull/10726/head
Using Skara CLI tools
Checkout this PR locally:
$ git pr checkout 10726
View PR using the GUI difftool:
$ git pr show -t 10726
Using diff file
Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/10726.diff