FIX: DatagramSocket Causes Security Exception
This article was previously published under Q186032 On This PageSYMPTOMS
Creating a DatagramSocket generates the following exception in your Java
console:
com.ms.security.SecurityExceptionEx[className.methodName]:
NOTE: This exception may also occur on a port other than zero.
cannot access port 0 CAUSE
The Microsoft virtual machine incorrectly implements creating a
DatagramSocket as a trusted network operation. The correct behavior would
be to only treat the act of using the DatagramSocket to communicate with a
computer other than the computer hosting the applet is a trusted operation.
RESOLUTION
To workaround this problem, you must make your applet trusted. See the
"REFERENCES" section below for articles explaining how to make your applet
trusted.
STATUSMicrosoft has confirmed that this is a problem in the Microsoft products that are listed at the beginning of this article. This problem was corrected in Microsoft virtual machine 31xx and later builds. MORE INFORMATIONSteps to Reproduce Behavior
REFERENCES
For other information on making your code trusted, please see the Microsoft
SDK for Java documentation, available at the following Web site:
http://www.microsoft.com/mscorp/java/ (http://www.microsoft.com/mscorp/java/)
For additional information, please see the following articles in the
Microsoft Knowledge Base:
181374 (http://support.microsoft.com/kb/181374/EN-US/) INFO: Related Component Download Articles
175622 (http://support.microsoft.com/kb/175622/EN-US/) PRB: SecurityExceptionEx Exception Running a Java Applet
For additional information on making your Java Code trusted in Microsoft
Internet Explorer, please refer to the following Knowledge Base article:
193877 (http://support.microsoft.com/kb/193877/EN-US/) HOWTO: Make your Java Code Trusted in Internet Explorer
APPLIES TO
| Article Translations
|

Back to the top
