From owner-freebsd-hackers Tue Jan 16 16:20:34 1996 Return-Path: owner-hackers Received: (from root@localhost) by freefall.freebsd.org (8.7.3/8.7.3) id QAA29243 for hackers-outgoing; Tue, 16 Jan 1996 16:20:34 -0800 (PST) Received: from mail.cs.tu-berlin.de (root@mail.cs.tu-berlin.de [130.149.17.13]) by freefall.freebsd.org (8.7.3/8.7.3) with ESMTP id QAA29235 for ; Tue, 16 Jan 1996 16:20:24 -0800 (PST) Received: from caramba.cs.tu-berlin.de (wosch@caramba.cs.tu-berlin.de [130.149.17.12]) by mail.cs.tu-berlin.de (8.6.12/8.6.12) with ESMTP id BAA22322; Wed, 17 Jan 1996 01:15:54 +0100 Received: (from wosch@localhost) by localhost (8.6.9/8.6.9) id XAA01147; Tue, 16 Jan 1996 23:15:36 +0100 Date: Tue, 16 Jan 1996 23:15:36 +0100 From: Wolfram Schneider Message-Id: <199601162215.XAA01147@localhost> To: robin@is.co.za Cc: hackers@freebsd.org Subject: user management stuff In-Reply-To: <199601161207.OAA23785@admin.is.co.za> References: <199601161207.OAA23785@admin.is.co.za> Reply-to: Wolfram Schneider MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit Sender: owner-hackers@freebsd.org Precedence: bulk Robin Lunn writes: >I was horrified to see that /usr/sbin/adduser does no locking of the password >file! I recommend that instead of attempting to add the entry directly that >the program simply invoke chpass -a which will see to it that locking >is done etc. Much safer. Old chpass (FreeBSD 2.0) core dumped. >Also, I've made a userdel script in perl. It was written on company time and >so my company has the copyright. The company is however happy to allow this >to be freely released. Should I put this on a news group or would someone >like to have a look and perhaps put it into future FreeBSD releases? This is the 3th deluser perl script. I don't like the idea of a delete user script. It is too complex. I recommend first a man page with a brief description of possible problems. - delete password entry - delete user from group database (/etc/group), may be delete groups - delete ppp password (/etc/ppp/*) - delete slip entries (/etc/sliphome*) - delete user from /etc/ftpusers - check for other users with same uid (may be also for groups) - remove home dir - remove WWW files (/~user), which are not in HOME located - check other FS, $ find / -user user -print - delete user from /etc/inetd.conf, remove files which owned by user - delete user from /etc/rc.local if the user start programs - remove mailbox - delete mail aliases (/etc/aliases, may be /etc/sendmail.cf) - delete crontab entries (/etc/crontab, /var/cron/allow, /var/cron/deny, /var/cron/tabs/user) - delete at(8) entries - delete user phone numbers in /etc/phones - remove quota Wolfram