From owner-freebsd-questions Fri Dec 18 23:52:05 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id XAA08400 for freebsd-questions-outgoing; Fri, 18 Dec 1998 23:52:05 -0800 (PST) (envelope-from owner-freebsd-questions@FreeBSD.ORG) Received: from pcpsj.pfcs.com (harlan.fred.net [205.252.219.31]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id XAA08395 for ; Fri, 18 Dec 1998 23:52:02 -0800 (PST) (envelope-from Harlan.Stenn@pfcs.com) Received: from mumps.pfcs.com [192.52.69.11] (HELO mumps.pfcs.com) by pcpsj.pfcs.com (8.8.8/8.8.8) via ESMTP id for ; Sat, 19 Dec 1998 02:51:59 -0500 (EST) Received: from brown.pfcs.com [192.52.69.44] (HELO brown.pfcs.com) by mumps.pfcs.com (8.8.8/8.8.8) via ESMTP id for ; Fri, 18 Dec 1998 23:51:58 -0800 (PST) Received: from localhost [127.0.0.1] (HELO brown.pfcs.com) by brown.pfcs.com (8.8.8/8.8.8) via ESMTP id for ; Sat, 19 Dec 1998 02:51:58 -0500 (EST) X-Mailer: exmh version 2.0.2 2/24/98 To: questions@FreeBSD.ORG Subject: crypt() and DES *or* MD5 passwords X-Face: "csXK}xnnsH\h_ce`T#|pM]tG,6Xu.{3Rb\]&XJgVyTS'w{E+|-(}n:c(Cc* $cbtusxDP6T)Hr'k&zrwq0.3&~bAI~YJco[r.mE+K|(q]F=ZNXug:s6tyOk{VTqARy0#axm6BWti9C d Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Sat, 19 Dec 1998 02:51:57 -0500 Message-ID: <10205.914053917@brown.pfcs.com> From: Harlan Stenn Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Perhaps I'm doing something wrong. I've got the secure distribution installed. I have a password file that has *mixed* MD5 and DES passwords in it - some are legacy POP passwords, and they're in DES format now. >From reading the man page, if the salt does not begin with _ or $, it should be taken as a DES salt, and I would *expect* that crypt() would generate a DES password from the key. crypt() generates an MD5 password unless I link with -ldescrypt. This seems wrong to me - I'd expect crypt() to generate an encrypted key using the provided key *in the form specified by the salt*. Am I missing something? How can I get a single crypt() function that will do this? H To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message