karakun / OpenWebStart

Run Web Start based applications after the release of Java 11
https://openwebstart.com
Other
417 stars 48 forks source link

Continue browser jsessionid for downloading jar from OWS #578

Open satishgv1 opened 5 months ago

satishgv1 commented 5 months ago

As part of our project we are using JNLP and OWS. In the JSP, jnlp file is dynamically generated and the same is launched and executed using "jnlp://host:port/test/test.jnlp" as part of the JSP within script tag.

This downloads and launches the jnlp file using OWS. But, we can notice that JNLP is getting launched with a different JSESSIONID and trying to download the required jar and not the browser's JSESSIONID where user is authenticated.

How to use browser's JSESSIONID to launch jnlp file ?

AlBundy33 commented 3 months ago

IMO your application is responsible for session-handling. E.g. if the user downloads the file than you have a local file with no reference to the browser or a session.

But you can put your session-id in the jnlp (e.g. arguments or properties) and read it from there on application start