mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-29 06:38:52 +00:00
fix for bug #5490
- make sure bots are catched by the posting auth too. git-svn-id: file:///svn/phpbb/trunk@6619 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
parent
e03fb0aafd
commit
2774981b2d
2 changed files with 6 additions and 1 deletions
|
@ -244,6 +244,7 @@ class p_master
|
||||||
case '(':
|
case '(':
|
||||||
case '&&':
|
case '&&':
|
||||||
case '||':
|
case '||':
|
||||||
|
case ',':
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
|
@ -254,8 +255,12 @@ class p_master
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$module_auth = implode(' ', $tokens);
|
$module_auth = implode(' ', $tokens);
|
||||||
|
|
||||||
|
// Make sure $id seperation is working fine
|
||||||
|
$module_auth = str_replace(' , ', ',', $module_auth);
|
||||||
|
|
||||||
$is_auth = false;
|
$is_auth = false;
|
||||||
eval('$is_auth = (int) (' . preg_replace(array('#acl_([a-z_]+)(,\$id)?#', '#\$id#', '#aclf_([a-z_]+)#', '#cfg_([a-z_]+)#'), array('(int) $auth->acl_get(\'\\1\'\\2)', '(int) $this->acl_forum_id', '(int) $auth->acl_getf_global(\'\\1\')', '(int) $config[\'\\1\']'), $module_auth) . ');');
|
eval('$is_auth = (int) (' . preg_replace(array('#acl_([a-z_]+)(,\$id)?#', '#\$id#', '#aclf_([a-z_]+)#', '#cfg_([a-z_]+)#'), array('(int) $auth->acl_get(\'\\1\'\\2)', '(int) $this->acl_forum_id', '(int) $auth->acl_getf_global(\'\\1\')', '(int) $config[\'\\1\']'), $module_auth) . ');');
|
||||||
|
|
||||||
|
|
|
@ -163,7 +163,7 @@ if ($post_data['forum_password'])
|
||||||
// Is the user able to read within this forum?
|
// Is the user able to read within this forum?
|
||||||
if (!$auth->acl_get('f_read', $forum_id))
|
if (!$auth->acl_get('f_read', $forum_id))
|
||||||
{
|
{
|
||||||
if ($user->data['is_registered'])
|
if ($user->data['user_id'] != ANONYMOUS)
|
||||||
{
|
{
|
||||||
trigger_error('USER_CANNOT_READ');
|
trigger_error('USER_CANNOT_READ');
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue