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

8314283: Support for NSS tests on aarch64 platforms #15429

Closed
wants to merge 6 commits into from

Conversation

mpdonova
Copy link
Contributor

@mpdonova mpdonova commented Aug 25, 2023

This PR updates the version of NSS to 3.91 and includes aarch64 platforms.

There is a related bug in PR (#15217) so we may want to wait for that to merge before merging this one.


Progress

  • Change must be properly reviewed (1 review required, with at least 1 Reviewer)
  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue

Issue

  • JDK-8314283: Support for NSS tests on aarch64 platforms (Bug - P3)

Reviewers

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk.git pull/15429/head:pull/15429
$ git checkout pull/15429

Update a local copy of the PR:
$ git checkout pull/15429
$ git pull https://git.openjdk.org/jdk.git pull/15429/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 15429

View PR using the GUI difftool:
$ git pr show -t 15429

Using diff file

Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/15429.diff

Webrev

Link to Webrev Comment

@bridgekeeper
Copy link

bridgekeeper bot commented Aug 25, 2023

👋 Welcome back mdonovan! A progress list of the required criteria for merging this PR into master will be added to the body of your pull request. There are additional pull request commands available for use with this pull request.

@openjdk openjdk bot added the rfr Pull request is ready for review label Aug 25, 2023
@openjdk
Copy link

openjdk bot commented Aug 25, 2023

@mpdonova The following label will be automatically applied to this pull request:

  • security

When this pull request is ready to be reviewed, an "RFR" email will be sent to the corresponding mailing list. If you would like to change these labels, use the /label pull request command.

@openjdk openjdk bot added the security security-dev@openjdk.org label Aug 25, 2023
@mlbridge
Copy link

mlbridge bot commented Aug 25, 2023

Webrevs

@DingliZhang
Copy link
Member

Hi @mpdonova thanks for this PR!

I executed sun/security/pkcs11/SampleTest.java on linux-aarch64 but the nss test is skipped.

bash configure \
--with-jtreg=/home/dingli/jdk-tools/jtreg \
--disable-warnings-as-errors \
--with-boot-jdk=/home/dingli/jdk-bin/jdk-21 \
--with-debug-level=fastdebug \
--with-native-debug-symbols=none

make test TEST="jtreg:sun/security/pkcs11/SampleTest.java" JOBS=8

Log in test-support/jtreg_test_jdk_sun_security_pkcs11_SampleTest_java/sun/security/pkcs11/SampleTest.jtr :

===> testNSS: Starting test run
Cannot resolve artifact, please check if JIB jar is present in classpath.
Warning: unsupported OS: Linux-aarch64-64, please initialize NSS library location, skipping test
testNSS: Skipped
jtreg.SkippedException: testNSS: Problem loading NSS libraries
        at PKCS11Test.testNSS(PKCS11Test.java:563)
        at PKCS11Test.main(PKCS11Test.java:205)
        at PKCS11Test.main(PKCS11Test.java:168)
        at SampleTest.main(SampleTest.java:42)
        at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
        at java.base/java.lang.reflect.Method.invoke(Method.java:580)
        at com.sun.javatest.regtest.agent.MainActionHelper$AgentVMRunnable.run(MainActionHelper.java:333)
        at java.base/java.lang.Thread.run(Thread.java:1570)

The question here is do I need to set up the jib? I tried to use bin/jib.sh but I don't know how to set JIB_SERVER(export JIB_SERVER=https://java.se.oracle.com/artifactory doesn't seem to work). Could you give me some advice? Thanks a lot!

@valeriepeng
Copy link

There is another bug id for updating the NSS version to 3.91 - https://bugs.openjdk.org/browse/JDK-8312476 Besides just changing the NSS version, we need to ensure there is corresponding NSS library in the artifactory... So, this may have to wait til 8312476 is addressed?

@mpdonova
Copy link
Contributor Author

If you have a local copy of NSS you can run the tests with jtreg instead of make. The tests expect a directory structure that looks like this:

nss/
   lib/

When I built NSS 3.91 locally, the final binaries were in nss-3.91/dist/Debug/. I created a directory, nss, and copied the bin, lib, and include directories into it:

% ls $HOME/nss-3.91/dist/Debug/nss
bin/	  include/	  lib/

I can run the test with jtreg by specifying the path in a system property:

jtreg -verbose:summary -ea -esa -a -agentvm -conc:4 -report:executed  \
    -Djdk.test.lib.artifacts.nsslib-macosx_aarch64=$HOME/nss-3.91/dist/Debug \
    test/jdk/sun/security/pkcs11/SampleTest.java

The final component of the system property will depend on that platform you're running the test on and some of the jtreg arguments and paths will be different on your machine.

@rhalade
Copy link
Member

rhalade commented Aug 29, 2023

@bridgekeeper
Copy link

bridgekeeper bot commented Sep 26, 2023

@mpdonova This pull request has been inactive for more than 4 weeks and will be automatically closed if another 4 weeks passes without any activity. To avoid this, simply add a new comment to the pull request. Feel free to ask for assistance if you need help with progressing this pull request towards integration!

@mpdonova
Copy link
Contributor Author

Waiting for #15644 to merge before merging this.

@mpdonova
Copy link
Contributor Author

mpdonova commented Oct 3, 2023

I updated this PR with changes from #15644.

name = "nsslib-windows_x64",
revision = "3.46-VS2017",
Copy link
Member

Choose a reason for hiding this comment

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

nsslib-windows_x86 support is not updated to 3.91. Is it possible to upgrade this (although we don't have it as a supported platform)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I spent a few hours trying to get this to compile but the build environment is corrupted somehow and didn't want to spend a lot of time on this since it's not supported. I can make a new bug to support if if we need it.

@openjdk
Copy link

openjdk bot commented Oct 10, 2023

@mpdonova 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:

8314283: Support for NSS tests on aarch64 platforms

Reviewed-by: rhalade

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 4 new commits pushed to the master branch:

  • 2d46b29: 8317874: Add @sealedGraph to StringTemplate.Processor.Linkage
  • 8f8c45b: 8315716: RISC-V: implement ChaCha20 intrinsic
  • 8a9c4d5: 8317675: Serial: Move gc/shared/generation to serial folder
  • bcafec5: 8316958: Add test for unstructured locking

Please see this link for an up-to-date comparison between the source branch of this pull request and the master branch.
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 master branch, type /integrate in a new comment.

@openjdk openjdk bot added the ready Pull request is ready to be integrated label Oct 10, 2023
@mpdonova
Copy link
Contributor Author

/integrate

@openjdk
Copy link

openjdk bot commented Oct 11, 2023

Going to push as commit 2a80160.
Since your change was applied there have been 5 commits pushed to the master branch:

  • 3f6d016: 8314896: additional clarifications to reversed() default methods' implementation requirements
  • 2d46b29: 8317874: Add @sealedGraph to StringTemplate.Processor.Linkage
  • 8f8c45b: 8315716: RISC-V: implement ChaCha20 intrinsic
  • 8a9c4d5: 8317675: Serial: Move gc/shared/generation to serial folder
  • bcafec5: 8316958: Add test for unstructured locking

Your commit was automatically rebased without conflicts.

@openjdk openjdk bot added the integrated Pull request has been integrated label Oct 11, 2023
@openjdk openjdk bot closed this Oct 11, 2023
@openjdk openjdk bot removed ready Pull request is ready to be integrated rfr Pull request is ready for review labels Oct 11, 2023
@openjdk
Copy link

openjdk bot commented Oct 11, 2023

@mpdonova Pushed as commit 2a80160.

💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
integrated Pull request has been integrated security security-dev@openjdk.org
4 participants