Menu

No left page in phpDHCPadmin 0.9 and 0.9.1b

2008-12-01
2015-12-20
  • Peter Okupski

    Peter Okupski - 2008-12-01

    Hi
    This what i can see after login in with admin/blankpass.
    MySQL database is imported, apache+php+mysql is working.
    [IMG]http://img504.imageshack.us/img504/5107/dhcpadminil2.jpg[/IMG]
    Here is my sys info:
    Debian 4.0
    PHP 5.2.6
    Apache 2.
    Mysql 5.0.26
    I have tried in firefox 3.0 and in IE 6.0 and no luck, the admin page/left MENU doesnt seem to show up.
    If anybody know what might be the case please let me know.

    Peter

     
    • Spiffturk

      Spiffturk - 2009-05-21

      After sifting through the code, the problem is EncodeAuthToken() in class.encryption.php. Well, sort of. I guess more accurately, the problem is a blank password. EncodeAuthToken returns -1 if any of its inputs are blank (including the initial admin password). Instead of rewriting code, I just did this from mysql:

      delete from auth_users;
      INSERT INTO auth_users (username, password, level, group, reset, owner) VALUES ('admin', sha1( 'admin' ), 'admin', 'admin', 'TRUE', 'admin');

      That sets the default admin password to 'admin' and that should get you logged in.

      --
      Will

       
    • jas

      jas - 2008-12-02

      I think I know what the problem is. You will need to manually edit the user you are authenticating and add a valid access level... I will address this in the .sql installation file in the next release. Below is an example using mysql.

      %> mysql -u root -p
      Enter password:
      %> use phpDHCPAdmin;
      %> INSERT INTO auth_users (username, password, level, group, owner) VALUES ('admin', sha1( '' ), 'admin', 'admin', 'admin');

      My apologies. It seems in my testing I over looked this. The installation file in the setup directory for the phpDHCPAdmin-0.9.1-beta release addresses this as well.

      Let me know if you encounter anything else.
      Jas

       
    • jas

      jas - 2008-12-02

      Actually run this one instead... this way it will prompt you to reset the initial admin user password on first log on.

      %> INSERT INTO auth_users (username, password, level, group, reset, owner) VALUES ('admin', sha1( '' ), 'admin', 'admin', 'TRUE', 'admin');

      With this command it will allow you log in as the user 'admin' with no password and you can then create users, groups, subnets, hosts, groups etc. etc.

       
    • tim ng

      tim ng - 2009-03-22

      After I login to phpDHCPadmin.The admin page/left MENU does not seem to show up.How to resolve this problem
      thanks.

       
  • Wayne Workman

    Wayne Workman - 2015-12-20

    I've experienced this exact problem - I figured out that it was the checks for blank fields that was preventing authentication. I wish I had found this thread sooner.

    Here's what I did to set the admin password to 'admin'

    mysql
    use phpDHCPAdmin;
    update auth_users set password = 'd033e22ae348aeb5660fc2140aec35850c4da997' where username = 'admin';
    

    I don't understand why this issue hasn't been resolved by simply making the default password something other than blank...

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.