Re: VisAD Applet

Hi everyone,

Ugo Taddei wrote me with several questions regarding the recently
announced visad.browser package.  I thought I'd respond to the entire
VisAD list since many of you will probably ask a lot of the same
questions.

>It's stated in the VisAD page: "You can run in netscape if you put
>socket_applet.html on a web server on your computer."

Sorry to say, Bill misreported that information.  I have tried the
package with appletviewer, Internet Explorer, and Netscape.  As expected,
it works great in appletviewer.  With Internet Explorer, it works as long
as the codebase server of the applet is the same as the server running
Test68 (or other SocketSlaveDisplay server).  According to Netscape's
documentation, the applet should work under those conditions in Netscape
also, but that is not the case.  I have not been successful in getting
the applet to do a socket connect in Netscape--a SecurityException is
always thrown.

By default, Netscape only works with signed JAR files, not unsigned ones.
And Netscape does not support DSA encryption, only RSA encryption.  The
provided JAR signing tool that comes with the JDK 1.1, javakey, only
supports DSA encryption, not RSA.  So, to sign a JAR file in a way that
Netscape can understand, you must download and use Netscape's JAR signing
tool (I have not tried this).  Internet Explorer will launch unsigned JAR
files without a problem.

My hope is that Netscape's new Netscape 6 browser will provide more
reliable and easy to use Java applet support, but we here at SSEC have
not been able to get Java working with the current beta of Netscape 6.

>I've put the code in visad/browser in a .www directory and tried to call
>socket_applet.html from netscape (which didn't work; as I sort of
>expected ;-) I got the message: 
>
># Applet exception: class visad.browser.VisADApplet could not be loaded
>java.lang.ClassNotFoundException: visad.browser.VisADApplet
>
>(I've got java and all that stuff activated)

Netscape should load and run the applet, but it refuses to connect to the
SocketSlaveDisplay server to view and manipulate a VisAD display.  If
things are set up correctly, you should not be getting a
ClassNotFoundException.

Try removing the codebase="../.." part of the applet tag, then putting
all the visad.browser classes in the visad/browser subdirectory of your
www directory.  So for example, if you put socket_applet.html in
   ~/public_html
then try putting the visad.browser classes in
   ~/public_html/visad/browser

>Have you got an idea how to run the applet in netscape?

I know that Netscape has a few workarounds in its preferences file.
A summary of these preferences can be found at:
   http://developer.netscape.com/docs/manuals/communicator/preferences/
Enabling signed.applets.codebase_principle_support may solve the problem.
Any Netscape security experts out there who know more about this?

>Then my second question: when I minimize the window of Test68 I get a
>blak applet. Is there a way of running the applet without an application
>running on some screen?

Currently, no.  This is a limitation of Java3D 1.1.  The server feeds
image snapshots to the applet, but Java3D cannot take a snapshot if the
Java3D frame is not visible onscreen.  Java3D 1.2 can do offscreen
rendering, and VisAD will probably add support for this feature once
Java3D 1.2.1 comes out later in the year (1.2 is too buggy to be useable
in VisAD right now).

Unfortunately, Netscape has a completely different security model from
Internet Explorer.  My goal was to make the applet work in both NS and IE
without needing to be signed, and without having to change the
preferences in either NS or IE, but that does not seem possible.  I
experimented some with signing the applet, but from what I have seen on
the comp.lang.java.security newsgroup, NS and IE each require the JAR
file to be set up differently for proper operation.

Ideally, an HTML file could be set up with some Javascript that detects
which browser the user is running, and launches the corresponding signed
JAR file.  This solution should be able to get around all socket connect
problems, allowing the applet to connect to a SocketSlaveDisplay server
from any host.  If anyone out there experiments with this and can get it
working, I would appreciate hearing about it.

Curtis


  • 2000 messages navigation, sorted by:
    1. Thread
    2. Subject
    3. Author
    4. Date
    5. ↑ Table Of Contents
  • Search the visad archives: