From owner-freebsd-questions@FreeBSD.ORG Mon Oct 6 06:07:39 2008 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2AAEC1065688 for ; Mon, 6 Oct 2008 06:07:39 +0000 (UTC) (envelope-from talk@holon.urwis.cc) Received: from holon.urwis.cc (urwis.cc [82.177.38.81]) by mx1.freebsd.org (Postfix) with ESMTP id DCB948FC25 for ; Mon, 6 Oct 2008 06:07:38 +0000 (UTC) (envelope-from talk@holon.urwis.cc) Received: from [82.177.38.80] (artax.pwsz.elblag.pl [82.177.38.80]) (Authenticated sender: talk) by holon.urwis.cc (Postfix) with ESMTP id 1421532AD0D for ; Mon, 6 Oct 2008 07:50:23 +0200 (CEST) Message-ID: <48E9A71C.90004@holon.urwis.cc> Date: Mon, 06 Oct 2008 07:50:20 +0200 From: Adam Zaleski User-Agent: Thunderbird 2.0.0.17 (Windows/20080914) MIME-Version: 1.0 To: freebsd-questions@freebsd.org References: <89ce7f740810052214k4419d939s8bb8ebce5e703626@mail.gmail.com> In-Reply-To: <89ce7f740810052214k4419d939s8bb8ebce5e703626@mail.gmail.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: How to generate password hashes for vipw and chpass X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 06 Oct 2008 06:07:39 -0000 Ivan "Rambius" Ivanov pisze: > # /sbin/md5 -s newpassword > and then I passed the output to chpass. I tried to use the new > password for the next login but it failed - so I believe this is > wrong. > Can you please show me how to generate the password hashes? You can add new account with one command like this: echo user_password |pw user add new_user -h0 Also if you only want to generate valid password hash you can use 'openssl passwd -1 new_password'