Login bug in ispconfig 3.1 beta [solved]

Discussion in 'Installation/Configuration' started by Florian, Apr 22, 2016.

  1. Florian

    Florian New Member

    Hello there!
    I upgraded using the blog post instructions, but I cannot login anymore, I always get back to the login screen

    My server is ubuntu 15.10
    I tried latest Chrome and firefox for mac OsX, in private browsing or normal

    The console is showing
    Navigated to https://vps156534.ovh.net:8080/login/
    jquery.min.js:4 GET https://vps156534.ovh.net:8080/login/dashboard/dashboard.php 404 (Not Found)k.cors.a.crossDomain.send @ jquery.min.js:4n.extend.ajax @ jquery.min.js:4ISPConfig.loadInitContent @ ispconfig.min.js:1(anonymous function) @ ispconfig.min.js:1n.event.dispatch @ jquery.min.js:3r.handle @ jquery.min.js:3n.event.trigger @ jquery.min.js:3n.fn.extend.triggerHandler @ jquery.min.js:3n.extend.ready @ jquery.min.js:2I @ jquery.min.js:2
    jquery.min.js:4 GET https://vps156534.ovh.net:8080/login/nav.php?nav=side 404 (Not Found)k.cors.a.crossDomain.send @ jquery.min.js:4n.extend.ajax @ jquery.min.js:4ISPConfig.loadMenus @ ispconfig.min.js:1ISPConfig.loadInitContent @ ispconfig.min.js:1(anonymous function) @ ispconfig.min.js:1n.event.dispatch @ jquery.min.js:3r.handle @ jquery.min.js:3n.event.trigger @ jquery.min.js:3n.fn.extend.triggerHandler @ jquery.min.js:3n.extend.ready @ jquery.min.js:2I @ jquery.min.js:2
    jquery.min.js:4 GET https://vps156534.ovh.net:8080/login/nav.php?nav=top 404 (Not Found)k.cors.a.crossDomain.send @ jquery.min.js:4n.extend.ajax @ jquery.min.js:4ISPConfig.loadMenus @ ispconfig.min.js:1ISPConfig.loadInitContent @ ispconfig.min.js:1(anonymous function) @ ispconfig.min.js:1n.event.dispatch @ jquery.min.js:3r.handle @ jquery.min.js:3n.event.trigger @ jquery.min.js:3n.fn.extend.triggerHandler @ jquery.min.js:3n.extend.ready @ jquery.min.js:2I @ jquery.min.js:2
    jquery.min.js:4 GET https://vps156534.ovh.net:8080/login/keepalive.php 404 (Not Found)k.cors.a.crossDomain.send @ jquery.min.js:4n.extend.ajax @ jquery.min.js:4ISPConfig.keepalive @ ispconfig.min.js:1ISPConfig.loadInitContent @ ispconfig.min.js:1(anonymous function) @ ispconfig.min.js:1n.event.dispatch @ jquery.min.js:3r.handle @ jquery.min.js:3n.event.trigger @ jquery.min.js:3n.fn.extend.triggerHandler @ jquery.min.js:3n.extend.ready @ jquery.min.js:2I @ jquery.min.js:2

    The url https://vps156534.ovh.net:8080/login/dashboard/dashboard.php seems wrong, any idea?

    Thanks
     
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    I have a test system on Ubuntu 15.10 here as well and login works fine in latest chrome. It might be that your browser has still old files or libraries cached. Empty the browser cache.
     
  3. Florian

    Florian New Member

    Nope, nothing better after clearing the cache in chrome..

    I also noticed an error during php -q update.php :
    PHP Warning: symlink(): No such file or directory in /tmp/ispconfig3_install/install/lib/installer_base.lib.php on line 2007

    I tried to create the symlink by hand, and restart nginx, but nothing better

    Still the console message : Failed to load resource: the server responded with a status of 404 (Not Found) for https://vps156534.ovh.net:8080/login/dashboard/dashboard.php , https://vps156534.ovh.net:8080/login/nav.php?nav=top , https://vps156534.ovh.net:8080/login/nav.php?nav=side and https://vps156534.ovh.net:8080/login/keepalive.php

    Are those the good routes?
     
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    No, the paths on your system are not ok. the login script makes a redirect to ../index.php, not sure why your server tries to load the files realtive to /login/ dir. The test servers with apache and nginx tthat I have here are all working correctly.
     
  5. till

    till Super Moderator Staff Member ISPConfig Developer

    Please try to edit /usr/local/ispconfig/interface/web/login/index.php line 263 and change:

    header('Location: ../index.php');

    to

    header('Location: /index.php');

    The resulting path change to / from /login/ is the same, but maybe your browser does not follow the redirect correctly. Then logout, empty the cache and login again.
     
  6. Florian

    Florian New Member

    thanks for the help, I tried to change this, without success..
    I can't explain why the url always keeps /login/ inside...
    I played with nginx (installed version 1.9.14 from ppa) and did config tweaks to boost performances, i will check if i did something wrong there.
     
  7. till

    till Super Moderator Staff Member ISPConfig Developer

    Or maybe its something in the MacOS version of Chrome. I can test here in Windows and Linux Desktops only. We'll see if others report the same issue.
     
  8. till

    till Super Moderator Staff Member ISPConfig Developer

    I guess I've found the reason for the issue. ISPConfig uses the PHP funktion session_regenarete_id() for security reasons. This works fine in e.g. PHP 7 but the function seems to be buggy in e.g. PHP 5.4. Havent tested all intermediate releases yet, but the reason might be a php bug in some releases.

    You can test that on your server by commenting out line 212:

    if (!$loginAs) session_regenerate_id(true);

    the file /usr/local/ispconfig/interface/web/login/index.php
     
  9. Florian

    Florian New Member

    Yes!!
    Thank you so much, this solved the problem!
    For info my php version is : 5.6.11 from the ubuntu 15.10 server release.

    Do you think it is worth to upgrade to the 16.04 (I suppose that now php7 is in the packages) ?
     
  10. florian030

    florian030 ISPConfig Developer ISPConfig Developer

    Can you check the value for session.use_strict_mode in your php.ini ?
     
  11. Florian

    Florian New Member

    it is:
    session.use_strict_mode = 0
     
  12. till

    till Super Moderator Staff Member ISPConfig Developer

    I would wait a few weeks and not always update to the latest Ubuntu version immediately.
     
  13. Florian

    Florian New Member

    Good idea, also there will be the final release of ispconfig! Sounds good to wait for that, meanwhile i will test the new features, it's very neat!
     
    till likes this.
  14. QuaxEros

    QuaxEros New Member

    Hi all. I encountered the same issue (loop on login screen with 404 errors on dashboard.php, nav.php, keepalive.php) just after upgrading to Ispconfig 3.1.1p1 (though it can be that "apt-get upgrade") was the real cause. I'm under Proxmox (kernel 4.4.21-1-pve #1 x86_64 GNU/Linux) employing LXContainers Debian Jessie with Apache 2.4 and PHP 5.6.27-0+deb8u1 The line to change in this new version is line 225 in /usr/local/ispconfig/interface/web/login/index.php. Set ['session_regenerate_id'] == 'yes' to ['session_regenerate_id'] == 'no' at the end of that line. (Do you agree this is the way to go about this issue, Till?)
    Now it seems to work fine again.
     

Share This Page