
Securing Your Java Code • Chapter 7 283
We will now add a new permission to our policy file. Select Add
Permission and a new window pops up (Figure 7.10).The first selec-
tion box allows us to choose what types of permissions to allow.These
are the 10 permissions listed earlier. Let’s choose SocketPermission.
Some, but not all permissions allow a Target Name to be selected.With
our FilePermission, we included a directory or file as our target. In the
case of a SocketPermission, we can include an IP address (or a port
number). Under action we can choose what we will give permission for.
Usually there is list of individual actions, and the last entry includes ...