diff options
-rw-r--r-- | phpBB/includes/functions_jabber.php | 15 | ||||
-rw-r--r-- | phpBB/install/install.php | 2 | ||||
-rwxr-xr-x | phpBB/language/en/install.php | 3 |
3 files changed, 8 insertions, 12 deletions
diff --git a/phpBB/includes/functions_jabber.php b/phpBB/includes/functions_jabber.php index 3d74069946..00d7a6c5ab 100644 --- a/phpBB/includes/functions_jabber.php +++ b/phpBB/includes/functions_jabber.php @@ -185,12 +185,12 @@ class jabber // was a result returned? if ($this->get_info_from_iq_type($packet) == 'result' && $this->get_info_from_iq_id($packet) == $this->auth_id) { - if (@function_exists('mhash') && isset($packet['iq']['#']['query'][0]['#']['sequence'][0]['#']) && isset($packet['iq']['#']['query'][0]['#']['token'][0]['#'])) + if (isset($packet['iq']['#']['query'][0]['#']['sequence'][0]['#']) && isset($packet['iq']['#']['query'][0]['#']['token'][0]['#'])) { // auth_0k return $this->_sendauth_ok($packet['iq']['#']['query'][0]['#']['token'][0]['#'], $packet['iq']['#']['query'][0]['#']['sequence'][0]['#']); } - else if (@function_exists('mhash') && isset($packet['iq']['#']['query'][0]['#']['digest'])) + else if (isset($packet['iq']['#']['query'][0]['#']['digest'])) { // digest return $this->_sendauth_digest(); @@ -577,18 +577,15 @@ class jabber function _sendauth_ok($zerok_token, $zerok_sequence) { // initial hash of password - $zerok_hash = @mhash(MHASH_SHA1, $this->password); - $zerok_hash = bin2hex($zerok_hash); + $zerok_hash = sha1($this->password); // sequence 0: hash of hashed-password and token - $zerok_hash = @mhash(MHASH_SHA1, $zerok_hash . $zerok_token); - $zerok_hash = bin2hex($zerok_hash); + $zerok_hash = sha1($zerok_hash . $zerok_token); // repeat as often as needed for ($a = 0; $a < $zerok_sequence; $a++) { - $zerok_hash = @mhash(MHASH_SHA1, $zerok_hash); - $zerok_hash = bin2hex($zerok_hash); + $zerok_hash = sha1($zerok_hash); } $payload = "<username>{$this->username}</username> @@ -605,7 +602,7 @@ class jabber { $payload = "<username>{$this->username}</username> <resource>{$this->resource}</resource> - <digest>" . bin2hex(mhash(MHASH_SHA1, $this->stream_id . $this->password)) . "</digest>"; + <digest>" . sha1($this->stream_id . $this->password) . "</digest>"; $packet = $this->send_iq(NULL, 'set', $this->auth_id, 'jabber:iq:auth', $payload); diff --git a/phpBB/install/install.php b/phpBB/install/install.php index f689af2b4f..2ce5e418d7 100644 --- a/phpBB/install/install.php +++ b/phpBB/install/install.php @@ -76,7 +76,7 @@ $error = array(); // Other PHP modules we may find useful //$php_dlls_other = array('zlib', 'mbstring', 'ftp'); -$php_dlls_other = array('zlib', 'ftp', 'xml', 'mhash'); +$php_dlls_other = array('zlib', 'ftp', 'xml'); // Supported DB layers including relevant details $available_dbms = array( diff --git a/phpBB/language/en/install.php b/phpBB/language/en/install.php index fa57a6017b..94affe7d1d 100755 --- a/phpBB/language/en/install.php +++ b/phpBB/language/en/install.php @@ -57,7 +57,6 @@ $lang = array_merge($lang, array( 'DLL_FIREBIRD' => 'Firebird 1.5+', 'DLL_FTP' => 'Remote FTP support [ Installation ]', 'DLL_MBSTRING' => 'Multi-byte character support', - 'DLL_MHASH' => 'Mhash hashing support [ Jabber ]', 'DLL_MSSQL' => 'MSSQL Server 2000', 'DLL_MSSQL_ODBC' => 'MSSQL Server 2000 via ODBC', 'DLL_MYSQL' => 'MySQL 3.23.x/4.x', @@ -67,7 +66,7 @@ $lang = array_merge($lang, array( 'DLL_POSTGRES' => 'PostgreSQL 7.x', 'DLL_SQLITE' => 'SQLite', 'DLL_XML' => 'XML support [ Jabber ]', - 'DLL_ZLIB' => 'zlib Compression support [ Visual confirmation, gz, .tar.gz, .zip ]', + 'DLL_ZLIB' => 'zlib Compression support [ gz, .tar.gz, .zip ]', 'DL_CONFIG' => 'Download config', 'DL_CONFIG_EXPLAIN' => 'You may download the complete config.php to your own PC. You will then need to upload the file manually, replacing any existing config.php in your phpBB 3.0 root directory. Please remember to upload the file in ASCII format (see your FTP application documentation if you are unsure how to achieve this). When you have uploaded the config.php please click "Done" to move to the next stage.', 'DL_DOWNLOAD' => 'Download', |