Start jnlp that has expired and can no longer be started without using Java Web Start

Java security is getting stricter and tighter. I feel like Ora * le is telling me to quit Java.

When I was asked to issue a digital certificate because the certificate was about to expire, I received a USB that can only be recognized by WinPC. But I don't have WinPC at hand. I have a test environment, but I can't boot from jnlp because I can't sign.

So, I'm going to launch the app without using Java Web Start. ** Note: For testing purposes only. Not recommended. ** **


Suppose you have a jnlp file that looks like this.

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<jnlp codebase="">
    <vendor>Kai Shoya</vendor>
    <jar href="main.jar"/>
    <jar href="library.jar"/>
    <j2se version="1.7+" initial-heap-size="512m" max-heap-size="1024m"/>
  <application-desc main-class="com.example.test.Main"/>

Do it this way. (vocabulary...

SCRIPT_PATH="$(cd $(dirname $0); pwd)"

mkdir -p $LIB_PATH

curl -O "$URL/main.jar"
curl -O "$URL/library.jar"

java -cp "$LIB_PATH/*" com.example.test.Main

There are three points.

  1. Combine <jnlp codebase =" http: / "> and <jar href =" main.jar "/> and fetch with curl

  2. Pass the path of the file downloaded with java -cp The path doesn't go well with -cp and -jar

  3. <application-desc main-class =" com.example.test.Main "/> is the main class name

Please note that even if you rewrite jnlp like this, a security error will occur. It took hours to resolve this. .. ..

<jnlp codebase="./lib/">

Recommended Posts

Start jnlp that has expired and can no longer be started without using Java Web Start
Problems that can easily be mistaken for Java and JavaScript
After using Android Studio 3, Java application dependencies can no longer be resolved, so what to do about it
Ruby 2.7.2 has been released and deprecated warnings will no longer be issued by default
Compiled kotlin with cli with docker and created an environment that can be executed with java