Как закрыть phpMyAdmin за NAT?

Правим файл конфигурации PAM — /etc/httpd/conf.d/phpMyAdmin.conf и разрешаем доступ к приложению только с локального IP 192.168.0.108. Также можно указать диапазон адресов, о дополнительных опциях можно почитать в документации к Apache по контролю доступа, и в частности по модулю mod_authz_host.

# phpMyAdmin - Web based MySQL browser written in php
#.
# Allows only localhost by default
#
# But allowing phpMyAdmin to anyone other than localhost should be considered
# dangerous unless properly secured by SSLAlias /phpMyAdmin /usr/share/phpMyAdmin
Alias /phpmyadmin /usr/share/phpMyAdminOrder Deny,Allow
Deny from All
Allow from 192.168.0.108 #All
Order Deny,Allow
Deny from All
Allow from None 192.168.0.108 #All
# This directory does not require access over HTTP - taken from the original
# phpMyAdmin upstream tarball
#
Order Deny,Allow
Deny from All
Allow from None
# This configuration prevents mod_security at phpMyAdmin directories from
# filtering SQL etc.  This may break your mod_security implementation.
#
#
#
#        SecRuleInheritance Off
#
#
kupereal