I had this problem for a long time, I really need to solve it. I hope you can find the solution for me!!
This has been on perl and php versions, through several upgrades, but right now I am a little behind
Powered BY WWWThreads 5.4.1php
Problem
I used to run a message board on 2 different servers. When a user registered a password on freebsd server, they would not allow authentication on the linux server.
I gave up and ended up running all on one server.
Now I have another reason why I would want to either run the board on 2 servers, or convert the entire board onto the other server.
I fear password problems again. Can someone help me, I could not figure this out!
=======================
From: QuickServe Support
Subject: Re: crypt function on linux different from freebsd?? [C4J9M7X]
The only thing I can think of off-hand is that you'd want to make
sure all systems (and functions) are encrypting in the same format.
It is possible that some systems might default to MD5 and others
might default to DES depending on their setup. You can recognize
MD5 passwords because the encrypted string always begins with "$1$".
Erik
----
> I am sending this to several people in the hope to get a solution.
>
> I run wwwthreads.com board, a bulletin board in perl and/or php,
> with mysql database background .
>
> It runs on both a freebsd and 2 linux servers, using the same
> database. There are some strange problems occurring. I narrowed
> it down, that seemingly passwords changed occurring on the freebsd
> servers will not be accepted on the linux server, and vice versa.
> It seems, though, that this does not occur all the time.
>
> Question:
>
> a) could it be that the perl/php/unix crypt function works differently on
> these servers, i.e. yields different results for encrypting and for
> comparison??
>
> b) if so, can it be circumvented? Can the crypt function of one
> operating system be imported into the other at least as a callable
> subroutine? How?
>
> c) Or is the only way to remain consistent to run the board only
> on one operating system? Or at least run the routines that change
> passwords only on one operating system, i.e. block user registration
> and profile changes on the other operating system. Any other
> solution in sight?
===================
You can choose the encryption type by the size of the salt you
apply to the 'crypt()' call. FreeBSD supports both DES and MD5.
Since it looks like you're passing a two-character salt, passwords
are being encrypted on qs13 in Standard DES. If you wish to use
Extended DES or MD5, you need to pass a longer salt. Please see
http://www.php.net/manual/en/function.crypt.php for further
information.
Erik
----
>
www.a3.com/chat/pinwand is a message board, based on a mysql database
>
> This database is accessed by other (linux) servers, for copies of
> the board, running on the server and for other authentication
> purposes (chat authentication)
>
> Passwords registered on my qs13 server get stored in crypted form
> in mysql database. When compared with crypted form of user password
> on a linux machine, there is a mismatch.
>
> basically: linux-crypt NOTEQUAL pair-quickserve-crypt