From owner-freebsd-questions Mon Jun 21 11:48:59 1999 Delivered-To: freebsd-questions@freebsd.org Received: from resnet.uoregon.edu (resnet.uoregon.edu [128.223.144.32]) by hub.freebsd.org (Postfix) with ESMTP id 02AAB14BB8 for ; Mon, 21 Jun 1999 11:48:55 -0700 (PDT) (envelope-from dwhite@resnet.uoregon.edu) Received: from localhost (dwhite@localhost) by resnet.uoregon.edu (8.9.3/8.9.3) with ESMTP id LAA76471; Mon, 21 Jun 1999 11:48:24 -0700 (PDT) (envelope-from dwhite@resnet.uoregon.edu) Date: Mon, 21 Jun 1999 11:48:23 -0700 (PDT) From: Doug White To: Jim Pazarena Cc: freebsd-questions@FreeBSD.ORG Subject: Re: setting/changing password inside 'c' In-Reply-To: <9906211116.aa15402@dick.ccstores.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Mon, 21 Jun 1999, Jim Pazarena wrote: > I would like to create a (root) routine in 'c' to be able to > change a user's password. > > I presently use a script which uses 'expect' to trick the password > command. I would like to convert this to a 'c' program. > > The routine is mostly written. But I need to interface the routine > to that system for the actual change. > > Are there any functions available to accomplish this within 'c' ? Go read the source for passwd. http://www.freebsd.org/cgi/cvsweb.cgi/src/usr.bin/passwd Doug White Internet: dwhite@resnet.uoregon.edu | FreeBSD: The Power to Serve http://gladstone.uoregon.edu/~dwhite | www.freebsd.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message