*BSD News Article 38409


Return to BSD News archive

Path: sserve!newshost.anu.edu.au!harbinger.cc.monash.edu.au!msuinfo!agate!howland.reston.ans.net!news.sprintlink.net!sundog.tiac.net!spoon.beta.com!mcgovern
From: mcgovern@spoon.beta.com (Brian McGovern)
Newsgroups: comp.os.386bsd.questions
Subject: Crypting passwords...
Date: 26 Nov 1994 16:12:59 GMT
Organization: B.E.T.A. Mountain, Framingham, MA
Lines: 19
Message-ID: <3b7mqb$l2d@sundog.tiac.net>
NNTP-Posting-Host: spoon.beta.com

I've been having an interesting problem under FreeBSD 1.1.5.1 trying to
crypt passwords. After mulling through the code for passwd, it looks
like the way passwords are encrypted is something like this:

crypted_password = crypt(ClearTextPassword, ClearTextPassword);

Now... That actually works with login, rlogin, etc. However, it doesn't
match the output of password (which seems to change the crypted
password every time, even if you set the password to the same thing.

The reason this is becoming important is that I'm about to write a user
database to distribute password information to several disparate devices
that use DES (couple of freebsd boxes, a Livingston Port Master, a SPARC
station, etc), and I want to make sure I'm generating the passwords properly
for DES, and not just FreeBSD

	Thankx.
		Brian