This site has been archived and you can no longer log in or post new messages. For up-to-date community resources please visit ezplatform.com

eZ Community » Forums » eZ Publish 5 Platform » Auth routes are /user/login instead...
expandshrink

Auth routes are /user/login instead of /login in eZ Publish 5.3

Auth routes are /user/login instead of /login in eZ Publish 5.3

Wednesday 19 November 2014 12:56:47 pm - 4 replies

Hey, guys

I'm working with a eZ Publish installation we recently upgraded to the 5 stack from eZ Publish 4. All views are written in using eZ Publish legacy template language, so we pass all siteaccesses through to the legacy kernel. This is what we've done for all sites we've upgraded from 4 to 5.

The difference here is that the new auth route to /login, /login_check and /logout does not work. We have to apply htaccess rewrites to /user/login, etc. I'm suspecting that this may have to do with some kind of legacy settings we are overlooking. Anyone experienced something like that?

Please let me know if you need more information to assess the issue. 

Thanks in advanced. 

Wednesday 19 November 2014 1:02:32 pm

How are you linking to your login pages? 

Anyway, my advice here would be use symfony login form instead of the old legacy one.

Wednesday 19 November 2014 3:10:37 pm

Hey, Carlos

This is the route eZ redirects to when a user tries to access protected content. This is why I think it might be caused by some kind of eZ legacy setting. 

Thomas

Thursday 20 November 2014 11:30:31 am

Hi Thomas

Are you using 5.3 EE? If so are you up to date (last maintenance release is 5.3.3) ?

Tuesday 25 November 2014 8:36:04 am

Hi, Jérôme

Thank you for answering. Yes, the site is running EE, and was on 5.3.0 as of yesterday. I then patched it to 5.3.3, but that did not change the auth routes. Looking at output from router:debug, I noticed the site has routes named _ezpublishLegacyLogin and _ezpublishLegacyLogout, which I cannot find on other sites I've upgraded. These all point to /user/{ACTION}/. At the same time, the new Symfony auth routes are correctly pointing to /login, /login_check and /logout, but does result in an "module not found" error. We run the frontend_group with legacy_mode: true.

Anyone experienced something like this before?

We also got a new error after applying the patch. This one is also new, and we experience it both live and in our dev environment. The error message is "Failed to start the session: already started by PHP ($_SESSION is set).". We squelched the exception by changing the file vendor/symfony/symfony/src/Symfony/Component/HttpFoundation/Session/Storage/NativeSessionStorage.php, commenting out the exception on line 139. I believe we are also getting this one due to some legacy setting that differs from the Symfony config.

Here's the full exception, with some paths tweaked:

[2014-11-25 08:11:04] request.CRITICAL: Uncaught PHP Exception RuntimeException: "Failed to start the session: already started by PHP ($_SESSION is set)." at /mnt/data/....../ezpublish/cache/prod/classes.php line 100 {"exception":"[object] (RuntimeException: Failed to start the session: already started by PHP ($_SESSION is set). at /mnt/data/....../ezpublish/cache/prod/classes.php:100)"} []

expandshrink

You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu

Proudly Developed with from