Results 1 to 9 of 9

Thread: OpenJDK 1.8.0 Policy Tool don't exists

  1. #1
    Join Date
    Aug 2013
    Location
    Jundiai, São Paulo, Brazil
    Posts
    467

    Default OpenJDK 1.8.0 Policy Tool don't exists

    I am using KDE and Firefox
    On my PC I have an option to start-> system-> OpenJDK 1.8.0 Policy Tool
    But when I click I get the message that the program does not exist

    I have reinstalled Java, but this program is still missing.
    How do I solve this problem?

  2. #2

    Default Re: OpenJDK 1.8.0 Policy Tool don't exists

    Run it manually in a shell (Konsole, e.g.) via "policytool".

    Apparently the menu entry is "broken", it tries to run _BINDIR_/policytool.

    Code:
    $ cat /usr/share/applications/policytool.desktop      
    [Desktop Entry]
    Name=OpenJDK 1.8.0 Policy Tool
    GenericName=OpenJDK 1.8.0 Policy Tool
    Comment=Manage OpenJDK policy files
    Exec=_BINDIR_/policytool
    Icon=java
    Terminal=false
    Type=Application
    StartupWMClass=sun-security-tools-PolicyTool
    Categories=System;DesktopSettings;Security;
    Version=1.0
    
    You could of course also use the menu editor or a text editor to fix the Exec line (should be "/usr/bin/policytool", or just "policytool"...).

    Also, you should file a bug report at bugzilla.opensuse.org (against Java) so that it gets fixed.

  3. #3
    Join Date
    Aug 2013
    Location
    Jundiai, São Paulo, Brazil
    Posts
    467

    Default Re: OpenJDK 1.8.0 Policy Tool don't exists

    Quote Originally Posted by wolfi323 View Post
    Run it manually in a shell (Konsole, e.g.) via "policytool".

    Apparently the menu entry is "broken", it tries to run _BINDIR_/policytool.

    Code:
    $ cat /usr/share/applications/policytool.desktop      
    [Desktop Entry]
    Name=OpenJDK 1.8.0 Policy Tool
    GenericName=OpenJDK 1.8.0 Policy Tool
    Comment=Manage OpenJDK policy files
    Exec=_BINDIR_/policytool
    Icon=java
    Terminal=false
    Type=Application
    StartupWMClass=sun-security-tools-PolicyTool
    Categories=System;DesktopSettings;Security;
    Version=1.0
    
    You could of course also use the menu editor or a text editor to fix the Exec line (should be "/usr/bin/policytool", or just "policytool"...).

    Also, you should file a bug report at bugzilla.opensuse.org (against Java) so that it gets fixed.
    The "policytool" command worked perfectly on a console.
    Thanks for the tip.
    But this tool does not do what I need.
    I need Java to install a program that is on a website of the Brazilian government
    It should be easy, but over here these ties are complicated by being made by people who do not care about the people in general.

    To install the program, you must first download a Java application.
    This Java application downloads and installs the program I need.

    The download is successful but then the following error occurs:


    Code:
    net.sourceforge.jnlp.LaunchException: Fatal: Initialization Error: Could not initialize application. The application has not been initialized, for more information execute javaws from the command line.
        at net.sourceforge.jnlp.Launcher.createApplication(Launcher.java:813)
        at net.sourceforge.jnlp.Launcher.launchApplication(Launcher.java:532)
        at net.sourceforge.jnlp.Launcher$TgThread.run(Launcher.java:936)
    Caused by: net.sourceforge.jnlp.LaunchException: Fatal: Application Error: Cannot grant permissions to unsigned jars. Application requested security permissions, but jars are not signed.
        at net.sourceforge.jnlp.runtime.JNLPClassLoader$SecurityDelegateImpl.getClassLoaderSecurity(JNLPClassLoader.java:2393)
        at net.sourceforge.jnlp.runtime.JNLPClassLoader.setSecurity(JNLPClassLoader.java:321)
        at net.sourceforge.jnlp.runtime.JNLPClassLoader.initializeResources(JNLPClassLoader.java:734)
        at net.sourceforge.jnlp.runtime.JNLPClassLoader.<init>(JNLPClassLoader.java:285)
        at net.sourceforge.jnlp.runtime.JNLPClassLoader.createInstance(JNLPClassLoader.java:357)
        at net.sourceforge.jnlp.runtime.JNLPClassLoader.getInstance(JNLPClassLoader.java:429)
        at net.sourceforge.jnlp.runtime.JNLPClassLoader.getInstance(JNLPClassLoader.java:403)
        at net.sourceforge.jnlp.Launcher.createApplication(Launcher.java:805)
        ... 2 more
    Some people have said that this also happens with Windows and is "fixed"
    , simply type "./ControlPanel" by opening a Java window and registering the address of the site that originates the program

    Could you tell me how I can do the same inside Linux?

  4. #4
    Join Date
    Aug 2013
    Location
    Jundiai, São Paulo, Brazil
    Posts
    467

    Default Re: OpenJDK 1.8.0 Policy Tool don't exists

    Finally I was able to find the Java configuration window installed with the OpenSuse repositories

    Probably this solution is also suitable for other distros

    I removed everything that refers to java that was installed via OpenSuse distribution

    I installed the latest version of Java as instructed directly from Oracle

    After many hours, I found the file that opens the java configuration console .... Below is the link

    /usr/java/jre1.8.0_161/sun_java.desktop

    Now just make the settings ....

    I hope it passes to OpenSuse users

  5. #5
    Join Date
    Jun 2008
    Location
    San Diego, Ca, USA
    Posts
    11,283
    Blog Entries
    2

    Default Re: OpenJDK 1.8.0 Policy Tool don't exists

    A FYI

    The @OP found his solution which was to obviously install Oracle Java (The including Java Control Panel can configure how to handle unsigned applets)

    openjdk does not have a similar Java Control Panel.

    The current way to configure this is described in the following article
    https://unix.stackexchange.com/quest...ed-javaws-code

    If you have to, or are willing to disable the security check altogether (not recommended, but if you have no other immediate solution)
    https://velenux.wordpress.com/2017/0...unsigned-jars/

    HTH,
    TSU
    Beginner Wiki Quickstart - https://en.opensuse.org/User:Tsu2/Quickstart_Wiki
    Solved a problem recently? Create a wiki page for future personal reference!
    Learn something new?
    Attended a computing event?
    Post and Share!

  6. #6
    Join Date
    Aug 2013
    Location
    Jundiai, São Paulo, Brazil
    Posts
    467

    Default Re: OpenJDK 1.8.0 Policy Tool don't exists

    Quote Originally Posted by tsu2 View Post
    A FYI

    The @OP found his solution which was to obviously install Oracle Java (The including Java Control Panel can configure how to handle unsigned applets)

    openjdk does not have a similar Java Control Panel.

    The current way to configure this is described in the following article
    https://unix.stackexchange.com/quest...ed-javaws-code

    If you have to, or are willing to disable the security check altogether (not recommended, but if you have no other immediate solution)
    https://velenux.wordpress.com/2017/0...unsigned-jars/

    HTH,
    TSU
    The first link shows paths and files that do not exist in my PC... maybe they exist on Ubunto...
    I made the suggested change in the second link but the problem remains the same ....
    I rebooted the PC after editing but it remains don't run unsigned applets

  7. #7
    Join Date
    Jun 2008
    Location
    San Diego, Ca, USA
    Posts
    11,283
    Blog Entries
    2

    Default Re: OpenJDK 1.8.0 Policy Tool don't exists

    Quote Originally Posted by sergelli View Post
    The first link shows paths and files that do not exist in my PC... maybe they exist on Ubunto...
    I made the suggested change in the second link but the problem remains the same ....
    I rebooted the PC after editing but it remains don't run unsigned applets
    Been awhile since I've looked at the details...

    The files exist, but are in different locations in openSUSE...

    So, for example the java security file isn't in /etc/, for openjdk 1.8 the file is at
    Code:
    /usr/lib64/jvm/java-1.8.0-openjdk-1.8.0/jre/lib/security/java.security
    The settings in the second link can be made in this same file.

    If there are other files you're looking for, I recommend using the "locate" utility installed by the package mlocate.
    And, if you can't find any other files, just ask...

    TSU
    Beginner Wiki Quickstart - https://en.opensuse.org/User:Tsu2/Quickstart_Wiki
    Solved a problem recently? Create a wiki page for future personal reference!
    Learn something new?
    Attended a computing event?
    Post and Share!

  8. #8

    Default Re: OpenJDK 1.8.0 Policy Tool don't exists

    Quote Originally Posted by tsu2 View Post
    The files exist, but are in different locations in openSUSE...

    So, for example the java security file isn't in /etc/, for openjdk 1.8 the file is at
    Code:
    /usr/lib64/jvm/java-1.8.0-openjdk-1.8.0/jre/lib/security/java.security
    The settings in the second link can be made in this same file.
    The problem with this approach is that your changes likely get lost when you install updates, though.

    There is a /etc/java/security/security.d/ though where you could apparently put your additions (I'm not sure how exactly).
    And this also seems to imply that it might respect /etc/java/security/java.security, if you create it.


    Quote Originally Posted by tsu2 View Post
    openjdk does not have a similar Java Control Panel.

    The current way to configure this is described in the following article
    https://unix.stackexchange.com/quest...ed-javaws-code
    That link is about IcedTea AFAICS (openJDK's webbrowser plugin), which does come with a graphical config tool (as mentioned in a comment on that page), itweb-settings.

    Regarding the paths mentioned there: yes, they do seem to be "wrong", apparently the user settings are stored in ~/.config/icedtea-web/(security/) now.
    And itweb-settings should create that if it doesn't exist yet.
    Last edited by wolfi323; 20-Apr-2018 at 01:24.

  9. #9

    Default Re: OpenJDK 1.8.0 Policy Tool don't exists

    Quote Originally Posted by wolfi323 View Post
    The problem with this approach is that your changes likely get lost when you install updates, though.
    Correction: I just checked, and these files are actually marked as config files in openSUSE's java packages:
    Code:
    wolfi@amiga:~> rpm -qc java-1_8_0-openjdk-headless
    /usr/lib64/jvm/java-1.8.0-openjdk-1.8.0/jre/lib/security/blacklisted.certs
    /usr/lib64/jvm/java-1.8.0-openjdk-1.8.0/jre/lib/security/java.policy
    /usr/lib64/jvm/java-1.8.0-openjdk-1.8.0/jre/lib/security/java.security
    /usr/lib64/jvm/java-1.8.0-openjdk-1.8.0/jre/lib/security/nss.cfg
    So modifications to those files will in fact survive package updates.
    Last edited by wolfi323; 20-Apr-2018 at 03:14.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •