Securing .jar file

Hi guys,
I need to secure my .jar file so that nobody can unjar it and reverse engineer it.... is there a solution in the market that you suggest to be used??
I would very much appreciate your response

How do you imagine the classes in the jar could be loaded if java cannot unjar the jar file? And if java can unjar it, so can jar.
Individual class files can be encrypted - then you need a custom ClassLoader that can decrypt them when loading them - which means someone can reverse-engineer your ClassLoader and un-encrypt the class files.
You can run your classes through an obfuscator making it more difficult to reverse-engineer the classes.

Similar Messages

  • Problem with addition of jar file to DC

    Hi WDers,
    I have a DC of type WD.
    I'm trying to add com.sap.security.api.jar file to this component so that I can get IUser and work on it.
    I have added this security jar file as an External jar file to the DC. But whenever I try to DC->Build, the jar entry is going away. So the Build is failing.
    Can you kindly let me know why this is happening?
    Or is there any other way to add a jar file so that I can use the IUser interface in my view?
    Thanks in Advance
    RK

    Hello,
    Add the Standard DC "com.sap.security.api.sda" from the SAP-JEE. This ahould solve the problem.
    To do that follow the steps:
    1. Go to the "DC Metadata" option available under the DC.
    2. Go to "Used DCs" and choose "Add used DCs" from the context menu which appears on a right click at the Used Dcs option.
    3.Select "com.sap.security.api.sda" under SAP-JEE and choose finish.
    4. Build the DC to gain access to the IUser and other related classes.
    Bala.

  • How to encrypt jar files ? (please recommand tool to secure java class file

    Dear All:
    After release of our webstart application,I begin to worry about the source code -anti compiling if jars are extracted by un-knowen user.
    Is there any tool to secure specified jars of a webstart application (wich is composed of lot jar files,I just only want to secure the "KEY" jar file)
    I also heard that obfuscator hurts performance ,My boss does not allow such solution)
    Besides,If I have to use obfuscator,Is there any setting in jnlp to noted?
    Regards
    john from Taiwan.

    We're using Klassmaster: http://www.zelix.com/klassmaster/index.html
    There are a lot of discussions about de-compiling, encrypting and so on on the web, but enctyption discussions allways end up in a catch-22 case, because you will have to supply the classloader with key to unlock your jar-files....
    obfuscation is not perfect either, but it can make it really had to get anything usefull from the de-compiled code. We have not noted any preformance problems with obfuscation, only some reflection issues :-)
    There are also some special compilers for java which creates linux / windows executables: http://www.excelsior-usa.com/jet.html but I have not tried this myself...
    Message was edited by:
    AsbjornAarrestad

  • Where is the .jar file that contain this package oracle.security.idm

    Dear Everybody
    Could you tell me where is the .jar file that contain this package
    oracle.security.idm
    Thanks for your help

    Hi,
    check jdeveloper_home\jdeveloper_10133_<version>\jlib\identitystore.jar
    Frank

  • Ep5.0 ? what jar file is the com.sap.security.api package in ?

    Hi ,
    Can i know , in Ep5.0 , what jar file has com.sap.security.api ? Please reply soon...
    Thank you ,
    avinash

    so , is there a procedure for me to use the Ep5.0 API and retrieve details from the data sources (for usermapping) ?
    Please reply me soon....
    thank you,
    avinash

  • Where is the jar file for secure Webservices??

    Hi all,
    Please, let me know where can I get jar file with SecurityProtocol and AuthenticationContext classes !
    references : http://help.sap.com/saphelp_nw04/helpdata/en/56/f26a4db4eca14780ab2c1a1e211372/frameset.htm
    web service standalone client
    thanks.

    Hi Isaac,
    <NWDS_ROOT>\SAP\JDT\eclipse\plugins\com.sap.tc.ap\comp\SAP-JEE\DCs\sap.com\webservices_lib\_comp\gen\default\public\default\lib\java\tc_sec_wssec_lib.jar
    Best regards, Maksim Rashchynki.

  • .jar file is not working properly :developed in NETBEANS

    Hi Gurus,
    i am using NETBEANS IDE 7.2.
    i am developing a project that interacts with databases 10g and COM ports of machine , these all processes are performed by .bat file which i am trying to run from jFramform , code works perfectly .bat file is also called perfectly when i run the project using F6 from the NETBEANS, for testing i placed some dialogue boxes on the form to test it ,
    but when i run executable .jar  file , form run successfully and dialogue box works perfectly but .bat file is not called by executable .jar file.
    this is how i call the .bat file...
      String filePath = "D:/pms/Libraries/portlib.bat";  
            try { 
              Process p = Runtime.getRuntime().exec(filePath); 
            } catch (Exception e) { 
                e.printStackTrace(); 
    and below is the contents of portlib.bat file
    java -jar "D:\SMS\SMS\dist\SMS.jar" 
    you must probably ask why i am calling a .jar file using .bat file .
    reason is that this .jar project sends message using GSM mobile , System.exit(); is compulsory to complete a job and then do the next one ,
    if i use the same file to execute this job it makes exit to entire the application (hope you can understand my logic).
    that's why i use extra .jar file in .bat file , when single job is completed .bat exits itself and new command is given.
    Problem is that code is working perfectly in NETBEANS when i run the project but when i run .jar then .bat file is not working  ,
    thanks.

    Thanks Sir ,
    You need to first test an example that works like the one in the article.
    There are plenty of other examples on the web - find one you like:
    http://javapapers.com/core-java/os-processes-using-java-processbuilder/
    I tried this one.
      try {
                ProcessBuilder dirProcess = new ProcessBuilder("D:/SMS/SMS/Send_message.bat");
                 File commands = new File("D:/SMS/SMS/Send_message.bat");
                 File dirOut = new File("C:/process/out.txt");
                 File dirErr = new File("C:/process/err.txt");
               dirProcess.redirectInput(commands);
                 dirProcess.redirectOutput(dirOut);
               dirProcess.redirectError(dirErr);
                 dirProcess.start();
            } catch (IOException ex) {
                Logger.getLogger(mainform.class.getName()).log(Level.SEVERE, null, ex);
    as instructed in the article i compiled  both the projects at same version or sources and libraries which is 1.7
    here is my version details
    C:\>javac -version
    javac 1.7.0_07
    C:\>java -version
    java version "1.7.0_07"
    Java(TM) SE Runtime Environment (build 1.7.0_07-b11)
    Java HotSpot(TM) Client VM (build 23.3-b01, mixed mode, sharing)
    inside the NETBEANS IDE c:\process\err.txt  remains empty and code works perfectly , but when I run executable .jar file( by double clicking on that file in dist directry) then c:\process\err.txt becomes full with this error text and there is no response from calling D:\SMS\SMS\send_message.bat
    here is the error text
    java.lang.UnsupportedClassVersionError: sms/SMSMAIN (Unsupported major.minor version 51.0)
      at java.lang.ClassLoader.defineClass0(Native Method)
      at java.lang.ClassLoader.defineClass(Unknown Source)
      at java.security.SecureClassLoader.defineClass(Unknown Source)
      at java.net.URLClassLoader.defineClass(Unknown Source)
      at java.net.URLClassLoader.access$100(Unknown Source)
      at java.net.URLClassLoader$1.run(Unknown Source)
      at java.security.AccessController.doPrivileged(Native Method)
      at java.net.URLClassLoader.findClass(Unknown Source)
      at java.lang.ClassLoader.loadClass(Unknown Source)
      at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
      at java.lang.ClassLoader.loadClass(Unknown Source)
      at java.lang.ClassLoader.loadClassInternal(Unknown Source)
    Exception in thread "main"
    here is /SMS/SMS
    unknown source ?

  • Loading jar files at execution time via URLClassLoader

    Hello�All,
    I'm�making�a�Java�SQL�Client.�I�have�practicaly�all�basic�work�done,�now�I'm�trying�to�improve�it.
    One�thing�I�want�it�to�do�is�to�allow�the�user�to�specify�new�drivers�and�to�use�them�to�make�new�connections.�To�do�this�I�have�this�class:�
    public�class�DriverFinder�extends�URLClassLoader{
    ����private�JarFile�jarFile�=�null;
    ����
    ����private�Vector�drivers�=�new�Vector();
    ����
    ����public�DriverFinder(String�jarName)�throws�Exception{
    ��������super(new�URL[]{�new�URL("jar",�"",�"file:"�+�new�File(jarName).getAbsolutePath()�+"!/")�},�ClassLoader.getSystemClassLoader());
    ��������jarFile�=�new�JarFile(new�File(jarName));
    ��������
    ��������/*
    ��������System.out.println("-->"�+�System.getProperty("java.class.path"));
    ��������System.setProperty("java.class.path",�System.getProperty("java.class.path")+File.pathSeparator+jarName);
    ��������System.out.println("-->"�+�System.getProperty("java.class.path"));
    ��������*/
    ��������
    ��������Enumeration�enumeration�=�jarFile.entries();
    ��������while(enumeration.hasMoreElements()){
    ������������String�className�=�((ZipEntry)enumeration.nextElement()).getName();
    ������������if(className.endsWith(".class")){
    ����������������className�=�className.substring(0,�className.length()-6);
    ����������������if(className.indexOf("Driver")!=-1)System.out.println(className);
    ����������������
    ����������������try{
    ��������������������Class�classe�=�loadClass(className,�true);
    ��������������������Class[]�interfaces�=�classe.getInterfaces();
    ��������������������for(int�i=0;�i<interfaces.length;�i++){
    ������������������������if(interfaces.getName().equals("java.sql.Driver")){
    ����������������������������drivers.add(classe);
    ������������������������}
    ��������������������}
    ��������������������Class�superclasse�=�classe.getSuperclass();
    ��������������������interfaces�=�superclasse.getInterfaces();
    ��������������������for(int�i=0;�i<interfaces.length;�i++){
    ������������������������if(interfaces[i].getName().equals("java.sql.Driver")){
    ����������������������������drivers.add(classe);
    ������������������������}
    ��������������������}
    ����������������}catch(NoClassDefFoundError�e){
    ����������������}catch(Exception�e){}
    ������������}
    ��������}
    ����}
    ����
    ����public�Enumeration�getDrivers(){
    ��������return�drivers.elements();
    ����}
    ����
    ����public�String�getJarFileName(){
    ��������return�jarFile.getName();
    ����}
    ����
    ����public�static�void�main(String[]�args)�throws�Exception{
    ��������DriverFinder�df�=�new�DriverFinder("D:/Classes/db2java.zip");
    ��������System.out.println("jar:�"�+�df.getJarFileName());
    ��������Enumeration�enumeration�=�df.getDrivers();
    ��������while(enumeration.hasMoreElements()){
    ������������Class�classe�=�(Class)enumeration.nextElement();
    ������������System.out.println(classe.getName());
    ��������}
    ����}
    It�loads�a�jar�and�searches�it�looking�for�drivers�(classes�implementing�directly�or�indirectly�interface�java.sql.Driver)�At�the�end�of�the�execution�I�have�found�all�drivers�in�the�jar�file.
    The�main�application�loads�jar�files�from�an�XML�file�and�instantiates�one�DriverFinder�for�each�jar�file.�The�problem�is�at�execution�time,�it�finds�the�drivers�and�i�think�loads�it�by�issuing�this�statement�(Class�classe�=�loadClass(className,�true);),�but�what�i�think�is�not�what�is�happening...�the�execution�of�my�code�throws�this�exception
    java.lang.ClassNotFoundException:�com.ibm.as400.access.AS400JDBCDriver
    ��������at�java.net.URLClassLoader$1.run(URLClassLoader.java:198)
    ��������at�java.security.AccessController.doPrivileged(Native�Method)
    ��������at�java.net.URLClassLoader.findClass(URLClassLoader.java:186)
    ��������at�java.lang.ClassLoader.loadClass(ClassLoader.java:299)
    ��������at�sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:265)
    ��������at�java.lang.ClassLoader.loadClass(ClassLoader.java:255)
    ��������at�java.lang.ClassLoader.loadClassInternal(ClassLoader.java:315)
    ��������at�java.lang.Class.forName0(Native�Method)
    ��������at�java.lang.Class.forName(Class.java:140)
    ��������at�com.marmots.database.DB.<init>(DB.java:44)
    ��������at�com.marmots.dbreplicator.DBReplicatorConfigHelper.carregaConfiguracio(DBReplicatorConfigHelper.java:296)
    ��������at�com.marmots.dbreplicator.DBReplicatorConfigHelper.<init>(DBReplicatorConfigHelper.java:74)
    ��������at�com.marmots.dbreplicator.DBReplicatorAdmin.<init>(DBReplicatorAdmin.java:115)
    ��������at�com.marmots.dbreplicator.DBReplicatorAdmin.main(DBReplicatorAdmin.java:93)
    Driver�file�is�not�in�the�classpath�!!!�
    I�have�tried�also�(as�you�can�see�in�comented�lines)�to�update�System�property�java.class.path�by�adding�the�path�to�the�jar�but�neither...
    I'm�sure�I'm�making�a/some�mistake/s...�can�you�help�me?
    Thanks�in�advice,
    (if�there�is�some�incorrect�word�or�expression�excuse�me)

    Sorry i have tried to format the code, but it has changed   to �... sorry read this one...
    Hello All,
    I'm making a Java SQL Client. I have practicaly all basic work done, now I'm trying to improve it.
    One thing I want it to do is to allow the user to specify new drivers and to use them to make new connections. To do this I have this class:
    public class DriverFinder extends URLClassLoader{
    private JarFile jarFile = null;
    private Vector drivers = new Vector();
    public DriverFinder(String jarName) throws Exception{
    super(new URL[]{ new URL("jar", "", "file:" + new File(jarName).getAbsolutePath() +"!/") }, ClassLoader.getSystemClassLoader());
    jarFile = new JarFile(new File(jarName));
    System.out.println("-->" + System.getProperty("java.class.path"));
    System.setProperty("java.class.path", System.getProperty("java.class.path")+File.pathSeparator+jarName);
    System.out.println("-->" + System.getProperty("java.class.path"));
    Enumeration enumeration = jarFile.entries();
    while(enumeration.hasMoreElements()){
    String className = ((ZipEntry)enumeration.nextElement()).getName();
    if(className.endsWith(".class")){
    className = className.substring(0, className.length()-6);
    if(className.indexOf("Driver")!=-1)System.out.println(className);
    try{
    Class classe = loadClass(className, true);
    Class[] interfaces = classe.getInterfaces();
    for(int i=0; i<interfaces.length; i++){
    if(interfaces.getName().equals("java.sql.Driver")){
    drivers.add(classe);
    Class superclasse = classe.getSuperclass();
    interfaces = superclasse.getInterfaces();
    for(int i=0; i<interfaces.length; i++){
    if(interfaces[i].getName().equals("java.sql.Driver")){
    drivers.add(classe);
    }catch(NoClassDefFoundError e){
    }catch(Exception e){}
    public Enumeration getDrivers(){
    return drivers.elements();
    public String getJarFileName(){
    return jarFile.getName();
    public static void main(String[] args) throws Exception{
    DriverFinder df = new DriverFinder("D:/Classes/db2java.zip");
    System.out.println("jar: " + df.getJarFileName());
    Enumeration enumeration = df.getDrivers();
    while(enumeration.hasMoreElements()){
    Class classe = (Class)enumeration.nextElement();
    System.out.println(classe.getName());
    It loads a jar and searches it looking for drivers (classes implementing directly or indirectly interface java.sql.Driver) At the end of the execution I have found all drivers in the jar file.
    The main application loads jar files from an XML file and instantiates one DriverFinder for each jar file. The problem is at execution time, it finds the drivers and i think loads it by issuing this statement (Class classe = loadClass(className, true);), but what i think is not what is happening... the execution of my code throws this exception
    java.lang.ClassNotFoundException: com.ibm.as400.access.AS400JDBCDriver
    at java.net.URLClassLoader$1.run(URLClassLoader.java:198)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(URLClassLoader.java:186)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:299)
    at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:265)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:255)
    at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:315)
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:140)
    at com.marmots.database.DB.<init>(DB.java:44)
    at com.marmots.dbreplicator.DBReplicatorConfigHelper.carregaConfiguracio(DBReplicatorConfigHelper.java:296)
    at com.marmots.dbreplicator.DBReplicatorConfigHelper.<init>(DBReplicatorConfigHelper.java:74)
    at com.marmots.dbreplicator.DBReplicatorAdmin.<init>(DBReplicatorAdmin.java:115)
    at com.marmots.dbreplicator.DBReplicatorAdmin.main(DBReplicatorAdmin.java:93)
    Driver file is not in the classpath !!!
    I have tried also (as you can see in comented lines) to update System property java.class.path by adding the path to the jar but neither...
    I'm sure I'm making a/some mistake/s... can you help me?
    Thanks in advice,
    (if there is some incorrect word or expression excuse me)

  • How to authenticate a JWS Client download of jar files on a web server

    Here is a history of how i tried to implement the auth system:
    The resources(jar files) cannot be downloaded by any HTTP client from the server without some authentication method.
    As JWS is not reliable when using cookies (only 1.5 supports them, but with problems when in JNLP file i specify j2se version=older that 1.5) , i implemented another mecanism that works like this:
    1. 1.The template JNLP looks like this
    <?xml version="1.0" encoding="utf-8"?>
    <jnlp codebase="http://10.3.0.62/" href="mapped/#JWS_CODE#___#PLATFORM#___app2.2.jnlp">
        <information>
           bla bla
        </information>
        <security>
            <all-permissions/>
        </security>
        <resources>
            <j2se version="1.4"/>
            <jar href="http://10.3.0.62/mapped/gui.jar?jwsid=#JWS_CODE#" version="2.2"/>
            <jar href="http://10.3.0.62/mapped/data.jar?jwsid=#JWS_CODE#" version="2.2"/>
            <jar href="http://10.3.0.62/mapped/log4j.jar?jwsid=#JWS_CODE#"/>
        </resources>
        <application-desc main-class="com.bet.blues.gui.Application">
            <argument>-host</argument>
            <argument>ursus</argument>
            <argument>-port</argument>
            <argument>17771</argument>
        </application-desc>
    </jnlp>2. All resources found in /mapped/ directory are mapped to JWSServlet
    3. The users login to a site , clik on link , /mapped/app2.2.jnlp , the servlet checks if the session is active , gets the PLATFORM form browser request header , gets the JWSCODE for the logged user, replaces this in the template, and returns it to the client
    4.Now after the 1st download the JNLP file is opened by JWS Client , that checks for latest version , requesting the JNLP file again
    like this:
    GET http://10.3.0.62/mapped/f12ks21092___windows___app2.2.jnlp5.Now the servlet sees the the request has a JNLP file name with an ID and PLATFORM, and serves the JNLP as before
    6.The JWS Client will request for JAR Files
    GET http://10.3.0.62/mapped/gui.jar?jwscode=f12ks21092?version-id=2.2Note: that i have forced JWSID parameter in the URL, that's why the query string contains 2 "?"
    - forcing this is because the mapped/*.jar is redirected JnlpDownloadServlet that supports versions , diffs - i cannot use 'version' to put there the jswid param(e.g .../mapped/gui.jar version="fk12ks21092_2.2" because the JnlpDownloadServlet will not find this version , and if JWS Servlet will redirect to JnlpDownloadServlet with correct version param in request, the JWS Client will raise an exception because version responded is not right(JNLPDownloadServlet marks in response HTTP header the version of the jar so JWS CLient will chek it)
    JWS Client expects version 'fk12ks21092_ver2.2'; to correct this i should modify the JnlpDownloadServlet and i shouldnt
    THE PROBLEM :
    on older versions than 1.5 JWS Client raises an exception because it wants to create a temp file named
    " gui.jar?jwscode=f12ks21092" because it contains "?"
    Only with 1.5 that seems to parse the jar name until it meets "?" char :(
    Thats why i wanted to send an error to the client to upgrade to Java Web Start 1.5
    Now, maybe u have a solution to this problem...
    All i want is a solution to let JWS Client download jars only if the user is authenticated by some mecanism....and also support the versioning system.
    Also:
    Note that the jar names must preserve on the client JWS Cache dir ( i cannot use the same method to pass the JWSCODE when requesting the JARS as when requesting the JNLP).

    You need to look into JAAS

  • Yet another problem getting a .jar file working on Mountain Lion

    The program I need to run is used for generating sounds. Its a simple java program, set up in a Windows .msi container: http://innertotality.com/?q=node/9
    I currently have the most up to date Java build from Oracle, according to their online test: v7 update 15. However, it shows up in Terminal after a java -version command as 1.6.0_41.
    Whatever version it is, I can't get this program running on it. I've pulled the .msi file apart to get the cab file, pulled that apart to get my jar file, in this case "headwave.jar". Clicking on it makes the JRE icon appear in the dock and do its dance, then it closes down. I can repeat that all I want and never get a running app out of it. I've opened the console up and watched for messages. This is all I've managed to get:
    2/23/13 9:58:44.218 PM login[2871]: USER_PROCESS: 2871 ttys000
    Nothing more, and I've only seen that once. I get more out of Console simply dragging a word around in this box to edit this post.
    If anyone could shed some light on what I need to do to get this running, I would greatly appreciate it. There are very few Mac OS X sound tools available to do what I need so this is really holding my project back. Most everything out there has to do with professional or amateur audio editing, not pure tone generation. I tried ToneGen and it just isn't doing what I need, and Perfect Tone and Tone Generator X haven't been updated for Intel Macs.

    No I haven't, but I just tried it. I tried to cd to the desktop (worked), found the Headwave folder with ls and then cd into it, found the jar folder I extracted earlier (disk1), cd into it, etc etc. I found HeadWave.jar and knew I had the right directory. java -jar HeadWave.jar gave me the following:
    Exception in thread "AWT-EventQueue-0" java.lang.NoClassDefFoundError: Widgets/JSSampleListener
              at headwave.Main.<init>(Unknown Source)
              at headwave.Main$1.run(Unknown Source)
              at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
              at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:708)
              at java.awt.EventQueue.access$400(EventQueue.java:82)
              at java.awt.EventQueue$2.run(EventQueue.java:669)
              at java.awt.EventQueue$2.run(EventQueue.java:667)
              at java.security.AccessController.doPrivileged(Native Method)
              at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlConte xt.java:87)
              at java.awt.EventQueue.dispatchEvent(EventQueue.java:678)
              at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:29 6)
              at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211)
              at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:20 1)
              at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196)
              at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188)
              at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
    Caused by: java.lang.ClassNotFoundException: Widgets.JSSampleListener
              at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
              at java.security.AccessController.doPrivileged(Native Method)
              at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
              at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
              at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
              at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
              ... 16 more
    This is the same message I received earlier. I'm sure the info I need is hidden behind the "...16 more" lol

  • Please I can not get a .jar file to run on XP SP3 start/run/cmd/

    I can not get a .jar file to run on XP SP3 start/run/cmd/
    Please help if can figure this out. I'm convinced it is a Windows XP SP3 problem from searching on google and seeing other ppl on XP SP3 with same problem (but no working solution for myself). I'll try to be complete-listing all I've done.
    I had installed: Java SE Runtime Environment v6u14 for Windows Multi-language
    I had checked here it was working properly: http://www.java.com/en/download/manual.jsp
    I'm trying to run this jar file (soht-client-0.6.2.jar):
    http://prdownloads.sourceforge.net/telnetoverhttp/soht-java-client-0.6.2.zip?download
    http://www.ericdaugherty.com/dev/soht/javaclient.html < this is the information for the program.
    (yes the file can be executed and should open the program's window
    I wanted to post screenshot of it but friend that it's working for isn't here)
    _(Please find log of all cmds I did in this post here: http://pastebin.com/f792983df )_
    _I have extracted +'all' the files to: C:\062\+_ (I have tried using other directories, same problem)
    ++I then start/open/run/cmd+
    then I: cd C:\062\+
    then I try various commands - all+ of these do absolutely nothing- meaning no errors, no reply, no window opens, nothing except enters that directoy again:
    java -jar soht-client-0.6.2.jar
    java -jar -client soht-client-0.6.2.jar
    java -client -jar soht-client-0.6.2.jar
    java -jar soht-client-0.6.2.jar soht.properties
    soht-client-0.6.2.jar
    So I try this cmd: java soht-client-0.6.2.jar
    Reply:
    C:\062>java soht-client-0.6.2.jar
    Exception in thread "main" java.lang.NoClassDefFoundError: soht-client-0/6/2/jar
    Caused by: java.lang.ClassNotFoundException: soht-client-0.6.2.jar
    at java.net.URLClassLoader$1.run(Unknown Source)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(Unknown Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at java.lang.ClassLoader.loadClassInternal(Unknown Source)
    Could not find the main class: soht-client-0.6.2.jar. Program will exit.
    I try this cmd:
    java -jar soht-client-0.6.2.jar -client
    Reply:
    C:\062>java -jar soht-client-0.6.2.jar -client
    Unable to load configuration file: -client - java.io.FileNotFoundException: -cli
    ent (The system cannot find the file specified)
    SOHT Java Client
    The SOHT Java Client requires a properties file. Either start
    the application in the same directory as the soht.properties
    file, or specify the file name on the command line:
    java -jar soht-cleint-<version>.jar c:\soht.properties
    So then I do these cmds which produce the exact same error/reply just above; Unable to load..:
    j_ava -jar soht-client-0.6.2.jar -client soht.properties_
    java -jar soht-client-0.6.2.jar -client C:\062\soht.properties
    So then I copy soht.properties to C root and do:
    java -jar soht-client-0.6.2.jar -client C:\soht.properties <same error as above
    Then from other information I have read I right click on the .jar file, select open with Always open with:
    _"C:\Program Files\Java\jre6\bin\javaw.exe"_
    Try again.. same problem.
    Then I do cmd:
    _"C:\Program Files\Java\jre6\bin\javaw.exe" -jar "C:\062\soht-client-0.6.2.jar"_
    does nothing, retry the other commands same thing (either nothing or those same replies)
    Then I read (http://forums.sun.com/thread.jspa?threadID=5384879) someone had the same problem as I and they solved it by uninstalling all Java/reboot/ then install JDK 6 Update 14 with NetBeans 6.5.1 start NetBeans and then it worked for them.
    So I unistalled all Java, rebooted and gave the cmd another try (before re-installing), now a new error, of course:
    C:\062>java -jar soht-client-0.6.2.jar
    'java' is not recognized as an internal or external command, operable program or batch file.
    Then I install  Java SE and NetBeans Cobundle (JDK 6u14 and NB 6.5.1) Final Release/ reboot/ open Netbeans/
    go to test java page; all is good, run cmds again -and still nothing..
    C:\062>java -version
    java version "1.6.0_14"
    Java(TM) SE Runtime Environment (build 1.6.0_14-b08)
    Java HotSpot(TM) Client VM (build 14.0-b16, mixed mode, sharing)
    I reassociate program with: C:\Program Files\Java\jre1.6.007\bin\javaw.exe_
    same thing.. nothing
    Thank you very much for your time :D_
    PS. My computer has been newly reformatted so needing another reformat I'm sure is not the solution.

    Thank you very much for your replies Taggert_77 & swmtgoet_x :D
    Taggert77_: I have never used NetBeans. I only installed it in the bundle as I had read on another post that somehow installing the bundle magically helped another user with the same problem (he didn't know why it worked after that either).
    Before XP SP3 I was able to execute .jar file through cmd prompt. Now I am not.
    This file is executable, grab it and you will see. Here is a screen shot (program in front is FlashFXP, behind is the cmd prompt and what should happen):http://www.freeimagehosting.net/uploads/53273b4ddf.jpg
    swmtgoetx_: I only did the other cmd's to try to make it spit out something, anything lol :D
    The proper cmd is simply: java -jar soht-client-0.6.2.jar
    I did give your cmd a try, and it produced nothing :( (just like the other correct cmds)
    java -client -jar soht-client-0.6.2.jar soht.properties
    Thank you again...the mystery remains
    PS. If you do a search for this you'll find an amazing amount of XP SP3 users with the same problem and no solution posted that I could find except one chap that did the unistall install order that I did above).

  • Can't run JavaFX app as a jar file from command line

    I'm trying to build a JavaFX app from scratch (that is, by including the jar file from the JavaFX SDK rather than by using the special JavaFX project type from NetBeans). It runs fine in NetBeans. However, when I try to launch it as a jar file from the command line (using "java -jar dist\TestApp") I get the following. Has anybody seen this before, and if so how can I fix it?:
    *** Fallback to Prism SW pipeline
    Exception in thread "main" java.lang.RuntimeException: java.lang.UnsatisfiedLink
    Error: Can't load library: C:\dev\TestApp\dist\bin\mat.dll
    at com.sun.javafx.tk.quantum.QuantumToolkit.startup(QuantumToolkit.java:
    289)
    at com.sun.javafx.application.PlatformImpl.startup(PlatformImpl.java:68)
    at com.sun.javafx.application.LauncherImpl.launchApplication1(LauncherIm
    pl.java:145)
    at com.sun.javafx.application.LauncherImpl.access$000(LauncherImpl.java:
    27)
    at com.sun.javafx.application.LauncherImpl$1.run(LauncherImpl.java:97)
    at java.lang.Thread.run(Unknown Source)
    Caused by: java.lang.UnsatisfiedLinkError: Can't load library: C:\dev\RedactionT
    oolPrototype\RedactionToolPrototype.Core\dist\bin\mat.dll
    at java.lang.ClassLoader.loadLibrary(Unknown Source)
    at java.lang.Runtime.load0(Unknown Source)
    at java.lang.System.load(Unknown Source)
    at com.sun.glass.utils.NativeLibLoader.loadLibraryFullPath(NativeLibLoad
    er.java:155)
    at com.sun.glass.utils.NativeLibLoader.loadLibraryInternal(NativeLibLoad
    er.java:85)
    at com.sun.glass.utils.NativeLibLoader.loadLibrary(NativeLibLoader.java:
    30)
    at com.sun.glass.ui.Application$1.run(Application.java:28)
    at java.security.AccessController.doPrivileged(Native Method)
    at com.sun.glass.ui.Application.loadNativeLibrary(Application.java:26)
    at com.sun.glass.ui.win.WinApplication.<clinit>(WinApplication.java:33)
    at com.sun.glass.ui.win.WinPlatformFactory.createApplication(WinPlatform
    Factory.java:20)
    at com.sun.glass.ui.win.WinPlatformFactory.createApplication(WinPlatform
    Factory.java:17)
    at com.sun.glass.ui.Application.Run(Application.java:51)
    at com.sun.javafx.tk.quantum.QuantumToolkit.startup(QuantumToolkit.java:
    279)
    ... 5 more

    Unsatisfied link means that Java is trying to access a native library, but it cannot be found. As to why this error is being thrown, here is my guess:
    If you open up one of the sample jars with a zip viewer, you will see that the Manifest file has the following entries:
    >
    Manifest-Version: 1.0
    JavaFX-Version: 2.0
    implementation-vendor: Oracle
    implementation-title: BrickBreaker
    implementation-version: 1.0
    JavaFX-Application-Class: brickbreaker.Main
    Created-By: JavaFX Packager
    Main-Class: com/javafx/main/Main
    >
    In other words, a JavaFX project works a bit differently than a normal Java project. com/javafx/main/Main is used as the Main class and your "Main" class is called later.
    If you are trying to build this from a normal Java project, then com/javafx/main/Main will not be created and it will call your Main class right away. Thus, whatever setup is needed to run JavaFX will not occur.

  • Adogjf Unable to generate jar files under JAVA_TOP error while patching

    Hi,
    I'm upgrading my version of Java from 1.3.1_19 to 1.5.0_17. I downloaded the jdk-1_5_0_17-linux-i586.bin file and unpackaged it to /u0/<SID>/<SID>db/10.2.0. It unpackaged it to a new directory jdk1.5.0_17 (/u0/<SID>/<SID>db/10.2.0/jdk1.5.0_17), whereas the old version is in a directory jdk (/u0/<SID>/<SID>db/10.2.0/jdk).
    Having done that I had to run an interoperability patch (4372996). Upon running this patch I received an error at the end:
    adogjf() Unable to generate jar files under JAVA_TOP
    There were no other errors.
    I think the problem has to do with where my new java version is located but I'm not sure. I'm thinking that it's still looking under the old JAVA_TOP (/u0/<SID>/<SID>db/10.2.0/jdk) when I want it to look under the new JAVA_TOP (/u0/<SID>/<SID>db/10.2.0/jdk1.5.0_17). So, should I move the contents from the new directory (jdk1.5.0_17) to the old directory (jdk) or is there a way to 'point' it to the new JAVA_TOP.
    Please let me know if I'm totally off base and there's another solution. We're currently on EBS 11.5.10.2, DB 10.2.0.4 and RHEL 4 Update 5.
    Thanks,
    Lia.

    Here you go. Hope this helps you to help me :-). Thanks.
    +
    ** Generating the product JAR files...
    STRT_TASK: [Generate JAR files] [] [Fri Mar 27 2009 09:20:32]
    STRT_TASK: [Generate JAR files under JAVA_TOP] [] [Fri Mar 27 2009 09:20:32]
    Signing product JAR files in JAVA_TOP -
    /u0/mary/marycomn/java
    using entity Customer and certificate 1.
    Calling /u0/mary/marycomn/util/jre/1.1.8/bin/jre ...
    Successfully created javaVersionFile.
    Generating product JAR files in JAVA_TOP -
    /u0/mary/marycomn/java with command:
    adjava -mx512m -nojit oracle.apps.ad.jri.adjmx @/u0/mary/maryappl/admin/mary/out/genjars.cmd
    Reading product information from file...
    Reading language and territory information from file...
    Reading language information from applUS.txt ...
    Temporarily resetting CLASSPATH to:
    "/u0/mary/maryappl/ad/11.5.0/java/adjri.zip:/u0/mary/marycomn/util/jre/1.1.8/lib/rt.jar:/u0/mary/marycomn/util/jre/1.1.8/lib/i18n.jar:/u0/mary/marycomn/util/jre/1.1.8/lib/tools.jar:/u0/mary/marycomn/java/appsborg.zip:/u0/mary/marycomn/java/apps.zip:/u0/mary/maryora/8.0.6/forms60/java:/u0/mary/marycomn/java"
    Calling /u0/mary/marycomn/util/jre/1.1.8/bin/jre ...
    The JDK version is 1.1.8
    Validating the files/directories specified for -areas option
    Validating the files/directories specified for -outputSpec option
    Validating the directory specified for -lstDir option
    About to Analyze the input areas : Fri Mar 27 2009 09:20:36
    WARNING: Will not load stale resource unit META-INF/services/javax.xml.parsers
    WARNING: Will not load stale resource unit META-INF/services/javax.xml.transform
    Done Analyzing the input areas : Fri Mar 27 2009 09:20:43
    About to Analyze/Generate jar files : Fri Mar 27 2009 09:20:43
    About to Analyze fndnetcharts.jar : Fri Mar 27 2009 09:20:43
    Up-to-date : fndnetcharts.jar
    Done Analyzing fndnetcharts.jar : Fri Mar 27 2009 09:20:44
    About to Analyze fndtdg.jar : Fri Mar 27 2009 09:20:44
    Up-to-date : fndtdg.jar
    Done Analyzing fndtdg.jar : Fri Mar 27 2009 09:20:44
    About to Analyze fndjgl.jar : Fri Mar 27 2009 09:20:44
    Up-to-date : fndjgl.jar
    Done Analyzing fndjgl.jar : Fri Mar 27 2009 09:20:45
    About to Analyze fndjle.jar : Fri Mar 27 2009 09:20:45
    Up-to-date : fndjle.jar
    Done Analyzing fndjle.jar : Fri Mar 27 2009 09:20:47
    About to Analyze fndlrucache.jar : Fri Mar 27 2009 09:20:47
    Up-to-date : fndlrucache.jar
    Done Analyzing fndlrucache.jar : Fri Mar 27 2009 09:20:47
    About to Analyze fndgantt.jar : Fri Mar 27 2009 09:20:47
    Up-to-date : fndgantt.jar
    Done Analyzing fndgantt.jar : Fri Mar 27 2009 09:20:47
    About to Analyze fndpromise.jar : Fri Mar 27 2009 09:20:47
    Up-to-date : fndpromise.jar
    Done Analyzing fndpromise.jar : Fri Mar 27 2009 09:20:48
    About to Analyze fndforms.jar : Fri Mar 27 2009 09:20:48
    About to Generate fndforms.jar : Fri Mar 27 2009 09:20:49
    Done Generating fndforms.jar : Fri Mar 27 2009 09:20:50
    About to Sign fndforms.jar : Fri Mar 27 2009 09:20:50
    ERROR: Javakey subcommand exited with status 1
    Javakey standard output:
    Adding entry: META-INF/MANIFEST.MF
    Copyright (c) 2002 Oracle Corporation
    Redwood Shores, California, USA
    AD Java Key Generation
    Version 11.5.0
    NOTE: You may not use this utility for custom development
    unless you have written permission from Oracle Corporation.
    Javakey error output:
    Reading product information from file...
    Reading language and territory information from file...
    Reading language information from applUS.txt ...
    Successfully created javaVersionFile.
    Customer not found in database.
    java key error:
    adjava -ms128m -mx256m sun.security.provider.Main -gs /u0/mary/marycomn/java/oracle/apps/fnd/jar/fndforms.jar.tmp /u0/mary/marycomn/java/oracle/apps/fnd/jar/fndforms.jar.uns
    The above Java program failed with error code 1.
    Done Analyzing/Generating jar files : Fri Mar 27 2009 09:20:51
    AD Run Java Command is complete.
    Copyright (c) 2002 Oracle Corporation
    Redwood Shores, California, USA
    AD Java
    Version 11.5.0
    NOTE: You may not use this utility for custom development
    unless you have written permission from Oracle Corporation.
    Failed to generate product JAR files in JAVA_TOP -
    /u0/mary/marycomn/java.
    adogjf() Unable to generate jar files under JAVA_TOP
    AutoPatch error:
    Failed to generate the product JAR files
    You should check the file
    /u0/mary/maryappl/admin/mary/log/4372996.log
    for errors.
    +

  • Reading from the Applet's JAR file.

    Is it possible to read a file stored in the jar file that the (unsigned) applet is being executed in? I have a line that goes like (in is just an InputStream):
    in = getClass().getResource( "/exercise.xml" ).openStream();
    and then, in another class, i do (bulider is an instance of javax.xml.parsers.DocumentBuilder, created from the DocumentBuilderFactory class):
    doc = builder.parse( in );
    but this always results in a security exception (works fine from the applet viewer). I tried specifying the full path to the .jar file as the codebase, but got the same results. I have not tested this from an actual web server, i am only opening the .html file directly in IE.
    Due to the nature of the application, it is not possible to host the file seperately on a webserver.
    It seems to me that there is no reason an applet shouldnt be allowed to load a file from the .jar it is executing in, could this simply be a problem of the file being local, and thus linked to from a file:// tag?
    Thanks for any help.
    Thomas Stephens

    Hi Guys
    I have figured out this problem. It's got to do with classloader.
    Applet uses a separate classloader. So using the static getSystemResource(),
    we never get contents from applet jar files. The following will work nicely.
    It is noted that you must loacate the applet classloader as in the first line
    and use the non-static method getResource();
    ObjectInJar obj = new ObjectInJar(); // create an object with a class in the jar file.
    ClassLoader cl = obj.getClass().getClassLoader();
    InputStream stream = cl.getResource("your_filepath_in_jar").openStream();
    Cheers.

  • Can't open .jar file, says it cannot be launched, Help?

    I'm trying to download this mod for a game called minecraft. It involves opening a jar file to begin the installation, but everytime i click on the jar file it comes up with this message: The Java JAR file “YOGBOX Installer.jar” could not be launched. Check the Console for possible error messages.     I have checked the Console and there doesn't seem to be any recent messages. I have tried opening the file with a different application than the default Java launcher, but it doesn't open the installation window i need. Please help, i have tried all i could. Any ideas?

    This is what popped up after i typed all that in :
    Exception in thread "main" java.lang.UnsupportedClassVersionError: Bad version number in .class file
              at java.lang.ClassLoader.defineClass1(Native Method)
              at java.lang.ClassLoader.defineClass(ClassLoader.java:676)
              at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
              at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
              at java.net.URLClassLoader.access$100(URLClassLoader.java:56)
              at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
              at java.security.AccessController.doPrivileged(Native Method)
              at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
              at java.lang.ClassLoader.loadClass(ClassLoader.java:317)
              at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:280)
              at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
              at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:375)

Maybe you are looking for

  • Why is my last thread I entered locked?

    Can somebody tell me how to unlock my last thread I entered which is "I search for the SAP transaction for customer part-payment" Thanks, Anita

  • Mail Notifications Not Appearing

    I have just noticed that my mail notifications are not appearing on the side. I have double checked that all of the settings are right, but still no joy. Anyone got any ideas.

  • Getting Previous Period Date

    Hello - I'm wondering if anyone can help. Im currently developing a tool which filters and aggregates some data. I have the user to be able to select a period for example - 01/01/2010 to 07/10/2010. Then, I want to compare the selected data with the

  • Standard SAP code is calling HTTP - want it to call HTTPS

    We have recently switched our environment to HTTPS however some SAP code such as this: FORM get_url  USING    p_application               CHANGING p_url.   DATA: lw_application_name TYPE string.   lw_application_name = p_application.   CALL METHOD cl

  • BADI for COVGR Feature.

    We have a requirement that coverage for certain insurance plan should be based on number of dependents. Tried following options: (1) Enhance Feature - COVGR using "program option". This didl not work because PERNR or any other employee attribute whic