Applet cannot connect to originating host

paul-strain@hlp.com
Tue, 5 May 1998 12:06:30 -0500

From: paul-strain@hlp.com
Date: Tue, 5 May 1998 12:06:30 -0500
Subject: Applet cannot connect to originating host
To: java-security@web1.javasoft.com

Java Security,

My applet cannot open a socket with a Java server application running
on the originating host. I get securtiy exceptions.

When I run the applet as a Java (client) application, there are no
problems.

I tried using the JDK 1.1.5 appletviewer and IE 4.0. I'm also running
the Windows NT Personal Web Server.

Here's the output from appetviewer:

Exception occurred during event dispatching:
sun.applet.AppletSecurityException: checkconnect.networkhost1
at
sun.applet.AppletSecurity.checkConnect(AppletSecurity.java:564)
at
sun.applet.AppletSecurity.checkConnect(AppletSecurity.java:606)
at
sun.applet.AppletSecurity.checkConnect(AppletSecurity.java:506)
at java.net.InetAddress.getAllByName0(InetAddress.java:445)
at java.net.InetAddress.getAllByName(InetAddress.java:429)
at java.net.InetAddress.getLocalHost(InetAddress.java:515)
at MainFrame.connect(MainFrame.java:28)
at MainFrame.<init>(MainFrame.java:103)
at PhoneBook.actionPerformed(PhoneBook.java:19)
at java.awt.Button.processActionEvent(Button.java:254)
at java.awt.Button.processEvent(Button.java:227)
at java.awt.Component.dispatchEventImpl(Component.java:1764)
at java.awt.Component.dispatchEvent(Component.java:1704)
at
java.awt.EventDispatchThread.run(EventDispatchThread.java:63)

I'm confused because according to http://java.sun.com/sfaq/, it
appears that I should be having this problem.

"In general, applets loaded over the net are prevented from reading
and writing files on the client file system, and from making network
connections except to the originating host."

I looked at the last Q&A archive
(http://java.sun.com/security/hypermail/java-security-archive-3/index.
html). Eric Lee had the same problem (see:
http://java.sun.com/security/hypermail/java-security-archive-3/0737.ht
ml), but there was no answer to his question.

Any help would be GREATLY appreciated.

Thanks,
Paul Strain
713-207-8760