开发者

How to check if a class file version 50.0 (Java 6) has been preverified?

开发者 https://www.devze.com 2023-03-08 19:13 出处:网络
I \"upgraded\" some jar files from class file version 49.0 to 50.0 with ProGuard. Because preverification is optional with version 50.0, I wonder if there is a way to check if the class file has real

I "upgraded" some jar files from class file version 49.0 to 50.0 with ProGuard.

Because preverification is optional with version 50.0, I wonder if there is a way to check if the class file has really an StackMapTable attribute in it.

(It's not that I don't trust ProGuard "[...] The following options upgrade class files to J开发者_开发技巧ava 6, by updating their internal version numbers and preverifying them." but I'd like to learn how to verify the existance of the StackMapTable.)


Javaasist has support for reviewing stack map tables.

The one other nugget I came across was java -XX:-FailOverToOldVerifier -Xverify:all which should only verify if there is SMT information in a 50+ version class file. However, I haven't tried that and cant even tell you what it might look like on output.

0

精彩评论

暂无评论...
验证码 换一张
取 消