mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-27 12:00:26 +02:00
Correctly check empty subjects/messages (Bug #17915)
Do not check usernames against word censor list. Disallowed usernames is already checked and word censor belong to posts. (Bug #17745) Additionally include non-postable forums for moderators forums shown within the teams list. (Bug #17265) git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@8306 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
@@ -20,11 +20,11 @@ if (!defined('IN_PHPBB'))
|
||||
*
|
||||
* Jabber class from Flyspray project
|
||||
*
|
||||
* @version class.jabber2.php 1306 2007-06-21
|
||||
* @version class.jabber2.php 1488 2007-11-25
|
||||
* @copyright 2006 Flyspray.org
|
||||
* @author Florian Schmitz (floele)
|
||||
*
|
||||
* Modified by Acyd Burn
|
||||
* Only slightly modified by Acyd Burn
|
||||
*
|
||||
* @package phpBB3
|
||||
*/
|
||||
@@ -286,7 +286,7 @@ class jabber
|
||||
$read = trim(fread($this->connection, 4096));
|
||||
$data .= $read;
|
||||
}
|
||||
while (time() <= $start + $timeout && ($wait || $data == '' || $read != '' || (substr(rtrim($data), -1) != '>')));
|
||||
while (time() <= $start + $timeout && !feof($this->connection) && ($wait || $data == '' || $read != '' || (substr(rtrim($data), -1) != '>')));
|
||||
|
||||
if ($data != '')
|
||||
{
|
||||
@@ -385,7 +385,6 @@ class jabber
|
||||
{
|
||||
case 'stream:stream':
|
||||
// Connection initialised (or after authentication). Not much to do here...
|
||||
$this->session['id'] = $xml['stream:stream'][0]['@']['id'];
|
||||
|
||||
if (isset($xml['stream:stream'][0]['#']['stream:features']))
|
||||
{
|
||||
@@ -397,6 +396,16 @@ class jabber
|
||||
$this->features = $this->listen();
|
||||
}
|
||||
|
||||
$second_time = isset($this->session['id']);
|
||||
$this->session['id'] = $xml['stream:stream'][0]['@']['id'];
|
||||
|
||||
if ($second_time)
|
||||
{
|
||||
// If we are here for the second time after TLS, we need to continue logging in
|
||||
$this->login();
|
||||
return;
|
||||
}
|
||||
|
||||
// go on with authentication?
|
||||
if (isset($this->features['stream:features'][0]['#']['bind']) || !empty($this->session['tls']))
|
||||
{
|
||||
@@ -519,9 +528,10 @@ class jabber
|
||||
'response' => $this->encrypt_password(array_merge($decoded, array('nc' => '00000001'))),
|
||||
'charset' => 'utf-8',
|
||||
'nc' => '00000001',
|
||||
'qop' => 'auth', // only auth being supported
|
||||
);
|
||||
|
||||
foreach (array('nonce', 'qop', 'digest-uri', 'realm', 'cnonce') as $key)
|
||||
foreach (array('nonce', 'digest-uri', 'realm', 'cnonce') as $key)
|
||||
{
|
||||
if (isset($decoded[$key]))
|
||||
{
|
||||
|
Reference in New Issue
Block a user