error

J

juicy

Does anyone knows what cause an error as below
"Error :
com.ms.security.SecurityExceptionEx[fileTransfer.actionPerformed]: cannot
access "127.0.0.1":1053".
I have done a file transferring program, when i called the client applet
from html file, error has occured.
 
K

KC Wong

Does anyone knows what cause an error as below
"Error :
com.ms.security.SecurityExceptionEx[fileTransfer.actionPerformed]: cannot
access "127.0.0.1":1053".
I have done a file transferring program, when i called the client applet
from html file, error has occured.

1. Applets are not allowed to access many system resources, like writing
files. Or we'll be seeing lots of computer hacked and files erased by
applets. Applets are also not allowed to connect to web sites other than the
one the applet is downloaded from.

2. Stop using Microsoft's VM. It's not standard Java, it's full of bugs,
it's full of security risks (there are virus targetting MSJVM). Download a
Java Runtime Environment (JRE) from java.sun.com. See
http://physci.org/jvmclean.jsp on how to remove MSJVM completely.

3. Source code would help people find out the problem and solution.
http://physci.org/codes/sscce.jsp

4. Stating what you're trying to accomplish will help a lot also. The
problem may not be in your code... it could be in the method you used to
solve the case.

5. This group is archived in groups.google.com. Please use a better subject
line like "SecurityExceptionEx in my applet" instead of just "error", which
means nothing. Doing so will help others to find questions already answered
through the use of Google Groups. Likewise you should search Google Groups
first before posting a question.
 
J

juicy

i have just tried to use JRE instead of Microsoft's VM,and my file transfer
program works well.
But unfortunately I combined my file transferring program with vrml
program where VRML program can only be run in Microsoft VM.
Is there any other solutions?
Thanks for your reply.
 
P

Paul Lutus

juicy said:
i have just tried to use JRE instead of Microsoft's VM,and my file
transfer program works well.
But unfortunately I combined my file transferring program with vrml
program where VRML program can only be run in Microsoft VM.
Is there any other solutions?

Yes, there is. Remove the requirement for this Microsoft-specific class, any
way you can. This kind of dependence goes against the most basic advantage
of Java -- platform portability.
 
K

KC Wong

i have just tried to use JRE instead of Microsoft's VM,and my file
transfer
program works well.

That shouldn't be the case... Sun JRE imposes restriction on applets, so
applets cannot access system resources.

Maybe you should check your .java.policy file... open comand prompt, type in
policytool. Try to open C:\Documents and Settings\[user name]\.java.policy
with it. Make sure you haven't grant permissions to your applet.

See http://mindprod.com/jgloss/policytool.html about PolicyTool.
But unfortunately I combined my file transferring program with vrml
program where VRML program can only be run in Microsoft VM.
Is there any other solutions?

I have no experience in VRML, but I googled "Java VRML" and there's a lot of
results. I peeked in some of them, and they have applets rendering VRML
models (is model the correct word?). Perhaps you can search for some
open-source or free Java VRML programs...
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,431
Messages
2,571,678
Members
48,796
Latest member
Greg L.

Latest Threads

Top