Changelog
phil/menu-bundlePas encore traduite
Cette page n’est pas encore traduite en français ; elle est montrée en anglais.
All notable changes to phil/menu-bundle will be documented in this file.
Updates should follow the Keep a CHANGELOG principles.
0.1.1-alpha - 2026-11-11
Security
MenuItem::withUrl()refuses an address with a backslash, which a browser reads as a slash:/\evil.exampleand\\evil.example, taken for paths of the site, led to evil.example. An address of the web,http:,https:or//, is read byphil/url: one with a user name or a password,https://example.com@evil.example/, whose label says example.com, or whose host is an IP address, is refused.
Added
- The configuration key
allow_localhost,falseby default, also the container parameterphil_menu.allow_localhost, andMenuItem::withUrl($url, allowLocalhost: true): in development and tests, an address onlocalhostor under.localhostis taken; an IP address stays refused.
Changed
Menusreads the path of an address of the site and the visitor's path byphil/url, no longer byparse_url():/games/rules/../about,/games/%2e%2e/aboutand/jeux/théare current at/games/about,/aboutand/jeux/th%C3%A9, the pages a browser asks for.- The package requires
phil/url0.1.3 andsymfony/config8.2, for its configuration key.
0.1.0-alpha - 2026-11-11
Added
MenuItem:map()passes on an item whose children come back the same as it is, and checks the keys of the children only when one of them is renamed;withUrl()refuses an address with a scheme other thanhttp,https,mailtoandtel, such asjavascript:, and one with a space or a control character;withAttribute()refuses a name that is not an attribute name or that starts withon, as event handlers do.Menu,InvalidMenu;MenuBuilder,MenuDecorator,MenuContext;Menus, which parses an address once to tell the current item.PhilMenuBundle, extension aliasphil_menu.MenuExtension, which takes the translator and the URL generator, wired from thetranslatorandrouterservices when the application has them, and builds and decorates a menu once per request and name.BreadcrumbSchemaand the Twig functionmenu_breadcrumb_schema: the breadcrumb as a schema.orgBreadcrumbList, each item named by its translated label, an item with a route given its absolute URL, and an address on the site the request's scheme and host.- The templates
menu.html.twig, whose ancestors of the current item getdata-active-trail,breadcrumb.html.twigandcards.html.twig; their labels in English and French. - The documentation in
doc/, one file per topic, indexed by the README. CONTRIBUTING.md,SECURITY.mdandCODE_OF_CONDUCT.md.