Deploy java.policy
Asked Answered
A

2

7

I have written some Java Applets and bundled them into a signed JAR. Even though the Applets are signed, they still need to be some changes on the client concerning the java.policy file. For example, to do a print job.

To help the end user, the user can download another JAR with a small Swing app which will add the entries to their .java.policy.

My questions:

Is there a well known library to deploy/deliver/install java.policy?

The small application will simply append to the .java.policy. If run several time, the program will append the same data several times. It would be better if I only add the entry once. For that I have to parse the .java.policy and write back. Is there any library to manipulate java.policy entries?

Achondroplasia answered 23/11, 2010 at 18:13 Comment(1)
Hi , I am looking for the same tools too. We want to manage hundreds of workstation to update the java.policy file. Do you have solutions today?Hackworth
L
5

Java's Policy Tool lets you manipulate existing policy file (and even create new ones). But it's mostly geared towards developers. If you want to make it more user-friendly, I imagine you would have to write one yourself (you should be able to reuse a lot of the code from the standard policy tool).

Lacustrine answered 23/11, 2010 at 18:19 Comment(0)
F
1

I don't think changing local policy files is the correct solution. Normally your applet should name the required permission level in its manifest file, e.g.: Permissions: all-permissions Codebase: * Trusted-Only: true More on the follwing page, see "Permissions Attribute"

https://docs.oracle.com/javase/8/docs/technotes/guides/deploy/manifest.html#A1148525

The applet needs to be signed as well.

Few answered 1/12, 2015 at 1:13 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.