Merge branch '3.1'

* 3.1:
  [travis] Use hhvm-stable instead of discontinued hhvm-3.12
  bumped Symfony version to 3.1.6
  updated VERSION for 3.1.5
  updated CHANGELOG for 3.1.5
  bumped Symfony version to 2.8.13
  updated VERSION for 2.8.12
  updated CHANGELOG for 2.8.12
  bumped Symfony version to 2.7.20
  updated VERSION for 2.7.19
  update CONTRIBUTORS for 2.7.19
  updated CHANGELOG for 2.7.19
  [Validator] Url validator not validating hosts ending in a number
This commit is contained in:
Nicolas Grekas 2016-10-04 11:33:03 +02:00
commit 3ad5b2918d
5 changed files with 89 additions and 36 deletions

View File

@ -20,7 +20,7 @@ env:
matrix:
include:
# Use the newer stack for HHVM as HHVM does not support Precise anymore since a long time and so Precise has an outdated version
- php: hhvm-3.12
- php: hhvm-stable
sudo: required
dist: trusty
group: edge

View File

@ -7,6 +7,51 @@ in 3.1 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.1.0...v3.1.1
* 3.1.5 (2016-10-03)
* bug #20102 [Validator] Url validator not validating hosts ending in a number (gwkunze)
* bug #20132 Use "more entropy" option for uniqid() (javiereguiluz)
* bug #20122 [Validator] Reset constraint options (ro0NL)
* bug #20116 fixed AddConstraintValidatorsPass config (fabpot)
* bug #20078 Fix #19943 Make sure to process each interface metadata only once (lemoinem)
* bug #20080 [Form] compound forms without children should be considered rendered implicitly (backbone87)
* bug #20087 [VarDumper] Fix PHP 7.1 compat (nicolas-grekas)
* bug #20086 [VarDumper] Fix PHP 7.1 compat (nicolas-grekas)
* bug #20077 [Process] silent file operation to avoid open basedir issues (xabbuh)
* bug #20079 fixed Twig support for 1.26 and 2.0 (fabpot)
* bug #20051 Fix indexBy type extraction (lemoinem)
* bug #19951 [Finder] Trim trailing directory slash in ExcludeDirectoryFilterIterator (ro0NL)
* bug #19980 [Ldap] Fixed issue with legacy find() method not working as expected (csarrazi)
* bug #20026 [Cache] Fixed password used to make the redis connection. (ErikSaunier)
* bug #20018 [VarDumper] Fix test (nicolas-grekas)
* bug #20011 Use UUID for error codes for Form validator. (Koc)
* bug #20010 [DX] Fixed regression when exception message swallowed when logging it. (Koc)
* bug #19983 [TwigBridge] removed Twig null nodes (deprecated as of Twig 1.25) (fabpot)
* bug #19946 [Console] Fix parsing optionnal options with empty value in argv (chalasr)
* bug #19636 [Finder] no PHP warning on empty directory iteration (ggottwald)
* bug #19784 [HttpKernel] Fixed the nullable support for php 7.1 and below (iltar)
* bug #19923 [bugfix] [Console] Set `Input::$interactive` to `false` when command is executed with `--quiet` as verbosity level (phansys)
* bug #19811 Fixed the nullable support for php 7.1 and below (2.7, 2.8, 3.0) (iltar)
* bug #19853 [PropertyInfo] Make ReflectionExtractor compatible with ReflectionType changes in PHP 7.1 (teohhanhui)
* bug #19904 [Form] Fixed collapsed ChoiceType options attributes (HeahDude)
* bug #19872 [Filesystem] Consider the umask setting when dumping a file (leofeyer)
* bug #19908 [Config] Handle open_basedir restrictions in FileLocator (Nicofuma)
* bug #19893 [FrameworkBundle] Remove cache clearer default value in config (nicolas-grekas)
* bug #19924 [DoctrineBridge][PropertyInfo] Treat Doctrine decimal type as string (teohhanhui)
* bug #19932 Fixed bad merge (GrahamCampbell)
* bug #19922 [Yaml][TwigBridge] Use JSON_UNESCAPED_SLASHES for lint commands output (chalasr)
* bug #19928 [Validator] Update IpValidatorTest data set with a valid reserved IP (jakzal)
* bug #19813 [Console] fixed PHP7 Errors are now handled and converted to Exceptions (fonsecas72)
* bug #19879 [Form] Incorrect timezone with DateTimeLocalizedStringTransformer (mbeccati)
* bug #19878 Fix translation:update command count (tgalopin)
* bug #19859 [ClassLoader] Fix ClassCollectionLoader inlining with declare(strict_types=1) (nicolas-grekas)
* bug #19780 [FrameworkBundle] Incorrect line break in exception message (500 debug page) (pedroresende)
* bug #19595 [form] lazy trans `post_max_size_message`. (aitboudad)
* bug #19870 [DI] Fix setting synthetic services on ContainerBuilder (nicolas-grekas)
* bug #19848 Revert "minor #19689 [DI] Cleanup array_key_exists (ro0NL)" (nicolas-grekas)
* bug #19842 [FrameworkBundle] Check for class existence before is_subclass_of (chalasr)
* bug #19827 [BrowserKit] Fix cookie expiration on 32 bit systems (jameshalsall)
* 3.1.4 (2016-09-03)
* bug #19812 [WebProfilerBundle] Fix margin on toolbar route panel when no route is found in the request (jameshalsall)

