Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error with tncc #17

Open
orgads opened this issue May 16, 2014 · 7 comments
Open

Error with tncc #17

orgads opened this issue May 16, 2014 · 7 comments

Comments

@orgads
Copy link

orgads commented May 16, 2014

Exception in thread "main" java.lang.NoClassDefFoundError: netscape/javascript/JSObject                                                                  
        at com.neoteris.Logger.a(Unknown Source)                                                                                                         
        at com.neoteris.Logger.a(Unknown Source)                                                                                                         
        at com.neoteris.Logger.if(Unknown Source)                                                                                                        
        at com.neoteris.Logger.log(Unknown Source)                                                                                                       
        at net.juniper.tnc.NARPlatform.linux.LinuxNARlatform.logInfo(LinuxNARlatform.java:111)
        at net.juniper.tnc.HttpNAR.NARUtil.logInfo(NARUtil.java:59)
        at net.juniper.tnc.HttpNAR.HttpNAR.initialize(HttpNAR.java:193)
        at net.juniper.tnc.NARPlatform.linux.LinuxHttpNAR.main(LinuxHttpNAR.java:50)
Caused by: java.lang.ClassNotFoundException: netscape.javascript.JSObject
        at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
        at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
        at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
        ... 8 more

Jar can be found here

@orgads
Copy link
Author

orgads commented May 16, 2014

The problem is missing plugin.jar in classpath.

@vsnine
Copy link

vsnine commented Dec 10, 2014

On Fedora 21, adding the following before executing the jvpn.pl script solved this for me.
CLASSPATH="/usr/share/icedtea-web/plugin.jar"

@AdnanHodzic
Copy link

I have same problem on Debian Jessie (8.1).

Transfer went ok
Exception in thread "main" java.lang.NoClassDefFoundError: netscape/javascript/JSObject
    at com.neoteris.Logger.a(Unknown Source)
    at com.neoteris.Logger.a(Unknown Source)
    at com.neoteris.Logger.if(Unknown Source)
    at com.neoteris.Logger.log(Unknown Source)
    at net.juniper.tnc.NARPlatform.linux.LinuxNARlatform.logInfo(LinuxNARlatform.java:111)
    at net.juniper.tnc.HttpNAR.NARUtil.logInfo(NARUtil.java:59)
    at net.juniper.tnc.HttpNAR.HttpNAR.initialize(HttpNAR.java:193)
    at net.juniper.tnc.NARPlatform.linux.LinuxHttpNAR.main(LinuxHttpNAR.java:50)
Caused by: java.lang.ClassNotFoundException: netscape.javascript.JSObject
    at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
    at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
    at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
    ... 8 more
Unable to start tncc.jar process at ./jvpn.pl line 743.

I've run:
export CLASSPATH="/usr/share/icedtea-web/plugin.jar"
before running jvpn.pl but without success.

Any other ideas?

@orgads
Copy link
Author

orgads commented Sep 5, 2015

Do you have icedtea-netx-common installed?

plugin.jar can be in /usr/share/icedtea-web/plugin.jar or /usr/lib/jvm/jdk-7-oracle-i586/jre/lib/plugin.jar. If you have one of them it should work.

@AdnanHodzic
Copy link

In the end I went with a different solution (openconnect).

If you're interested in my setup, please see my "Juniper/Pulse Secure VPN on Linux (2015 edition)" blog post.

@juliogc
Copy link

juliogc commented Jan 30, 2018

@AdnanHodzic unfortunately the openconnect didn't solve my problem.

@orgads I could easily solve this issue by changing the openjdk to the Oracle JDK.

On Ubuntu:

$ sudo add-apt-repository ppa:webupd8team/java
$ sudo apt-get update
$ sudo apt-get install oracle-java8-installer
$ sudo update-alternatives --config java

  Selection    Path                                            Priority   Status
------------------------------------------------------------
  0            /usr/lib/jvm/java-8-oracle/jre/bin/java          1081      auto mode
  1            /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/java   1081      manual mode
* 2            /usr/lib/jvm/java-8-oracle/jre/bin/java          1081      manual mode

Press <enter> to keep the current choice[*], or type selection number: 2

@HugoDL
Copy link

HugoDL commented Sep 10, 2020

I was facing the same problem and could solve installing the package default-jre

