Re: home directory permission

2001-12-01 Thread Peter Samek

On Fri, Nov 30, 2001 at 12:22:34PM -0300, teste teste1 wrote:
 
 Hi all,
 
 Howto modify permission when create a new user, I
 do not want to change the permissions all time that to
 add a new user.
 
 
 Default Permission
 drwxr-sr-x2 teste2   teste2  teste2
 
 best security permission
 drwx--2 testeteste   teste
 
 
 Thanks,
 Ricardson
 

Hi.

You can create a script file /usr/local/sbin/adduser.local.
This file will be called after a new user is created.

In my adduser.local file I have something like:

L_HOMEDIR=$4
echo Changing the file permissions on $L_HOMEDIR.
if [ -d  $L_HOMEDIR ]; then chmod o-r $L_HOMEDIR; fi
#EOF

More in man adduser.

Of course it works only if you use adduser command.

Bye.
-- 
 Peter Samek
 [EMAIL PROTECTED]


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]




Re: home directory permission

2001-12-01 Thread Philippe Troin

Peter Samek [EMAIL PROTECTED] writes:

 On Fri, Nov 30, 2001 at 12:22:34PM -0300, teste teste1 wrote:
  
  Howto modify permission when create a new user, I
  do not want to change the permissions all time that to
  add a new user.
  
  
  Default Permission
  drwxr-sr-x2 teste2   teste2  teste2
  
  best security permission
  drwx--2 testeteste   teste

 You can create a script file /usr/local/sbin/adduser.local.
 This file will be called after a new user is created.
 
 In my adduser.local file I have something like:
 
 L_HOMEDIR=$4
 echo Changing the file permissions on $L_HOMEDIR.
 if [ -d  $L_HOMEDIR ]; then chmod o-r $L_HOMEDIR; fi
 #EOF
 
 More in man adduser.
 
 Of course it works only if you use adduser command.

Or if using woody or sid, change DIR_MODE in /etc/adduser.conf.

Phil.


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]




Re: home directory permission

2001-12-01 Thread Philippe Troin
Peter Samek [EMAIL PROTECTED] writes:

 On Fri, Nov 30, 2001 at 12:22:34PM -0300, teste teste1 wrote:
  
  Howto modify permission when create a new user, I
  do not want to change the permissions all time that to
  add a new user.
  
  
  Default Permission
  drwxr-sr-x2 teste2   teste2  teste2
  
  best security permission
  drwx--2 testeteste   teste

 You can create a script file /usr/local/sbin/adduser.local.
 This file will be called after a new user is created.
 
 In my adduser.local file I have something like:
 
 L_HOMEDIR=$4
 echo Changing the file permissions on $L_HOMEDIR.
 if [ -d  $L_HOMEDIR ]; then chmod o-r $L_HOMEDIR; fi
 #EOF
 
 More in man adduser.
 
 Of course it works only if you use adduser command.

Or if using woody or sid, change DIR_MODE in /etc/adduser.conf.

Phil.



Re: home directory permission

2001-11-30 Thread Rishi L Khan

How are you creating a new user directory? are you mkdir'ing directly or
using a program like useradd? If you are mkdir'ing, change your umask (be
aware, this changes the umask of ALL of your newly created files. If
you are using useradd, look into the -D option. If you are using some
other method, look into the manpages on that method and see how to change
the defaults. If you explain how you are creating user accounts, I'm sure
someone on the list can tell you how to change the defauls. Also, you
could write a small shell script to create the user home directory given
the username and group.

-rishi

On Fri, 30 Nov 2001, [iso-8859-1] teste teste1 wrote:


 Hi all,


 Howto modify permission when create a new user, I
 do not want to change the permissions all time that to
 add a new user.


 Default Permission
 drwxr-sr-x2 teste2   teste2  teste2

 best security permission
 drwx--2 testeteste   teste



 Thanks,
 Ricardson

 
___
 Yahoo! GeoCities
 Tenha seu lugar na Web. Construa hoje mesmo sua home page no Yahoo! GeoCities. É 
fácil e grátis!
 http://br.geocities.yahoo.com/


 --
 To UNSUBSCRIBE, email to [EMAIL PROTECTED]
 with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]



--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]




home directory permission

2001-11-30 Thread teste teste1

Hi all,


Howto modify permission when create a new user, I
do not want to change the permissions all time that to
add a new user.


Default Permission
drwxr-sr-x2 teste2   teste2  teste2

best security permission
drwx--2 testeteste   teste



Thanks,
Ricardson

___
Yahoo! GeoCities
Tenha seu lugar na Web. Construa hoje mesmo sua home page no Yahoo! GeoCities. 
É fácil e grátis!
http://br.geocities.yahoo.com/