Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Date: Tue, 1 Jun 2004 11:25:11 +0200 From: Corinna Vinschen To: cygwin Mailing List Subject: Re: problem with cygwin crypt function Message-ID: <20040601092511.GC1392@cygbert.vinschen.de> Reply-To: cygwin AT cygwin DOT com Mail-Followup-To: cygwin Mailing List References: <40B5BB24 DOT 5010600 AT yahoo DOT fr> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <40B5BB24.5010600@yahoo.fr> User-Agent: Mutt/1.4.2i On May 27 11:55, bertrand marquis wrote: > Hello > > i need to use the cygwin crypt function to compare the result with > the result of the linux string function. > > Under linux i crypt the string with a salt and then i have to remove the > first characters to remove the salt from the result string. > But under cygwin it seems that i only have a 13 char string with no salt > at the beginning and this result string is completely different from the > linux result string with the same input. > > Does anyone know a way to solve that Using the right crypt function under Linux, perhaps. The crypt function is defined to return the encrypted password. Using DES, this is always 13 characters, including the salt. Hint: Download the sources of the Cygwin crypt package and compile the tiny crypt.c tool under Linux (needs minor tweaking. Replace `#include "encrypt.h"' by `#include '). Corinna -- Corinna Vinschen Please, send mails regarding Cygwin to Cygwin Co-Project Leader mailto:cygwin AT cygwin DOT com Red Hat, Inc. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/