Whole document tree SecurityThere are three security-related areas in OJI: For general information about security and applets, see Java Plug-in Security. RSA Signed AppletsPrevious to Netscape 6, Netscape had its own security model and its own signing
method called Netscape
Object Signing. The Object-Signing Tools could be used to sign a Java applet
so that it could be executed in the JVM. Netscape also provides a set of Java
classes, In Netscape 6, two mechanisms may be used for applet signing:
In Netscape 4 an applet must call into the In Netscape 6, signed applets are directly supported by the Java Plug-in. When the browser encounters a signed applet, a security dialog is automatically popped up. The applet does not have to call any method to enable privileges; privileges are already enabled. However, so that Netscape 4 applets will continue to work in Netscape 6, a
stub class for the HTTPSWith this release of Java Plug-in, HTTPS is completely handled by the browser. Thus, anything related to HTTPS, such as the service certificate, can be configured through the browser. LiveConnectLiveConnect allows bi-directional communication between Java and JavaScript. But such communication can present security problems. For instance, suppose an applet and a web page originate from different hosts. Without a security policy, the applet might request sensitive information from a page through a call to JavaScript. Since an applet is allowed to connect to any host, it might then send such information out over the network in an irresponsible manner. A security policy has been implemented to prevent such actions from occurring. Each direction of communication is considered separately below. JavaScript-to-Java CommunicationIn JavaScript-to-Java communication, a call from JavaScript to an applet is allowed only if one or both of the following is true:
Without 1 or 2 being true, no call will be allowed from JavaScript to Java. Given that a call is allowed, then there are two possibilities: JavaScript will have default or all permissions. Permissions are determined by checking JavaScript signing:
Note that to access an applet from JavaScript, the applet tag will need to
specify an Java-to-JavaScript CommunicationA call from Java to JavaScript is allowed only if the applet and JavaScript have the same origin. Assuming the above condition is met, the applet is checked for its permissions.
If it has all, then JavaScript will perform the requested actions. If the applet
does not have all permissions, then JavaScript checks the origin of the applet
and the Note that to access JavaScript, Java does so through an instance of the
|