From owner-freebsd-questions Mon May 13 07:50:33 1996 Return-Path: owner-questions Received: (from root@localhost) by freefall.freebsd.org (8.7.3/8.7.3) id HAA25687 for questions-outgoing; Mon, 13 May 1996 07:50:33 -0700 (PDT) Received: from mail.EUnet.hu (mail.eunet.hu [193.225.28.100]) by freefall.freebsd.org (8.7.3/8.7.3) with ESMTP id HAA25649 for ; Mon, 13 May 1996 07:50:11 -0700 (PDT) Received: by mail.EUnet.hu, id QAA22444; Mon, 13 May 1996 16:43:31 +0200 Received: by CoDe.CoDe.hu (PAA00340); Mon, 13 May 1996 15:49:20 GMT From: Gabor Zahemszky Message-Id: <199605131549.PAA00340@CoDe.CoDe.hu> Subject: Re: Help generating passwords for Apache users To: fqueries@jraynard.demon.co.uk (James Raynard) Date: Mon, 13 May 1996 15:49:19 +0000 (GMT) Cc: freebsd-questions@freebsd.org In-Reply-To: <199605092033.UAA11147@jraynard.demon.co.uk> from "James Raynard" at May 9, 96 08:33:21 pm X-Mailer: ELM [version 2.4 PL24] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-questions@freebsd.org X-Loop: FreeBSD.org Precedence: bulk > > Is there a utility in FreeBSD to generate encrypted passwords ( for use > > in an Apache users file ) > > or do I have to write a script myself using crypt() !? > > > > Can I use adduser and then cut/paste from the passwd file? > > You'd have to use vipw to view the encrypted password, as the passwd > file is shadowed and has a '*' where the password would be. And you > have to be root to run vipw. > > It may well be more practical to write a short Perl script using the > crypt() function - this is how adduser uses it:- > > $cryptpwd = crypt($password, &salt) if $password ne ""; > I don't know, but if I remember well, there is a makekey utility, to do it from command line. (OK, I know that it is an AT&T command, and not so popular in a BSD-base user land.) -- Gabor Zahemszky -:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:-:- Earth is the cradle of human sense, but you can't stay in the cradle forever. Tsiolkovsky