Download the JDK
Search the Tutorials
Hide the TOC
Trail: Security Features in Java SE
Lesson: Signing Code and Granting It Permissions
Section: Steps for the Code Receiver
Subsection: Set Up a Policy File to Grant the Required Permission
Signing Code and Granting It Permissions
Steps for the Code Signer
Download and Try the Sample Application
Create a JAR File Containing the Class File
Generate Keys
Sign the JAR File
Export the Public Key Certificate
Steps for the Code Receiver
Observe the Restricted Application
Import the Certificate as a Trusted Certificate
Set Up a Policy File to Grant the Required Permission
Start Policy Tool
Specify the Keystore
Add a Policy Entry with a SignedBy Alias
Save the Policy File
See the Policy File Effects
Home Page > Security Features in Java SE > Signing Code and Granting It Permissions
« Previous • Trail • Next »
Save the Policy File

> To save the new policy file you've been creating, choose the Save As command from the File menu. This brings up the Save As dialog box.

> Navigate the directory structure to get to the directory in which to save the policy file: the `Test` directory on the `C:` drive. Type the file name

> >     raypolicy

> Then choose the Save button. The policy file is now saved, and its name and path are shown in the text box labeled Policy File, as shown in the following figure.

> This figure has been reduced to fit on the page.
> Click the image to view it at its natural size.

> Then exit Policy Tool by selecting the Exit command from the File menu.

« Previous • Trail • Next »
Previous page: Add a Policy Entry with a SignedBy Alias
Next page: See the Policy File Effects