Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

apache

Posted on 2004-04-13
4
Medium Priority
?
314 Views
Last Modified: 2010-04-20
I Use Phpmyadmin how can I set password whrn go to page phpmyadmin I use apache
Thank
0
Comment
Question by:teera
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 6

Assisted Solution

by:karlwilbur
karlwilbur earned 700 total points
ID: 10813799
You could use an htaccess file. Maybe not the best choice but it's easy. It'd go a li'l somethin' like this.  And a one, and a two, and a one, two, three, four...

change to the dir you want to password protect

cat > .htaccess << "EOF"
AuthUserFile /etc/httpd-users
AuthGroupFile /etc/htttpd-groups
AuthName "Private Directory"
AuthType Basic
require valid-user
Options +Indexes
EOF

Now do the following as root:

(to create empty files)
touch /etc/httpd-users
touch /etc/httpd-groups

(to add users)
htpasswd -b /etc/httpd-users [username] [password]   ...(rinse and repeat)

-Karl
0
 
LVL 44

Accepted Solution

by:
Karl Heinz Kremer earned 700 total points
ID: 10817630
I think that using the MySQL authentication is even simpler than that. Open your config.inc.php file and go to the section that defines your MySQL user id and password and change it to this:

$cfg['Servers'][$i]['auth_type']     = 'http';    // Authentication method (config, http or cookie based)?
$cfg['Servers'][$i]['user']          = '';      // MySQL user
$cfg['Servers'][$i]['password']      = '';          // MySQL password (only needed
                                                    // with 'config' auth_type)

You are changing the authentication method from config to http. This will automatically prompt you for your MySQL user ID and password.
0
 
LVL 6

Expert Comment

by:karlwilbur
ID: 10817655
I think your right.  That is even easier. :-)
0
 
LVL 44

Expert Comment

by:Karl Heinz Kremer
ID: 10817848
And if you believe the commends, you can even get rid of the last line :-)
0

Featured Post

Docker-Compose to Simplify Multi-Container Builds

Our veteran DevOps Author takes you through how to build a multi-container environment, managed with a single utility in order to simplify your deployments.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Setting up Secure Ubuntu server on VMware 1.      Insert the Ubuntu Server distribution CD or attach the ISO of the CD which is in the “Datastore”. Note that it is important to install the x64 edition on servers, not the X86 editions. 2.      Power on th…
In part one, we reviewed the prerequisites required for installing SQL Server vNext. In this part we will explore how to install Microsoft's SQL Server on Ubuntu 16.04.
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.
Suggested Courses

664 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question