From owner-freebsd-hackers Wed Dec 20 23:41:31 1995 Return-Path: owner-hackers Received: (from root@localhost) by freefall.freebsd.org (8.7.3/8.7.3) id XAA18806 for hackers-outgoing; Wed, 20 Dec 1995 23:41:31 -0800 (PST) Received: from ibp.ibp.fr (ibp.ibp.fr [132.227.60.30]) by freefall.freebsd.org (8.7.3/8.7.3) with ESMTP id XAA18798 for ; Wed, 20 Dec 1995 23:41:20 -0800 (PST) Received: from blaise.ibp.fr (blaise.ibp.fr [132.227.60.1]) by ibp.ibp.fr (8.6.12/jtpda-5.0) with ESMTP id IAA15078 ; Thu, 21 Dec 1995 08:41:10 +0100 Received: from (uucp@localhost) by blaise.ibp.fr (8.6.12/jtpda-5.0) with UUCP id IAA25840 ; Thu, 21 Dec 1995 08:41:10 +0100 Received: (from roberto@localhost) by keltia.freenix.fr (8.7.3/keltia-uucp-2.7) id IAA14478; Thu, 21 Dec 1995 08:32:36 +0100 (MET) From: Ollivier Robert Message-Id: <199512210732.IAA14478@keltia.freenix.fr> Subject: Re: Password file manipulation... To: scrappy@hub.org (Marc G. Fournier) Date: Thu, 21 Dec 1995 08:32:35 +0100 (MET) Cc: hackers@FreeBSD.org In-Reply-To: from "Marc G. Fournier" at Dec 20, 95 08:50:30 pm X-Operating-System: FreeBSD 2.2-CURRENT ctm#1449 X-Mailer: ELM [version 2.4 PL24 ME8b] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-hackers@FreeBSD.org Precedence: bulk It seems that Marc G. Fournier said: > Just wondering if there is any way of ... easily(?) ... adding > and deleting entries from the master password file? Essentially, what > I'm looking for C functions that I can use too addpwent, delpwent > or chgpwent (and ya, I know, I should learn Perl, cause it would be > easier that way...*sigh*)? I have a Perl script (800+ lines) to add users on a FreeBSD system. If you want it, just ask. I haven't found th etime to add real documentation but it should be easy to read (if you know Perl :-)). 257 [23:51] root@keltia:doc/FAQ# new-account new-account : Account Creation Program. Copyright (c) 1993, 94 by Ollivier Robert (roberto@keltia.frmug.fr.net) Version 1.06.3 on 18/04/95. Usage: new-account [options] login fullname group [group...] Options: -N doesn't execute anything, just show commands, -m send greeting message to new user, -s shell specifies the shell to use instead of /sbin/tcsh, -u uid specifies une user-id to use (default is next free in class), -a alias specifies the alias to put in /etc/mail/aliases, -p pwd use that encrypted password, -q be quiet and do not display messages. Configuration file is /usr/local/etc/accountrc. Group definition file is /usr/local/etc/groupdefs. -- Ollivier ROBERT -=- The daemon is FREE! -=- roberto@keltia.frmug.fr.net FreeBSD keltia.freenix.fr 2.2-CURRENT #7: Mon Dec 18 00:50:47 MET 1995