[SOLVED] Ask for Username and Password in phpMyAdmin
Moderator: General Moderators
[SOLVED] Ask for Username and Password in phpMyAdmin
I have phpMyAdmin setup alright but the url is like http://www.xxx.com/phpMyAdmin
This automatically connects to the database with username and password - thats because its set in config.inc.php.
Any way to have it ask for username and password ?
Thanks
This automatically connects to the database with username and password - thats because its set in config.inc.php.
Any way to have it ask for username and password ?
Thanks
Last edited by anjanesh on Sun Mar 27, 2005 11:18 am, edited 1 time in total.
- Chris Corbyn
- Breakbeat Nuttzer
- Posts: 13098
- Joined: Wed Mar 24, 2004 7:57 am
- Location: Melbourne, Australia
Just create .htaccess and a .htpassword file. That will protect the entire directory. Read more here.
http://www.2020dns-hosting.net/help/access.html
http://www.2020dns-hosting.net/help/access.html
-
Sphen001
- Forum Contributor
- Posts: 107
- Joined: Thu Mar 10, 2005 12:24 pm
- Location: Land of the Beaver
Well, I know there is a way to force phpMyAdmin to ask for passwords. I think it has something to do with the config file. There should be some info in the manual.
Also, I wouldn't recommend .htaccess because it could get really difficult to maintain. Better stick with the built in authentication.
Sphen
Also, I wouldn't recommend .htaccess because it could get really difficult to maintain. Better stick with the built in authentication.
Sphen
I could not find anything in config.inc.php regarding this.
There is a $cfg['Servers'][$i]['password'] = "mypassword" where if I have it null $cfg['Servers'][$i]['password'] = "", it'll say access denied because not using password etc.
The only other thing I found in config.inc.php was this :
Before I change anything, what is this SQL Validator service ?
Thanks
There is a $cfg['Servers'][$i]['password'] = "mypassword" where if I have it null $cfg['Servers'][$i]['password'] = "", it'll say access denied because not using password etc.
The only other thing I found in config.inc.php was this :
Code: Select all
/**
* If you wish to use the SQL Validator service, you should be
* aware of the following:
* All SQL statements are stored anonymously for statistical purposes.
* Mimer SQL Validator, Copyright 2002 Upright Database Technology.
* All rights reserved.
*/
$cfgї'SQLValidator']ї'use'] = FALSE; // Make the SQL Validator available
$cfgї'SQLValidator']ї'username'] = ''; // If you have a custom username, specify it here (defaults to anonymous)
$cfgї'SQLValidator']ї'password'] = ''; // Password for usernameThanks
- John Cartwright
- Site Admin
- Posts: 11470
- Joined: Tue Dec 23, 2003 2:10 am
- Location: Toronto
- Contact:
You do require a password is the default username does not contain a password.
It requires some sort of validation or anyone would have access to your machines db
I believe, not too sure though.
It requires some sort of validation or anyone would have access to your machines db
I believe, not too sure though.
Last edited by John Cartwright on Sun Mar 27, 2005 11:08 am, edited 1 time in total.
- feyd
- Neighborhood Spidermoddy
- Posts: 31559
- Joined: Mon Mar 29, 2004 3:24 pm
- Location: Bothell, Washington, USA
Code: Select all
$cfgї'Servers']ї$i]ї'auth_type'] = 'http'; // Authentication method (config, http or cookie based)?
$cfgї'Servers']ї$i]ї'user'] = 'your mysql username'; // MySQL user
$cfgї'Servers']ї$i]ї'password'] = 'your mysql password'; // MySQL password (only needed- feyd
- Neighborhood Spidermoddy
- Posts: 31559
- Joined: Mon Mar 29, 2004 3:24 pm
- Location: Bothell, Washington, USA
Most times, I've gone through or know enough about a subject to figure it out real fast. Part of the reason I charge what I do for workI wonder how he manages to get all answers so quickly.
This particular instance, I've gone through and figured out how phpMyAdmin is configured for it previously. Reading the docs helps