ezsystems/ezpublish-kernel — pull request #947 by lolautruche (2014-07-31 13:57:46+00:00)
Title: Fix EZP-23210: Exception thrown when using alternative user provider/login handler

> https://jira.ez.no/browse/EZP-23210

When accessing to a protected resource, Symfony Security component generates a RedirectResponse to
the configured `login_path` (default being `/login`. This path can actually be an URI, but also a *route name*.
Some authentication *extensions* like `FOSUserBundle` use that.

Of course, when a route name is used, the UrlGenerator is called, with the route name and **all the request
attributes as parameters**. The problem is that the current SiteAccess object is stored as `siteaccess` request attribute,
which has the effect to trigger reverse SiteAccess matching, which is of course not an expected behavior.