Reseller can't login

Discussion in 'General' started by smartcall, May 17, 2007.

  1. smartcall

    smartcall ISPConfig Developer ISPConfig Developer

    Hello to all,

    I have this strange problem:
    One of the resellers can't login to his account anymore. He used to be able to do that, but all the sudden he can't.
    I changed his username and password, and the problem persists. I also tried to login with the new username and password, and ISPConfig rejects the credentials.
    What could be wrong?

    P.S. Maybe important: this guy has two reseller account and somehow the usernames for both were the same.
     
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    Is the user account listed correctly in the database table sys_user ? Or is it listed twice? Then change one of the usernames in this table.
     
  3. smartcall

    smartcall ISPConfig Developer ISPConfig Developer

    Currently the account username is different, but still, he can't login. It is listed in the database table sys_user. With the same other attributes as this user's other reseller account.

    Maybe I could create another reseller, then a user for him and move all websites to the new user?
     
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    This will work of course, but i hope we will find another solution.

    Please edit the user entry in the sys_user table and set a new password with e.g. phpmyadmin. The password is md5 encrypted and stored in the "passwort" column.

    A SQL statement like this should work:

    Code:
    update sys_user set passwort = md5('newpassword') WHERE username = 'resellerusername';
     
  5. smartcall

    smartcall ISPConfig Developer ISPConfig Developer

    Thanks.

    That solved the problem. Strange is why this didn't work from thr frontend?
     
  6. till

    till Super Moderator Staff Member ISPConfig Developer

    It might be that the connection between reseller and cp user is somewhat broken. Please check if the "doc_id" of the user from the table sys_user is correct in the column reseller_userid in the table isp_isp_reseller for this reseller.
     
  7. DrmCtchr

    DrmCtchr New Member

    I have the same problem it seems due to the fact that isp_isp_reseller doesn't seem to contain anything. I have noticed that all the historical backups of sysdb all contain this instead of a list of resellers:

    Code:
    LOCK TABLES `isp_isp_reseller` WRITE;
    /*!40000 ALTER TABLE `isp_isp_reseller` DISABLE KEYS */;
    /*!40000 ALTER TABLE `isp_isp_reseller` ENABLE KEYS */;
    UNLOCK TABLES;
    I'm pretty sure there should be at least one insert between the comments, right?

    I'm not really sure how to recreate my resellers. If someone can help me script a reseller recovery perl script or at least point me in the right direction of where I can get the reseller data from and a proper way to reinsert it into the database.. It would be most kind.

    Thank you all in advance,

    David.
     
  8. DrmCtchr

    DrmCtchr New Member

    Obviously, I cant get ALL the data from other places in the database. But if I could at least recreate their record in isp_isp_reseller then I could login as the administrator and manually edit the field info in the UI. Luckily for me there wasn't very many resellers.
    D
     
  9. rdtech

    rdtech New Member

    I'm getting an error with ispconfig. Everything worked fine. I logged in and then while in the systems area, it kicked me off. Now I can't log in at all. I've tried the other account with no luck.

    I logged into phpmyadmin and changed the password but it still doest not work. Any idea
    Falk?

    Till?

    http://domain:81/login.php?err=

    I've tried restarting the server as well. Theres a problem somewhere but I dont' know where. It doesnt take to me into the back in. If I put in a fake uname and password, then it takes me to an error 101 page
     
  10. falko

    falko Super Moderator ISPConfig Developer

    Please check if the MySQL details are correct in /home/admispconfig/ispconfig/lib/config.inc.php.
     
  11. rdtech

    rdtech New Member

    Here is the code. I'm not sure what I should be looking for.

    Code:
    <?
    /*
    Copyright (c) 2005, projektfarm Gmbh, Till Brehm, Falko Timme
    All rights reserved.
    
    Redistribution and use in source and binary forms, with or without modification,
    are permitted provided that the following conditions are met:
    
        * Redistributions of source code must retain the above copyright notice,
          this list of conditions and the following disclaimer.
        * Redistributions in binary form must reproduce the above copyright notice,
          this list of conditions and the following disclaimer in the documentation
          and/or other materials provided with the distribution.
        * Neither the name of ISPConfig nor the names of its contributors
          may be used to endorse or promote products derived from this software without
          specific prior written permission.
    
    THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
    ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
    WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
    IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
    INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
    BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
    DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
    OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
    NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
    EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
    */
    // Register Globals emulieren, falls notwendig
    if(get_cfg_var('register_globals') != 'On') {
    
        foreach($HTTP_GET_VARS as $getkey => $getval) {
            $$getkey = $getval;
        }
        unset($getkey);
        unset($getval);
    
        foreach($HTTP_POST_VARS as $postkey => $postval) {
            $$postkey = $postval;
        }
        unset($postkey);
        unset($postval);
    
        foreach($HTTP_COOKIE_VARS as $cookiekey => $cookieval) {
            $$cookiekey = $cookieval;
        }
        unset($cookiekey);
        unset($cookieval);
    }
    
    $go_info = array();
    
    $s = $HTTP_GET_VARS["s"];
    if(isset($HTTP_POST_VARS["s"])) $s = $HTTP_POST_VARS["s"];
    $s = addslashes($s);
    $session = "s=$s";
    $set_header = 1;
    @session_start();
    
    /**********************************************
    * System Settings
    **********************************************/
    
    $go_info["server"]["dir_trenner"] = "/";
    $go_info["server"]["server_root"] = "/home/admispconfig/ispconfig";
    
    define("DIR_TRENNER","/");
    define("SERVER_ROOT","/home/admispconfig/ispconfig");
    define("INCLUDE_ROOT",SERVER_ROOT.DIR_TRENNER."lib");
    define("CLASSES_ROOT",INCLUDE_ROOT.DIR_TRENNER."classes");
    define("DB_TYPE","mysql");
    
    if(isset($_SERVER['HTTP_HOST'])){
      $go_info["server"]["server_url"] = 'http://'.$_SERVER['HTTP_HOST'];
    } else {
      $go_info["server"]["server_url"] = "http://www.domain.com:81";
    }
    $go_info["server"]["include_root"] = $go_info["server"]["server_root"] . $go_info["server"]["dir_trenner"] ."lib";
    $go_info["server"]["classes_root"] = $go_info["server"]["include_root"] . $go_info["server"]["dir_trenner"] ."classes";
    $go_info["server"]["temp_dir"] = $go_info["server"]["server_root"] . $go_info["server"]["dir_trenner"] ."temp";
    $go_info["server"]["files_dir"] = $go_info["server"]["server_root"] . $go_info["server"]["dir_trenner"] ."files";
    $go_info["server"]["backup_dir"] = $go_info["server"]["server_root"] . $go_info["server"]["dir_trenner"] ."backup";
    $go_info["server"]["version"] = "2.2.23";
    $go_info["server"]["os"] = "linux";
    $go_info["server"]["ort"] = "local";
    $go_info["server"]["banner"] = "0";
    $go_info["server"]["db_host"] = "localhost";
    $go_info["server"]["db_name"] = "db_ispconfig";
    $go_info["server"]["db_user"] = "root";
    $go_info["server"]["db_password"] = "XXXX";
    $go_info["server"]["db_type"] = "mysql";
    $go_info["server"]["mail_server"] = "";
    $go_info["server"]["mail_user"] = "";
    $go_info["server"]["mail_password"] = "";
    $go_info["server"]["smtp_server"] = "localhost";
    $go_info["server"]["mode"] = "";
    $go_info["server"]["lang"] = "en";
    
    $go_info["server"]["postfix_config"] = 1; // 1 = SENDMAIL-STYLE, 2 = POSTFIX-STYLE
    $go_info["server"]["smtp_restart"] = 1; // 1 = stop/start, 2 = restart
    $go_info["server"]["network_config"] = 0; // 0 = none, 1 = automatic
    $go_info["server"]["sudo_du_enabled"] = 0; // enable sudo for gathering website file usage
    $go_info["server"]["apache2_php"] = 'both'; // 'filter' = set PHP filters, 'addtype' = Set PHP addtype or 'both' = Set Filter + Addtype, suphp = SuPHP wrapper enabled, 'addhandler' = Set PHP AddHandler (nescessary for SuSE 10.2)
    $go_info["server"]["password_hash"] = 'crypt'; // 'crypt' = crypt; 'md5' = crypt-md5
    $go_info["server"]["do_automated_backups"] = 0; // 0 = no, 1 = yes; PLEASE NOTE: automated backups might fill up your HDD fast!
    $go_info["server"]["ssh_chroot"] = 0;
    $go_info["server"]["httpd_check"] = 1;
    $go_info["server"]["salutatory_email_charset"] = 'iso-8859-1'; // possible values are iso-8859-1, iso-8859-2, ..., us-ascii, koi8-r (Russian), ...; if no charset is specified, unknown-8bit is assumed.
    $go_info["server"]["webdav"] = 0;
    
    /**********************************************
    * Tools Settings
    **********************************************/
    
    $go_info["tools"]["zip"] = $go_info["server"]["server_root"] . $go_info["server"]["dir_trenner"] ."tools".$go_info["server"]["dir_trenner"]."zip".$go_info["server"]["dir_trenner"]."zip"; // nicht gzip !!
    $go_info["tools"]["unzip"] = $go_info["server"]["server_root"] . $go_info["server"]["dir_trenner"] ."tools".$go_info["server"]["dir_trenner"]."unzip".$go_info["server"]["dir_trenner"]."unzip";
    $go_info["tools"]["imagemagick"]["mogrify"] = "mogrify.exe";
    
    /**********************************************
    * Themes Settings
    **********************************************/
    
    // Themes Section
    $go_info["theme"]["sitename"] = "ISPConfig";
    $go_info["theme"]["page"]["box_color"] = "E4E4E4"; // z.B. E4E4E4 , angaben ohne #
    $go_info["theme"]["page"]["nav_color"] = "E0E0E0"; // z.B. 025CCA , angaben ohne #
    // Die Logo-Datei muss im Verzeichnis /home/admispconfig/ispconfig/web/design/default liegen!
    $go_info["theme"]["page"]["logo"] = ""; // z.B. meinlogo.gif
    $go_info["theme"]["charset"] = "iso-8859-1";
    
    /**********************************************
    * Logging
    **********************************************/
    
    $go_info["server"]["log_level"] = 0; // 0 = Debug, 1 = Info, 2 = Warning, 3 = Failure
    $go_info["server"]["log_file"] = $go_info["server"]["server_root"] . $go_info["server"]["dir_trenner"] ."ispconfig.log"; // Logdatei
    if(is_file("/home/admispconfig/ispconfig/adminmail.txt")){
      $go_info["server"]["log_mail"] = trim(shell_exec("cat /home/admispconfig/ispconfig/adminmail.txt")); // Log Emailadresse
    } else {
      $go_info["server"]["log_mail"] = "root@localhost";
    }
    $go_info["server"]["log_device"] = "FILE"; // FILE, SYSTEM, MAIL
    
    /**********************************************
    * Demo Mode Settings
    **********************************************/
    
    $go_info["demo"]["web_path"] = "";
    
    /**********************************************
    * Localisation Settings
    **********************************************/
    
    $go_info["localisation"]["dec_point"] = ",";
    $go_info["localisation"]["thousands_sep"] = ".";
    $go_info["localisation"]["currency"] = "EUR";
    
    define("CONFIG_LOADED",1);
    
    
    ?>
     
    Last edited: Mar 26, 2009
  12. falko

    falko Super Moderator ISPConfig Developer

    Code:
    $go_info["server"]["db_host"] = "localhost";
    $go_info["server"]["db_name"] = "db_ispconfig";
    $go_info["server"]["db_user"] = "root";
    $go_info["server"]["db_password"] = "XXXX";
    
    Are these details correct?
     
  13. rdtech

    rdtech New Member



    they are correct except I've put XXXX in place of the real password. I've also changed the real domain name to something generic. Those are the only 2 things i've changed.
     
  14. falko

    falko Super Moderator ISPConfig Developer

    Is the sys_user table in the ISPConfig database ok?
     
  15. rdtech

    rdtech New Member

    I'm assuming it should be good. I haven't touched it. It worked just fine the day before. All the sudden i couldn't access it anymore. I don't understand it. I've tried restarting the server with no luch.
     
  16. falko

    falko Super Moderator ISPConfig Developer

    Can you take a look at the table with phpMyAdmin?
     
  17. rdtech

    rdtech New Member

    tables

    I can log into phpmyadmin just fine. domain:81/phpmyadmin

    I can see the tables and the users. It all looks fine to me.
     
  18. rdtech

    rdtech New Member

    pic

    here is a screen shot of it.
     

    Attached Files:

    • 111.jpg
      111.jpg
      File size:
      55.9 KB
      Views:
      548
  19. falko

    falko Super Moderator ISPConfig Developer

    Looks ok. Is there anything you changed before the login started to fail?
     
  20. rdtech

    rdtech New Member

    nothing changed. Thats why i'm confused. Well I did do some updates but I didn't have problems logging in a few days later. Everything worked fine. The follow day, I logged into to ispconfig. I logged in fine. As I was clicking on the tabs from DNS manager to the other tabs, it kicked me off. Ever since then, I couldn't log back on.
     

Share This Page