Re: Wrong permissions for user home directories

2005-09-21 Thread Declan Moriarty
Recently, Somebody Somewhere wrote these words > When I create a new user > > # useradd -m > > the user's home directory is created with a bad set of permissions. > (drwxr-xr-x) Where do I set the default permissions for home > directories? I'd prefer 700 (wrx--) for the home directorie

Re: Wrong permissions for user home directories

2005-09-20 Thread Doug Reich
Archaic wrote: On Tue, Sep 20, 2005 at 10:34:48PM -0400, Doug Reich wrote: Since we're already off topic... No, it won't kill the public_html dir. I happen to have an account on a system in which the home directory has 0700 permissions, but so long as the public_html directory has 755 permis

Re: Wrong permissions for user home directories

2005-09-20 Thread Randy McMurchy
Doug Reich wrote these words on 09/20/05 21:34 CST: > No, it won't kill the public_html dir. I happen to have an account on a > system in which the home directory has 0700 permissions, but so long as > the public_html directory has 755 permissions, everything will work > fine. The 0700 on the h

Re: Wrong permissions for user home directories

2005-09-20 Thread Archaic
On Tue, Sep 20, 2005 at 10:34:48PM -0400, Doug Reich wrote: > > Since we're already off topic... > > No, it won't kill the public_html dir. I happen to have an account on a > system in which the home directory has 0700 permissions, but so long as > the public_html directory has 755 permissions,

Re: Wrong permissions for user home directories

2005-09-20 Thread Doug Reich
writability is needed. Perhaps there is a public_html dir. 0700 on /home/username would kill it. Since we're already off topic... No, it won't kill the public_html dir. I happen to have an account on a system in which the home directory has 0700 permissions, but so long as the public_html di

Re: Wrong permissions for user home directories

2005-09-20 Thread Archaic
On Tue, Sep 20, 2005 at 09:17:16PM -0500, Randy McMurchy wrote: > > Yup. But the OP requested a method to set 0700 on his home dirs. > This is what I thought the thread was about. Not debating the need > for 0700. True enough, but just throwing it out there for completeness sake, especially since

Re: Wrong permissions for user home directories

2005-09-20 Thread Randy McMurchy
Archaic wrote these words on 09/20/05 21:11 CST: > Perhaps there is a public_html dir. 0700 on > /home/username would kill it. Yup. But the OP requested a method to set 0700 on his home dirs. This is what I thought the thread was about. Not debating the need for 0700. -- Randy rmlscsi: [GNU ld

Re: Wrong permissions for user home directories

2005-09-20 Thread Archaic
On Tue, Sep 20, 2005 at 08:26:05PM -0500, Randy McMurchy wrote: > > I mentioned this earlier, but this thread won't die so I'll mention > it again. Can't one simply set up a rule in /etc/default/useradd? Not having looked at the code, but relying on what is in /etc/default/useradd, useradd -D, an

Re: Wrong permissions for user home directories

2005-09-20 Thread Randy McMurchy
Brandin Creech wrote these words on 09/20/05 20:23 CST: > That assumes the last argument given to useradd is the username. I think this > is the only correct way to specify it to useradd, anyway. I mentioned this earlier, but this thread won't die so I'll mention it again. Can't one simply set up

Re: Wrong permissions for user home directories

2005-09-20 Thread Brandin Creech
--- "Peter B. Steiger" <[EMAIL PROTECTED]> wrote: > On Tue, 2005-09-20 at 12:33 -0700, Brandin Creech wrote: > > umask 0077 > > mkdir /home/username && > > useradd -m username > > Every time you add a user? That would get old real fast if you expect > to add more than 3 users. True. But you can

Re: Wrong permissions for user home directories

2005-09-20 Thread Lennon Cook
Peter B. Steiger wrote: > On Tue, 2005-09-20 at 12:33 -0700, Brandin Creech wrote: > > umask 0077 > > mkdir /home/username && > > useradd -m username > > Every time you add a user? That would get old real fast if you expect > to add more than 3 users. This is why we have shell scripts. :) -- Le

Re: Wrong permissions for user home directories

2005-09-20 Thread Peter B. Steiger
On Tue, 2005-09-20 at 12:33 -0700, Brandin Creech wrote: > umask 0077 > mkdir /home/username && > useradd -m username Every time you add a user? That would get old real fast if you expect to add more than 3 users. -- Peter B. Steiger Cheyenne, WY -- http://linuxfromscratch.org/mailman/listin

Re: Wrong permissions for user home directories

2005-09-20 Thread Archaic
On Tue, Sep 20, 2005 at 10:31:01PM +0200, Dan Osterrath wrote: > > Then I suggest > install -m700 -o -g /home/ && Won't that give an unknown user/group error? Afterall, the user doesn't exist before useradd. -- Archaic Want control, education, and security from your operating system? Hardened

Re: Wrong permissions for user home directories

2005-09-20 Thread Randy McMurchy
Dan Osterrath wrote these words on 09/20/05 15:31 CST: > Then I suggest > install -m700 -o -g /home/ && > useradd -m Of course. Dumb me. (you did leave off the -d switch, though) :-) -- Randy rmlscsi: [GNU ld version 2.15.94.0.2 20041220] [gcc (GCC) 3.4.3] [GNU C Library stable release versio

Re: Wrong permissions for user home directories

2005-09-20 Thread Dan Osterrath
Randy McMurchy schrieb: >>umask 0077 >>mkdir /home/username && >>useradd -m username > install -m700 -d /home/username > useradd -m username > chown username/usergroup /home/username (this was added) Then I suggest install -m700 -o -g /home/ && useradd -m signature.asc Description: OpenPGP dig

Re: Wrong permissions for user home directories

2005-09-20 Thread Randy McMurchy
Brandin Creech wrote these words on 09/20/05 14:33 CST: > So, here's what I suggest: > > umask 0077 > mkdir /home/username && > useradd -m username I don't have time to research it, but couldn't a rule be set in /etc/default/useradd? BTW - The instructions above could be made simpler by this: i

Wrong permissions for user home directories

2005-09-20 Thread Joseph M Dupre (AVAB Inc.)
When I create a new user # useradd -m the user's home directory is created with a bad set of permissions. (drwxr-xr-x) Where do I set the default permissions for home directories? I'd prefer 700 (wrx--) for the home directories. - Joe -- http://linuxfromscratch.org/mailman/listinfo/bl