View File

@ -16,8 +16,8 @@ Symfony is the result of the work of many people who made the code better
- Kris Wallsmith (kriswallsmith)
- Jakub Zalas (jakubzalas)
- Ryan Weaver (weaverryan)
- Javier Eguiluz (javier.eguiluz)
- Kévin Dunglas (dunglas)
- Javier Eguiluz (javier.eguiluz)
- Hugo Hamon (hhamon)
- Abdellatif Ait boudad (aitboudad)
- Pascal Borreli (pborreli)
@ -35,8 +35,8 @@ Symfony is the result of the work of many people who made the code better
- Eriksen Costa (eriksencosta)
- Sarah Khalil (saro0h)
- Jules Pietri (heah)
- Jonathan Wage (jwage)
- Maxime Steinhausser (ogizanagi)
- Jonathan Wage (jwage)
- Diego Saint Esteben (dosten)
- Alexandre Salomé (alexandresalome)
- William Durand (couac)
@ -49,22 +49,22 @@ Symfony is the result of the work of many people who made the code better
- Henrik Bjørnskov (henrikbjorn)
- Miha Vrhovnik
- Diego Saint Esteben (dii3g0)
- Ener-Getick (energetick)
- Konstantin Kudryashov (everzet)
- Bilal Amarni (bamarni)
- Florin Patan (florinpatan)
- Ener-Getick (energetick)
- Peter Rehm (rpet)
- Iltar van der Berg (kjarli)
- Robin Chalas (chalas_r)
- Kevin Bond (kbond)
- Andrej Hudec (pulzarraider)
- Gábor Egyed (1ed)
- Michel Weimerskirch (mweimerskirch)
- Eric Clemmons (ericclemmons)
- Charles Sarrazin (csarrazi)
- Matthias Pigulla (mpdude)
- Christian Raue
- Arnout Boks (aboks)
- Charles Sarrazin (csarrazi)
- Robin Chalas (chalas_r)
- Deni
- Henrik Westphal (snc)
- Dariusz Górecki (canni)
@ -72,22 +72,22 @@ Symfony is the result of the work of many people who made the code better
- Lee McDermott
- Brandon Turner
- Luis Cordova (cordoval)
- Graham Campbell (graham)
- Titouan Galopin (tgalopin)
- Daniel Holmes (dholmes)
- Pierre du Plessis (pierredup)
- Konstantin Myakshin (koc)
- Bart van den Burg (burgov)
- Jordan Alliot (jalliot)
- Graham Campbell (graham)
- John Wards (johnwards)
- Toni Uebernickel (havvg)
- Fran Moreno (franmomu)
- Antoine Hérault (herzult)
- Paráda József (paradajozsef)
- Arnaud Le Blanc (arnaud-lb)
- Jérôme Tamarelle (gromnan)
- Paráda József (paradajozsef)
- Titouan Galopin (tgalopin)
- Michal Piotrowski (eventhorizon)
- Tim Nagel (merk)
- Konstantin Myakshin (koc)
- Brice BERNARD (brikou)
- Alexander M. Turek (derrabus)
- Dariusz Ruminski
@ -105,6 +105,7 @@ Symfony is the result of the work of many people who made the code better
- excelwebzone
- Jacob Dreesen (jdreesen)
- Jáchym Toušek (enumag)
- Roland Franssen (ro0)
- Jérémy DERUSSÉ (jderusse)
- Vladimir Reznichenko (kalessil)
- Tomáš Votruba (tomas_votruba)
@ -112,6 +113,7 @@ Symfony is the result of the work of many people who made the code better
- Gordon Franke (gimler)
- Eric GELOEN (gelo)
- David Buchmann (dbu)
- Tugdual Saunier (tucksaun)
- Théo FIDRY (theofidry)
- Robert Schönthal (digitalkaoz)
- Florian Lonqueu-Brochard (florianlb)
@ -123,7 +125,6 @@ Symfony is the result of the work of many people who made the code better
- Daniel Gomes (danielcsgomes)
- Hidenori Goto (hidenorigoto)
- Sebastiaan Stok (sstok)
- Tugdual Saunier (tucksaun)
- Guilherme Blanco (guilhermeblanco)
- Pablo Godel (pgodel)
- Jérémie Augustin (jaugustin)
@ -133,6 +134,7 @@ Symfony is the result of the work of many people who made the code better
- Joel Wurtz (brouznouf)
- Philipp Wahala (hifi)
- Vyacheslav Pavlov
- Javier Spagnoletti (phansys)
- Richard Shank (iampersistent)
- Thomas Rabaix (rande)
- Vincent AUBERT (vincent)
@ -144,10 +146,10 @@ Symfony is the result of the work of many people who made the code better
- Richard van Laak (rvanlaak)
- Matthieu Ouellette-Vachon (maoueh)
- Michał Pipa (michal.pipa)
- Javier Spagnoletti (phansys)
- Amal Raghav (kertz)
- Jonathan Ingram (jonathaningram)
- Artur Kotyrba
- Teoh Han Hui (teohhanhui)
- Warnar Boekkooi (boekkooi)
- Dmitrii Chekaliuk (lazyhammer)
- Clément JOBEILI (dator)
@ -158,11 +160,12 @@ Symfony is the result of the work of many people who made the code better
- Mario A. Alvarez Garcia (nomack84)
- Dennis Benkert (denderello)
- Benjamin Dulau (dbenjamin)
- Mathieu Lemoine (lemoinem)
- Andreas Hucks (meandmymonkey)
- Noel Guilbert (noel)
- Yonel Ceruto González (yonelceruto)
- Stepan Anchugov (kix)
- bronze1man
- Roland Franssen (ro0)
- sun (sun)
- Larry Garfield (crell)
- Martin Schuhfuß (usefulthink)
@ -188,14 +191,13 @@ Symfony is the result of the work of many people who made the code better
- Dawid Nowak
- Eugene Wissner
- Julien Brochet (mewt)
- Yonel Ceruto González (yonelceruto)
- jeremyFreeAgent (jeremyfreeagent)
- Sergey Linnik (linniksa)
- Michaël Perrin (michael.perrin)
- Marcel Beerta (mazen)
- Loïc Faugeron
- Jannik Zschiesche (apfelbox)
- Marco Pivetta (ocramius)
- Teoh Han Hui (teohhanhui)
- julien pauli (jpauli)
- Michael Lee (zerustech)
- Lorenz Schori
@ -216,6 +218,7 @@ Symfony is the result of the work of many people who made the code better
- Xavier Perez
- Arjen Brouwer (arjenjb)
- Katsuhiro OGAWA
- James Halsall (jaitsu)
- Alif Rachmawadi
- Kristen Gilden (kgilden)
- Pierre-Yves LEBECQ (pylebecq)
@ -226,10 +229,10 @@ Symfony is the result of the work of many people who made the code better
- Joseph Rouff (rouffj)
- Félix Labrecque (woodspire)
- GordonsLondon
- jeremyFreeAgent (jeremyfreeagent)
- Jan Sorgalla (jsor)
- Ray
- Grégoire Paris (greg0ire)
- Leo Feyer
- Chekote
- Tobias Nyholm (tobias)
- Thomas Adam
@ -252,12 +255,14 @@ Symfony is the result of the work of many people who made the code better
- Peter Kruithof (pkruithof)
- Michael Holm (hollo)
- Marc Weistroff (futurecat)
- SpacePossum
- Hidde Wieringa (hiddewie)
- Chris Smith (cs278)
- Florian Klein (docteurklein)
- Oleg Voronkovich
- Manuel Kiessling (manuelkiessling)
- Daniel Wehner
- Tristan Darricau (nicofuma)
- Atsuhiro KUBO (iteman)
- Andrew Moore (finewolf)
- Bertrand Zuchuat (garfield-fr)
@ -266,7 +271,6 @@ Symfony is the result of the work of many people who made the code better
- Thomas Tourlourat (armetiz)
- Andrey Esaulov (andremaha)
- Grégoire Passault (gregwar)
- Leo Feyer
- Ismael Ambrosi (iambrosi)
- Uwe Jäger (uwej711)
- Aurelijus Valeiša (aurelijus)
@ -315,14 +319,11 @@ Symfony is the result of the work of many people who made the code better
- JhonnyL
- hossein zolfi (ocean)
- Clément Gautier (clementgautier)
- James Halsall (jaitsu)
- Eduardo Gulias (egulias)
- giulio de donato (liuggio)
- Stéphane PY (steph_py)
- Philipp Kräutli (pkraeutli)
- Kirill chEbba Chebunin (chebba)
- Tristan Darricau (nicofuma)
- SpacePossum
- Greg Thornton (xdissent)
- Costin Bereveanu (schniper)
- Loïc Chardonnet (gnusat)
@ -390,13 +391,13 @@ Symfony is the result of the work of many people who made the code better
- Christian Schmidt
- Marcin Sikoń (marphi)
- Dominik Zogg (dominik.zogg)
- Maxime STEINHAUSSER
- Marek Pietrzak
- Chad Sikorra (chadsikorra)
- Mathieu Lemoine
- franek (franek)
- Christian Wahler
- Mathieu Lemoine
- Gintautas Miselis
- Rob Bast
- David Badura (davidbadura)
- Zander Baldwin
- Adam Harvey
@ -414,6 +415,7 @@ Symfony is the result of the work of many people who made the code better
- Sebastian Bergmann
- Pablo Díez (pablodip)
- Kevin McBride
- Sergio Santoro
- Philipp Rieber (bicpi)
- Manuel de Ruiter (manuel)
- Eduardo Oliveira (entering)
@ -545,10 +547,10 @@ Symfony is the result of the work of many people who made the code better
- Luc Vieillescazes (iamluc)
- Johann Saunier (prophet777)
- Antoine Corcy
- Rob Bast
- Artur Eshenbrener
- Arturs Vonda
- Sascha Grossenbacher
- David Maicher (dmaicher)
- Szijarto Tamas
- Catalin Dan
- Stephan Vock
@ -559,9 +561,10 @@ Symfony is the result of the work of many people who made the code better
- Tristan Roussel
- Cameron Porter
- Hossein Bukhamsin
- Oliver Hoff
- Disparity
- origaminal
- Maxime STEINHAUSSER
- Matteo Beccati (matteobeccati)
- Paweł Wacławczyk (pwc)
- Oleg Zinchenko (cystbear)
- Johannes Klauss (cloppy)
@ -581,7 +584,6 @@ Symfony is the result of the work of many people who made the code better
- Michael Piecko
- yclian
- twifty
- Sergio Santoro
- Peter Ward
- Dominik Ritter (dritter)
- Sebastian Grodzicki (sgrodzicki)
@ -604,6 +606,7 @@ Symfony is the result of the work of many people who made the code better
- Andrew Tchircoff (andrewtch)
- michaelwilliams
- 1emming
- Victor Bocharsky (bocharsky_bw)
- Leevi Graham (leevigraham)
- Casper Valdemar Poulsen
- Josiah (josiah)
@ -651,6 +654,7 @@ Symfony is the result of the work of many people who made the code better
- Fabian Vogler (fabian)
- Korvin Szanto
- Alaattin Kahramanlar (alaattin)
- Sergey Zolotov (enleur)
- Maksim Kotlyar (makasim)
- Neil Ferreira
- Nathanael Noblet (gnat)
@ -722,6 +726,7 @@ Symfony is the result of the work of many people who made the code better
- Benoît Merlet (trompette)
- Koen Kuipers
- datibbaw
- Erik Saunier (snickers)
- Rootie
- Raul Fraile (raulfraile)
- sensio
@ -731,6 +736,7 @@ Symfony is the result of the work of many people who made the code better
- Mátyás Somfai (smatyas)
- stefan.r
- Valérian Galliat
- Rikijs Murgs
- Alexandru Furculita (afurculita)
- Ben Ramsey (ramsey)
- Christian Jul Jensen
@ -810,6 +816,7 @@ Symfony is the result of the work of many people who made the code better
- Benjamin Paap (benjaminpaap)
- Christian
- Sergii Smertin (nfx)
- hugofonseca (fonsecas72)
- Bailey Parker
- Eddie Jaoude
- Haritz Iturbe (hizai)
@ -837,7 +844,6 @@ Symfony is the result of the work of many people who made the code better
- Rodrigo Díez Villamuera (rodrigodiez)
- e-ivanov
- Jochen Bayer (jocl)
- Matteo Beccati (matteobeccati)
- Jeremy Bush
- wizhippo
- Viacheslav Sychov
@ -887,7 +893,6 @@ Symfony is the result of the work of many people who made the code better
- Christian Sciberras
- Clement Herreman (clemherreman)
- Dan Ionut Dumitriu (danionut90)
- David Maicher (dmaicher)
- Nyro (nyro)
- Marco
- Marc Torres
@ -983,7 +988,6 @@ Symfony is the result of the work of many people who made the code better
- Tadcka
- Beth Binkovitz
- Romain Geissler
- Oliver Hoff
- Tomaz Ahlin
- Benjamin Cremer (bcremer)
- Marcus Stöhr (dafish)
@ -1012,6 +1016,7 @@ Symfony is the result of the work of many people who made the code better
- BilgeXA
- r1pp3rj4ck
- Robert Queck
- Peter Bouwdewijn
- mlively
- Amine Matmati
- Fabian Steiner (fabstei)
@ -1040,6 +1045,7 @@ Symfony is the result of the work of many people who made the code better
- Konrad Mohrfeldt
- Lance Chen
- Andrey Astakhov (aast)
- Andrew (drew)
- Nikolay Labinskiy (e-moe)
- kor3k kor3k (kor3k)
- Stelian Mocanita (stelian)
@ -1203,7 +1209,6 @@ Symfony is the result of the work of many people who made the code better
- J Bruni
- Alexey Prilipko
- bertillon
- Victor Bocharsky (bocharsky_bw)
- Yannick Bensacq (cibou)
- Luca Genuzio (genuzio)
- Hans Nilsson (hansnilsson)
@ -1236,6 +1241,7 @@ Symfony is the result of the work of many people who made the code better
- Julien DIDIER (juliendidier)
- Martin Mayer (martin)
- Grzegorz Łukaszewicz (newicz)
- Götz Gottwald
- Veres Lajos
- grifx
- Robert Campbell
@ -1462,8 +1468,8 @@ 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)
- Fabien Bourigault (fbourigault)
- Carsten Eilers (fnc)
- Sorin Gitlan (forapathy)
- Yohan Giarelli (frequence-web)
@ -1498,6 +1504,7 @@ Symfony is the result of the work of many people who made the code better
- Paul Andrieux (paulandrieux)
- Paweł Szczepanek (pauluz)
- Philippe Degeeter (pdegeeter)
- Pedro Miguel Maymone de Resende (pedroresende)
- Christian López Espínola (penyaskito)
- Petr Jaroš (petajaros)
- Philipp Hoffmann (philipphoffmann)
@ -1522,6 +1529,7 @@ Symfony is the result of the work of many people who made the code better
- Moritz Kraft (userfriendly)
- Víctor Mateo (victormateo)
- Vincent (vincent1870)
- Valentin Udaltsov (vudaltsov)
- Eugene Babushkin (warl)
- Wouter Sioen (wouter_sioen)
- Xavier Amado (xamado)
@ -1559,6 +1567,5 @@ Symfony is the result of the work of many people who made the code better
- Pierre Geyer (ptheg)
- Sam Fleming (sam_fleming)
- Thomas BERTRAND (sevrahk)
- Erik Saunier (snickers)
- Matej Žilák (teo_sk)
- Vladislav Vlastovskiy (vlastv)

