diff --git a/CHANGELOG-2.3.md b/CHANGELOG-2.3.md index 1fa2df288d..c7acce7993 100644 --- a/CHANGELOG-2.3.md +++ b/CHANGELOG-2.3.md @@ -7,6 +7,30 @@ in 2.3 minor versions. To get the diff for a specific change, go to https://github.com/symfony/symfony/commit/XXX where XXX is the change hash To get the diff between two versions, go to https://github.com/symfony/symfony/compare/v2.3.0...v2.3.1 +* 2.3.24 (2015-01-07) + + * bug #13286 [Security] Don't destroy the session on buggy php releases. (derrabus) + * bug #12417 [HttpFoundation] Fix an issue caused by php's Bug #66606. (wusuopu) + * bug #13200 Don't add Accept-Range header on unsafe HTTP requests (jaytaph) + * bug #12491 [Security] Don't send remember cookie for sub request (blanchonvincent) + * bug #12574 [HttpKernel] Fix UriSigner::check when _hash is not at the end of the uri (nyroDev) + * bug #13185 Fixes Issue #13184 - incremental output getters now return empty strings (Bailey Parker) + * bug #13145 [DomCrawler] Fix behaviour with tag (dkop, WouterJ) + * bug #13141 [TwigBundle] Moved the setting of the default escaping strategy from the Twig engine to the Twig environment (fabpot) + * bug #13114 [HttpFoundation] fixed error when an IP in the X-Forwarded-For HTTP head... (fabpot) + * bug #12572 [HttpFoundation] fix checkip6 (Neime) + * bug #13075 [Config] fix error handler restoration in test (nicolas-grekas) + * bug #13081 [FrameworkBundle] forward error reporting level to insulated Client (nicolas-grekas) + * bug #13053 [FrameworkBundle] Fixed Translation loader and update translation command. (saro0h) + * bug #13048 [Security] Delete old session on auth strategy migrate (xelaris) + * bug #12999 [FrameworkBundle] fix cache:clear command (nicolas-grekas) + * bug #13004 add a limit and a test to FlattenExceptionTest. (Daniel Wehner) + * bug #12961 fix session restart on PHP 5.3 (Tobion) + * bug #12761 [Filesystem] symlink use RealPath instead LinkTarget (aitboudad) + * bug #12855 [DependencyInjection] Perf php dumper (nicolas-grekas) + * bug #12894 [FrameworkBundle][Template name] avoid error message for the shortcut n... (aitboudad) + * bug #12858 [ClassLoader] Fix undefined index in ClassCollectionLoader (szicsu) + * 2.3.23 (2014-12-03) * bug #12811 Configure firewall's kernel exception listener with configured entry point or a default entry point (rjkip) diff --git a/CONTRIBUTORS.md b/CONTRIBUTORS.md index 75afab4337..0598e0ee35 100644 --- a/CONTRIBUTORS.md +++ b/CONTRIBUTORS.md @@ -12,10 +12,12 @@ Symfony is the result of the work of many people who made the code better - Johannes S (johannes) - Kris Wallsmith (kriswallsmith) - Christophe Coevoet (stof) + - Nicolas Grekas (nicolas-grekas) - Pascal Borreli (pborreli) - Jakub Zalas (jakubzalas) - Karma Dordrak (drak) - Joseph Bielawski (stloyd) + - Hugo Hamon (hhamon) - Ryan Weaver (weaverryan) - Lukas Kahwe Smith (lsmith) - Romain Neutron (romain) @@ -23,11 +25,9 @@ Symfony is the result of the work of many people who made the code better - Jean-François Simon (jfsimon) - Benjamin Eberlei (beberlei) - Igor Wiedler (igorw) - - Hugo Hamon (hhamon) - - Nicolas Grekas (nicolas-grekas) + - Christian Flothmann (xabbuh) - Martin Hasoň (hason) - Eriksen Costa (eriksencosta) - - Christian Flothmann (xabbuh) - Jonathan Wage (jwage) - Grégoire Pineau (lyrixx) - Alexandre Salomé (alexandresalome) @@ -35,12 +35,12 @@ Symfony is the result of the work of many people who made the code better - ornicar - stealth35 ‏ (stealth35) - Alexander Mols (asm89) + - Wouter De Jong (wouterj) - Bulat Shakirzyanov (avalanche123) - Francis Besset (francisbesset) - Saša Stamenković (umpirsky) - - Wouter De Jong (wouterj) - - Miha Vrhovnik - Henrik Bjørnskov (henrikbjorn) + - Miha Vrhovnik - Konstantin Kudryashov (everzet) - Bilal Amarni (bamarni) - Florin Patan (florinpatan) @@ -49,8 +49,10 @@ Symfony is the result of the work of many people who made the code better - Deni - Henrik Westphal (snc) - Dariusz Górecki (canni) - - Christian Raue - Arnout Boks (aboks) + - Christian Raue + - Sarah Khalil (saro0h) + - Ait Boudad Abdellatif (aitboudad) - Michel Weimerskirch (mweimerskirch) - Lee McDermott - Brandon Turner @@ -62,7 +64,6 @@ Symfony is the result of the work of many people who made the code better - Fran Moreno (franmomu) - Antoine Hérault (herzult) - Toni Uebernickel (havvg) - - Ait Boudad Abdellatif (aitboudad) - Luis Cordova (cordoval) - Arnaud Le Blanc (arnaud-lb) - Kevin Bond (kbond) @@ -70,15 +71,17 @@ Symfony is the result of the work of many people who made the code better - Brice BERNARD (brikou) - marc.weistroff - lenar + - Graham Campbell (graham) - Włodzimierz Gajda (gajdaw) - Colin Frei + - Gábor Egyed (1ed) - excelwebzone - Jacob Dreesen (jdreesen) - Florian Voutzinos (florianv) - Jérôme Tamarelle (gromnan) - Adrien Brault (adrienbrault) - - Gábor Egyed (1ed) - Fabien Pennequin (fabienpennequin) + - Kévin Dunglas (dunglas) - Michal Piotrowski (eventhorizon) - Gordon Franke (gimler) - Robert Schönthal (digitalkaoz) @@ -93,11 +96,10 @@ Symfony is the result of the work of many people who made the code better - Jérémie Augustin (jaugustin) - Rafael Dohms (rdohms) - Jérémy DERUSSÉ (jderusse) + - Stefano Sala (stefano.sala) - Tigran Azatyan (tigranazatyan) - Javier Eguiluz (javier.eguiluz) - Richard Shank (iampersistent) - - Kévin Dunglas (dunglas) - - Stefano Sala (stefano.sala) - Clemens Tolboom - Helmer Aaviksoo - Sebastiaan Stok (sstok) @@ -111,9 +113,11 @@ Symfony is the result of the work of many people who made the code better - Rouven Weßling (realityking) - Dmitrii Chekaliuk (lazyhammer) - Clément JOBEILI (dator) + - Peter Rehm (rpet) - Dorian Villet (gnutix) - Richard Miller (mr_r_miller) - Arnaud Kleinpeter (nanocom) + - hacfi (hifi) - Mario A. Alvarez Garcia (nomack84) - Dennis Benkert (denderello) - Benjamin Dulau (dbenjamin) @@ -121,7 +125,7 @@ Symfony is the result of the work of many people who made the code better - Andreas Hucks (meandmymonkey) - Andréia Bohner (andreia) - Noel Guilbert (noel) - - Peter Rehm (rpet) + - Joel Wurtz (brouznouf) - Charles Sarrazin (csarrazi) - bronze1man - sun (sun) @@ -139,14 +143,12 @@ Symfony is the result of the work of many people who made the code better - Justin Hileman (bobthecow) - Sven Paulus (subsven) - Lars Strojny (lstrojny) - - Joel Wurtz (brouznouf) - Rui Marinho (ruimarinho) - Julien Brochet (mewt) - Tugdual Saunier (tucksaun) - - Graham Campbell (graham) - Sergey Linnik (linniksa) - Marcel Beerta (mazen) - - hacfi (hifi) + - Iltar van der Berg - Francois Zaninotto - Alexander Kotynia (olden) - Daniel Tschinder @@ -172,9 +174,9 @@ Symfony is the result of the work of many people who made the code better - Thomas Adam - Albert Casademont (acasademont) - jdhoek + - Jeremy Livingston (jeremylivingston) - Nikita Konstantinov - Wodor Wodorski - - Iltar van der Berg - julien pauli (jpauli) - Beau Simensen (simensen) - Robert Kiss (kepten) @@ -193,6 +195,7 @@ Symfony is the result of the work of many people who made the code better - Bertrand Zuchuat (garfield-fr) - Gabor Toth (tgabi333) - realmfoo + - Chris Wilkinson (thewilkybarkid) - Thomas Tourlourat (armetiz) - Andrey Esaulov (andremaha) - Grégoire Passault (gregwar) @@ -216,6 +219,7 @@ Symfony is the result of the work of many people who made the code better - alquerci - Francesco Levorato - Vitaliy Zakharov (zakharovvi) + - Florian Lonqueu-Brochard (florianlb) - Gyula Sallai (salla) - Inal DJAFAR (inalgnu) - Christian Gärtner (dagardner) @@ -223,8 +227,10 @@ Symfony is the result of the work of many people who made the code better - Yaroslav Kiliba - Sébastien Lavoie (lavoiesl) - Terje Bråten + - Joshua Thijssen - Kristen Gilden (kgilden) - Robbert Klarenbeek (robbertkl) + - Blanchon Vincent (blanchonvincent) - hossein zolfi (ocean) - Clément Gautier (clementgautier) - Eduardo Gulias (egulias) @@ -234,13 +240,13 @@ Symfony is the result of the work of many people who made the code better - Kirill chEbba Chebunin (chebba) - Greg Thornton (xdissent) - Grégoire Paris (greg0ire) - - Chris Wilkinson (thewilkybarkid) - Costin Bereveanu (schniper) - Loïc Chardonnet (gnusat) - Marek Kalnik (marekkalnik) - Vyacheslav Salakhutdinov (megazoll) - Alex Pott - Tamas Szijarto + - Mikael Pajunen - Pavel Volokitin (pvolok) - Endre Fejes - Tobias Naumann (tna) @@ -248,6 +254,7 @@ Symfony is the result of the work of many people who made the code better - Shein Alexey - Joe Lencioni - Kai + - Maximilian Reichel (phramz) - Karoly Negyesi (chx) - Xavier HAUSHERR - Albert Jessurum (ajessu) @@ -255,6 +262,7 @@ Symfony is the result of the work of many people who made the code better - Miha Vrhovnik - Alessandro Desantis - hubert lecorche (hlecorche) + - Marc Morales Valldepérez (kuert) - Oscar Cubo Medina (ocubom) - Karel Souffriau - Christophe L. (christophelau) @@ -262,6 +270,7 @@ Symfony is the result of the work of many people who made the code better - Jáchym Toušek - Jannik Zschiesche (apfelbox) - Emanuele Gaspari (inmarelibero) + - Dariusz Rumiński - Brian King - Michel Salib (michelsalib) - geoffrey @@ -275,6 +284,7 @@ Symfony is the result of the work of many people who made the code better - Olivier Dolbeau (odolbeau) - Roumen Damianoff (roumen) - Tobias Sjösten (tobiassjosten) + - Konstantin Myakshin (koc) - vagrant - Asier Illarramendi (doup) - Chris Sedlmayr (catchamonkey) @@ -307,6 +317,7 @@ Symfony is the result of the work of many people who made the code better - Iker Ibarguren (ikerib) - Ricardo Oliveira (ricardolotr) - ondrowan + - Jerzy Zawadzki (jzawadzki) - Evan S Kaufman (evanskaufman) - mcben - Maks Slesarenko @@ -316,7 +327,6 @@ Symfony is the result of the work of many people who made the code better - Ioan Negulescu - Jakub Škvára (jskvara) - Andrew Udvare (audvare) - - Sarah Khalil (saro0h) - alexpods - Erik Trapman (eriktrapman) - De Cock Xavier (xdecock) @@ -327,8 +337,8 @@ Symfony is the result of the work of many people who made the code better - Nils Adermann (naderman) - Gábor Fási - Benjamin Leveque (benji07) - - Maximilian Reichel (phramz) - sasezaki + - Dawid Pakuła (zulusx) - Florian Rey (nervo) - Rodrigo Borrego Bernabé (rodrigobb) - Denis Gorbachev (starfall) @@ -346,8 +356,8 @@ Symfony is the result of the work of many people who made the code better - Zach Badgett (zachbadgett) - Aurélien Fredouelle - Pavel Campr (pcampr) + - Alexander Schwenn (xelaris) - Disquedur - - Marc Morales Valldepérez (kuert) - Geoffrey Tran (geoff) - Jan Behrens - Sebastian Krebs @@ -364,7 +374,6 @@ Symfony is the result of the work of many people who made the code better - Max Rath (drak3) - Stéphane Escandell (sescandell) - Sinan Eldem - - Konstantin Myakshin (koc) - Nahuel Cuesta (ncuesta) - Chris Boden (cboden) - Asmir Mustafic (goetas) @@ -383,7 +392,6 @@ Symfony is the result of the work of many people who made the code better - Erkhembayar Gantulga (erheme318) - David Fuhr - Kamil Kokot (pamil) - - Florian Lonqueu-Brochard (florianlb) - Rostyslav Kinash - Daisuke Ohata - Vincent Simonin @@ -433,7 +441,6 @@ Symfony is the result of the work of many people who made the code better - Alex Xandra Albert Sim - Yuen-Chi Lian - Besnik Br - - Jerzy Zawadzki (jzawadzki) - Joshua Nye - avorobiev - Venu @@ -445,9 +452,11 @@ Symfony is the result of the work of many people who made the code better - 1emming - Leevi Graham (leevigraham) - Casper Valdemar Poulsen + - Daniel Wehner - Josiah (josiah) - Marek Štípek (maryo) - John Bohn (jbohn) + - Marc Morera (mmoreram) - Andrew Hilobok (hilobok) - Christian Soronellas (theunic) - Yosmany Garcia (yosmanyga) @@ -459,7 +468,6 @@ Symfony is the result of the work of many people who made the code better - Krzysiek Łabuś - Xavier Lacot (xavier) - Olivier Maisonneuve (olineuve) - - Blanchon Vincent (blanchonvincent) - Francis Turmel (fturmel) - Loick Piera (pyrech) - cgonzalez @@ -482,6 +490,7 @@ Symfony is the result of the work of many people who made the code better - frost-nzcr4 - Abhoryo - Fabian Vogler (fabian) + - Javier Spagnoletti (phansys) - Korvin Szanto - Maksim Kotlyar (makasim) - Neil Ferreira @@ -529,6 +538,7 @@ Symfony is the result of the work of many people who made the code better - Maks - Gábor Tóth - Daniel Cestari + - Massimiliano Arione (garak) - Brunet Laurent (lbrunet) - Magnus Nordlander (magnusnordlander) - Mikhail Yurasov (mym) @@ -601,12 +611,14 @@ Symfony is the result of the work of many people who made the code better - Dan Finnie - Ken Marfilla (marfillaster) - benatespina (benatespina) + - Denis Kop - jfcixmedia - Martijn Evers - Benjamin Paap (benjaminpaap) - Christian - Sergii Smertin (nfx) - Artur Eshenbrener + - Bailey Parker - Eddie Jaoude - Haritz Iturbe (hizai) - Nerijus Arlauskas (nercury) @@ -638,6 +650,7 @@ Symfony is the result of the work of many people who made the code better - Albert Ganiev (helios-ag) - Neil Katin - David Otton + - Will Donohoe - peter - Jérémy Jourdin (jjk801) - Artem Kolesnikov (tyomo4ka) @@ -645,6 +658,7 @@ Symfony is the result of the work of many people who made the code better - Yannick - Luc Vieillescazes (iamluc) - Eduardo García Sanz (coma) + - Szijarto Tamas - Roy Van Ginneken - David de Boer (ddeboer) - Gilles Doge (gido) @@ -666,6 +680,7 @@ Symfony is the result of the work of many people who made the code better - Philipp Strube - Christian Sciberras - Clement Herreman (clemherreman) + - Nyro (nyro) - Trent Steel (trsteel88) - Marco - Marc Torres @@ -678,6 +693,7 @@ Symfony is the result of the work of many people who made the code better - Jakub Kulhan - Mo Di (modi) - Jeroen van den Enden (stoefke) + - origaminal - Quique Porta (quiqueporta) - Tomasz Szymczyk (karion) - ConneXNL @@ -685,6 +701,7 @@ Symfony is the result of the work of many people who made the code better - Abdul.Mohsen B. A. A - Benoît Burnichon - Malaney J. Hill + - Christian Flach (cmfcmf) - Cédric Girard (enk_) - Oriol Mangas Abellan (oriolman) - Sebastian Göttschkes (sgoettschkes) @@ -697,7 +714,6 @@ Symfony is the result of the work of many people who made the code better - Erika Heidi Reinaldo (erikaheidi) - Pierre Tachoire (krichprollsch) - Marc J. Schmidt (marcjs) - - Marc Morera (mmoreram) - Marco Jantke - Saem Ghani - Sebastian Utz @@ -708,6 +724,7 @@ Symfony is the result of the work of many people who made the code better - steveYeah - Samy Dindane (dinduks) - Keri Henare (kerihenare) + - Mickaël Andrieu (mickaelandrieu) - Cédric Lahouste (rapotor) - Samuel Vogel (samuelvogel) - Berat Doğan @@ -736,6 +753,7 @@ Symfony is the result of the work of many people who made the code better - Felds Liscia - James Halsall (jaitsu) - Maxime Veber (nek-) + - Sullivan SENECHAL - Tadcka - Beth Binkovitz - Romain Geissler @@ -754,6 +772,7 @@ Symfony is the result of the work of many people who made the code better - Timothy Anido (xanido) - Rick Prent - Martin Eckhardt + - Pieter Jordaan - Damien Tournoud - Jon Gotlin (jongotlin) - Michael Dowling (mtdowling) @@ -777,7 +796,6 @@ Symfony is the result of the work of many people who made the code better - Simon Neidhold - Kevin Dew - James Cowgill - - Jeremy Livingston (jeremylivingston) - Nicolas Schwartz (nicoschwartz) - Patrik Gmitter (patie) - Jonathan Gough @@ -798,12 +816,14 @@ Symfony is the result of the work of many people who made the code better - César Suárez (csuarez) - Nicolas Badey (nico-b) - Shane Preece (shane) + - wusuopu - povilas - Diego Agulló - Alexander Obuhovich - Alessandro Tagliapietra (alex88) - Gunnar Lium (gunnarlium) - Tiago Garcia (tiagojsag) + - Artiom - Bouke Haarsma - Martin Eckhardt - Denis Zunke @@ -836,7 +856,6 @@ Symfony is the result of the work of many people who made the code better - Michal Gebauer - Gleb Sidora - David Stone - - Javier Spagnoletti (phansys) - Pablo Maria Martelletti (pmartelletti) - Yassine Guedidi (yguedidi) - Luis Muñoz @@ -852,6 +871,7 @@ Symfony is the result of the work of many people who made the code better - Ionel Scutelnicu (ionelscutelnicu) - Johnny Peck (johnnypeck) - Nicolas Tallefourtané (nicolab) + - Botond Dani (picur) - Thierry Marianne (thierrymarianne) - Nick Stemerdink - jjanvier @@ -871,7 +891,6 @@ Symfony is the result of the work of many people who made the code better - Mike Meier - Warwick - Chris - - Daniel Wehner - efeen - Michał Dąbrowski (defrag) - Dominik Zogg (dominik.zogg) @@ -897,6 +916,7 @@ Symfony is the result of the work of many people who made the code better - Kevin Decherf - Jason Woods - dened + - Dmitry Korotovsky - Sam Ward - Walther Lalk - Adam @@ -905,16 +925,19 @@ Symfony is the result of the work of many people who made the code better - gedrox - dropfen - Andrey Chernykh + - Edvinas Klovas - Drew Butler - J Bruni - Alexey Prilipko - bertillon + - Luca Genuzio (genuzio) - Hans Nilsson (hansnilsson) - Ioana Hazsda (ioana-hazsda) - Jan Marek (janmarek) - Mark de Haan (markdehaan) - Dan Patrick (mdpatrick) - Rares Vlaseanu (raresvla) + - Sofiane HADDAG (sofhad) - tante kinast (tante) - Vincent LEFORT (vlefort) - Alexander Zogheb @@ -941,6 +964,7 @@ Symfony is the result of the work of many people who made the code better - Hein Zaw Htet™ - Ruben Kruiswijk - Michael J + - Berny Cantos - Alex Pods - timaschew - Ian Phillips @@ -964,10 +988,12 @@ Symfony is the result of the work of many people who made the code better - ddebree - Alex - Klaas Naaijkens + - Daniel González Cerviño - Rafał - Adria Lopez (adlpz) - Rosio (ben-rosio) - Simon Paarlberg (blamh) + - Jeroen Thora (bolle) - Masao Maeda (brtriver) - Darius Leskauskas (darles) - Dave Hulbert (dave1010) @@ -989,6 +1015,7 @@ Symfony is the result of the work of many people who made the code better - Muriel (metalmumu) - Michaël Perrin (michael.perrin) - Michael Pohlers (mick_the_big) + - Mantas Var (mvar) - Cayetano Soriano Gallego (neoshadybeat) - Pablo Monterde Perez (plebs) - Jimmy Leger (redpanda) @@ -1093,6 +1120,7 @@ Symfony is the result of the work of many people who made the code better - tirnanog06 - phc - ilyes kooli + - Matthias Althaus - Michaël VEROUX - sualko - Nicolas Roudaire @@ -1117,7 +1145,6 @@ Symfony is the result of the work of many people who made the code better - Fabien D. (fabd) - Sorin Gitlan (forapathy) - Yohan Giarelli (frequence-web) - - Massimiliano Arione (garak) - Gerry Vandermaesen (gerryvdm) - Ghazy Ben Ahmed (ghazy) - Arash Tabriziyan (ghost098) @@ -1141,6 +1168,7 @@ Symfony is the result of the work of many people who made the code better - Matt Drollette (mdrollette) - Adam Monsen (meonkeys) - Ala Eddine Khefifi (nayzo) + - emilienbouard (neime) - ollie harridge (ollietb) - Paweł Szczepanek (pauluz) - Christian López Espínola (penyaskito) @@ -1153,7 +1181,9 @@ Symfony is the result of the work of many people who made the code better - scourgen hung (scourgen) - Sebastian Busch (sebu) - André Filipe Gonçalves Neves (seven) + - Bruno Ziegler (sfcoder) - Andrea Giuliano (shark) + - Schuyler Jager (sjager) - Volker (skydiablo) - Julien Sanchez (sumbobyboys) - Guillermo Gisinger (t3chn0r) @@ -1163,8 +1193,6 @@ Symfony is the result of the work of many people who made the code better - Vincent (vincent1870) - Eugene Babushkin (warl) - Xavier Amado (xamado) - - Alexander Schwenn (xelaris) - - Dawid Pakuła (zulusx) - Florent Cailhol - szymek - craigmarvelley @@ -1181,6 +1209,7 @@ Symfony is the result of the work of many people who made the code better - Philipp Scheit - max - Mohamed Karnichi (amiral) + - Daniel Kolvik (dkvk) - Jeroen De Dauw (jeroendedauw) - Muharrem Demirci (mdemirci) - Evgeny Z (meze) diff --git a/src/Symfony/Component/Security/Http/Session/SessionAuthenticationStrategy.php b/src/Symfony/Component/Security/Http/Session/SessionAuthenticationStrategy.php index dd258a086f..ccfa6ba67a 100644 --- a/src/Symfony/Component/Security/Http/Session/SessionAuthenticationStrategy.php +++ b/src/Symfony/Component/Security/Http/Session/SessionAuthenticationStrategy.php @@ -47,7 +47,10 @@ class SessionAuthenticationStrategy implements SessionAuthenticationStrategyInte return; case self::MIGRATE: - $request->getSession()->migrate(true); + // Destroying the old session is broken in php 5.4.0 - 5.4.10 + // See php bug #63379 + $destroy = PHP_VERSION_ID < 50400 || PHP_VERSION_ID >= 50411; + $request->getSession()->migrate($destroy); return; diff --git a/src/Symfony/Component/Security/Http/Tests/Session/SessionAuthenticationStrategyTest.php b/src/Symfony/Component/Security/Http/Tests/Session/SessionAuthenticationStrategyTest.php index a1f960fde4..4aef4b203b 100644 --- a/src/Symfony/Component/Security/Http/Tests/Session/SessionAuthenticationStrategyTest.php +++ b/src/Symfony/Component/Security/Http/Tests/Session/SessionAuthenticationStrategyTest.php @@ -39,6 +39,10 @@ class SessionAuthenticationStrategyTest extends \PHPUnit_Framework_TestCase public function testSessionIsMigrated() { + if (PHP_VERSION_ID >= 50400 && PHP_VERSION_ID < 50411) { + $this->markTestSkipped('We cannot destroy the old session on PHP 5.4.0 - 5.4.10.'); + } + $session = $this->getMock('Symfony\Component\HttpFoundation\Session\SessionInterface'); $session->expects($this->once())->method('migrate')->with($this->equalTo(true)); @@ -46,6 +50,19 @@ class SessionAuthenticationStrategyTest extends \PHPUnit_Framework_TestCase $strategy->onAuthentication($this->getRequest($session), $this->getToken()); } + public function testSessionIsMigratedWithPhp54Workaround() + { + if (PHP_VERSION_ID < 50400 || PHP_VERSION_ID >= 50411) { + $this->markTestSkipped('This PHP version is not affected.'); + } + + $session = $this->getMock('Symfony\Component\HttpFoundation\Session\SessionInterface'); + $session->expects($this->once())->method('migrate')->with($this->equalTo(false)); + + $strategy = new SessionAuthenticationStrategy(SessionAuthenticationStrategy::MIGRATE); + $strategy->onAuthentication($this->getRequest($session), $this->getToken()); + } + public function testSessionIsInvalidated() { $session = $this->getMock('Symfony\Component\HttpFoundation\Session\SessionInterface');