The following link might be useful, it's a public discussion about the Oracle Java licensing topic. I am not able to verify all the statements, I'm not a lawyer, so you are on your own.
Elasticsearch, to my knowledge, does not force you to use black-magic Oracle JVM parameters such as
-XX:+UnlockCommercialFeatures -XX:+FlightRecorder -XX:StartFlightRecording=duration=60s,filename=myrecording.jfr
but it is always possible for sysadmins to tamper with the configuration after having downloaded and installed Oracle Java, and then running a Java application like Elasticsearch afterwards.
As said, it's primarily a business of the person who installed Java, not just Elasticsearch.
In order to validate, you should check the file
config/jvm.options and the environment variables
ES_JAVA_OPTS of your Elasticsearch installation for proper values, and examine the Java process command line of running processes for dubious parameters.
Also make sure to verify the Java installation on the computers for proper configuration. In case of doubt you should ask your sysadmin and/or policy/compliance/legal department for help, they are able to explain and understand the Java installations and the license agreements.