I'm using the crypt() function for the first time in c. I'm just running some initial tests, so none of this is actually going to be used, the constant salt value in particular. :)
I run the following code:
crypt(password, "$1$k7de83ka7");
From my understanding of the crypt docs, this provided salt value should specify that crypt() run in MD5 mode, which will produce a hash of the format "$1$". The $1$ specifies the value was hashed with MD5. That's how I understand it should work.
However, when I test the above code, the value returned is "$1ciFuWRySk3A", so it seems to be missing one of the '$' chars. Am I doing something wrong to cause this problem?