- Distributed Computing in Java 9
- Raja Malleswara Rao Pattamsetti
- 101字
- 2025-04-04 19:00:33
Running a remote client program
Between the hosts running the server and client programs, there can be a security manager installed. When you run either a server or client program with a security policy, the associated security policy definition needs to be specified with the instructions to grant security permissions to both the server and the client as they run. The following are example policy files to use with the server program:
- For server.policy, the code is as follows:
grant codeBase "file:D://development//eclipseworkspace//CalculateApp//src//remote//" {
permission java.security.AllPermission;
};
- For client.policy, the code is as follows:
grant codeBase "file:D://development//eclipseworkspace//CalculateApp//src//local//" {
permission java.security.AllPermission;
};