aspose file tools
The moose likes Sockets and Internet Protocols and the fly likes applet network problem??! Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » Sockets and Internet Protocols
Reply Bookmark "applet network problem??!" Watch "applet network problem??!" New topic
Author

applet network problem??!

hekaro sa
Greenhorn

Joined: Oct 10, 2007
Posts: 5
hello,
if i make network between 2 applets in html page, one side is the server and the other is a client..it didn't work

it stop in the server side after Socket socket=serversocket.accept();...

and security error appear in client side.

what is the reason? and how can I solve this problem please(in details)?
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 35258
    
    7
Are the two applets on the same network? If not, firewall issues will likely prevent this from working.

Also, the applets need to be signed (or the local security policy relaxed) in order to use sockets (assuming that neither applet runs on the server where they are served from).


Android appsImageJ pluginsJava web charts
Ryan Muster
Greenhorn

Joined: Nov 11, 2007
Posts: 18
If you google you'll find the answer Applet Security or Applet Sandbox.

Its a long long time since I used Applets... they not my favorite technology.

But (from memory) essentially if you dont want to get a verisign cert, they can only talk to the server they come from.

So saving to the user PC or reading files... no.
Loading an Applet from one site, another from another site, and using a little java script between them... I think is also a no.

Applets have massive security walls around them.

I wish they put a big sign at the top of Applet tutorials... YOU WILL PROBABLY HAVE TO PAY TO USE IT

Sucks... but they have to do it.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 35258
    
    7
Originally posted by Ryan Muster:
But (from memory) essentially if you dont want to get a verisign cert, they can only talk to the server they come from.

I wish they put a big sign at the top of Applet tutorials... YOU WILL PROBABLY HAVE TO PAY TO USE IT


It's possible to use a (free) self-signed certificate instead of one from Verisign. For an intranet application, or a non-commercial internet app, that might be sufficient. For a commercial application the cost of one certificate should be no big deal.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: applet network problem??!
 
Similar Threads
How many data was transfer
Help, remote port = 0.
SocketException Using Pooled Sockets
Doubt in ServerSocket and Socket
socket callback