Index: trunk/extensions/LdapAuthentication/LdapAuthentication.php |
— | — | @@ -1746,6 +1746,10 @@ |
1747 | 1747 | // Set the password hashing based upon admin preference |
1748 | 1748 | switch ( $hashtouse ) { |
1749 | 1749 | case 'crypt': |
| 1750 | + // https://bugs.php.net/bug.php?id=55439 |
| 1751 | + if ( crypt( 'password', '$1$U7AjYB.O$' ) == '$1$U7AjYB.O' ) { |
| 1752 | + die( 'The version of PHP in use has a broken crypt function. Please upgrade your installation of PHP, or use another encryption function for LDAP.' ); |
| 1753 | + } |
1750 | 1754 | $pass = '{CRYPT}' . crypt( $password ); |
1751 | 1755 | break; |
1752 | 1756 | case 'clear': |