sudo apt install default-jre

Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
default-jre-headless openjdk-11-jre openjdk-11-jre-headless
Suggested packages:
fonts-ipafont-gothic fonts-ipafont-mincho fonts-wqy-microhei | fonts-wqy-zenhei
The following NEW packages will be installed:
default-jre default-jre-headless openjdk-11-jre openjdk-11-jre-headless
0 upgraded, 4 newly installed, 0 to remove and 1 not upgraded.
Need to get 4.276 B/37,5 MB of archives.
After this operation, 171 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://sft.if.usp.br/ubuntu focal/main amd64 default-jre-headless amd64 2:1.11-72 [3.192 B]
Get:2 http://sft.if.usp.br/ubuntu focal/main amd64 default-jre amd64 2:1.11-72 [1.084 B]
Fetched 4.276 B in 0s (22,1 kB/s)
Selecting previously unselected package openjdk-11-jre-headless:amd64.
(Reading database ... 395271 files and directories currently installed.)
Preparing to unpack .../openjdk-11-jre-headless_11.0.8+10-0ubuntu120.04_amd64.deb ...
Unpacking openjdk-11-jre-headless:amd64 (11.0.8+10-0ubuntu1
20.04) ...
Selecting previously unselected package default-jre-headless.
Preparing to unpack .../default-jre-headless_2%3a1.11-72_amd64.deb ...
Unpacking default-jre-headless (2:1.11-72) ...
Selecting previously unselected package openjdk-11-jre:amd64.
Preparing to unpack .../openjdk-11-jre_11.0.8+10-0ubuntu120.04_amd64.deb ...
Unpacking openjdk-11-jre:amd64 (11.0.8+10-0ubuntu1
20.04) ...
Selecting previously unselected package default-jre.
Preparing to unpack .../default-jre_2%3a1.11-72_amd64.deb ...
Unpacking default-jre (2:1.11-72) ...
Setting up openjdk-11-jre-headless:amd64 (11.0.8+10-0ubuntu120.04) ...
update-alternatives: using /usr/lib/jvm/java-11-openjdk-amd64/bin/rmid to provide /usr/bin/rmid (rmid) in auto mode
update-alternatives: using /usr/lib/jvm/java-11-openjdk-amd64/bin/java to provide /usr/bin/java (java) in auto mode
update-alternatives: using /usr/lib/jvm/java-11-openjdk-amd64/bin/keytool to provide /usr/bin/keytool (keytool) in auto mode
update-alternatives: using /usr/lib/jvm/java-11-openjdk-amd64/bin/jjs to provide /usr/bin/jjs (jjs) in auto mode
update-alternatives: using /usr/lib/jvm/java-11-openjdk-amd64/bin/pack200 to provide /usr/bin/pack200 (pack200) in auto mode
update-alternatives: using /usr/lib/jvm/java-11-openjdk-amd64/bin/rmiregistry to provide /usr/bin/rmiregistry (rmiregistry) in auto mode
update-alternatives: using /usr/lib/jvm/java-11-openjdk-amd64/bin/unpack200 to provide /usr/bin/unpack200 (unpack200) in auto mode
update-alternatives: using /usr/lib/jvm/java-11-openjdk-amd64/bin/jfr to provide /usr/bin/jfr (jfr) in auto mode
update-alternatives: using /usr/lib/jvm/java-11-openjdk-amd64/lib/jexec to provide /usr/bin/jexec (jexec) in auto mode
Setting up openjdk-11-jre:amd64 (11.0.8+10-0ubuntu1
20.04) ...
Setting up default-jre-headless (2:1.11-72) ...
Setting up default-jre (2:1.11-72) ...
Processing triggers for mime-support (3.64ubuntu1) ...
Processing triggers for hicolor-icon-theme (0.17-2) ...
Processing triggers for gnome-menus (3.36.0-1ubuntu1) ...
Processing triggers for desktop-file-utils (0.24+linuxmint1) ...

I'm using Linux Mint 20

cat /etc/*release

DISTRIB_ID=LinuxMint
DISTRIB_RELEASE=20
DISTRIB_CODENAME=ulyana
DISTRIB_DESCRIPTION="Linux Mint 20 Ulyana"
NAME="Linux Mint"
VERSION="20 (Ulyana)"
ID=linuxmint
ID_LIKE=ubuntu
PRETTY_NAME="Linux Mint 20"
VERSION_ID="20"
HOME_URL="https://www.linuxmint.com/"
SUPPORT_URL="https://forums.ubuntu.com/"
BUG_REPORT_URL="http://linuxmint-troubleshooting-guide.readthedocs.io/en/latest/"
PRIVACY_POLICY_URL="https://www.linuxmint.com/"
VERSION_CODENAME=ulyana
UBUNTU_CODENAME=focal
cat: /etc/upstream-release: Is a directory

java --version

openjdk 11.0.8 2020-07-14
OpenJDK Runtime Environment (build 11.0.8+10-post-Ubuntu-0ubuntu120.04)
OpenJDK 64-Bit Server VM (build 11.0.8+10-post-Ubuntu-0ubuntu120.04, mixed mode, sharing)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants