Also For Debian:
For apache:
~: sudo nano /etc/phpmyadmin/apache.conf
WARNING: Do not add Allow Override all into this file or it will SLOWDOWN your phpmyadmin@max
And right under
Code:
<Directory /usr/share/phpmyadmin>
add:
Code:
Order allow,deny
allow from 192.168.1.4
And add as many ips you want ;p
Also if you want double password protection +IP protection add:
Code:
AuthUserFile /home/gali/.htpasswd
AuthName PhpMyAdmin
AuthType Basic
Require valid-user
Change the AuthUserFile path to your basic validation file
If you don't know how to generate one auth basic validation file is easy with just one command:
Code:
htpasswd -c /path/to/your/file/PasswordFileName username
Feel free to add it into your tutorial