BUG 14801 Requerimiento de compatibilidad con Safari de Mac SOLVED
- La computadora del cliente tiene una hora muy diferente a la hora del servidor, por lo que las cookies creadas son inmediatamente deshechadas por el navegador - La validcion adicional para las cookies no se aplica cuando se tiene la bandera "safari_cookie_lifetime" con valor "0" - OJO. ESTE CAMBIO SOLO ARREGLA EL PROBLEMA EXISTENTE EN VIVA PARA LA AUTENTIFICACION DE USUARIOS, CUALQUIER OTRO ISSUE RELACIONADO A FUNCIONAMIENTO DE PM EN SAFARI NO ESTA GARANTIZADO (ESPECIALMENTE ISSUES DE JAVASCRIPT), YA QUE PM NO ES OFICIALMENTE PROBADO EN PM Y NO SABEMOS HASTA CUANDO SEA ASI, ASI QUE FUTUROS ISSUES EN SAFARI SERAN ENVIADOS AL ROADMAP Y DEBE SER APROBADO POR INSTANCIAS SUPERIORES EL VISTO BUENO PARA IR ADELANTE CON LAS PRUEBAS EN SAFARI
This commit is contained in:
@@ -85,7 +85,7 @@ class Bootstrap
|
||||
}
|
||||
|
||||
// default configuration
|
||||
$config = array('debug' => 0, 'debug_sql' => 0, 'debug_time' => 0, 'debug_calendar' => 0, 'wsdl_cache' => 1, 'memory_limit' => "256M", 'time_zone' => 'America/New_York', 'memcached' => 0, 'memcached_server' => '', 'default_skin' => 'neoclassic', 'default_lang' => 'en', 'proxy_host' => '', 'proxy_port' => '', 'proxy_user' => '', 'proxy_pass' => '' , 'size_log_file' => 5000000 , 'number_log_file' => 5, 'ie_cookie_lifetime' => 1);
|
||||
$config = array('debug' => 0, 'debug_sql' => 0, 'debug_time' => 0, 'debug_calendar' => 0, 'wsdl_cache' => 1, 'memory_limit' => "256M", 'time_zone' => 'America/New_York', 'memcached' => 0, 'memcached_server' => '', 'default_skin' => 'neoclassic', 'default_lang' => 'en', 'proxy_host' => '', 'proxy_port' => '', 'proxy_user' => '', 'proxy_pass' => '' , 'size_log_file' => 5000000 , 'number_log_file' => 5, 'ie_cookie_lifetime' => 1, 'safari_cookie_lifetime' => 1);
|
||||
|
||||
// read the global env.ini configuration file
|
||||
if ($readGlobalIniFile && ($globalConf = @parse_ini_file($globalIniFile)) !== false) {
|
||||
|
||||
@@ -285,7 +285,10 @@ if (is_null($timelife)) {
|
||||
$timelife = 1440;
|
||||
}
|
||||
ini_set('session.gc_maxlifetime', $timelife);
|
||||
if (preg_match("/msie/i", $_SERVER ['HTTP_USER_AGENT']) != 1 || $config['ie_cookie_lifetime'] == 1) {
|
||||
if ((preg_match("/msie/i", $_SERVER ['HTTP_USER_AGENT']) != 1 ||
|
||||
$config['ie_cookie_lifetime'] == 1) &&
|
||||
(!(preg_match("/safari/i", $_SERVER ['HTTP_USER_AGENT']) == 1 && preg_match("/chrome/i", $_SERVER ['HTTP_USER_AGENT']) == 0) ||
|
||||
$config['safari_cookie_lifetime'] == 1)) {
|
||||
ini_set('session.cookie_lifetime', $timelife);
|
||||
}
|
||||
session_start();
|
||||
@@ -888,7 +891,10 @@ if (! defined( 'EXECUTE_BY_CRON' )) {
|
||||
define( 'SYS_LANG_DIRECTION', $oServerConf->getLanDirection() );
|
||||
|
||||
if ((isset( $_SESSION['USER_LOGGED'] )) && (! (isset( $_GET['sid'] )))) {
|
||||
if (preg_match("/msie/i", $_SERVER ['HTTP_USER_AGENT']) != 1 || $config['ie_cookie_lifetime'] == 1) {
|
||||
if ((preg_match("/msie/i", $_SERVER ['HTTP_USER_AGENT']) != 1 ||
|
||||
$config['ie_cookie_lifetime'] == 1) &&
|
||||
(!(preg_match("/safari/i", $_SERVER ['HTTP_USER_AGENT']) == 1 && preg_match("/chrome/i", $_SERVER ['HTTP_USER_AGENT']) == 0) ||
|
||||
$config['safari_cookie_lifetime'] == 1)) {
|
||||
if (PHP_VERSION < 5.2) {
|
||||
setcookie(session_name(), session_id(), time() + $timelife, '/', '; HttpOnly');
|
||||
} else {
|
||||
@@ -957,7 +963,10 @@ if (! defined( 'EXECUTE_BY_CRON' )) {
|
||||
$_SESSION['USER_LOGGED'] = $aUser['USR_UID'];
|
||||
$_SESSION['USR_USERNAME'] = $aUser['USR_USERNAME'];
|
||||
$bRedirect = false;
|
||||
if (preg_match("/msie/i", $_SERVER ['HTTP_USER_AGENT']) != 1 || $config['ie_cookie_lifetime'] == 1) {
|
||||
if ((preg_match("/msie/i", $_SERVER ['HTTP_USER_AGENT']) != 1 ||
|
||||
$config['ie_cookie_lifetime'] == 1) &&
|
||||
(!(preg_match("/safari/i", $_SERVER ['HTTP_USER_AGENT']) == 1 && preg_match("/chrome/i", $_SERVER ['HTTP_USER_AGENT']) == 0) ||
|
||||
$config['safari_cookie_lifetime'] == 1)) {
|
||||
if (PHP_VERSION < 5.2) {
|
||||
setcookie(session_name(), session_id(), time() + $timelife, '/', '; HttpOnly');
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user