RFR: 8277100: Dynamic dump can inadvertently overwrite default CDS archive
David Holmes
dholmes at openjdk.java.net
Mon Dec 20 22:46:31 UTC 2021
On Mon, 20 Dec 2021 18:14:05 GMT, Calvin Cheung <ccheung at openjdk.org> wrote:
> Please review this small fix for preventing the default CDS archive from being overwritten via the
> -XX:ArchiveClassesAtExit VM option.
>
> If the user sets the -XX:ArchiveClassesAtExit option pointing to the default CDS archive, VM will
> exit with the following message:
>
> `Cannot specify the default CDS archive for -XX:ArchiveClassesAtExit: <path to classes.jsa>`
>
> Passed CI tiers 1 and 2 tests.
Hi Calvin,
Fix is good, but I have to query whether this is just a P4? I suppose anyone who can overwrite the default archive this way can also restore it with -Xdump, but still this seems a bit of a usability issue worthy of a P3 and fixing in 18.
Thanks,
David
-------------
Marked as reviewed by dholmes (Reviewer).
PR: https://git.openjdk.java.net/jdk/pull/6896
More information about the hotspot-runtime-dev
mailing list