MikeB Posted November 5, 2014 Share Posted November 5, 2014 I have for a while now been trying unsuccessfully to login as another user on my development site, so I can be sure they see what I want them to and check my permissions. I am running version from 11/2/2014 (2.5.7). After clearing cache and cookies I can get in as superuser/admin but not as anyone with my 'manager' role. When I try it gets into a redirect loop. Anyone have any ideas, or similar experience. Tried debugging this but to no avail. If you require more information, let me know what you need and I will get it for you. Here is a screenshot of the permissions page for manager role. Link to comment Share on other sites More sharing options...
RyanJ Posted November 5, 2014 Share Posted November 5, 2014 When I try it gets into a redirect loop. Where are you being redirected to? Is this a custom login page you created? Link to comment Share on other sites More sharing options...
MikeB Posted November 5, 2014 Author Share Posted November 5, 2014 No, just normal login to admin. Here is a screenshot of 'net' tab from from firebug. I have set not redirect, no code, nothing. Just normal prosswire functionality. Link to comment Share on other sites More sharing options...
MikeB Posted November 5, 2014 Author Share Posted November 5, 2014 Sorry, here is the responce from firefox. The page isn't redirecting properlyFirefox has detected that the server is redirecting the request for this address in a way that will never complete. This problem can sometimes be caused by disabling or refusing to accept cookies. I have checked the server, and I see nothing wrong, like i said, i can login as 'me' superuser. I just need to keep clearing broswer cache and cookies. Link to comment Share on other sites More sharing options...
RyanJ Posted November 5, 2014 Share Posted November 5, 2014 Seems to me it has something to due with how your environment is set up. This problem can sometimes be caused by disabling or refusing to accept cookies You mentioned you have to keep clearing your browser cache and cookies. What environment are you working in? Have a look here Link to comment Share on other sites More sharing options...
MikeB Posted November 5, 2014 Author Share Posted November 5, 2014 Thanks, but if the problem was my environment why can I login as the superuser. My environment knows nothing about that, it is internal to processwire. I have tried everything I can think of external, and no luck so far. I am thinking maybe fingerprinting on login/session. Something somewhere is saying, this user only on this machine or at least, redirect other users on this machine and getting the redirect wrong. Pretty sure it never did before, but if it did, then IMO that is not good for development. By the way, link you sent is more Drupal specific, never had this issue on Drupal, but thanks anyway. Link to comment Share on other sites More sharing options...
arjen Posted November 6, 2014 Share Posted November 6, 2014 Have you tried if you have the same problems on a clean PW 2.5.7 install? Also, if you create a new user with the same role and you try to login with a different browser (or incognito), what happens then? Link to comment Share on other sites More sharing options...
MikeB Posted November 6, 2014 Author Share Posted November 6, 2014 Tried new user with same role, and diffrent browsers (I always test everything on Firefox, Chrome, IE and Safari) Just tried incognito and same results. I had also given manager role permission to edit at the top level "Home" template, in case it was a permission issue. That should cascade down to everywhere unless excplicitly set further down the heirachy. Only thing left to test is a blank install of 2.5.7 thats up next. Let you know how that goes soon. Link to comment Share on other sites More sharing options...
MikeB Posted November 6, 2014 Author Share Posted November 6, 2014 OK here is what I did. Download new copy of 2.5.7 and install with intermediate profile. Create a manager role and assign edit permission. Assign manager edit on Home template. Create new user with manager role. Logout, then login with new user. Viola!! It worked. So now what? Where could this be going wrong. I wonder about the following: Admin Theme, real dev site uses Reno Dashboard module No idea what else it could be, will try now and remove the dashboard module, then change admin theme, then start remove modules one by one based on relevance to the site. Link to comment Share on other sites More sharing options...
MikeB Posted November 6, 2014 Author Share Posted November 6, 2014 OK have tried with removing a number of modules that I have installed recently for SEO and redirects and maintenance mode and anything else that could be messing with logins. Nothing works. Not sure what my next steps should be now, short of starting again, rebuild the site from a clean install. Checking all the way that the manager role is useable. Link to comment Share on other sites More sharing options...
arjen Posted November 6, 2014 Share Posted November 6, 2014 You could try to update to the latest dev version (since the latest seems to work) or downgrade to the latest stable. See what happens then. Link to comment Share on other sites More sharing options...
MikeB Posted November 7, 2014 Author Share Posted November 7, 2014 Finally got this fixed, however I was stupid and did 2 things at once without testing between. Just goes to prove i am really not a developer, my bad. Any way, I removed "Dashboard" module but it left the page in place, and also the page "admin" then had no process attached, checked with my clean install and added back the ProcessHome. I think when Dashboard is installed it changes that to ProcessDashboard but does not change back on uninstall. I then updated to 2.5.8, and finally tested and it works, can now login to backend as anyone with manager role. I guess to finally put this issue to bed I should role back and test if the fix was removing Dashboard module or upgrading to 2.5.8. Please note, removing Dashboard did not create the issue in the first place, as it's removal was one of my steps to fix the issue. Link to comment Share on other sites More sharing options...
MikeB Posted November 19, 2014 Author Share Posted November 19, 2014 I have for sometime now been unable to login as a test user to verify what my real users will see. I get an error telling me: The page isn't redirecting properlyFirefox has detected that the server is redirecting the request for this address in a way that will never complete. I did have this same problem a while ago, and it was seemingly fixed by updating to 2.5.8 but has subsequently returned. I have tried removing some modules that could impact logins and sessions, testing after each one is removed but still to no avail. Have also set sessionFingerprint and sessionChallenge to false and still no go. I can login as superuser no problem, but as soon as I try with an account with another role I get that message. Also once i have done that any attempt to get to admin page sends same error. have to clear the cache/cookies and everything else to get back to normal. Does anyone else have this probem, could someone please try and let me know. For the life of me I can not see what is causing the issue. Link to comment Share on other sites More sharing options...
MikeB Posted November 19, 2014 Author Share Posted November 19, 2014 (edited) Oppps sorry I forgot I already had an issue open about this, see https://processwire.com/talk/topic/8182-unable-to-login-as-any-user-other-then-superuser/ Though that states i had it fixed, but now that is no longer true. Edited November 19, 2014 by kongondo Mod edit: Merged topics... Link to comment Share on other sites More sharing options...
MikeB Posted November 21, 2014 Author Share Posted November 21, 2014 Have just downloaded new version of processwire dev, then emptied cache, sessions on the database. Tried login as superuser, and get the same message. The page isn't redirecting properlyFirefox has detected that the server is redirecting the request for this address in a way that will never complete. This problem can sometimes be caused by disabling or refusing to accept cookies. Have checked and cookies are stored. See screenshot. Checked the single entry in session and here is the output. Session|a:3:{s:5:"_user";a:2:{s:2:"id";i:41;s:2:"ts";i:1416583150;}s:27:"ProcessWireUpgrade_branches";a:2:{s:3:"dev";a:5:{s:4:"name";s:3:"dev";s:5:"title";s:11:"Development";s:6:"zipURL";s:63:"https://github.com/ryancramerdesign/ProcessWire/archive/dev.zip";s:7:"version";s:5:"2.5.8";s:10:"versionURL";s:92:"https://raw.githubusercontent.com/ryancramerdesign/ProcessWire/dev/wire/core/ProcessWire.php";}s:6:"master";a:5:{s:4:"name";s:6:"master";s:5:"title";s:13:"Stable/Master";s:6:"zipURL";s:66:"https://github.com/ryancramerdesign/ProcessWire/archive/master.zip";s:7:"version";s:5:"2.5.3";s:10:"versionURL";s:95:"https://raw.githubusercontent.com/ryancramerdesign/ProcessWire/master/wire/core/ProcessWire.php";}}s:7:"message";a:4:{i:0;a:2:{i:0;s:29:"mbrett5062 - Successful login";i:1;i:0;}i:1;a:2:{i:0;s:35:"Your ProcessWire core is up-to-date";i:1;i:0;}i:2;a:2:{i:0;s:27:"Your modules are up-to-date";i:1;i:0;}i:3;a:2:{i:0;s:48:"Saved cache - ProcessWireUpgradeCheck_loginHook";i:1;i:2;}}} As you can see it says i am succesfully logged in. But the page redirect is not working, gets caught in a loop. Previuosly I could login as superuser, but not manager. Now I can not login at all. Link to comment Share on other sites More sharing options...
MikeB Posted November 21, 2014 Author Share Posted November 21, 2014 Finally got that fixed. I had downloaded and installed "AdminRestrictPageTree" and assigned to "guest" and "manager". I assumed it would just hide the actual full tree leaving my listerpro lists of pages i want managers to be able to edit. No idea why guest is in there as they can not access that page anyway. Instead it rendered everyone unable to login due to a page redirect loop. I guess the issue was my own fault, I did not have a page to redirect them to, as I did not understand it was going to stop them getting to the admin page altogether. Guess that will teach me to be sure i know what i am doing with contributed modules. Have removed that module now after editing database to remove restricted roles and once again gaining access to the site admin. I guess the reason I could no longer get in was due to the guest role being added to restricted users. 4 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now