RFR: 8333854: IllegalAccessError with proxies after JDK-8332457 [v3]
Chen Liang
liach at openjdk.org
Wed Jun 12 20:48:41 UTC 2024
> Please review this patch that fixes a critical issue that breaks some Proxy usages.
>
> CONSTANT_Class and CONSTANT_MethodType must fail resolution for inaccessible package-private types per JVMS 5.4.3.1 and 5.4.3.5, yet such types can appear in method descriptors in the same class. The proposed way to bypass is to store the MethodType as its descriptor string in the bootstrap method arguments, and use MethodType.fromMethodDescriptorString to restore the arguments, which does not have this restriction and does not eagerly load the parameter classes. This case isn't covered by existing tests, so a new test has been added.
Chen Liang has updated the pull request incrementally with three additional commits since the last revision:
- Fix bad stack map frame
- Forgot to write field
- Try to align with previous code
-------------
Changes:
- all: https://git.openjdk.org/jdk/pull/19615/files
- new: https://git.openjdk.org/jdk/pull/19615/files/8448db2a..a57e0893
Webrevs:
- full: https://webrevs.openjdk.org/?repo=jdk&pr=19615&range=02
- incr: https://webrevs.openjdk.org/?repo=jdk&pr=19615&range=01-02
Stats: 198 lines in 1 file changed: 88 ins; 32 del; 78 mod
Patch: https://git.openjdk.org/jdk/pull/19615.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/19615/head:pull/19615
PR: https://git.openjdk.org/jdk/pull/19615
More information about the core-libs-dev
mailing list