[foreign-memaccess+abi] RFR: 8310659: The jar tool should support allowing access to restricted methods from executable jars

Jorn Vernee jvernee at openjdk.org
Mon Jun 26 19:35:38 UTC 2023


Add `Enable-Native-Access` jar attribute. `Enable-Native-Access: true` is equal to passing `--enable-native-access=ALL-UNNAMED` on the command line.

Question: right now I've implemented this to check if the attribute value is exactly `true`, otherwise it is ignored. Should we only allow `true` or `false`, and throw an error on other values?

Reviewer note: I've factored some of a test code for analyzing output to `TestEnableNativeAccessBase` for the enable native access tests.

-------------

Commit messages:
 - add missing newline
 - simplify condition
 - add missing test files
 - Add Enable-Native-Access jar manifest entry

Changes: https://git.openjdk.org/panama-foreign/pull/843/files
 Webrev: https://webrevs.openjdk.org/?repo=panama-foreign&pr=843&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8310659
  Stats: 397 lines in 7 files changed: 230 ins; 164 del; 3 mod
  Patch: https://git.openjdk.org/panama-foreign/pull/843.diff
  Fetch: git fetch https://git.openjdk.org/panama-foreign.git pull/843/head:pull/843

PR: https://git.openjdk.org/panama-foreign/pull/843


More information about the panama-dev mailing list