LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (http://www.linuxquestions.org/questions/linux-software-2/)
-   -   clesses need permissions to write (http://www.linuxquestions.org/questions/linux-software-2/clesses-need-permissions-to-write-4175415725/)

Thor_2.0 07-09-2012 11:40 AM

clesses need permissions to write
 
Hey gang!

Okay, so, I've got a class that needs to write to a local folder. Snag: only that one class should be allowed to do that, no other class, so it's not a question of "just opening everything up"...theres an other "OS" that does that, look where it got them... :D

I've been thinking into these lines: set up a group with one member: that class. Give the members of that group write permissions to the folde.
Just...how does one add a comp to a group?
Thanks for helping a noob out.

Thor

TobiSGD 07-10-2012 08:18 PM

Please clarify your question. What exactly do you mean with "classes"? And how does this relate to a "comp(uter?)"?

Thor_2.0 07-12-2012 03:23 PM

Okay...it's fairly simpel. I've got a Java RMI solution that exposes stuff to a client. There needs to be a save action to the serve. Eacht user has a folder, one portion of the program has to write these commits as an XML file to the local disk. A sample of the folder hirarchy:

/mainserver
/users
/[per user folder]

where the class resides in /mainserver and needs to write stuff to /users/[userfolder]
the class (program) gets all the info from a user profile, that angle is covered.
what I did was to add the class to a group that has write access, but I still have to experiment with this approach. I aim to let the class inherit the group rights.

Thanks for your interest!

Thor


All times are GMT -5. The time now is 03:56 AM.