File: includes/auth/auth_apache.php
Unmodified
Added
Modified
Removed
Line 217 | Line 217 |
---|
'group_id' => (int) $row['group_id'], 'user_type' => USER_NORMAL, 'user_ip' => $user->ip,
|
'group_id' => (int) $row['group_id'], 'user_type' => USER_NORMAL, 'user_ip' => $user->ip,
|
| 'user_new' => ($config['new_member_post_limit']) ? 1 : 0,
|
); }
| ); }
|
Line 227 | Line 228 |
---|
*/ function validate_session_apache(&$user) {
|
*/ function validate_session_apache(&$user) {
|
if (!isset($_SERVER['PHP_AUTH_USER']))
| // Check if PHP_AUTH_USER is set and handle this case if (isset($_SERVER['PHP_AUTH_USER']))
|
{
|
{
|
return false; }
| |
$php_auth_user = ''; set_var($php_auth_user, $_SERVER['PHP_AUTH_USER'], 'string', true);
return ($php_auth_user === $user['username']) ? true : false;
|
$php_auth_user = ''; set_var($php_auth_user, $_SERVER['PHP_AUTH_USER'], 'string', true);
return ($php_auth_user === $user['username']) ? true : false;
|
| }
// PHP_AUTH_USER is not set. A valid session is now determined by the user type (anonymous/bot or not) if ($user['user_type'] == USER_IGNORE) { return true; }
return false;
|
}
?>
| }
?>
|