[6546] in java-interest

home help back first fref pref prev next nref lref last post

Re: AppletSecurity Exception

daemon@ATHENA.MIT.EDU (seokkyukong)
Wed Apr 3 18:15:46 1996

Date:         Thu, 4 Apr 1996 08:15:39 +0900
Reply-To: Java Interest <JAVA-INTEREST@JAVASOFT.COM>
From: seokkyukong <skkong@AMINET.CO.KR>
To: Multiple recipients of list JAVA-INTEREST
              <JAVA-INTEREST@JAVASOFT.COM>

Kenneth Cheng wrote:
>
> I was trying to establish an URL connection.  When I run my code as a
> standalone program, it works fine. However, when I run it as an applet,
> I receive the following error message:
>
> *** Security Exception: socket.connect:->www-leland.stanford.edu ***
> sun.applet.AppletSecurityException: security.socket.connect: ->www-leland.stanfo
> rd.edu
>         at sun.applet.AppletSecurity.checkConnect(AppletSecurity.java:424)
>         at sun.applet.AppletSecurity.checkConnect(AppletSecurity.java:363)
>         at sun.net.www.http.HttpClient.openServer(HttpClient.java:103)
>         at sun.net.www.http.HttpClient.<init>(HttpClient.java:412)
>         at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection
> .java:68)
>         at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLCon
> nection.java:159)
>         at test.getInputData(test.java:41)
>         at test.init(test.java:26)
>         at sun.applet.AppletPanel.run(AppletPanel.java:243)
>         at java.lang.Thread.run(Thread.java:289)
> error in creating input stream.
>
> What have I done wrong?Hi,
hmmm....
applet can communicate withe only server from which launchs.
if you connect another server, then fail.
it's only security problem.
Bye

home help back first fref pref prev next nref lref last post