Tuesday, 11 December 2012

Setting password protection for WAMP

   This post will guide you to setup password protection to WAMP server, There are so many ways to set up password, But following is the easiest way to do.

Note: perform full backup of WAMP before you do any changes. Check here to learn how to set backup for WAMP.

Click on WAMP tray icon and put server to online, When it is turned back to green click on it and open phpMyAdmin from popped-up menu.



















On the PHP MyAdmin home page you will find an "No password for root" error message at the bottom of the page.
















In this screen click on Users menu item on the top menu.
















Now click on Edit Privilages tab next to any root user
















On the popped-up window scroll down till you find Change Password section. and enter desired password twice in those password boxes.
















Now don't close that window yet. Open config.inc.php with a text editor which will be on your installation directory

in my case it is C  >> wamp >> apps >> phpmyadmin3.5.1
















Add $cfg['blowfish_secret'] = ' Your secret phrase word  ';

Enter a secret phrase word in ( not your password which you used in phpmyadmin root ),

Find the following line

$cfg['Servers'][$i]['auth_type'] = 'config';

And change config to cookie 

$cfg['Servers'][$i]['auth_type'] = 'cookie';

Find the following line and enter your phpmyadmin password in it

$cfg['Servers'][$i]['password'] = ' your password'; // which you used in phpmyadmin
















Now save and close the editor, close phpmyadmin page and restart WAMP server to effect the changes.

Now open phpmyadmin again, now it will ask for username and password.

Username : root
Password: your password

Log in using your details, and go to users tab and enter the password for the remaining root users ( same password as you entered earlier). You dont have to edit settings file now, Just change password from phpmyadmin.
















That is end of this guide. If you do it exactly how it was explained, You have successfully set password for your WAMP server.

No comments:

Post a Comment