From owner-freebsd-questions Thu Oct 7 0:48:38 1999 Delivered-To: freebsd-questions@freebsd.org Received: from snoopy.pacific.net.sg (snoopy.pacific.net.sg [203.120.90.116]) by hub.freebsd.org (Postfix) with ESMTP id A11BF14C1C for ; Thu, 7 Oct 1999 00:48:33 -0700 (PDT) (envelope-from jk.tan@pacific.net.sg) Received: from pop2.pacific.net.sg (pop2.pacific.net.sg [203.120.90.86]) by snoopy.pacific.net.sg with ESMTP id PAA22603 for ; Thu, 7 Oct 1999 15:46:31 +0800 (SGT) Received: from firefox.pacific.net.sg (firefox.pacific.net.sg [203.120.89.74]) by pop2.pacific.net.sg with ESMTP id PAA22185 for ; Thu, 7 Oct 1999 15:46:31 +0800 (SGT) Date: Thu, 7 Oct 1999 15:45:10 +0800 (SGT) From: Tan Juay Kwang X-Sender: tanjk@firefox.pacific.net.sg To: freebsd-questions@freebsd.org Subject: crypt(3) 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 Hi, I have a freebsd 3.2 system and is having some problem with the crypt(3) function. According to the man page, if I were to supply a 2 byte salt, it will return the historical 13 byte string. However, it seems like the one in 3.2 is not doing what is said in the man pages? Sample code and output :- printf("%s\n",crypt("a","_1234abcd")); printf("%s\n", crypt("a","ab")); Output: $1$_1234abc$zyNh.miJty685SsEEDPDT0 $1$ab$NM4FR4Dl/CzoTSJTd3YJ3. Or is my way of using crypt(3) wrong in some way? Thanks and regards, Juay Kwang To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message