jQuery in Action, 2nd edition*
The moose likes Security and the fly likes File permission in java security Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » Security
Bookmark "File permission in java security" Watch "File permission in java security" New topic
Author

File permission in java security

xeon costa
Greenhorn

Joined: May 10, 2011
Posts: 15

Hi,

I've a java platform made by myself that offers a multicast communication. This platform is running in daemon and if a user want to send some multicast message, just have to call the interface method send(String group, Message m), and the platform will deliver the message to the group. There is some configuration files saved locally that is where the groups are specified. The user can't update the configuration files, only the admin user can do that.

For example, the admin user defined Group1, that includes Host1, Host2 and Host4. Group2 includes Host2 and Host3. If the user want to send the message to Group1, just has to call the method like this:


I would like to use java access control to allow only the admin user access these configuration files. Other users can't read or write to these files.

How can I do this using the Java Security platform?

Thanks,


Thanks,
Maarten Bodewes
Greenhorn

Joined: Aug 04, 2011
Posts: 14
Why would you use Java for this? Just make the config file only available to the account of the deamon, not any old user. The users only get access to the functions offered by the deamon.
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: File permission in java security
 
Similar Threads
deploy app in wscp with roles
Ldap and security-role-ref mappings
AJAX, JSF and security
DatagramPacket with more than one group
Network application being both a client and a server