Merge branch '3.4' into 4.0
* 3.4: simplified code
This commit is contained in:
commit
86f164b6ff
@ -115,10 +115,6 @@ class GuardAuthenticatorHandler
|
||||
if (!$request->hasSession() || !$request->hasPreviousSession()) {
|
||||
return;
|
||||
}
|
||||
|
||||
// Destroying the old session is broken in php 5.4.0 - 5.4.10
|
||||
// See https://bugs.php.net/63379
|
||||
$destroy = \PHP_VERSION_ID < 50400 || \PHP_VERSION_ID >= 50411;
|
||||
$request->getSession()->migrate($destroy);
|
||||
$request->getSession()->migrate(true);
|
||||
}
|
||||
}
|
||||
|
@ -123,10 +123,6 @@ abstract class AbstractPreAuthenticatedListener implements ListenerInterface
|
||||
if (!$request->hasSession() || !$request->hasPreviousSession()) {
|
||||
return;
|
||||
}
|
||||
|
||||
// Destroying the old session is broken in php 5.4.0 - 5.4.10
|
||||
// See https://bugs.php.net/63379
|
||||
$destroy = \PHP_VERSION_ID < 50400 || \PHP_VERSION_ID >= 50411;
|
||||
$request->getSession()->migrate($destroy);
|
||||
$request->getSession()->migrate(true);
|
||||
}
|
||||
}
|
||||
|
@ -98,10 +98,6 @@ class BasicAuthenticationListener implements ListenerInterface
|
||||
if (!$request->hasSession() || !$request->hasPreviousSession()) {
|
||||
return;
|
||||
}
|
||||
|
||||
// Destroying the old session is broken in php 5.4.0 - 5.4.10
|
||||
// See https://bugs.php.net/63379
|
||||
$destroy = \PHP_VERSION_ID < 50400 || \PHP_VERSION_ID >= 50411;
|
||||
$request->getSession()->migrate($destroy);
|
||||
$request->getSession()->migrate(true);
|
||||
}
|
||||
}
|
||||
|
@ -121,10 +121,6 @@ class SimplePreAuthenticationListener implements ListenerInterface
|
||||
if (!$request->hasSession() || !$request->hasPreviousSession()) {
|
||||
return;
|
||||
}
|
||||
|
||||
// Destroying the old session is broken in php 5.4.0 - 5.4.10
|
||||
// See https://bugs.php.net/63379
|
||||
$destroy = \PHP_VERSION_ID < 50400 || \PHP_VERSION_ID >= 50411;
|
||||
$request->getSession()->migrate($destroy);
|
||||
$request->getSession()->migrate(true);
|
||||
}
|
||||
}
|
||||
|
@ -190,9 +190,6 @@ class UsernamePasswordJsonAuthenticationListener implements ListenerInterface
|
||||
if (!$request->hasSession() || !$request->hasPreviousSession()) {
|
||||
return;
|
||||
}
|
||||
// Destroying the old session is broken in php 5.4.0 - 5.4.10
|
||||
// See https://bugs.php.net/63379
|
||||
$destroy = \PHP_VERSION_ID < 50400 || \PHP_VERSION_ID >= 50411;
|
||||
$request->getSession()->migrate($destroy);
|
||||
$request->getSession()->migrate(true);
|
||||
}
|
||||
}
|
||||
|
@ -49,11 +49,7 @@ class SessionAuthenticationStrategy implements SessionAuthenticationStrategyInte
|
||||
case self::MIGRATE:
|
||||
// Note: this logic is duplicated in several authentication listeners
|
||||
// until Symfony 5.0 due to a security fix with BC compat
|
||||
|
||||
// Destroying the old session is broken in php 5.4.0 - 5.4.10
|
||||
// See https://bugs.php.net/63379
|
||||
$destroy = \PHP_VERSION_ID < 50400 || \PHP_VERSION_ID >= 50411;
|
||||
$request->getSession()->migrate($destroy);
|
||||
$request->getSession()->migrate(true);
|
||||
|
||||
return;
|
||||
|
||||
|
Reference in New Issue
Block a user