username to uid mapping
ok - i may have asked this question before - but i can't find it by searching!!
is there a quick and easy way to get a username to uid mapping?
i'm writing a daemon that forces its owning uid to a specified uid despite another user starting it. like apache forcing to run as nobody.
however, on different boxes a user will have different uid's. Therefore the common variable across different boxes is the username and not the uid.
so, do i have to parse the /etc/passwd file? is there an easier way?
thanks - thats what i needed!