|
-
April 23rd, 2005, 02:17 AM
#3
Senior Member
sorry i should have specified...
I'm editing the debian pmount utility to work with gentoo, hal, and gvm, instead of using fstab-sync which is unsafe and just didn't work period for me, and want to allow users in the plugdev group to unmount devices. So far I can get the gid of the mounting user through /etc/mtab, and can get a vector of user names in that group through getgrgid(). I would like to check to see if the calling user (getuid()) is in the group that mounted the volume to allow that user to unmount it.
is there a way to use either method in c, or preferrebly a function that i can call to get either an id or a user name?
upon further googling, getpwnam() looks promising, i'll get back to you if it works
Thanks!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|