Re: Why no setuid in linux.d?

2010-11-19 Thread 0ffh
Steven Schveighoffer wrote: [...] You are not required to modify phobos to prototype a C function, just do this: extern(C) int setuid(uid_t uid); [...] Yeah I know, and you're right! It's just I felt that it belonged there... As to why it was omitted, I'm unsure. So am I! =) -Frank

Re: Why no setuid in linux.d?

2010-11-19 Thread Steven Schveighoffer
On Fri, 19 Nov 2010 06:33:02 -0500, 0ffh wrote: Hi, I've written a programme that serves port 80, which usually requires root access. Therefore, after acquiring the socket I want to relinquish root by setting the uid to nonzero. I needed to add "int setuid(uid_t uid);" to linux.d and recomp

Re: Why no setuid in linux.d?

2010-11-19 Thread Lars T. Kyllingstad
On Fri, 19 Nov 2010 13:02:42 +0100, 0ffh wrote: > Lars T. Kyllingstad wrote: >> On Fri, 19 Nov 2010 12:33:02 +0100, 0ffh wrote: >> >>> Hi, >>> [...] >>> I there a specific reason that setuid (and the related commands >>> setgid, getuid, geteuid, getgid and getegid) is/are missing in the >>> stand

Re: Why no setuid in linux.d?

2010-11-19 Thread 0ffh
Lars T. Kyllingstad wrote: On Fri, 19 Nov 2010 12:33:02 +0100, 0ffh wrote: Hi, [...] I there a specific reason that setuid (and the related commands setgid, getuid, geteuid, getgid and getegid) is/are missing in the standard version of linux.d? All the POSIX headers are in the core.sys.posix

Re: Why no setuid in linux.d?

2010-11-19 Thread Lars T. Kyllingstad
On Fri, 19 Nov 2010 12:33:02 +0100, 0ffh wrote: > Hi, > > I've written a programme that serves port 80, which usually requires > root access. Therefore, after acquiring the socket I want to relinquish > root by setting the uid to nonzero. I needed to add "int setuid(uid_t > uid);" to linux.d and

Why no setuid in linux.d?

2010-11-19 Thread 0ffh
Hi, I've written a programme that serves port 80, which usually requires root access. Therefore, after acquiring the socket I want to relinquish root by setting the uid to nonzero. I needed to add "int setuid(uid_t uid);" to linux.d and recompile Phobos in order to do so. I there a specific reas