View File

@ -24,13 +24,13 @@ class UrlValidator extends ConstraintValidator
(%s):// # protocol
(([\pL\pN-]+:)?([\pL\pN-]+)@)? # basic auth
(
([\pL\pN\pS-\.])+(\.?([\pL]|xn\-\-[\pL\pN-]+)+\.?) # a domain name
| # or
\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3} # a IP address
| # or
([\pL\pN\pS-\.])+(\.?([\pL\pN]|xn\-\-[\pL\pN-]+)+\.?) # a domain name
| # or
\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3} # an IP address
| # or
\[
(?:(?:(?:(?:(?:(?:(?:[0-9a-f]{1,4})):){6})(?:(?:(?:(?:(?:[0-9a-f]{1,4})):(?:(?:[0-9a-f]{1,4})))|(?:(?:(?:(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9]))\.){3}(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9])))))))|(?:(?:::(?:(?:(?:[0-9a-f]{1,4})):){5})(?:(?:(?:(?:(?:[0-9a-f]{1,4})):(?:(?:[0-9a-f]{1,4})))|(?:(?:(?:(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9]))\.){3}(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9])))))))|(?:(?:(?:(?:(?:[0-9a-f]{1,4})))?::(?:(?:(?:[0-9a-f]{1,4})):){4})(?:(?:(?:(?:(?:[0-9a-f]{1,4})):(?:(?:[0-9a-f]{1,4})))|(?:(?:(?:(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9]))\.){3}(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9])))))))|(?:(?:(?:(?:(?:(?:[0-9a-f]{1,4})):){0,1}(?:(?:[0-9a-f]{1,4})))?::(?:(?:(?:[0-9a-f]{1,4})):){3})(?:(?:(?:(?:(?:[0-9a-f]{1,4})):(?:(?:[0-9a-f]{1,4})))|(?:(?:(?:(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9]))\.){3}(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9])))))))|(?:(?:(?:(?:(?:(?:[0-9a-f]{1,4})):){0,2}(?:(?:[0-9a-f]{1,4})))?::(?:(?:(?:[0-9a-f]{1,4})):){2})(?:(?:(?:(?:(?:[0-9a-f]{1,4})):(?:(?:[0-9a-f]{1,4})))|(?:(?:(?:(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9]))\.){3}(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9])))))))|(?:(?:(?:(?:(?:(?:[0-9a-f]{1,4})):){0,3}(?:(?:[0-9a-f]{1,4})))?::(?:(?:[0-9a-f]{1,4})):)(?:(?:(?:(?:(?:[0-9a-f]{1,4})):(?:(?:[0-9a-f]{1,4})))|(?:(?:(?:(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9]))\.){3}(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9])))))))|(?:(?:(?:(?:(?:(?:[0-9a-f]{1,4})):){0,4}(?:(?:[0-9a-f]{1,4})))?::)(?:(?:(?:(?:(?:[0-9a-f]{1,4})):(?:(?:[0-9a-f]{1,4})))|(?:(?:(?:(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9]))\.){3}(?:(?:25[0-5]|(?:[1-9]|1[0-9]|2[0-4])?[0-9])))))))|(?:(?:(?:(?:(?:(?:[0-9a-f]{1,4})):){0,5}(?:(?:[0-9a-f]{1,4})))?::)(?:(?:[0-9a-f]{1,4})))|(?:(?:(?:(?:(?:(?:[0-9a-f]{1,4})):){0,6}(?:(?:[0-9a-f]{1,4})))?::))))
\] # a IPv6 address
\] # an IPv6 address
)
(:[0-9]+)? # a port (optional)
(/?|/\S+|\?\S*|\#\S*) # a /, nothing, a / with something, a query or a fragment

View File

@ -85,6 +85,7 @@ class UrlValidatorTest extends ConstraintValidatorTestCase
array('http://www.symfony.com/doc/current/book/validation.html#supported-constraints'),
array('http://very.long.domain.name.com/'),
array('http://localhost/'),
array('http://myhost123/'),
array('http://127.0.0.1/'),
array('http://127.0.0.1:80/'),
array('http://[::1]/'),