Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Signing applet cab file for I.E. problem

 
Paul Bork
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
We've have an application that has an applet to print label and barcodes to a Smart Lable Printer model 100. It works fine in I.E. when running under SUN's JDK and modifying the policy.java security file to grant permission to the application http//server. It also runs under the MS JVM in I.E. whem modifying the advance setting and using custom options. The problem is that the users desktops a locked down (crippled) so that custom setting can not be used and SUN's JDK can not be used. To try and get around this I created an applet .cab file and signed it with Authenticode and changed the applet code as follows;

Original code(works fine when modifying policy.java)
APPLET_BEGIN_TAG = "<applet CODE=\"com/wfsc/rush/barcode/SLPApplet.class\" CODEBASE=\"../../\" ARCHIVE=\"slp_applet.jar\" HEIGHT=\"0\" WIDTH=\"0\">";

Modified code for cab file;
APPLET_BEGIN_TAG = "<applet CODE=\"com/wfsc/rush/barcode/SLPApplet.class\" CODEBASE=\"../../\" HEIGHT=\"0\" WIDTH=\"0\"> <PARAM name=\"cabbase\" value=\"slp_applet.cab\">";

When the applet is called, the Authenticode dialog box appears as would be expected and after clicking RUN the applet does not load. The java console reports the following;

Microsoft (R) VM for Java, 5.0 Release 5.0.0.3810
==============================================
? help
c clear
f run finalizers
g garbage collect
m memory usage
q quit
t thread list
==============================================
java.lang.ClassNotFoundException: com.wfsc.rush.barcode.SLPApplet
at com/ms/vm/loader/URLClassLoader.loadClass
at com/ms/vm/loader/URLClassLoader.loadClass
at com/ms/applet/AppletPanel.securedClassLoad
at com/ms/applet/AppletPanel.processSentEvent
at com/ms/applet/AppletPanel.processSentEvent
at com/ms/applet/AppletPanel.run
at java/lang/Thread.run

The SLPApplet class file and slp_applet.cab file are in the correct locations. What could be causing the applet not to be found?

Thanks
Paul
 
Ulf Dittmer
Rancher
Posts: 42967
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can you observe the network traffic to see whether the CAB file is actually downloaded? Can you download it manually?
 
Paul Bork
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Actually, I'm testing this locally on my pc as a local host using Tomcat and I can manually see and access all the files.

Paul
 
Ulf Dittmer
Rancher
Posts: 42967
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
By "download" I meant download over HTTP, which is what the applet would be doing. I've never used the cabbase attribute, so I don't know how it interacts with the codebase attribute. You can take a look at the Tomcat logs to see whether it gets downloaded, and from which location the JVM actually tries to download it.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic