Exception running CLI tool in Java 17

I am having this issue when running CLI tool (version 136) on Java 17. Our developer tells us there are no changes to their build platform. Here is the error:
at com.sonatype.insight.scan.cli.PolicyEvaluatorCli.instantiate(PolicyEvaluatorCli.java:106)
at com.sonatype.insight.scan.cli.PolicyEvaluatorCli.boot(PolicyEvaluatorCli.java:86)
at com.sonatype.insight.scan.cli.PolicyEvaluatorCli.run(PolicyEvaluatorCli.java:55)
at com.sonatype.insight.scan.cli.PolicyEvaluatorCli.main(PolicyEvaluatorCli.java:47)
Caused by: java.lang.reflect.InaccessibleObjectException: Unable to make protected final java.lang.Class java.lang.ClassLoader.defineClass(java.lang.String,byte[],int,int,java.security.ProtectionDomain) throws java.lang.ClassFormatError accessible: module java.base does not “opens java.lang” to unnamed module @3d71d552

I have never seen this before, any guidance on how to further troubleshoot? So far I told them to update to latest CLI tool, or at least 138, which is what many are using. Using Java 8 may not be feasible for the team at this time.

Ryan - if you are a licensed customer (which you have to be to run Lifecycle/Firewall) and you are an authorized support contact, you can reach out to support at https://SUPPORT.sonatype.com for assistance with any Sonatype supported product.

1 Like

We have same issue with version 1.158, do you found any solution to this issue?