From 9828f232908b398a67b7b8edd011eea98768fcfa Mon Sep 17 00:00:00 2001 From: Oliver Hoff Date: Mon, 21 Mar 2016 09:24:44 +0100 Subject: [PATCH 01/38] bug #17460 [DI] fix ambiguous services schema --- .../schema/dic/services/services-1.0.xsd | 24 +++++++++++++++---- 1 file changed, 19 insertions(+), 5 deletions(-) diff --git a/src/Symfony/Component/DependencyInjection/Loader/schema/dic/services/services-1.0.xsd b/src/Symfony/Component/DependencyInjection/Loader/schema/dic/services/services-1.0.xsd index 8ad313f8cf3bf..042d2fdc155fc 100644 --- a/src/Symfony/Component/DependencyInjection/Loader/schema/dic/services/services-1.0.xsd +++ b/src/Symfony/Component/DependencyInjection/Loader/schema/dic/services/services-1.0.xsd @@ -24,14 +24,28 @@ ]]> - - - - - + + + + + + + + + + + + + + + + + + + Date: Thu, 14 Apr 2016 20:06:25 +0000 Subject: [PATCH 02/38] [FrameworkBundle] Remove misleading comment --- .../Bundle/FrameworkBundle/Console/Descriptor/TextDescriptor.php | 1 - 1 file changed, 1 deletion(-) diff --git a/src/Symfony/Bundle/FrameworkBundle/Console/Descriptor/TextDescriptor.php b/src/Symfony/Bundle/FrameworkBundle/Console/Descriptor/TextDescriptor.php index 22d0bde4d42e7..0fe5fa70f59bb 100644 --- a/src/Symfony/Bundle/FrameworkBundle/Console/Descriptor/TextDescriptor.php +++ b/src/Symfony/Bundle/FrameworkBundle/Console/Descriptor/TextDescriptor.php @@ -227,7 +227,6 @@ protected function describeContainerServices(ContainerBuilder $builder, array $o $alias = $definition; $table->addRow(array_merge(array($serviceId, sprintf('alias for "%s"', $alias)), $tagsCount ? array_fill(0, $tagsCount, '') : array())); } else { - // we have no information (happens with "service_container") $table->addRow(array_merge(array($serviceId, get_class($definition)), $tagsCount ? array_fill(0, $tagsCount, '') : array())); } } From e249bc3cae9ca81a09790ce2ff7e45b3b59f3a5a Mon Sep 17 00:00:00 2001 From: Shawn Iwinski Date: Tue, 19 Apr 2016 14:38:18 -0400 Subject: [PATCH 03/38] [Security] Normalize "symfony/security-acl" dependency versions across all composer.json files --- composer.json | 2 +- src/Symfony/Component/Security/composer.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/composer.json b/composer.json index ad54861696ee0..ee035f235b3e0 100644 --- a/composer.json +++ b/composer.json @@ -20,7 +20,7 @@ "doctrine/common": "~2.4", "twig/twig": "~1.23|~2.0", "psr/log": "~1.0", - "symfony/security-acl": "~2.7", + "symfony/security-acl": "~2.7|~3.0.0", "symfony/polyfill-apcu": "~1.1", "symfony/polyfill-intl-icu": "~1.0", "symfony/polyfill-mbstring": "~1.0", diff --git a/src/Symfony/Component/Security/composer.json b/src/Symfony/Component/Security/composer.json index 8764ce6d56447..3eab48b1a3ab0 100644 --- a/src/Symfony/Component/Security/composer.json +++ b/src/Symfony/Component/Security/composer.json @@ -17,7 +17,7 @@ ], "require": { "php": ">=5.3.9", - "symfony/security-acl": "~2.7", + "symfony/security-acl": "~2.7|~3.0.0", "symfony/event-dispatcher": "~2.2|~3.0.0", "symfony/http-foundation": "~2.1|~3.0.0", "symfony/http-kernel": "~2.4|~3.0.0", From 996251ce13bab912f267e491c898126b68ea2fba Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Thu, 28 Apr 2016 11:59:09 +0200 Subject: [PATCH 04/38] fixed deprecation notices in tests --- .../Form/Tests/Extension/Core/Type/ChoiceTypeTest.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Symfony/Component/Form/Tests/Extension/Core/Type/ChoiceTypeTest.php b/src/Symfony/Component/Form/Tests/Extension/Core/Type/ChoiceTypeTest.php index 8036502805358..02f64e37e87d3 100644 --- a/src/Symfony/Component/Form/Tests/Extension/Core/Type/ChoiceTypeTest.php +++ b/src/Symfony/Component/Form/Tests/Extension/Core/Type/ChoiceTypeTest.php @@ -202,7 +202,7 @@ public function testExpandedChoiceListWithScalarValues() public function testExpandedChoiceListWithBooleanAndNullValues() { - $view = $this->factory->create('choice', null, array( + $view = $this->factory->create('Symfony\Component\Form\Extension\Core\Type\ChoiceType', null, array( 'choices' => $this->booleanChoicesWithNull, 'choices_as_values' => true, 'expanded' => true, @@ -229,7 +229,7 @@ public function testExpandedChoiceListWithScalarValuesAndFalseAsPreSetData() public function testExpandedChoiceListWithBooleanAndNullValuesAndFalseAsPreSetData() { - $view = $this->factory->create('choice', false, array( + $view = $this->factory->create('Symfony\Component\Form\Extension\Core\Type\ChoiceType', false, array( 'choices' => $this->booleanChoicesWithNull, 'choices_as_values' => true, 'expanded' => true, From e9dda1ee0ac6cb05e869b0f3e0f6126c3e42b482 Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Thu, 28 Apr 2016 12:50:52 +0200 Subject: [PATCH 05/38] Revert "fixed CS" This reverts commit ba1cd26237adce6757fab28bc0ad7d1b4d776b6b. --- src/Symfony/Component/Routing/Generator/UrlGenerator.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Symfony/Component/Routing/Generator/UrlGenerator.php b/src/Symfony/Component/Routing/Generator/UrlGenerator.php index 2bde7e90d5af5..db5a68ff531c1 100644 --- a/src/Symfony/Component/Routing/Generator/UrlGenerator.php +++ b/src/Symfony/Component/Routing/Generator/UrlGenerator.php @@ -187,15 +187,15 @@ protected function doGenerate($variables, $defaults, $requirements, $tokens, $pa if ('' === $url) { $url = '/'; - } elseif (preg_match($this->urlEncodingSkipRegexp, $url)) { - // the context base URL is already encoded (see Symfony\Component\HttpFoundation\Request) + } else if (preg_match($this->urlEncodingSkipRegexp, $url)) { + // the contexts base URL is already encoded (see Symfony\Component\HttpFoundation\Request) $url = strtr(rawurlencode($url), $this->decodedChars); } // the path segments "." and ".." are interpreted as relative reference when resolving a URI; see http://tools.ietf.org/html/rfc3986#section-3.3 // so we need to encode them as they are not used for this purpose here // otherwise we would generate a URI that, when followed by a user agent (e.g. browser), does not match this route - if (false !== strpos($url, '/.')) { + if(false !== strpos($url, '/.')) { $url = strtr($url, array('/../' => '/%2E%2E/', '/./' => '/%2E/')); if ('/..' === substr($url, -3)) { $url = substr($url, 0, -2).'%2E%2E'; From 616ebb758fa928cd557f1e8d0fb228d6784155a1 Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Thu, 28 Apr 2016 12:50:58 +0200 Subject: [PATCH 06/38] Revert "minor #18257 [Routing] Don't needlessly execute strtr's as they are fairly expensive (arjenm)" This reverts commit f03dc6eec58b9c424967c8eb3282de856e7ed600, reversing changes made to 2f2ce3e6371276a0d2ef0f6a2d27653184753674. --- .../Routing/Generator/UrlGenerator.php | 25 +++++++------------ 1 file changed, 9 insertions(+), 16 deletions(-) diff --git a/src/Symfony/Component/Routing/Generator/UrlGenerator.php b/src/Symfony/Component/Routing/Generator/UrlGenerator.php index db5a68ff531c1..e72b6cf974c74 100644 --- a/src/Symfony/Component/Routing/Generator/UrlGenerator.php +++ b/src/Symfony/Component/Routing/Generator/UrlGenerator.php @@ -75,11 +75,6 @@ class UrlGenerator implements UrlGeneratorInterface, ConfigurableRequirementsInt '%7C' => '|', ); - /** - * @var string This regexp matches all characters that are not or should not be encoded by rawurlencode (see list in array above). - */ - private $urlEncodingSkipRegexp = '#[^-.~a-zA-Z0-9_/@:;,=+!*|]#'; - /** * Constructor. * @@ -187,21 +182,19 @@ protected function doGenerate($variables, $defaults, $requirements, $tokens, $pa if ('' === $url) { $url = '/'; - } else if (preg_match($this->urlEncodingSkipRegexp, $url)) { - // the contexts base URL is already encoded (see Symfony\Component\HttpFoundation\Request) - $url = strtr(rawurlencode($url), $this->decodedChars); } + // the contexts base URL is already encoded (see Symfony\Component\HttpFoundation\Request) + $url = strtr(rawurlencode($url), $this->decodedChars); + // the path segments "." and ".." are interpreted as relative reference when resolving a URI; see http://tools.ietf.org/html/rfc3986#section-3.3 // so we need to encode them as they are not used for this purpose here // otherwise we would generate a URI that, when followed by a user agent (e.g. browser), does not match this route - if(false !== strpos($url, '/.')) { - $url = strtr($url, array('/../' => '/%2E%2E/', '/./' => '/%2E/')); - if ('/..' === substr($url, -3)) { - $url = substr($url, 0, -2).'%2E%2E'; - } elseif ('/.' === substr($url, -2)) { - $url = substr($url, 0, -1).'%2E'; - } + $url = strtr($url, array('/../' => '/%2E%2E/', '/./' => '/%2E/')); + if ('/..' === substr($url, -3)) { + $url = substr($url, 0, -2).'%2E%2E'; + } elseif ('/.' === substr($url, -2)) { + $url = substr($url, 0, -1).'%2E'; } $schemeAuthority = ''; @@ -278,7 +271,7 @@ protected function doGenerate($variables, $defaults, $requirements, $tokens, $pa if ($extra && $query = http_build_query($extra, '', '&')) { // "/" and "?" can be left decoded for better user experience, see // http://tools.ietf.org/html/rfc3986#section-3.4 - $url .= '?'.(false === strpos($query, '%2F') ? $query : strtr($query, array('%2F' => '/'))); + $url .= '?'.strtr($query, array('%2F' => '/')); } return $url; From 84d46cc40416ccaacfb580d4dd41552fbc4060d1 Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Fri, 29 Apr 2016 07:37:42 +0200 Subject: [PATCH 07/38] updated CHANGELOG for 2.3.40 --- CHANGELOG-2.3.md | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/CHANGELOG-2.3.md b/CHANGELOG-2.3.md index b8e185e9de783..d0ca6221aca02 100644 --- a/CHANGELOG-2.3.md +++ b/CHANGELOG-2.3.md @@ -7,6 +7,35 @@ 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.40 (2016-04-29) + + * bug #18246 [DependencyInjection] fix ambiguous services schema (backbone87) + * bug #18603 [PropertyAccess] ->getValue() should be read-only (nicolas-grekas) + * bug #18280 [Routing] add query param if value is different from default (Tobion) + * bug #18515 [Filesystem] Better error handling in remove() (nicolas-grekas) + * bug #18449 [PropertyAccess] Fix regression (nicolas-grekas) + * bug #18467 [DependencyInjection] Resolve aliases before removing abstract services + add tests (nicolas-grekas) + * bug #18460 [DomCrawler] Fix select option with empty value (Matt Wells) + * bug #18425 [Security] Fixed SwitchUserListener when exiting an impersonation with AnonymousToken (lyrixx) + * bug #18317 [Form] fix "prototype" not required when parent form is not required (HeahDude) + * bug #18439 [Logging] Add support for Firefox (43+) in ChromePhpHandler (arjenm) + * bug #18385 Detect CLI color support for Windows 10 build 10586 (mlocati) + * bug #18426 [EventDispatcher] Try first if the event is Stopped (lyrixx) + * bug #18265 Optimize ReplaceAliasByActualDefinitionPass (ajb-in) + * bug #18358 [Form] NumberToLocalizedStringTransformer should return floats when possible (nicolas-grekas) + * bug #17926 [DependencyInjection] Enable alias for service_container (hason) + * bug #18336 [Debug] Fix handling of php7 throwables (nicolas-grekas) + * bug #18312 [ClassLoader] Fix storing not-found classes in APC cache (nicolas-grekas) + * bug #18255 [HttpFoundation] Fix support of custom mime types with parameters (Ener-Getick) + * bug #18259 [PropertyAccess] Backport fixes from 2.7 (nicolas-grekas) + * bug #18224 [PropertyAccess] Remove most ref mismatches to improve perf (nicolas-grekas) + * bug #18210 [PropertyAccess] Throw an UnexpectedTypeException when the type do not match (dunglas, nicolas-grekas) + * bug #18216 [Intl] Fix invalid numeric literal on PHP 7 (nicolas-grekas) + * bug #18147 [Validator] EmailValidator cannot extract hostname if email contains multiple @ symbols (natechicago) + * bug #18175 [Translation] Add support for fuzzy tags in PoFileLoader (nud) + * bug #18179 [Form] Fix NumberToLocalizedStringTransformer::reverseTransform with big integers (ovrflo, nicolas-grekas) + * bug #18164 [HttpKernel] set s-maxage only if all responses are cacheable (xabbuh) + * 2.3.39 (2016-03-13) * bug #18080 [HttpFoundation] Set the Content-Range header if the requested Range is unsatisfied (jakzal) From 30d7571ec6b076e6dd33328b877609deae28c507 Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Fri, 29 Apr 2016 07:37:50 +0200 Subject: [PATCH 08/38] update CONTRIBUTORS for 2.3.40 --- CONTRIBUTORS.md | 84 +++++++++++++++++++++++++++++++++---------------- 1 file changed, 57 insertions(+), 27 deletions(-) diff --git a/CONTRIBUTORS.md b/CONTRIBUTORS.md index 79ca50e61c6f6..456aeba37aa74 100644 --- a/CONTRIBUTORS.md +++ b/CONTRIBUTORS.md @@ -9,25 +9,25 @@ Symfony is the result of the work of many people who made the code better - Bernhard Schussek (bschussek) - Tobias Schultze (tobion) - Christophe Coevoet (stof) + - Christian Flothmann (xabbuh) - Jordi Boggiano (seldaek) - Victor Berchet (victor) - - Christian Flothmann (xabbuh) - Johannes S (johannes) - Kris Wallsmith (kriswallsmith) - Jakub Zalas (jakubzalas) - Ryan Weaver (weaverryan) - Javier Eguiluz (javier.eguiluz) - Hugo Hamon (hhamon) + - Kévin Dunglas (dunglas) - Abdellatif Ait boudad (aitboudad) - Pascal Borreli (pborreli) - - Kévin Dunglas (dunglas) - Joseph Bielawski (stloyd) - Wouter De Jong (wouterj) - Karma Dordrak (drak) - Romain Neutron (romain) - Lukas Kahwe Smith (lsmith) - - Jeremy Mikola (jmikola) - Martin Hasoň (hason) + - Jeremy Mikola (jmikola) - Jean-François Simon (jfsimon) - Benjamin Eberlei (beberlei) - Igor Wiedler (igorw) @@ -42,6 +42,7 @@ Symfony is the result of the work of many people who made the code better - ornicar - stealth35 ‏ (stealth35) - Alexander Mols (asm89) + - Jules Pietri (heah) - Francis Besset (francisbesset) - Bulat Shakirzyanov (avalanche123) - Saša Stamenković (umpirsky) @@ -56,13 +57,15 @@ Symfony is the result of the work of many people who made the code better - Michel Weimerskirch (mweimerskirch) - Eric Clemmons (ericclemmons) - Andrej Hudec (pulzarraider) + - Peter Rehm (rpet) - Christian Raue - Matthias Pigulla (mpdude) - - Peter Rehm (rpet) - Deni - Henrik Westphal (snc) - Dariusz Górecki (canni) - Arnout Boks (aboks) + - Iltar van der Berg (kjarli) + - Ener-Getick (energetick) - Douglas Greenshields (shieldo) - Lee McDermott - Brandon Turner @@ -71,21 +74,18 @@ Symfony is the result of the work of many people who made the code better - Pierre du Plessis (pierredup) - Bart van den Burg (burgov) - Jordan Alliot (jalliot) + - Charles Sarrazin (csarrazi) - John Wards (johnwards) - Toni Uebernickel (havvg) - Fran Moreno (franmomu) - Graham Campbell (graham) - Antoine Hérault (herzult) - - Iltar van der Berg (kjarli) - Arnaud Le Blanc (arnaud-lb) - Jérôme Tamarelle (gromnan) - - Jules Pietri (heah) - Michal Piotrowski (eventhorizon) - Tim Nagel (merk) - Paráda József (paradajozsef) - Brice BERNARD (brikou) - - Ener-Getick (energetick) - - Charles Sarrazin (csarrazi) - Alexander M. Turek (derrabus) - Dariusz Ruminski - marc.weistroff @@ -93,6 +93,7 @@ Symfony is the result of the work of many people who made the code better - Włodzimierz Gajda (gajdaw) - Alexander Schwenn (xelaris) - Florian Voutzinos (florianv) + - Konstantin Myakshin (koc) - Colin Frei - Adrien Brault (adrienbrault) - Joshua Thijssen @@ -100,19 +101,18 @@ Symfony is the result of the work of many people who made the code better - Peter Kokot (maastermedia) - excelwebzone - Jacob Dreesen (jdreesen) - - Konstantin Myakshin (koc) - Jérémy DERUSSÉ (jderusse) - Vladimir Reznichenko (kalessil) - Baptiste Clavié (talus) - Fabien Pennequin (fabienpennequin) - Gordon Franke (gimler) + - David Buchmann (dbu) - Tomáš Votruba (tomas_votruba) - Jáchym Toušek - Robert Schönthal (digitalkaoz) - Florian Lonqueu-Brochard (florianlb) - Eric GELOEN (gelo) - Stefano Sala (stefano.sala) - - David Buchmann (dbu) - Juti Noppornpitak (shiroyuki) - Tigran Azatyan (tigranazatyan) - Sebastian Hörl (blogsh) @@ -127,26 +127,27 @@ Symfony is the result of the work of many people who made the code better - Andréia Bohner (andreia) - Rafael Dohms (rdohms) - Arnaud Kleinpeter (nanocom) + - Joel Wurtz (brouznouf) - Philipp Wahala (hifi) - Richard Shank (iampersistent) - Thomas Rabaix (rande) - Vincent AUBERT (vincent) - - Joel Wurtz (brouznouf) - Mikael Pajunen - Clemens Tolboom - Helmer Aaviksoo - Hiromi Hishida (77web) + - Richard van Laak (rvanlaak) - Matthieu Ouellette-Vachon (maoueh) - Michał Pipa (michal.pipa) - Amal Raghav (kertz) - Jonathan Ingram (jonathaningram) + - Titouan Galopin (tgalopin) - Artur Kotyrba - Rouven Weßling (realityking) - Warnar Boekkooi (boekkooi) - Dmitrii Chekaliuk (lazyhammer) - Clément JOBEILI (dator) - Daniel Wehner - - Richard van Laak (rvanlaak) - Possum - Dorian Villet (gnutix) - Javier Spagnoletti (phansys) @@ -183,7 +184,6 @@ Symfony is the result of the work of many people who made the code better - Sergey Linnik (linniksa) - Michaël Perrin (michael.perrin) - Marcel Beerta (mazen) - - Titouan Galopin (tgalopin) - Loïc Faugeron - Jannik Zschiesche (apfelbox) - Marco Pivetta (ocramius) @@ -209,6 +209,7 @@ Symfony is the result of the work of many people who made the code better - Katsuhiro OGAWA - Alif Rachmawadi - Kristen Gilden (kgilden) + - Dawid Nowak - Pierre-Yves LEBECQ (pylebecq) - Jakub Kucharovic (jkucharovic) - Eugene Leonovich (rybakit) @@ -226,6 +227,7 @@ Symfony is the result of the work of many people who made the code better - Nikita Konstantinov - Wodor Wodorski - Thomas Lallement (raziel057) + - Matthieu Napoli (mnapoli) - Beau Simensen (simensen) - Michael Hirschler (mvhirsch) - Robert Kiss (kepten) @@ -237,7 +239,7 @@ Symfony is the result of the work of many people who made the code better - Peter Kruithof (pkruithof) - Michael Holm (hollo) - Marc Weistroff (futurecat) - - Dawid Nowak + - Hidde Wieringa (hiddewie) - Chris Smith (cs278) - Florian Klein (docteurklein) - Manuel Kiessling (manuelkiessling) @@ -272,12 +274,12 @@ Symfony is the result of the work of many people who made the code better - janschoenherr - Thomas Schulz (king2500) - Berny Cantos (xphere81) + - Teoh Han Hui (teohhanhui) - Ricard Clau (ricardclau) - Mark Challoner (markchalloner) - Gregor Harlan (gharlan) - Gennady Telegin (gtelegin) - Giorgio Premi - - Matthieu Napoli (mnapoli) - Ben Davies (bendavies) - Erin Millard - Artur Melo (restless) @@ -296,6 +298,8 @@ Symfony is the result of the work of many people who made the code better - Yaroslav Kiliba - Terje Bråten - Robbert Klarenbeek (robbertkl) + - Alessandro Chitolina + - JhonnyL - hossein zolfi (ocean) - Clément Gautier (clementgautier) - Eduardo Gulias (egulias) @@ -321,6 +325,7 @@ Symfony is the result of the work of many people who made the code better - Kai - Lee Rowlands - Maximilian Reichel (phramz) + - Loick Piera (pyrech) - Karoly Negyesi (chx) - Ivan Kurnosov - Xavier HAUSHERR @@ -351,6 +356,7 @@ Symfony is the result of the work of many people who made the code better - Niklas Fiekas - Markus Bachmann (baachi) - lancergr + - Mihai Stancu - Olivier Dolbeau (odolbeau) - Jan Rosier (rosier) - vagrant @@ -367,7 +373,6 @@ Symfony is the result of the work of many people who made the code better - cedric lombardot (cedriclombardot) - Jonas Flodén (flojon) - Christian Schmidt - - Hidde Wieringa (hiddewie) - Marek Štípek (maryo) - Marcin Sikoń (marphi) - Dominik Zogg (dominik.zogg) @@ -380,7 +385,6 @@ Symfony is the result of the work of many people who made the code better - Zander Baldwin - Adam Harvey - Alex Bakhturin - - Alessandro Chitolina - boombatower - Fabrice Bernhard (fabriceb) - Jérôme Macias (jeromemacias) @@ -425,12 +429,13 @@ Symfony is the result of the work of many people who made the code better - Norbert Orzechowicz (norzechowicz) - Denis Charrier (brucewouaigne) - Matthijs van den Bos (matthijs) - - Loick Piera (pyrech) - Lenard Palko - Nils Adermann (naderman) - Gábor Fási - DUPUCH (bdupuch) - Benjamin Leveque (benji07) + - Nate (frickenate) + - jhonnyL - sasezaki - Dawid Pakuła (zulusx) - Florian Rey (nervo) @@ -453,7 +458,9 @@ Symfony is the result of the work of many people who made the code better - Marcin Chyłek (songoq) - Ned Schwartz - Ziumin + - Jeremy Benoist - Lenar Lõhmus + - Krzysztof Piasecki (krzysztek) - Benjamin Laugueux (yzalis) - Zach Badgett (zachbadgett) - Aurélien Fredouelle @@ -492,12 +499,13 @@ Symfony is the result of the work of many people who made the code better - Javier López (loalf) - Reinier Kip - Dustin Dobervich (dustin10) + - Anne-Sophie Bachelard (annesophie) - Sebastian Marek (proofek) - Erkhembayar Gantulga (erheme318) - Michal Trojanowski - - Mihai Stancu - David Fuhr - Kamil Kokot (pamil) + - Aurimas Niekis (gcds) - Max Grigorian (maxakawizard) - Rostyslav Kinash - Maciej Malarz (malarzm) @@ -521,11 +529,13 @@ Symfony is the result of the work of many people who made the code better - Arturs Vonda - Sascha Grossenbacher - Szijarto Tamas + - Catalin Dan - Stephan Vock - Benjamin Zikarsky (bzikarsky) - Simon Schick (simonsimcity) - redstar504 - Tristan Roussel + - Cameron Porter - Hossein Bukhamsin - Disparity - origaminal @@ -579,6 +589,7 @@ Symfony is the result of the work of many people who made the code better - Romain Gautier (mykiwi) - Yosmany Garcia (yosmanyga) - Wouter de Wild + - Miroslav Sustek - Degory Valentine - Benoit Lévêque (benoit_leveque) - Jeroen Fiege (fieg) @@ -587,6 +598,8 @@ Symfony is the result of the work of many people who made the code better - possum - Denis Zunke (donalberto) - Olivier Maisonneuve (olineuve) + - Michele Locati + - Masterklavi - Francis Turmel (fturmel) - cgonzalez - Ben @@ -598,6 +611,7 @@ Symfony is the result of the work of many people who made the code better - Adrien Lucas (adrienlucas) - James Michael DuPont - Tom Klingenberg + - Jhonny Lidfors (jhonne) - Christopher Hall (mythmakr) - Paul Kamer (pkamer) - Rafał Wrzeszcz (rafalwrzeszcz) @@ -607,6 +621,7 @@ Symfony is the result of the work of many people who made the code better - Pierre Vanliefland (pvanliefland) - Sofiane HADDAG (sofhad) - frost-nzcr4 + - Arjen van der Meijden - Abhoryo - Fabian Vogler (fabian) - Korvin Szanto @@ -614,6 +629,7 @@ Symfony is the result of the work of many people who made the code better - Maksim Kotlyar (makasim) - Neil Ferreira - Dmitry Parnas (parnas) + - Théo FIDRY (theofidry) - Paul LE CORRE - DQNEO - Emanuele Iannone @@ -670,10 +686,8 @@ Symfony is the result of the work of many people who made the code better - omerida - Gábor Tóth - Daniel Cestari - - Jeremy Benoist - David Lima - Jérôme Vasseur - - Krzysztof Piasecki (krzysztek) - Brunet Laurent (lbrunet) - Magnus Nordlander (magnusnordlander) - Mikhail Yurasov (mym) @@ -715,7 +729,6 @@ Symfony is the result of the work of many people who made the code better - fabios - Sander Coolen (scoolen) - Nicolas Le Goff (nlegoff) - - Anne-Sophie Bachelard (annesophie) - Manuele Menozzi - Anton Babenko (antonbabenko) - Irmantas Šiupšinskas (irmantas) @@ -723,6 +736,7 @@ Symfony is the result of the work of many people who made the code better - Zachary Tong (polyfractal) - Hryhorii Hrebiniuk - mcfedr (mcfedr) + - hamza - dantleech - Xavier Leune - Tero Alén (tero) @@ -735,6 +749,7 @@ Symfony is the result of the work of many people who made the code better - Sortex - chispita - Wojciech Sznapka + - Ariel J. Birnbaum - Arjan Keeman - Máximo Cuadros (mcuadros) - tamirvs @@ -750,7 +765,6 @@ Symfony is the result of the work of many people who made the code better - Ville Mattila - Boris Vujicic (boris.vujicic) - Max Beutel - - Catalin Dan - nacho - Piotr Antosik (antek88) - Artem Lopata @@ -783,6 +797,7 @@ Symfony is the result of the work of many people who made the code better - Benoit Garret - Thomas Royer (cydonia7) - DerManoMann + - Jhonny Lidfors (jhonny) - Julien Bianchi (jubianchi) - Marcin Chwedziak - Roland Franssen (ro0) @@ -796,7 +811,6 @@ Symfony is the result of the work of many people who made the code better - rpg600 - Péter Buri (burci) - Davide Borsatto (davide.borsatto) - - Teoh Han Hui (teohhanhui) - kaiwa - Charles Sanquer (csanquer) - Albert Ganiev (helios-ag) @@ -899,6 +913,7 @@ Symfony is the result of the work of many people who made the code better - Berat Doğan - Anthony Ferrara - Klaas Cuvelier (kcuvelier) + - Steve Frécinaux - ShiraNai7 - Vašek Purchart (vasek-purchart) - Janusz Jabłoński (yanoosh) @@ -919,7 +934,6 @@ Symfony is the result of the work of many people who made the code better - Pete Mitchell (peterjmit) - Tom Corrigan (tomcorrigan) - Martin Pärtel - - Miroslav Sustek - Patrick Daley (padrig) - Xavier Briand (xavierbriand) - Max Summe @@ -943,7 +957,6 @@ Symfony is the result of the work of many people who made the code better - Nathaniel Catchpole - Jose Gonzalez - Adrien Samson (adriensamson) - - Aurimas Niekis (gcds) - Samuel Gordalina (gordalina) - Max Romanovsky (maxromanovsky) - Mathieu Morlon @@ -960,6 +973,7 @@ Symfony is the result of the work of many people who made the code better - r1pp3rj4ck - Robert Queck - mlively + - Amine Matmati - Fabian Steiner (fabstei) - Klaus Silveira (klaussilveira) - Thomas Chmielowiec (chmielot) @@ -984,6 +998,7 @@ Symfony is the result of the work of many people who made the code better - Benjamin Bender - Konrad Mohrfeldt - Lance Chen + - Andrey Astakhov (aast) - kor3k kor3k (kor3k) - Stelian Mocanita (stelian) - Flavian (2much) @@ -1010,6 +1025,7 @@ Symfony is the result of the work of many people who made the code better - Jakub Simon - Bouke Haarsma - Martin Eckhardt + - natechicago - Jonathan Poston - Adrian Olek (adrianolek) - Przemysław Piechota (kibao) @@ -1032,12 +1048,13 @@ Symfony is the result of the work of many people who made the code better - Josef Cech - Arnau González (arnaugm) - Simon Bouland (bouland) - - Nate (frickenate) - Matthew Foster (mfoster) - Paul Seiffert (seiffert) - Vasily Khayrulin (sirian) - Stefan Koopmanschap (skoop) - Stefan Hüsges (tronsha) + - Dan Blows + - Matt Wells - stloyd - Chris Tickner - Andrew Coulton @@ -1051,6 +1068,7 @@ Symfony is the result of the work of many people who made the code better - Andreas - Thomas Chmielowiec - Andrey Ryaguzov + - Peter Bex - Manatsawin Hanmongkolchai - Gunther Konig - Maciej Schmidt @@ -1081,10 +1099,12 @@ Symfony is the result of the work of many people who made the code better - Aarón Nieves Fernández - Mike Meier - Kirill Saksin + - Koalabaerchen - michalmarcinkowski - Warwick - Chris - JakeFr + - Simon Sargeant - efeen - Michał Dąbrowski (defrag) - Nathanael Noblet (gnat) @@ -1118,10 +1138,12 @@ Symfony is the result of the work of many people who made the code better - Jason Woods - dened - Dmitry Korotovsky + - Michael van Tricht - Sam Ward - Walther Lalk - Adam - devel + - taiiiraaa - Trevor Suarez - gedrox - dropfen @@ -1229,6 +1251,7 @@ Symfony is the result of the work of many people who made the code better - Muriel (metalmumu) - Michael Pohlers (mick_the_big) - Cayetano Soriano Gallego (neoshadybeat) + - Patrick McDougle (patrick-mcdougle) - Pablo Monterde Perez (plebs) - Jimmy Leger (redpanda) - Cyrille Jouineau (tuxosaurus) @@ -1269,6 +1292,7 @@ Symfony is the result of the work of many people who made the code better - Myke79 - Brian Debuire - Piers Warmers + - Guilliam Xavier - Sylvain Lorinet - klyk50 - Andreas Lutro @@ -1332,6 +1356,7 @@ Symfony is the result of the work of many people who made the code better - Norman Soetbeer - zorn - Benjamin Long + - Robin Chalas - Matt Janssen - Peter Gribanov - kwiateusz @@ -1382,6 +1407,7 @@ Symfony is the result of the work of many people who made the code better - Adel ELHAIBA (eadel) - Damián Nohales (eagleoneraptor) - Elliot Anderson (elliot) + - Sergey Zolotov (enleur) - Fabien D. (fabd) - Sorin Gitlan (forapathy) - Yohan Giarelli (frequence-web) @@ -1395,6 +1421,7 @@ Symfony is the result of the work of many people who made the code better - Jose Manuel Gonzalez (jgonzalez) - Jorge Maiden (jorgemaiden) - Justin Rainbow (jrainbow) + - Juan Luis (juanlugb) - JuntaTom (juntatom) - Ismail Faizi (kanafghan) - Sébastien Armand (khepin) @@ -1439,6 +1466,7 @@ Symfony is the result of the work of many people who made the code better - Víctor Mateo (victormateo) - Vincent (vincent1870) - Eugene Babushkin (warl) + - Wouter Sioen (wouter_sioen) - Xavier Amado (xamado) - Jesper Søndergaard Pedersen (zerrvox) - Florent Cailhol @@ -1451,6 +1479,8 @@ Symfony is the result of the work of many people who made the code better - Andreas Streichardt - smokeybear87 - Gustavo Adrian + - Kevin Weber + - Sergey Fedotov - Michael - fh-github@fholzhauer.de - Mark Topper From 2dc63b3914773f2c43bc9928f8c1bbfbdeedc0cb Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Fri, 29 Apr 2016 07:38:17 +0200 Subject: [PATCH 09/38] updated VERSION for 2.3.40 --- src/Symfony/Component/HttpKernel/Kernel.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Symfony/Component/HttpKernel/Kernel.php b/src/Symfony/Component/HttpKernel/Kernel.php index de7b1a46fd271..27906badeb9aa 100644 --- a/src/Symfony/Component/HttpKernel/Kernel.php +++ b/src/Symfony/Component/HttpKernel/Kernel.php @@ -58,12 +58,12 @@ abstract class Kernel implements KernelInterface, TerminableInterface protected $startTime; protected $loadClassCache; - const VERSION = '2.3.40-DEV'; + const VERSION = '2.3.40'; const VERSION_ID = 20340; const MAJOR_VERSION = 2; const MINOR_VERSION = 3; const RELEASE_VERSION = 40; - const EXTRA_VERSION = 'DEV'; + const EXTRA_VERSION = ''; /** * Constructor. From ca80946379ff16694401e6f4065c70c3dc9a581b Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Fri, 29 Apr 2016 11:36:11 +0200 Subject: [PATCH 10/38] bumped Symfony version to 2.3.41 --- src/Symfony/Component/HttpKernel/Kernel.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Symfony/Component/HttpKernel/Kernel.php b/src/Symfony/Component/HttpKernel/Kernel.php index 27906badeb9aa..71cc0a60de511 100644 --- a/src/Symfony/Component/HttpKernel/Kernel.php +++ b/src/Symfony/Component/HttpKernel/Kernel.php @@ -58,12 +58,12 @@ abstract class Kernel implements KernelInterface, TerminableInterface protected $startTime; protected $loadClassCache; - const VERSION = '2.3.40'; - const VERSION_ID = 20340; + const VERSION = '2.3.41-DEV'; + const VERSION_ID = 20341; const MAJOR_VERSION = 2; const MINOR_VERSION = 3; - const RELEASE_VERSION = 40; - const EXTRA_VERSION = ''; + const RELEASE_VERSION = 41; + const EXTRA_VERSION = 'DEV'; /** * Constructor. From 2ada5535cde4fcf60ee20b5f61352f9bf27a58ed Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Fri, 29 Apr 2016 11:47:27 +0200 Subject: [PATCH 11/38] updated CHANGELOG for 2.7.12 --- CHANGELOG-2.7.md | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/CHANGELOG-2.7.md b/CHANGELOG-2.7.md index 5b1d9382488ff..89ee3b549f479 100644 --- a/CHANGELOG-2.7.md +++ b/CHANGELOG-2.7.md @@ -7,6 +7,37 @@ in 2.7 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.7.0...v2.7.1 +* 2.7.12 (2016-04-29) + + * bug #18180 [Form] fixed BC break with pre selection of choices with `ChoiceType` and its children (HeahDude) + * bug #18562 [WebProfilerBunde] Give an absolute url in case the request occured from another domain (romainneutron) + * bug #18603 [PropertyAccess] ->getValue() should be read-only (nicolas-grekas) + * bug #18593 [VarDumper] Fix dumping type hints for non-existing parent classes (nicolas-grekas) + * bug #18581 [Console] [TableHelper] make it work with SymfonyStyle. (aitboudad) + * bug #18280 [Routing] add query param if value is different from default (Tobion) + * bug #18496 [Console] use ANSI escape sequences in ProgressBar overwrite method (alekitto) + * bug #18491 [DependencyInjection] anonymous services are always private (xabbuh) + * bug #18515 [Filesystem] Better error handling in remove() (nicolas-grekas) + * bug #18449 [PropertyAccess] Fix regression (nicolas-grekas) + * bug #18429 [Console] Correct time formatting. (camporter) + * bug #18467 [DependencyInjection] Resolve aliases before removing abstract services + add tests (nicolas-grekas) + * bug #18460 [DomCrawler] Fix select option with empty value (Matt Wells) + * bug #18425 [Security] Fixed SwitchUserListener when exiting an impersonation with AnonymousToken (lyrixx) + * bug #18317 [Form] fix "prototype" not required when parent form is not required (HeahDude) + * bug #18439 [Logging] Add support for Firefox (43+) in ChromePhpHandler (arjenm) + * bug #18385 Detect CLI color support for Windows 10 build 10586 (mlocati) + * bug #18426 [EventDispatcher] Try first if the event is Stopped (lyrixx) + * bug #18394 [FrameworkBundle] Return the invokable service if its name is the class name (dunglas) + * bug #18265 Optimize ReplaceAliasByActualDefinitionPass (ajb-in) + * bug #18349 [Process] Fix stream_select priority when writing to stdin (nicolas-grekas) + * bug #18358 [Form] NumberToLocalizedStringTransformer should return floats when possible (nicolas-grekas) + * bug #17926 [DependencyInjection] Enable alias for service_container (hason) + * bug #18352 [Debug] Fix case sensitivity checks (nicolas-grekas) + * bug #18336 [Debug] Fix handling of php7 throwables (nicolas-grekas) + * bug #18354 [FrameworkBundle][TwigBridge] fix high deps tests (xabbuh) + * bug #18312 [ClassLoader] Fix storing not-found classes in APC cache (nicolas-grekas) + * bug #18298 [Validator] do not treat payload as callback (xabbuh) + * 2.7.11 (2016-03-25) * bug #18255 [HttpFoundation] Fix support of custom mime types with parameters (Ener-Getick) From 1ce2f04915a232ccb237a0857ed512cacdaee7e0 Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Fri, 29 Apr 2016 11:47:34 +0200 Subject: [PATCH 12/38] update CONTRIBUTORS for 2.7.12 --- CONTRIBUTORS.md | 84 +++++++++++++++++++++++++++++++++---------------- 1 file changed, 57 insertions(+), 27 deletions(-) diff --git a/CONTRIBUTORS.md b/CONTRIBUTORS.md index 79ca50e61c6f6..456aeba37aa74 100644 --- a/CONTRIBUTORS.md +++ b/CONTRIBUTORS.md @@ -9,25 +9,25 @@ Symfony is the result of the work of many people who made the code better - Bernhard Schussek (bschussek) - Tobias Schultze (tobion) - Christophe Coevoet (stof) + - Christian Flothmann (xabbuh) - Jordi Boggiano (seldaek) - Victor Berchet (victor) - - Christian Flothmann (xabbuh) - Johannes S (johannes) - Kris Wallsmith (kriswallsmith) - Jakub Zalas (jakubzalas) - Ryan Weaver (weaverryan) - Javier Eguiluz (javier.eguiluz) - Hugo Hamon (hhamon) + - Kévin Dunglas (dunglas) - Abdellatif Ait boudad (aitboudad) - Pascal Borreli (pborreli) - - Kévin Dunglas (dunglas) - Joseph Bielawski (stloyd) - Wouter De Jong (wouterj) - Karma Dordrak (drak) - Romain Neutron (romain) - Lukas Kahwe Smith (lsmith) - - Jeremy Mikola (jmikola) - Martin Hasoň (hason) + - Jeremy Mikola (jmikola) - Jean-François Simon (jfsimon) - Benjamin Eberlei (beberlei) - Igor Wiedler (igorw) @@ -42,6 +42,7 @@ Symfony is the result of the work of many people who made the code better - ornicar - stealth35 ‏ (stealth35) - Alexander Mols (asm89) + - Jules Pietri (heah) - Francis Besset (francisbesset) - Bulat Shakirzyanov (avalanche123) - Saša Stamenković (umpirsky) @@ -56,13 +57,15 @@ Symfony is the result of the work of many people who made the code better - Michel Weimerskirch (mweimerskirch) - Eric Clemmons (ericclemmons) - Andrej Hudec (pulzarraider) + - Peter Rehm (rpet) - Christian Raue - Matthias Pigulla (mpdude) - - Peter Rehm (rpet) - Deni - Henrik Westphal (snc) - Dariusz Górecki (canni) - Arnout Boks (aboks) + - Iltar van der Berg (kjarli) + - Ener-Getick (energetick) - Douglas Greenshields (shieldo) - Lee McDermott - Brandon Turner @@ -71,21 +74,18 @@ Symfony is the result of the work of many people who made the code better - Pierre du Plessis (pierredup) - Bart van den Burg (burgov) - Jordan Alliot (jalliot) + - Charles Sarrazin (csarrazi) - John Wards (johnwards) - Toni Uebernickel (havvg) - Fran Moreno (franmomu) - Graham Campbell (graham) - Antoine Hérault (herzult) - - Iltar van der Berg (kjarli) - Arnaud Le Blanc (arnaud-lb) - Jérôme Tamarelle (gromnan) - - Jules Pietri (heah) - Michal Piotrowski (eventhorizon) - Tim Nagel (merk) - Paráda József (paradajozsef) - Brice BERNARD (brikou) - - Ener-Getick (energetick) - - Charles Sarrazin (csarrazi) - Alexander M. Turek (derrabus) - Dariusz Ruminski - marc.weistroff @@ -93,6 +93,7 @@ Symfony is the result of the work of many people who made the code better - Włodzimierz Gajda (gajdaw) - Alexander Schwenn (xelaris) - Florian Voutzinos (florianv) + - Konstantin Myakshin (koc) - Colin Frei - Adrien Brault (adrienbrault) - Joshua Thijssen @@ -100,19 +101,18 @@ Symfony is the result of the work of many people who made the code better - Peter Kokot (maastermedia) - excelwebzone - Jacob Dreesen (jdreesen) - - Konstantin Myakshin (koc) - Jérémy DERUSSÉ (jderusse) - Vladimir Reznichenko (kalessil) - Baptiste Clavié (talus) - Fabien Pennequin (fabienpennequin) - Gordon Franke (gimler) + - David Buchmann (dbu) - Tomáš Votruba (tomas_votruba) - Jáchym Toušek - Robert Schönthal (digitalkaoz) - Florian Lonqueu-Brochard (florianlb) - Eric GELOEN (gelo) - Stefano Sala (stefano.sala) - - David Buchmann (dbu) - Juti Noppornpitak (shiroyuki) - Tigran Azatyan (tigranazatyan) - Sebastian Hörl (blogsh) @@ -127,26 +127,27 @@ Symfony is the result of the work of many people who made the code better - Andréia Bohner (andreia) - Rafael Dohms (rdohms) - Arnaud Kleinpeter (nanocom) + - Joel Wurtz (brouznouf) - Philipp Wahala (hifi) - Richard Shank (iampersistent) - Thomas Rabaix (rande) - Vincent AUBERT (vincent) - - Joel Wurtz (brouznouf) - Mikael Pajunen - Clemens Tolboom - Helmer Aaviksoo - Hiromi Hishida (77web) + - Richard van Laak (rvanlaak) - Matthieu Ouellette-Vachon (maoueh) - Michał Pipa (michal.pipa) - Amal Raghav (kertz) - Jonathan Ingram (jonathaningram) + - Titouan Galopin (tgalopin) - Artur Kotyrba - Rouven Weßling (realityking) - Warnar Boekkooi (boekkooi) - Dmitrii Chekaliuk (lazyhammer) - Clément JOBEILI (dator) - Daniel Wehner - - Richard van Laak (rvanlaak) - Possum - Dorian Villet (gnutix) - Javier Spagnoletti (phansys) @@ -183,7 +184,6 @@ Symfony is the result of the work of many people who made the code better - Sergey Linnik (linniksa) - Michaël Perrin (michael.perrin) - Marcel Beerta (mazen) - - Titouan Galopin (tgalopin) - Loïc Faugeron - Jannik Zschiesche (apfelbox) - Marco Pivetta (ocramius) @@ -209,6 +209,7 @@ Symfony is the result of the work of many people who made the code better - Katsuhiro OGAWA - Alif Rachmawadi - Kristen Gilden (kgilden) + - Dawid Nowak - Pierre-Yves LEBECQ (pylebecq) - Jakub Kucharovic (jkucharovic) - Eugene Leonovich (rybakit) @@ -226,6 +227,7 @@ Symfony is the result of the work of many people who made the code better - Nikita Konstantinov - Wodor Wodorski - Thomas Lallement (raziel057) + - Matthieu Napoli (mnapoli) - Beau Simensen (simensen) - Michael Hirschler (mvhirsch) - Robert Kiss (kepten) @@ -237,7 +239,7 @@ Symfony is the result of the work of many people who made the code better - Peter Kruithof (pkruithof) - Michael Holm (hollo) - Marc Weistroff (futurecat) - - Dawid Nowak + - Hidde Wieringa (hiddewie) - Chris Smith (cs278) - Florian Klein (docteurklein) - Manuel Kiessling (manuelkiessling) @@ -272,12 +274,12 @@ Symfony is the result of the work of many people who made the code better - janschoenherr - Thomas Schulz (king2500) - Berny Cantos (xphere81) + - Teoh Han Hui (teohhanhui) - Ricard Clau (ricardclau) - Mark Challoner (markchalloner) - Gregor Harlan (gharlan) - Gennady Telegin (gtelegin) - Giorgio Premi - - Matthieu Napoli (mnapoli) - Ben Davies (bendavies) - Erin Millard - Artur Melo (restless) @@ -296,6 +298,8 @@ Symfony is the result of the work of many people who made the code better - Yaroslav Kiliba - Terje Bråten - Robbert Klarenbeek (robbertkl) + - Alessandro Chitolina + - JhonnyL - hossein zolfi (ocean) - Clément Gautier (clementgautier) - Eduardo Gulias (egulias) @@ -321,6 +325,7 @@ Symfony is the result of the work of many people who made the code better - Kai - Lee Rowlands - Maximilian Reichel (phramz) + - Loick Piera (pyrech) - Karoly Negyesi (chx) - Ivan Kurnosov - Xavier HAUSHERR @@ -351,6 +356,7 @@ Symfony is the result of the work of many people who made the code better - Niklas Fiekas - Markus Bachmann (baachi) - lancergr + - Mihai Stancu - Olivier Dolbeau (odolbeau) - Jan Rosier (rosier) - vagrant @@ -367,7 +373,6 @@ Symfony is the result of the work of many people who made the code better - cedric lombardot (cedriclombardot) - Jonas Flodén (flojon) - Christian Schmidt - - Hidde Wieringa (hiddewie) - Marek Štípek (maryo) - Marcin Sikoń (marphi) - Dominik Zogg (dominik.zogg) @@ -380,7 +385,6 @@ Symfony is the result of the work of many people who made the code better - Zander Baldwin - Adam Harvey - Alex Bakhturin - - Alessandro Chitolina - boombatower - Fabrice Bernhard (fabriceb) - Jérôme Macias (jeromemacias) @@ -425,12 +429,13 @@ Symfony is the result of the work of many people who made the code better - Norbert Orzechowicz (norzechowicz) - Denis Charrier (brucewouaigne) - Matthijs van den Bos (matthijs) - - Loick Piera (pyrech) - Lenard Palko - Nils Adermann (naderman) - Gábor Fási - DUPUCH (bdupuch) - Benjamin Leveque (benji07) + - Nate (frickenate) + - jhonnyL - sasezaki - Dawid Pakuła (zulusx) - Florian Rey (nervo) @@ -453,7 +458,9 @@ Symfony is the result of the work of many people who made the code better - Marcin Chyłek (songoq) - Ned Schwartz - Ziumin + - Jeremy Benoist - Lenar Lõhmus + - Krzysztof Piasecki (krzysztek) - Benjamin Laugueux (yzalis) - Zach Badgett (zachbadgett) - Aurélien Fredouelle @@ -492,12 +499,13 @@ Symfony is the result of the work of many people who made the code better - Javier López (loalf) - Reinier Kip - Dustin Dobervich (dustin10) + - Anne-Sophie Bachelard (annesophie) - Sebastian Marek (proofek) - Erkhembayar Gantulga (erheme318) - Michal Trojanowski - - Mihai Stancu - David Fuhr - Kamil Kokot (pamil) + - Aurimas Niekis (gcds) - Max Grigorian (maxakawizard) - Rostyslav Kinash - Maciej Malarz (malarzm) @@ -521,11 +529,13 @@ Symfony is the result of the work of many people who made the code better - Arturs Vonda - Sascha Grossenbacher - Szijarto Tamas + - Catalin Dan - Stephan Vock - Benjamin Zikarsky (bzikarsky) - Simon Schick (simonsimcity) - redstar504 - Tristan Roussel + - Cameron Porter - Hossein Bukhamsin - Disparity - origaminal @@ -579,6 +589,7 @@ Symfony is the result of the work of many people who made the code better - Romain Gautier (mykiwi) - Yosmany Garcia (yosmanyga) - Wouter de Wild + - Miroslav Sustek - Degory Valentine - Benoit Lévêque (benoit_leveque) - Jeroen Fiege (fieg) @@ -587,6 +598,8 @@ Symfony is the result of the work of many people who made the code better - possum - Denis Zunke (donalberto) - Olivier Maisonneuve (olineuve) + - Michele Locati + - Masterklavi - Francis Turmel (fturmel) - cgonzalez - Ben @@ -598,6 +611,7 @@ Symfony is the result of the work of many people who made the code better - Adrien Lucas (adrienlucas) - James Michael DuPont - Tom Klingenberg + - Jhonny Lidfors (jhonne) - Christopher Hall (mythmakr) - Paul Kamer (pkamer) - Rafał Wrzeszcz (rafalwrzeszcz) @@ -607,6 +621,7 @@ Symfony is the result of the work of many people who made the code better - Pierre Vanliefland (pvanliefland) - Sofiane HADDAG (sofhad) - frost-nzcr4 + - Arjen van der Meijden - Abhoryo - Fabian Vogler (fabian) - Korvin Szanto @@ -614,6 +629,7 @@ Symfony is the result of the work of many people who made the code better - Maksim Kotlyar (makasim) - Neil Ferreira - Dmitry Parnas (parnas) + - Théo FIDRY (theofidry) - Paul LE CORRE - DQNEO - Emanuele Iannone @@ -670,10 +686,8 @@ Symfony is the result of the work of many people who made the code better - omerida - Gábor Tóth - Daniel Cestari - - Jeremy Benoist - David Lima - Jérôme Vasseur - - Krzysztof Piasecki (krzysztek) - Brunet Laurent (lbrunet) - Magnus Nordlander (magnusnordlander) - Mikhail Yurasov (mym) @@ -715,7 +729,6 @@ Symfony is the result of the work of many people who made the code better - fabios - Sander Coolen (scoolen) - Nicolas Le Goff (nlegoff) - - Anne-Sophie Bachelard (annesophie) - Manuele Menozzi - Anton Babenko (antonbabenko) - Irmantas Šiupšinskas (irmantas) @@ -723,6 +736,7 @@ Symfony is the result of the work of many people who made the code better - Zachary Tong (polyfractal) - Hryhorii Hrebiniuk - mcfedr (mcfedr) + - hamza - dantleech - Xavier Leune - Tero Alén (tero) @@ -735,6 +749,7 @@ Symfony is the result of the work of many people who made the code better - Sortex - chispita - Wojciech Sznapka + - Ariel J. Birnbaum - Arjan Keeman - Máximo Cuadros (mcuadros) - tamirvs @@ -750,7 +765,6 @@ Symfony is the result of the work of many people who made the code better - Ville Mattila - Boris Vujicic (boris.vujicic) - Max Beutel - - Catalin Dan - nacho - Piotr Antosik (antek88) - Artem Lopata @@ -783,6 +797,7 @@ Symfony is the result of the work of many people who made the code better - Benoit Garret - Thomas Royer (cydonia7) - DerManoMann + - Jhonny Lidfors (jhonny) - Julien Bianchi (jubianchi) - Marcin Chwedziak - Roland Franssen (ro0) @@ -796,7 +811,6 @@ Symfony is the result of the work of many people who made the code better - rpg600 - Péter Buri (burci) - Davide Borsatto (davide.borsatto) - - Teoh Han Hui (teohhanhui) - kaiwa - Charles Sanquer (csanquer) - Albert Ganiev (helios-ag) @@ -899,6 +913,7 @@ Symfony is the result of the work of many people who made the code better - Berat Doğan - Anthony Ferrara - Klaas Cuvelier (kcuvelier) + - Steve Frécinaux - ShiraNai7 - Vašek Purchart (vasek-purchart) - Janusz Jabłoński (yanoosh) @@ -919,7 +934,6 @@ Symfony is the result of the work of many people who made the code better - Pete Mitchell (peterjmit) - Tom Corrigan (tomcorrigan) - Martin Pärtel - - Miroslav Sustek - Patrick Daley (padrig) - Xavier Briand (xavierbriand) - Max Summe @@ -943,7 +957,6 @@ Symfony is the result of the work of many people who made the code better - Nathaniel Catchpole - Jose Gonzalez - Adrien Samson (adriensamson) - - Aurimas Niekis (gcds) - Samuel Gordalina (gordalina) - Max Romanovsky (maxromanovsky) - Mathieu Morlon @@ -960,6 +973,7 @@ Symfony is the result of the work of many people who made the code better - r1pp3rj4ck - Robert Queck - mlively + - Amine Matmati - Fabian Steiner (fabstei) - Klaus Silveira (klaussilveira) - Thomas Chmielowiec (chmielot) @@ -984,6 +998,7 @@ Symfony is the result of the work of many people who made the code better - Benjamin Bender - Konrad Mohrfeldt - Lance Chen + - Andrey Astakhov (aast) - kor3k kor3k (kor3k) - Stelian Mocanita (stelian) - Flavian (2much) @@ -1010,6 +1025,7 @@ Symfony is the result of the work of many people who made the code better - Jakub Simon - Bouke Haarsma - Martin Eckhardt + - natechicago - Jonathan Poston - Adrian Olek (adrianolek) - Przemysław Piechota (kibao) @@ -1032,12 +1048,13 @@ Symfony is the result of the work of many people who made the code better - Josef Cech - Arnau González (arnaugm) - Simon Bouland (bouland) - - Nate (frickenate) - Matthew Foster (mfoster) - Paul Seiffert (seiffert) - Vasily Khayrulin (sirian) - Stefan Koopmanschap (skoop) - Stefan Hüsges (tronsha) + - Dan Blows + - Matt Wells - stloyd - Chris Tickner - Andrew Coulton @@ -1051,6 +1068,7 @@ Symfony is the result of the work of many people who made the code better - Andreas - Thomas Chmielowiec - Andrey Ryaguzov + - Peter Bex - Manatsawin Hanmongkolchai - Gunther Konig - Maciej Schmidt @@ -1081,10 +1099,12 @@ Symfony is the result of the work of many people who made the code better - Aarón Nieves Fernández - Mike Meier - Kirill Saksin + - Koalabaerchen - michalmarcinkowski - Warwick - Chris - JakeFr + - Simon Sargeant - efeen - Michał Dąbrowski (defrag) - Nathanael Noblet (gnat) @@ -1118,10 +1138,12 @@ Symfony is the result of the work of many people who made the code better - Jason Woods - dened - Dmitry Korotovsky + - Michael van Tricht - Sam Ward - Walther Lalk - Adam - devel + - taiiiraaa - Trevor Suarez - gedrox - dropfen @@ -1229,6 +1251,7 @@ Symfony is the result of the work of many people who made the code better - Muriel (metalmumu) - Michael Pohlers (mick_the_big) - Cayetano Soriano Gallego (neoshadybeat) + - Patrick McDougle (patrick-mcdougle) - Pablo Monterde Perez (plebs) - Jimmy Leger (redpanda) - Cyrille Jouineau (tuxosaurus) @@ -1269,6 +1292,7 @@ Symfony is the result of the work of many people who made the code better - Myke79 - Brian Debuire - Piers Warmers + - Guilliam Xavier - Sylvain Lorinet - klyk50 - Andreas Lutro @@ -1332,6 +1356,7 @@ Symfony is the result of the work of many people who made the code better - Norman Soetbeer - zorn - Benjamin Long + - Robin Chalas - Matt Janssen - Peter Gribanov - kwiateusz @@ -1382,6 +1407,7 @@ Symfony is the result of the work of many people who made the code better - Adel ELHAIBA (eadel) - Damián Nohales (eagleoneraptor) - Elliot Anderson (elliot) + - Sergey Zolotov (enleur) - Fabien D. (fabd) - Sorin Gitlan (forapathy) - Yohan Giarelli (frequence-web) @@ -1395,6 +1421,7 @@ Symfony is the result of the work of many people who made the code better - Jose Manuel Gonzalez (jgonzalez) - Jorge Maiden (jorgemaiden) - Justin Rainbow (jrainbow) + - Juan Luis (juanlugb) - JuntaTom (juntatom) - Ismail Faizi (kanafghan) - Sébastien Armand (khepin) @@ -1439,6 +1466,7 @@ Symfony is the result of the work of many people who made the code better - Víctor Mateo (victormateo) - Vincent (vincent1870) - Eugene Babushkin (warl) + - Wouter Sioen (wouter_sioen) - Xavier Amado (xamado) - Jesper Søndergaard Pedersen (zerrvox) - Florent Cailhol @@ -1451,6 +1479,8 @@ Symfony is the result of the work of many people who made the code better - Andreas Streichardt - smokeybear87 - Gustavo Adrian + - Kevin Weber + - Sergey Fedotov - Michael - fh-github@fholzhauer.de - Mark Topper From 39890ed371a548baa266ceac52a69d638743801b Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Fri, 29 Apr 2016 11:47:36 +0200 Subject: [PATCH 13/38] updated VERSION for 2.7.12 --- src/Symfony/Component/HttpKernel/Kernel.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Symfony/Component/HttpKernel/Kernel.php b/src/Symfony/Component/HttpKernel/Kernel.php index 853e6337dad18..bee3360413739 100644 --- a/src/Symfony/Component/HttpKernel/Kernel.php +++ b/src/Symfony/Component/HttpKernel/Kernel.php @@ -58,12 +58,12 @@ abstract class Kernel implements KernelInterface, TerminableInterface protected $startTime; protected $loadClassCache; - const VERSION = '2.7.12-DEV'; + const VERSION = '2.7.12'; const VERSION_ID = 20712; const MAJOR_VERSION = 2; const MINOR_VERSION = 7; const RELEASE_VERSION = 12; - const EXTRA_VERSION = 'DEV'; + const EXTRA_VERSION = ''; const END_OF_MAINTENANCE = '05/2018'; const END_OF_LIFE = '05/2019'; From fb92d7a04a2779e4bd336c75c4b769980d4f0264 Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Fri, 29 Apr 2016 12:50:16 +0200 Subject: [PATCH 14/38] bumped Symfony version to 2.7.13 --- src/Symfony/Component/HttpKernel/Kernel.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Symfony/Component/HttpKernel/Kernel.php b/src/Symfony/Component/HttpKernel/Kernel.php index bee3360413739..6c871d77b3e67 100644 --- a/src/Symfony/Component/HttpKernel/Kernel.php +++ b/src/Symfony/Component/HttpKernel/Kernel.php @@ -58,12 +58,12 @@ abstract class Kernel implements KernelInterface, TerminableInterface protected $startTime; protected $loadClassCache; - const VERSION = '2.7.12'; - const VERSION_ID = 20712; + const VERSION = '2.7.13-DEV'; + const VERSION_ID = 20713; const MAJOR_VERSION = 2; const MINOR_VERSION = 7; - const RELEASE_VERSION = 12; - const EXTRA_VERSION = ''; + const RELEASE_VERSION = 13; + const EXTRA_VERSION = 'DEV'; const END_OF_MAINTENANCE = '05/2018'; const END_OF_LIFE = '05/2019'; From 73677e57ab68f6dd61f2ffa7013e99712088aa56 Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Fri, 29 Apr 2016 17:33:40 +0200 Subject: [PATCH 15/38] updated CHANGELOG for 2.8.5 --- CHANGELOG-2.8.md | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) diff --git a/CHANGELOG-2.8.md b/CHANGELOG-2.8.md index 7b0fb6cfb3131..854716d996a75 100644 --- a/CHANGELOG-2.8.md +++ b/CHANGELOG-2.8.md @@ -7,6 +7,46 @@ in 2.8 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.8.0...v2.8.1 +* 2.8.5 (2016-04-29) + + * bug #18180 [Form] fixed BC break with pre selection of choices with `ChoiceType` and its children (HeahDude) + * bug #18645 [Console] Fix wrong exceptions being thrown (JhonnyL) + * bug #18562 [WebProfilerBunde] Give an absolute url in case the request occured from another domain (romainneutron) + * bug #18600 [DI] Fix AutowirePass fatal error with classes that have non-existing parents (hason, nicolas-grekas) + * bug #18603 [PropertyAccess] ->getValue() should be read-only (nicolas-grekas) + * bug #18593 [VarDumper] Fix dumping type hints for non-existing parent classes (nicolas-grekas) + * bug #18596 [DI] Fix internal caching in AutowirePass (nicolas-grekas) + * bug #18581 [Console] [TableHelper] make it work with SymfonyStyle. (aitboudad) + * bug #18280 [Routing] add query param if value is different from default (Tobion) + * bug #18540 Replace iconv_*() uses by mb_*(), add mbstring polyfill when required (nicolas-grekas) + * bug #18496 [Console] use ANSI escape sequences in ProgressBar overwrite method (alekitto) + * bug #18490 [LDAP] Free the search result after a search to free memory (hiddewie) + * bug #18491 [DependencyInjection] anonymous services are always private (xabbuh) + * bug #18515 [Filesystem] Better error handling in remove() (nicolas-grekas) + * bug #18360 [PropertyInfo] Extract nullable and collection key type for Doctrine associations (teohhanhui) + * bug #18449 [PropertyAccess] Fix regression (nicolas-grekas) + * bug #18429 [Console] Correct time formatting. (camporter) + * bug #18457 [WebProfilerBundle] Fixed error from unset twig variable (simonsargeant) + * bug #18467 [DependencyInjection] Resolve aliases before removing abstract services + add tests (nicolas-grekas) + * bug #18469 Force profiler toolbar svg display (pyrech) + * bug #18460 [DomCrawler] Fix select option with empty value (Matt Wells) + * bug #18425 [Security] Fixed SwitchUserListener when exiting an impersonation with AnonymousToken (lyrixx) + * bug #18317 [Form] fix "prototype" not required when parent form is not required (HeahDude) + * bug #18439 [Logging] Add support for Firefox (43+) in ChromePhpHandler (arjenm) + * bug #18385 Detect CLI color support for Windows 10 build 10586 (mlocati) + * bug #18426 [EventDispatcher] Try first if the event is Stopped (lyrixx) + * bug #18407 Fixed the "hover" state of the profiler sidebar menu (javiereguiluz) + * bug #18394 [FrameworkBundle] Return the invokable service if its name is the class name (dunglas) + * bug #18347 Fixed the styles of the Symfony icon in the web debug toolbar (javiereguiluz) + * bug #18265 Optimize ReplaceAliasByActualDefinitionPass (ajb-in) + * bug #18349 [Process] Fix stream_select priority when writing to stdin (nicolas-grekas) + * bug #18358 [Form] NumberToLocalizedStringTransformer should return floats when possible (nicolas-grekas) + * bug #17926 [DependencyInjection] Enable alias for service_container (hason) + * bug #18352 [Debug] Fix case sensitivity checks (nicolas-grekas) + * bug #18336 [Debug] Fix handling of php7 throwables (nicolas-grekas) + * bug #18354 [FrameworkBundle][TwigBridge] fix high deps tests (xabbuh) + * bug #18312 [ClassLoader] Fix storing not-found classes in APC cache (nicolas-grekas) + * 2.8.4 (2016-03-27) * bug #18298 [Validator] do not treat payload as callback (xabbuh) From 25d166b4d82caaa529a15819e9d18d80846156de Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Fri, 29 Apr 2016 17:33:46 +0200 Subject: [PATCH 16/38] updated VERSION for 2.8.5 --- src/Symfony/Component/HttpKernel/Kernel.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Symfony/Component/HttpKernel/Kernel.php b/src/Symfony/Component/HttpKernel/Kernel.php index a804d4bbaf409..cfb6781f394da 100644 --- a/src/Symfony/Component/HttpKernel/Kernel.php +++ b/src/Symfony/Component/HttpKernel/Kernel.php @@ -59,12 +59,12 @@ abstract class Kernel implements KernelInterface, TerminableInterface protected $startTime; protected $loadClassCache; - const VERSION = '2.8.5-DEV'; + const VERSION = '2.8.5'; const VERSION_ID = 20805; const MAJOR_VERSION = 2; const MINOR_VERSION = 8; const RELEASE_VERSION = 5; - const EXTRA_VERSION = 'DEV'; + const EXTRA_VERSION = ''; const END_OF_MAINTENANCE = '11/2018'; const END_OF_LIFE = '11/2019'; From 2ac81f954bc4933b51991217ec0556d3ff504b17 Mon Sep 17 00:00:00 2001 From: Mathieu Lemoine Date: Mon, 2 May 2016 11:12:26 -0400 Subject: [PATCH 17/38] Make failed autowiring error messages more explicit --- .../Compiler/AutowirePass.php | 39 +++++++++++++------ .../Tests/Compiler/AutowirePassTest.php | 21 ++++++++-- 2 files changed, 45 insertions(+), 15 deletions(-) diff --git a/src/Symfony/Component/DependencyInjection/Compiler/AutowirePass.php b/src/Symfony/Component/DependencyInjection/Compiler/AutowirePass.php index 4cef7df71401a..e4457d4608451 100644 --- a/src/Symfony/Component/DependencyInjection/Compiler/AutowirePass.php +++ b/src/Symfony/Component/DependencyInjection/Compiler/AutowirePass.php @@ -105,7 +105,7 @@ private function completeDefinition($id, Definition $definition) $this->populateAvailableTypes(); } - if (isset($this->types[$typeHint->name])) { + if (isset($this->types[$typeHint->name]) && !isset($this->notGuessableTypes[$typeHint->name])) { $value = new Reference($this->types[$typeHint->name]); } else { try { @@ -190,22 +190,26 @@ private function populateAvailableType($id, Definition $definition) */ private function set($type, $id) { - if (isset($this->definedTypes[$type]) || isset($this->notGuessableTypes[$type])) { + if (isset($this->definedTypes[$type])) { return; } - if (isset($this->types[$type])) { - if ($this->types[$type] === $id) { - return; - } + if (!isset($this->types[$type])) { + $this->types[$type] = $id; - unset($this->types[$type]); - $this->notGuessableTypes[$type] = true; + return; + } + if ($this->types[$type] === $id) { return; } - $this->types[$type] = $id; + if (!isset($this->notGuessableTypes[$type])) { + $this->notGuessableTypes[$type] = true; + $this->types[$type] = (array) $this->types[$type]; + } + + $this->types[$type][] = $id; } /** @@ -220,8 +224,14 @@ private function set($type, $id) */ private function createAutowiredDefinition(\ReflectionClass $typeHint, $id) { - if (isset($this->notGuessableTypes[$typeHint->name]) || !$typeHint->isInstantiable()) { - throw new RuntimeException(sprintf('Unable to autowire argument of type "%s" for the service "%s".', $typeHint->name, $id)); + if (isset($this->notGuessableTypes[$typeHint->name])) { + throw new RuntimeException(sprintf('Unable to autowire argument of type "%s" for the service "%s". Several services implementing this type have been declared: "%s".', $typeHint->name, $id, implode('", "', $this->types[$typeHint->name]))); + } + + $noAvailableDefinitionMessage = sprintf('Unable to autowire argument of type "%s" for the service "%s". This type cannot be instantiated automatically and no service implementing this type is declared.', $typeHint->name, $id); + + if (!$typeHint->isInstantiable()) { + throw new RuntimeException($noAvailableDefinitionMessage); } $argumentId = sprintf('autowired.%s', $typeHint->name); @@ -230,7 +240,12 @@ private function createAutowiredDefinition(\ReflectionClass $typeHint, $id) $argumentDefinition->setPublic(false); $this->populateAvailableType($argumentId, $argumentDefinition); - $this->completeDefinition($argumentId, $argumentDefinition); + + try { + $this->completeDefinition($argumentId, $argumentDefinition); + } catch (RuntimeException $e) { + throw new RuntimeException($noAvailableDefinitionMessage, 0, $e); + } return new Reference($argumentId); } diff --git a/src/Symfony/Component/DependencyInjection/Tests/Compiler/AutowirePassTest.php b/src/Symfony/Component/DependencyInjection/Tests/Compiler/AutowirePassTest.php index 1c61f05b0b7b6..6098d9a9131c8 100644 --- a/src/Symfony/Component/DependencyInjection/Tests/Compiler/AutowirePassTest.php +++ b/src/Symfony/Component/DependencyInjection/Tests/Compiler/AutowirePassTest.php @@ -103,7 +103,7 @@ public function testCompleteExistingDefinitionWithNotDefinedArguments() /** * @expectedException \Symfony\Component\DependencyInjection\Exception\RuntimeException - * @expectedExceptionMessage Unable to autowire argument of type "Symfony\Component\DependencyInjection\Tests\Compiler\CollisionInterface" for the service "a". + * @expectedExceptionMessage Unable to autowire argument of type "Symfony\Component\DependencyInjection\Tests\Compiler\CollisionInterface" for the service "a". Several services implementing this type have been declared: "c1", "c2". */ public function testTypeCollision() { @@ -120,7 +120,7 @@ public function testTypeCollision() /** * @expectedException \Symfony\Component\DependencyInjection\Exception\RuntimeException - * @expectedExceptionMessage Unable to autowire argument of type "Symfony\Component\DependencyInjection\Tests\Compiler\Foo" for the service "a". + * @expectedExceptionMessage Unable to autowire argument of type "Symfony\Component\DependencyInjection\Tests\Compiler\Foo" for the service "a". Several services implementing this type have been declared: "a1", "a2". */ public function testTypeNotGuessable() { @@ -137,7 +137,7 @@ public function testTypeNotGuessable() /** * @expectedException \Symfony\Component\DependencyInjection\Exception\RuntimeException - * @expectedExceptionMessage Unable to autowire argument of type "Symfony\Component\DependencyInjection\Tests\Compiler\A" for the service "a". + * @expectedExceptionMessage Unable to autowire argument of type "Symfony\Component\DependencyInjection\Tests\Compiler\A" for the service "a". Several services implementing this type have been declared: "a1", "a2". */ public function testTypeNotGuessableWithSubclass() { @@ -207,6 +207,21 @@ public function testCreateDefinition() $this->assertEquals(__NAMESPACE__.'\Lille', $lilleDefinition->getClass()); } + /** + * @expectedException \Symfony\Component\DependencyInjection\Exception\RuntimeException + * @expectedExceptionMessage Unable to autowire argument of type "Symfony\Component\DependencyInjection\Tests\Compiler\CollisionInterface" for the service "a". This type cannot be instantiated automatically and no service implementing this type is declared. + */ + public function testCreateNonInstanciable() + { + $container = new ContainerBuilder(); + + $aDefinition = $container->register('a', __NAMESPACE__.'\CannotBeAutowired'); + $aDefinition->setAutowired(true); + + $pass = new AutowirePass(); + $pass->process($container); + } + public function testResolveParameter() { $container = new ContainerBuilder(); From a52e51a7b874bd9719e9600be6260c360674b2c2 Mon Sep 17 00:00:00 2001 From: Daniel Espendiller Date: Mon, 2 May 2016 19:24:41 +0200 Subject: [PATCH 18/38] add @Event annotation for KernelEvents --- src/Symfony/Component/HttpKernel/KernelEvents.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/Symfony/Component/HttpKernel/KernelEvents.php b/src/Symfony/Component/HttpKernel/KernelEvents.php index 8768979da6bd4..abbbfcc0048b9 100644 --- a/src/Symfony/Component/HttpKernel/KernelEvents.php +++ b/src/Symfony/Component/HttpKernel/KernelEvents.php @@ -108,6 +108,10 @@ final class KernelEvents * * This event allows you to reset the global and environmental state of * the application, when it was changed during the request. + * The event listener method receives a + * Symfony\Component\HttpKernel\Event\FinishRequestEvent instance. + * + * @Event * * @var string */ From 3b784921360739fafbfee42a6c3521f5a442b2a0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?K=C3=A9vin=20Dunglas?= Date: Mon, 2 May 2016 22:41:39 +0200 Subject: [PATCH 19/38] [PropertyInfo] PHPDoc correction --- .../Component/PropertyInfo/Extractor/ReflectionExtractor.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Symfony/Component/PropertyInfo/Extractor/ReflectionExtractor.php b/src/Symfony/Component/PropertyInfo/Extractor/ReflectionExtractor.php index 9b7262d237595..63454a5b45319 100644 --- a/src/Symfony/Component/PropertyInfo/Extractor/ReflectionExtractor.php +++ b/src/Symfony/Component/PropertyInfo/Extractor/ReflectionExtractor.php @@ -40,7 +40,7 @@ class ReflectionExtractor implements PropertyListExtractorInterface, PropertyTyp /** * @internal * - * @var array[] + * @var string[] */ public static $arrayMutatorPrefixes = array('add', 'remove'); From 7b3c65bf67923ce1fda717f731f7ce60a171655f Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Tue, 3 May 2016 07:55:22 +0200 Subject: [PATCH 20/38] bumped Symfony version to 2.8.6 --- src/Symfony/Component/HttpKernel/Kernel.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Symfony/Component/HttpKernel/Kernel.php b/src/Symfony/Component/HttpKernel/Kernel.php index cfb6781f394da..f949701322af0 100644 --- a/src/Symfony/Component/HttpKernel/Kernel.php +++ b/src/Symfony/Component/HttpKernel/Kernel.php @@ -59,12 +59,12 @@ abstract class Kernel implements KernelInterface, TerminableInterface protected $startTime; protected $loadClassCache; - const VERSION = '2.8.5'; - const VERSION_ID = 20805; + const VERSION = '2.8.6-DEV'; + const VERSION_ID = 20806; const MAJOR_VERSION = 2; const MINOR_VERSION = 8; - const RELEASE_VERSION = 5; - const EXTRA_VERSION = ''; + const RELEASE_VERSION = 6; + const EXTRA_VERSION = 'DEV'; const END_OF_MAINTENANCE = '11/2018'; const END_OF_LIFE = '11/2019'; From 42279b5d0031a6c39e28900505cf8a3a195a43c7 Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Tue, 3 May 2016 08:45:46 +0200 Subject: [PATCH 21/38] bumped Symfony version to 3.0.6 --- src/Symfony/Component/HttpKernel/Kernel.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Symfony/Component/HttpKernel/Kernel.php b/src/Symfony/Component/HttpKernel/Kernel.php index ffef82876ca1f..f81f3c5058dae 100644 --- a/src/Symfony/Component/HttpKernel/Kernel.php +++ b/src/Symfony/Component/HttpKernel/Kernel.php @@ -59,12 +59,12 @@ abstract class Kernel implements KernelInterface, TerminableInterface protected $startTime; protected $loadClassCache; - const VERSION = '3.0.5'; - const VERSION_ID = 30005; + const VERSION = '3.0.6-DEV'; + const VERSION_ID = 30006; const MAJOR_VERSION = 3; const MINOR_VERSION = 0; - const RELEASE_VERSION = 5; - const EXTRA_VERSION = ''; + const RELEASE_VERSION = 6; + const EXTRA_VERSION = 'DEV'; const END_OF_MAINTENANCE = '07/2016'; const END_OF_LIFE = '01/2017'; From d1ad43c174af76df51fc9fb8ad24914e1f89c7b6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Haso=C5=88?= Date: Tue, 3 May 2016 11:49:32 +0200 Subject: [PATCH 22/38] [DependencyInjection] Fixed the priority of service decoration on service with parent --- .../Compiler/ResolveDefinitionTemplatesPass.php | 2 +- .../Tests/Compiler/ResolveDefinitionTemplatesPassTest.php | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/Symfony/Component/DependencyInjection/Compiler/ResolveDefinitionTemplatesPass.php b/src/Symfony/Component/DependencyInjection/Compiler/ResolveDefinitionTemplatesPass.php index e654819c0edd1..55f1a24513dfc 100644 --- a/src/Symfony/Component/DependencyInjection/Compiler/ResolveDefinitionTemplatesPass.php +++ b/src/Symfony/Component/DependencyInjection/Compiler/ResolveDefinitionTemplatesPass.php @@ -174,7 +174,7 @@ private function resolveDefinition(ContainerBuilder $container, DefinitionDecora if (null === $decoratedService) { $def->setDecoratedService($decoratedService); } else { - $def->setDecoratedService($decoratedService[0], $decoratedService[1]); + $def->setDecoratedService($decoratedService[0], $decoratedService[1], $decoratedService[2]); } } diff --git a/src/Symfony/Component/DependencyInjection/Tests/Compiler/ResolveDefinitionTemplatesPassTest.php b/src/Symfony/Component/DependencyInjection/Tests/Compiler/ResolveDefinitionTemplatesPassTest.php index 15de79042ccd9..c56d199b2ffbe 100644 --- a/src/Symfony/Component/DependencyInjection/Tests/Compiler/ResolveDefinitionTemplatesPassTest.php +++ b/src/Symfony/Component/DependencyInjection/Tests/Compiler/ResolveDefinitionTemplatesPassTest.php @@ -276,10 +276,12 @@ public function testSetDecoratedServiceOnServiceHasParent() $container->register('parent', 'stdClass'); $container->setDefinition('child1', new DefinitionDecorator('parent')) - ->setDecoratedService('foo', 'foo_inner') + ->setDecoratedService('foo', 'foo_inner', 5) ; - $this->assertEquals(array('foo', 'foo_inner', 0), $container->getDefinition('child1')->getDecoratedService()); + $this->process($container); + + $this->assertEquals(array('foo', 'foo_inner', 5), $container->getDefinition('child1')->getDecoratedService()); } public function testDecoratedServiceCopiesDeprecatedStatusFromParent() From af4ca4f48b1aca08991f30ef7b4cdb58002c369e Mon Sep 17 00:00:00 2001 From: Daniel Espendiller Date: Mon, 2 May 2016 19:21:33 +0200 Subject: [PATCH 23/38] add @Event annotation for AuthenticationEvents --- src/Symfony/Component/Security/Core/AuthenticationEvents.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/Symfony/Component/Security/Core/AuthenticationEvents.php b/src/Symfony/Component/Security/Core/AuthenticationEvents.php index 90b714267466c..13bce30768908 100644 --- a/src/Symfony/Component/Security/Core/AuthenticationEvents.php +++ b/src/Symfony/Component/Security/Core/AuthenticationEvents.php @@ -20,6 +20,8 @@ final class AuthenticationEvents * The event listener method receives a * Symfony\Component\Security\Core\Event\AuthenticationEvent instance. * + * @Event + * * @var string */ const AUTHENTICATION_SUCCESS = 'security.authentication.success'; @@ -32,6 +34,8 @@ final class AuthenticationEvents * Symfony\Component\Security\Core\Event\AuthenticationFailureEvent * instance. * + * @Event + * * @var string */ const AUTHENTICATION_FAILURE = 'security.authentication.failure'; From 78ae2adb5bdd7a3224b32a99664ba6d6d64c52cb Mon Sep 17 00:00:00 2001 From: Christian Flothmann Date: Thu, 31 Mar 2016 19:22:31 +0200 Subject: [PATCH 24/38] [EventDispatcher] check for method to exist --- .../EventDispatcher/Debug/TraceableEventDispatcher.php | 4 ++++ .../Tests/Debug/TraceableEventDispatcherTest.php | 10 ++++++++++ 2 files changed, 14 insertions(+) diff --git a/src/Symfony/Component/EventDispatcher/Debug/TraceableEventDispatcher.php b/src/Symfony/Component/EventDispatcher/Debug/TraceableEventDispatcher.php index 75ba2a760f45a..0ea35fa0e3481 100644 --- a/src/Symfony/Component/EventDispatcher/Debug/TraceableEventDispatcher.php +++ b/src/Symfony/Component/EventDispatcher/Debug/TraceableEventDispatcher.php @@ -104,6 +104,10 @@ public function getListeners($eventName = null) */ public function getListenerPriority($eventName, $listener) { + if (!method_exists($this->dispatcher, 'getListenerPriority')) { + return 0; + } + return $this->dispatcher->getListenerPriority($eventName, $listener); } diff --git a/src/Symfony/Component/EventDispatcher/Tests/Debug/TraceableEventDispatcherTest.php b/src/Symfony/Component/EventDispatcher/Tests/Debug/TraceableEventDispatcherTest.php index 2dd8292a1b3e6..dd54e73b34f24 100644 --- a/src/Symfony/Component/EventDispatcher/Tests/Debug/TraceableEventDispatcherTest.php +++ b/src/Symfony/Component/EventDispatcher/Tests/Debug/TraceableEventDispatcherTest.php @@ -73,6 +73,16 @@ public function testGetListenerPriority() $this->assertSame(123, $tdispatcher->getListenerPriority('foo', $listeners[0])); } + public function testGetListenerPriorityReturnsZeroWhenWrappedMethodDoesNotExist() + { + $dispatcher = $this->getMock('Symfony\Component\EventDispatcher\EventDispatcherInterface'); + $traceableEventDispatcher = new TraceableEventDispatcher($dispatcher, new Stopwatch()); + $traceableEventDispatcher->addListener('foo', function () {}, 123); + $listeners = $traceableEventDispatcher->getListeners('foo'); + + $this->assertSame(0, $traceableEventDispatcher->getListenerPriority('foo', $listeners[0])); + } + public function testAddRemoveSubscriber() { $dispatcher = new EventDispatcher(); From 576a55c5d9786c53fd38c6bf674dac90fa2ccfe9 Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Tue, 3 May 2016 21:00:19 +0200 Subject: [PATCH 25/38] reverted some changes not needed in 3.0 --- .../EventDispatcher/Debug/TraceableEventDispatcher.php | 4 ---- 1 file changed, 4 deletions(-) diff --git a/src/Symfony/Component/EventDispatcher/Debug/TraceableEventDispatcher.php b/src/Symfony/Component/EventDispatcher/Debug/TraceableEventDispatcher.php index 9b460f55f6ac3..e729eeb103715 100644 --- a/src/Symfony/Component/EventDispatcher/Debug/TraceableEventDispatcher.php +++ b/src/Symfony/Component/EventDispatcher/Debug/TraceableEventDispatcher.php @@ -104,10 +104,6 @@ public function getListeners($eventName = null) */ public function getListenerPriority($eventName, $listener) { - if (!method_exists($this->dispatcher, 'getListenerPriority')) { - return 0; - } - return $this->dispatcher->getListenerPriority($eventName, $listener); } From 59ffd04d184776d03c83383718b8166811091ca4 Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Wed, 4 May 2016 18:16:16 +0200 Subject: [PATCH 26/38] added a conflict between Monolog bridge 2.8 and HTTP Kernel 3.0+ --- src/Symfony/Bridge/Monolog/composer.json | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/Symfony/Bridge/Monolog/composer.json b/src/Symfony/Bridge/Monolog/composer.json index 500a9f57c43b1..433e0e103ff4c 100644 --- a/src/Symfony/Bridge/Monolog/composer.json +++ b/src/Symfony/Bridge/Monolog/composer.json @@ -24,6 +24,9 @@ "symfony/console": "~2.4|~3.0.0", "symfony/event-dispatcher": "~2.2|~3.0.0" }, + "conflict": { + "symfony/http-kernel": ">=3.0" + }, "suggest": { "symfony/http-kernel": "For using the debugging handlers together with the response life cycle of the HTTP kernel.", "symfony/console": "For the possibility to show log messages in console commands depending on verbosity settings. You need version ~2.3 of the console for it.", From d6c9073ec2d9c86503944d5650d84195a60f2de8 Mon Sep 17 00:00:00 2001 From: Robin Chalas Date: Mon, 2 May 2016 22:11:35 +0200 Subject: [PATCH 27/38] [DependencyInjection] Suggest ExpressionLanguage in composer.json Add a suggestion message Fix wrong message --- src/Symfony/Component/DependencyInjection/composer.json | 1 + 1 file changed, 1 insertion(+) diff --git a/src/Symfony/Component/DependencyInjection/composer.json b/src/Symfony/Component/DependencyInjection/composer.json index c2b2550607005..d42c7a0c6c0d6 100644 --- a/src/Symfony/Component/DependencyInjection/composer.json +++ b/src/Symfony/Component/DependencyInjection/composer.json @@ -29,6 +29,7 @@ "suggest": { "symfony/yaml": "", "symfony/config": "", + "symfony/expression-language": "For using expressions in service container configuration", "symfony/proxy-manager-bridge": "Generate service proxies to lazy load them" }, "autoload": { From 13a47c3c6ddd9e5287ece292b9cc57d77dd22c5c Mon Sep 17 00:00:00 2001 From: Christian Flothmann Date: Wed, 4 May 2016 21:53:17 +0200 Subject: [PATCH 28/38] top-level anonymous services must be public --- .../Component/DependencyInjection/Loader/XmlFileLoader.php | 6 +++--- .../DependencyInjection/Tests/Loader/XmlFileLoaderTest.php | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Symfony/Component/DependencyInjection/Loader/XmlFileLoader.php b/src/Symfony/Component/DependencyInjection/Loader/XmlFileLoader.php index 0314ba6809586..f324aa969cc33 100644 --- a/src/Symfony/Component/DependencyInjection/Loader/XmlFileLoader.php +++ b/src/Symfony/Component/DependencyInjection/Loader/XmlFileLoader.php @@ -237,6 +237,9 @@ private function processAnonymousServices(SimpleXMLElement $xml, $file) $definitions[(string) $node['id']] = array($node->service, $file, false); $node->service['id'] = (string) $node['id']; + + // anonymous services are always private + $node->service['public'] = false; } } @@ -254,9 +257,6 @@ private function processAnonymousServices(SimpleXMLElement $xml, $file) // resolve definitions krsort($definitions); foreach ($definitions as $id => $def) { - // anonymous services are always private - $def[0]['public'] = false; - $this->parseDefinition($id, $def[0], $def[1]); $oNode = dom_import_simplexml($def[0]); diff --git a/src/Symfony/Component/DependencyInjection/Tests/Loader/XmlFileLoaderTest.php b/src/Symfony/Component/DependencyInjection/Tests/Loader/XmlFileLoaderTest.php index 38ee13d5ff73e..a8f8f35133ae5 100644 --- a/src/Symfony/Component/DependencyInjection/Tests/Loader/XmlFileLoaderTest.php +++ b/src/Symfony/Component/DependencyInjection/Tests/Loader/XmlFileLoaderTest.php @@ -158,7 +158,7 @@ public function testLoadAnonymousServices() $service = $container->getDefinition($id); } $this->assertEquals('BizClass', $service->getClass(), '->load() uses the same configuration as for the anonymous ones'); - $this->assertFalse($service->isPublic()); + $this->assertTrue($service->isPublic()); // anonymous services are shared when using decoration definitions $container->compile(); From 636401bbebb02521b736074dc97f81f10a1d69df Mon Sep 17 00:00:00 2001 From: Christian Flothmann Date: Thu, 5 May 2016 08:56:13 +0200 Subject: [PATCH 29/38] [EventDispatcher] fix tests The `getListenerPriority()` method was added to the event dispatcher interface in Symfony 3.0. Thus, it no longer makes sense to have a test that expects the method not to exist (the corresponding code in the `TraceableEventDispatcher` was already removed in 576a55c. --- .../Tests/Debug/TraceableEventDispatcherTest.php | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/src/Symfony/Component/EventDispatcher/Tests/Debug/TraceableEventDispatcherTest.php b/src/Symfony/Component/EventDispatcher/Tests/Debug/TraceableEventDispatcherTest.php index dd54e73b34f24..2dd8292a1b3e6 100644 --- a/src/Symfony/Component/EventDispatcher/Tests/Debug/TraceableEventDispatcherTest.php +++ b/src/Symfony/Component/EventDispatcher/Tests/Debug/TraceableEventDispatcherTest.php @@ -73,16 +73,6 @@ public function testGetListenerPriority() $this->assertSame(123, $tdispatcher->getListenerPriority('foo', $listeners[0])); } - public function testGetListenerPriorityReturnsZeroWhenWrappedMethodDoesNotExist() - { - $dispatcher = $this->getMock('Symfony\Component\EventDispatcher\EventDispatcherInterface'); - $traceableEventDispatcher = new TraceableEventDispatcher($dispatcher, new Stopwatch()); - $traceableEventDispatcher->addListener('foo', function () {}, 123); - $listeners = $traceableEventDispatcher->getListeners('foo'); - - $this->assertSame(0, $traceableEventDispatcher->getListenerPriority('foo', $listeners[0])); - } - public function testAddRemoveSubscriber() { $dispatcher = new EventDispatcher(); From beecc6c1bed7c5967d80a995e2185da9f5cff7d8 Mon Sep 17 00:00:00 2001 From: Francis Besset Date: Fri, 6 May 2016 22:13:08 +0200 Subject: [PATCH 30/38] Fixed readme of OptionsResolver --- src/Symfony/Component/OptionsResolver/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Symfony/Component/OptionsResolver/README.md b/src/Symfony/Component/OptionsResolver/README.md index 5768f68e7ff7d..245e69b548d6d 100644 --- a/src/Symfony/Component/OptionsResolver/README.md +++ b/src/Symfony/Component/OptionsResolver/README.md @@ -1,7 +1,7 @@ OptionsResolver Component ========================= -The OptionsResolver component is `array_replace on steroids. It allows you to +The OptionsResolver component is `array_replace` on steroids. It allows you to create an options system with required options, defaults, validation (type, value), normalization and more. From 954126b04f8650f31d50156af6723afa18e88bda Mon Sep 17 00:00:00 2001 From: Christian Flothmann Date: Mon, 9 May 2016 17:02:09 +0200 Subject: [PATCH 31/38] call get() after the container was compiled --- .../ProxyManager/Tests/LazyProxy/ContainerBuilderTest.php | 2 ++ .../Tests/DependencyInjection/WebProfilerExtensionTest.php | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/Symfony/Bridge/ProxyManager/Tests/LazyProxy/ContainerBuilderTest.php b/src/Symfony/Bridge/ProxyManager/Tests/LazyProxy/ContainerBuilderTest.php index ae13d543b0e1e..3f3c577b846df 100644 --- a/src/Symfony/Bridge/ProxyManager/Tests/LazyProxy/ContainerBuilderTest.php +++ b/src/Symfony/Bridge/ProxyManager/Tests/LazyProxy/ContainerBuilderTest.php @@ -33,6 +33,8 @@ public function testCreateProxyServiceWithRuntimeInstantiator() $builder->register('foo1', 'ProxyManagerBridgeFooClass')->setFile(__DIR__.'/Fixtures/includes/foo.php'); $builder->getDefinition('foo1')->setLazy(true); + $builder->compile(); + /* @var $foo1 \ProxyManager\Proxy\LazyLoadingInterface|\ProxyManager\Proxy\ValueHolderInterface */ $foo1 = $builder->get('foo1'); diff --git a/src/Symfony/Bundle/WebProfilerBundle/Tests/DependencyInjection/WebProfilerExtensionTest.php b/src/Symfony/Bundle/WebProfilerBundle/Tests/DependencyInjection/WebProfilerExtensionTest.php index 765d721842b8c..7ddb4dbd3539e 100644 --- a/src/Symfony/Bundle/WebProfilerBundle/Tests/DependencyInjection/WebProfilerExtensionTest.php +++ b/src/Symfony/Bundle/WebProfilerBundle/Tests/DependencyInjection/WebProfilerExtensionTest.php @@ -99,9 +99,9 @@ public function testToolbarConfig($enabled) $extension = new WebProfilerExtension(); $extension->load(array(array('toolbar' => $enabled)), $this->container); - $this->assertSame($enabled, $this->container->get('web_profiler.debug_toolbar')->isEnabled()); - $this->assertSaneContainer($this->getDumpedContainer()); + + $this->assertSame($enabled, $this->container->get('web_profiler.debug_toolbar')->isEnabled()); } public function getDebugModes() From 2d46bd4812110a518e28b50230f4ca50e4ca25c8 Mon Sep 17 00:00:00 2001 From: Christian Flothmann Date: Mon, 9 May 2016 17:02:20 +0200 Subject: [PATCH 32/38] prevent calling get() for service_container service --- .../Bundle/FrameworkBundle/Console/Descriptor/Descriptor.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/Symfony/Bundle/FrameworkBundle/Console/Descriptor/Descriptor.php b/src/Symfony/Bundle/FrameworkBundle/Console/Descriptor/Descriptor.php index d6e0c14da4893..33334e79920c9 100644 --- a/src/Symfony/Bundle/FrameworkBundle/Console/Descriptor/Descriptor.php +++ b/src/Symfony/Bundle/FrameworkBundle/Console/Descriptor/Descriptor.php @@ -274,6 +274,10 @@ protected function resolveServiceDefinition(ContainerBuilder $builder, $serviceI return $builder->getAlias($serviceId); } + if ('service_container' === $serviceId) { + return $builder; + } + // the service has been injected in some special way, just return the service return $builder->get($serviceId); } From b1c60b4f0d9861586cb870a723f8fa94a01c84ec Mon Sep 17 00:00:00 2001 From: Erik van Wingerden Date: Mon, 9 May 2016 09:52:08 +0200 Subject: [PATCH 33/38] [2.3][Component/Security] Fixed phpdoc in AnonymousToken constructor for user param --- .../Security/Core/Authentication/Token/AnonymousToken.php | 2 +- .../Core/Authentication/Token/PreAuthenticatedToken.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Symfony/Component/Security/Core/Authentication/Token/AnonymousToken.php b/src/Symfony/Component/Security/Core/Authentication/Token/AnonymousToken.php index 571816ca9ecb2..5f3241f20d62f 100644 --- a/src/Symfony/Component/Security/Core/Authentication/Token/AnonymousToken.php +++ b/src/Symfony/Component/Security/Core/Authentication/Token/AnonymousToken.php @@ -26,7 +26,7 @@ class AnonymousToken extends AbstractToken * Constructor. * * @param string $key The key shared with the authentication provider - * @param string $user The user + * @param string|object $user The user can be a UserInterface instance, or an object implementing a __toString method or the username as a regular string. * @param RoleInterface[] $roles An array of roles */ public function __construct($key, $user, array $roles = array()) diff --git a/src/Symfony/Component/Security/Core/Authentication/Token/PreAuthenticatedToken.php b/src/Symfony/Component/Security/Core/Authentication/Token/PreAuthenticatedToken.php index 1798203690455..5a3fc95327c08 100644 --- a/src/Symfony/Component/Security/Core/Authentication/Token/PreAuthenticatedToken.php +++ b/src/Symfony/Component/Security/Core/Authentication/Token/PreAuthenticatedToken.php @@ -26,7 +26,7 @@ class PreAuthenticatedToken extends AbstractToken /** * Constructor. * - * @param string|object $user The user + * @param string|object $user The user can be a UserInterface instance, or an object implementing a __toString method or the username as a regular string. * @param mixed $credentials The user credentials * @param string $providerKey The provider key * @param RoleInterface[]|string[] $roles An array of roles From f8dc28ae536a0e69434f31841e20366fbff16b63 Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Sun, 1 May 2016 06:13:23 +0200 Subject: [PATCH 34/38] limited the maximum length of a submitted username --- .../Core/SecurityContextInterface.php | 1 + ...namePasswordFormAuthenticationListener.php | 5 ++ ...PasswordFormAuthenticationListenerTest.php | 78 +++++++++++++++++++ 3 files changed, 84 insertions(+) create mode 100644 src/Symfony/Component/Security/Tests/Http/Firewall/UsernamePasswordFormAuthenticationListenerTest.php diff --git a/src/Symfony/Component/Security/Core/SecurityContextInterface.php b/src/Symfony/Component/Security/Core/SecurityContextInterface.php index 50c30bb51237f..0253a6ae23d3f 100644 --- a/src/Symfony/Component/Security/Core/SecurityContextInterface.php +++ b/src/Symfony/Component/Security/Core/SecurityContextInterface.php @@ -23,6 +23,7 @@ interface SecurityContextInterface const ACCESS_DENIED_ERROR = '_security.403_error'; const AUTHENTICATION_ERROR = '_security.last_error'; const LAST_USERNAME = '_security.last_username'; + const MAX_USERNAME_LENGTH = 4096; /** * Returns the current security token. diff --git a/src/Symfony/Component/Security/Http/Firewall/UsernamePasswordFormAuthenticationListener.php b/src/Symfony/Component/Security/Http/Firewall/UsernamePasswordFormAuthenticationListener.php index 21478175351d0..26aeb67780cd3 100644 --- a/src/Symfony/Component/Security/Http/Firewall/UsernamePasswordFormAuthenticationListener.php +++ b/src/Symfony/Component/Security/Http/Firewall/UsernamePasswordFormAuthenticationListener.php @@ -20,6 +20,7 @@ use Symfony\Component\Security\Http\HttpUtils; use Symfony\Component\Security\Core\Authentication\AuthenticationManagerInterface; use Symfony\Component\Security\Core\Authentication\Token\UsernamePasswordToken; +use Symfony\Component\Security\Core\Exception\BadCredentialsException; use Symfony\Component\Security\Core\Exception\InvalidCsrfTokenException; use Symfony\Component\Security\Core\SecurityContextInterface; use Symfony\Component\EventDispatcher\EventDispatcherInterface; @@ -83,6 +84,10 @@ protected function attemptAuthentication(Request $request) $password = $request->get($this->options['password_parameter'], null, true); } + if (strlen($username) > SecurityContextInterface::MAX_USERNAME_LENGTH) { + throw new BadCredentialsException('Invalid username.'); + } + $request->getSession()->set(SecurityContextInterface::LAST_USERNAME, $username); return $this->authenticationManager->authenticate(new UsernamePasswordToken($username, $password, $this->providerKey)); diff --git a/src/Symfony/Component/Security/Tests/Http/Firewall/UsernamePasswordFormAuthenticationListenerTest.php b/src/Symfony/Component/Security/Tests/Http/Firewall/UsernamePasswordFormAuthenticationListenerTest.php new file mode 100644 index 0000000000000..b7c6ab9db5752 --- /dev/null +++ b/src/Symfony/Component/Security/Tests/Http/Firewall/UsernamePasswordFormAuthenticationListenerTest.php @@ -0,0 +1,78 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +namespace Symfony\Component\Security\Tests\Http\Firewall; + +use Symfony\Component\HttpFoundation\Request; +use Symfony\Component\HttpFoundation\Response; +use Symfony\Component\Security\Http\Firewall\UsernamePasswordFormAuthenticationListener; +use Symfony\Component\Security\Core\SecurityContextInterface; + +class UsernamePasswordFormAuthenticationListenerTest extends \PHPUnit_Framework_TestCase +{ + /** + * @dataProvider getUsernameForLength + */ + public function testHandleWhenUsernameLength($username, $ok) + { + $request = Request::create('/login_check', 'POST', array('_username' => $username)); + $request->setSession($this->getMock('Symfony\Component\HttpFoundation\Session\SessionInterface')); + + $httpUtils = $this->getMock('Symfony\Component\Security\Http\HttpUtils'); + $httpUtils + ->expects($this->any()) + ->method('checkRequestPath') + ->will($this->returnValue(true)) + ; + + $failureHandler = $this->getMock('Symfony\Component\Security\Http\Authentication\AuthenticationFailureHandlerInterface'); + $failureHandler + ->expects($ok ? $this->never() : $this->once()) + ->method('onAuthenticationFailure') + ->will($this->returnValue(new Response())) + ; + + $authenticationManager = $this->getMockBuilder('Symfony\Component\Security\Core\Authentication\AuthenticationProviderManager')->disableOriginalConstructor()->getMock(); + $authenticationManager + ->expects($ok ? $this->once() : $this->never()) + ->method('authenticate') + ->will($this->returnValue(new Response())) + ; + + $listener = new UsernamePasswordFormAuthenticationListener( + $this->getMock('Symfony\Component\Security\Core\SecurityContextInterface'), + $authenticationManager, + $this->getMock('Symfony\Component\Security\Http\Session\SessionAuthenticationStrategyInterface'), + $httpUtils, + 'TheProviderKey', + $this->getMock('Symfony\Component\Security\Http\Authentication\AuthenticationSuccessHandlerInterface'), + $failureHandler, + array('require_previous_session' => false) + ); + + $event = $this->getMock('Symfony\Component\HttpKernel\Event\GetResponseEvent', array(), array(), '', false); + $event + ->expects($this->any()) + ->method('getRequest') + ->will($this->returnValue($request)) + ; + + $listener->handle($event); + } + + public function getUsernameForLength() + { + return array( + array(str_repeat('x', SecurityContextInterface::MAX_USERNAME_LENGTH + 1), false), + array(str_repeat('x', SecurityContextInterface::MAX_USERNAME_LENGTH - 1), true), + ); + } +} From c7d9c62c79398f8aa3aae0c7d3a934bb48bfbc9c Mon Sep 17 00:00:00 2001 From: Charles Sarrazin Date: Thu, 18 Feb 2016 12:25:21 +0100 Subject: [PATCH 35/38] Fixed issue with blank password with Ldap The bind operation of LDAP, as described in RFC 4513, provides a method which allows for authentication of users. For the Simple Authentication Method a user may use the anonymous authentication mechanism, the unauthenticated authentication mechanism, or the name/password authentication mechanism. The unauthenticated authentication mechanism is used when a client who desires to establish an anonymous authorization state passes a non-zero length distinguished name and a zero length password. Most LDAP servers either can be configured to allow this mechanism or allow it by default. _Web-based applications which perform the simple bind operation with the client's credentials are at risk when an anonymous authorization state is established. This can occur when the web-based application passes a distinguished name and a zero length password to the LDAP server._ Thus, misconfiguring a server with simple bind can trick Symfony into thinking the username/password tuple as valid, potentially leading to unauthorized access. --- .../LdapBindAuthenticationProvider.php | 4 ++++ .../LdapBindAuthenticationProviderTest.php | 19 ++++++++++++++++++- 2 files changed, 22 insertions(+), 1 deletion(-) diff --git a/src/Symfony/Component/Security/Core/Authentication/Provider/LdapBindAuthenticationProvider.php b/src/Symfony/Component/Security/Core/Authentication/Provider/LdapBindAuthenticationProvider.php index adc42ef3b38f5..e887f99af7963 100644 --- a/src/Symfony/Component/Security/Core/Authentication/Provider/LdapBindAuthenticationProvider.php +++ b/src/Symfony/Component/Security/Core/Authentication/Provider/LdapBindAuthenticationProvider.php @@ -73,6 +73,10 @@ protected function checkAuthentication(UserInterface $user, UsernamePasswordToke $username = $token->getUsername(); $password = $token->getCredentials(); + if ('' === $password) { + throw new BadCredentialsException('The presented password must not be empty.'); + } + try { $username = $this->ldap->escape($username, '', LDAP_ESCAPE_DN); $dn = str_replace('{username}', $username, $this->dnString); diff --git a/src/Symfony/Component/Security/Core/Tests/Authentication/Provider/LdapBindAuthenticationProviderTest.php b/src/Symfony/Component/Security/Core/Tests/Authentication/Provider/LdapBindAuthenticationProviderTest.php index 844bceff019cb..fbb4d733a93c4 100644 --- a/src/Symfony/Component/Security/Core/Tests/Authentication/Provider/LdapBindAuthenticationProviderTest.php +++ b/src/Symfony/Component/Security/Core/Tests/Authentication/Provider/LdapBindAuthenticationProviderTest.php @@ -21,6 +21,23 @@ */ class LdapBindAuthenticationProviderTest extends \PHPUnit_Framework_TestCase { + /** + * @expectedException \Symfony\Component\Security\Core\Exception\BadCredentialsException + * @expectedExceptionMessage The presented password must not be empty. + */ + public function testEmptyPasswordShouldThrowAnException() + { + $userProvider = $this->getMock('Symfony\Component\Security\Core\User\UserProviderInterface'); + $ldap = $this->getMock('Symfony\Component\Ldap\LdapClientInterface'); + $userChecker = $this->getMock('Symfony\Component\Security\Core\User\UserCheckerInterface'); + + $provider = new LdapBindAuthenticationProvider($userProvider, $userChecker, 'key', $ldap); + $reflection = new \ReflectionMethod($provider, 'checkAuthentication'); + $reflection->setAccessible(true); + + $reflection->invoke($provider, new User('foo', null), new UsernamePasswordToken('foo', '', 'key')); + } + /** * @expectedException \Symfony\Component\Security\Core\Exception\BadCredentialsException * @expectedExceptionMessage The presented password is invalid. @@ -40,7 +57,7 @@ public function testBindFailureShouldThrowAnException() $reflection = new \ReflectionMethod($provider, 'checkAuthentication'); $reflection->setAccessible(true); - $reflection->invoke($provider, new User('foo', null), new UsernamePasswordToken('foo', '', 'key')); + $reflection->invoke($provider, new User('foo', null), new UsernamePasswordToken('foo', 'bar', 'key')); } public function testRetrieveUser() From 9a0e29991d5eb186a43680b71487f9c6fba4312c Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Mon, 9 May 2016 14:39:01 -0500 Subject: [PATCH 36/38] fixed bad merge --- .../Tests/DependencyInjection/WebProfilerExtensionTest.php | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/Symfony/Bundle/WebProfilerBundle/Tests/DependencyInjection/WebProfilerExtensionTest.php b/src/Symfony/Bundle/WebProfilerBundle/Tests/DependencyInjection/WebProfilerExtensionTest.php index add171343e438..5eaa95c0a3022 100644 --- a/src/Symfony/Bundle/WebProfilerBundle/Tests/DependencyInjection/WebProfilerExtensionTest.php +++ b/src/Symfony/Bundle/WebProfilerBundle/Tests/DependencyInjection/WebProfilerExtensionTest.php @@ -103,8 +103,6 @@ public function testToolbarConfig($toolbarEnabled, $interceptRedirects, $listene $this->assertSame($listenerEnabled, $this->container->get('web_profiler.debug_toolbar')->isEnabled()); } - $this->assertSame($enabled, $this->container->get('web_profiler.debug_toolbar')->isEnabled()); - $this->assertSaneContainer($this->getDumpedContainer()); } From 4f8c89d1bef5ac4af31c1072676aa9c8da2fe931 Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Mon, 9 May 2016 17:12:58 -0500 Subject: [PATCH 37/38] updated CHANGELOG for 3.0.6 --- CHANGELOG-3.0.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/CHANGELOG-3.0.md b/CHANGELOG-3.0.md index 827f3b4140e46..4d98c24a93e44 100644 --- a/CHANGELOG-3.0.md +++ b/CHANGELOG-3.0.md @@ -7,6 +7,18 @@ in 3.0 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/v3.0.0...v3.0.1 +* 3.0.6 (2016-05-10) + + * security #18736 Fixed issue with blank password with Ldap (csarrazi) + * security #18733 limited the maximum length of a submitted username (fabpot) + * bug #18730 [FrameworkBundle] prevent calling get() for service_container service (xabbuh) + * bug #18705 added a conflict between Monolog bridge 2.8 and HTTP Kernel 3.0+ (fabpot) + * bug #18709 [DependencyInjection] top-level anonymous services must be public (xabbuh) + * bug #18388 [EventDispatcher] check for method to exist (xabbuh) + * bug #18699 [DependencyInjection] Use the priority of service decoration on service with parent (hason) + * bug #18692 add @Event annotation for KernelEvents (Haehnchen) + * bug #18246 [DependencyInjection] fix ambiguous services schema (backbone87) + * 3.0.5 (2016-05-03) * bug #18180 [Form] fixed BC break with pre selection of choices with `ChoiceType` and its children (HeahDude) From 4829ea2b1dc55d76ed27cda2c385c9f5f462a26f Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Mon, 9 May 2016 17:13:13 -0500 Subject: [PATCH 38/38] updated VERSION for 3.0.6 --- src/Symfony/Component/HttpKernel/Kernel.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Symfony/Component/HttpKernel/Kernel.php b/src/Symfony/Component/HttpKernel/Kernel.php index f81f3c5058dae..8dde0e1d8ed3e 100644 --- a/src/Symfony/Component/HttpKernel/Kernel.php +++ b/src/Symfony/Component/HttpKernel/Kernel.php @@ -59,12 +59,12 @@ abstract class Kernel implements KernelInterface, TerminableInterface protected $startTime; protected $loadClassCache; - const VERSION = '3.0.6-DEV'; + const VERSION = '3.0.6'; const VERSION_ID = 30006; const MAJOR_VERSION = 3; const MINOR_VERSION = 0; const RELEASE_VERSION = 6; - const EXTRA_VERSION = 'DEV'; + const EXTRA_VERSION = ''; const END_OF_MAINTENANCE = '07/2016'; const END_OF_LIFE = '01/2017'; pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy