RFR: 8320396: Class-File API ClassModel::verify should include checks from hotspot/share/classfile/classFileParser.cpp [v2]

Chen Liang liach at openjdk.org
Fri Mar 22 03:45:22 UTC 2024


On Fri, 22 Mar 2024 02:23:56 GMT, David Holmes <dholmes at openjdk.org> wrote:

> So I'm not clear at what point you would run these JVMS defined structural verification checks that you are adding?

This is more like an addon module to Class-File API; it is only run when users call `ClassFile::verify`. Otherwise, Class-File API performs minimal validation that's required to generate or parse class files.
The verification can be performed on both arbitrary byte array (may be built by Class-File API) or a ClassModel (always loaded from a byte array)

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

PR Comment: https://git.openjdk.org/jdk/pull/16809#issuecomment-2014295404


More information about the core-libs-dev mailing list