Solved

assertPermission

Posted on 1998-10-30
4
184 Views
Last Modified: 2012-05-05
How do I call the assertPermission function, what do i have to import?. I work with jdk1.1.5
I want to create a socket to localhost (=127.0.0.1) in IE4.0, I tried to set the security setting in IE4.0 but it didn't work.
0
Comment
Question by:ahannink
  • 2
4 Comments
 

Author Comment

by:ahannink
ID: 1226674
Edited text of question
0
 
LVL 2

Expert Comment

by:shchuka
ID: 1226675
You realize that you HAVE to sign your applet in order to be able to do it at all - right?
0
 

Accepted Solution

by:
sreedharK earned 50 total points
ID: 1226676
Here is how you can call it :
    PolicyEngine.assertPermission(PermissionID.NETIO);
If you use this code, you need the SDK for Java to compile the code.  
you can just take the com.ms.security package, put the package in the classpath and imoport the package in your code and compile it.
OR
Install SDK for java from Microsoft(It's free) and run the executable file classR or classD. You'll get the package or simply use the compiler jvc that comes with sdk for java..
0
 

Author Comment

by:ahannink
ID: 1226677
JDK1.1.5 is used to compile the code. So the import statement is necessary. But also take care you've put the IE classes into your classpath.
Most of the time they are allocated in Windows\java\classes\classes.zip
The comment of shchuka is true the applet must be signed.
Thank you for answering this question
0

Featured Post

Networking for the Cloud Era

Join Microsoft and Riverbed for a discussion and demonstration of enhancements to SteelConnect:
-One-click orchestration and cloud connectivity in Azure environments
-Tight integration of SD-WAN and WAN optimization capabilities
-Scalability and resiliency equal to a data center

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Java had always been an easily readable and understandable language.  Some relatively recent changes in the language seem to be changing this pretty fast, and anyone that had not seen any Java code for the last 5 years will possibly have issues undeā€¦
In this post we will learn how to connect and configure Android Device (Smartphone etc.) with Android Studio. After that we will run a simple Hello World Program.
This theoretical tutorial explains exceptions, reasons for exceptions, different categories of exception and exception hierarchy.
This tutorial explains how to use the VisualVM tool for the Java platform application. This video goes into detail on the Threads, Sampler, and Profiler tabs.

821 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question