Move contrib/htaccess into documentation
The contrib folder is too hidden for this.
This commit is contained in:
parent
d47d2fb13c
commit
147e256f0d
@ -3183,6 +3183,35 @@ ProxyPassReverseCookiePath /%7Euser/phpmyadmin /mirror/foo
|
||||
<p> The MySQL server's privilege tables are not up to date, you need to run
|
||||
the <tt>mysql_upgrade</tt> command on the server.</p>
|
||||
|
||||
<h4 id="faq1_42">
|
||||
<a href="#faq1_42">1.42 How can I prevent robots from accessing phpMyAdmin?</a></h4>
|
||||
|
||||
<p>You can add various rules to <a href="#glossary"><i>.htaccess</i></a> to filter access
|
||||
based on user agent field. This is quite easy to circumvent, but could prevent at least
|
||||
some robots accessing your installation.</p>
|
||||
|
||||
<pre>
|
||||
RewriteEngine on
|
||||
|
||||
# Allow only GET and POST verbs
|
||||
RewriteCond %{REQUEST_METHOD} !^(GET|POST)$ [NC,OR]
|
||||
|
||||
# Ban Typical Vulnerability Scanners and others
|
||||
# Kick out Script Kiddies
|
||||
RewriteCond %{HTTP_USER_AGENT} ^(java|curl|wget).* [NC,OR]
|
||||
RewriteCond %{HTTP_USER_AGENT} ^.*(libwww-perl|curl|wget|python|nikto|wkito|pikto|scan|acunetix).* [NC,OR]
|
||||
RewriteCond %{HTTP_USER_AGENT} ^.*(winhttp|HTTrack|clshttp|archiver|loader|email|harvest|extract|grab|miner).* [NC,OR]
|
||||
|
||||
# Ban Search Engines, Crawlers to your administrative panel
|
||||
# No reasons to access from bots
|
||||
# Ultimately Better than the useless robots.txt
|
||||
# Did google respect robots.txt?
|
||||
# Try google: intitle:phpMyAdmin intext:"Welcome to phpMyAdmin *.*.*" intext:"Log in" -wiki -forum -forums -questions intext:"Cookies must be enabled"
|
||||
RewriteCond %{HTTP_USER_AGENT} ^.*(AdsBot-Google|ia_archiver|Scooter|Ask.Jeeves|Baiduspider|Exabot|FAST.Enterprise.Crawler|FAST-WebCrawler|www\.neomo\.de|Gigabot|Mediapartners-Google|Google.Desktop|Feedfetcher-Google|Googlebot|heise-IT-Markt-Crawler|heritrix|ibm.com\cs/crawler|ICCrawler|ichiro|MJ12bot|MetagerBot|msnbot-NewsBlogs|msnbot|msnbot-media|NG-Search|lucene.apache.org|NutchCVS|OmniExplorer_Bot|online.link.validator|psbot0|Seekbot|Sensis.Web.Crawler|SEO.search.Crawler|Seoma.\[SEO.Crawler\]|SEOsearch|Snappy|www.urltrends.com|www.tkl.iis.u-tokyo.ac.jp/~crawler|SynooBot|crawleradmin.t-info@telekom.de|TurnitinBot|voyager|W3.SiteSearch.Crawler|W3C-checklink|W3C_Validator|www.WISEnutbot.com|yacybot|Yahoo-MMCrawler|Yahoo\!.DE.Slurp|Yahoo\!.Slurp|YahooSeeker).* [NC]
|
||||
RewriteRule .* - [F]
|
||||
</pre>
|
||||
|
||||
|
||||
|
||||
<h3 id="faqconfig">Configuration</h3>
|
||||
|
||||
|
||||
@ -1,19 +0,0 @@
|
||||
RewriteEngine on
|
||||
|
||||
# Allow only GET and POST verbs
|
||||
RewriteCond %{REQUEST_METHOD} !^(GET|POST)$ [NC,OR]
|
||||
|
||||
# Ban Typical Vulnerability Scanners and others
|
||||
# Kick out Script Kiddies
|
||||
RewriteCond %{HTTP_USER_AGENT} ^(java|curl|wget).* [NC,OR]
|
||||
RewriteCond %{HTTP_USER_AGENT} ^.*(libwww-perl|curl|wget|python|nikto|wkito|pikto|scan|acunetix).* [NC,OR]
|
||||
RewriteCond %{HTTP_USER_AGENT} ^.*(winhttp|HTTrack|clshttp|archiver|loader|email|harvest|extract|grab|miner).* [NC,OR]
|
||||
|
||||
# Ban Search Engines, Crawlers to your administrative panel
|
||||
# No reasons to access from bots
|
||||
# Ultimately Better than the useless robots.txt
|
||||
# Did google respect robots.txt?
|
||||
# Try google: intitle:phpMyAdmin intext:"Welcome to phpMyAdmin *.*.*" intext:"Log in" -wiki -forum -forums -questions intext:"Cookies must be enabled"
|
||||
RewriteCond %{HTTP_USER_AGENT} ^.*(AdsBot-Google|ia_archiver|Scooter|Ask.Jeeves|Baiduspider|Exabot|FAST.Enterprise.Crawler|FAST-WebCrawler|www\.neomo\.de|Gigabot|Mediapartners-Google|Google.Desktop|Feedfetcher-Google|Googlebot|heise-IT-Markt-Crawler|heritrix|ibm.com\cs/crawler|ICCrawler|ichiro|MJ12bot|MetagerBot|msnbot-NewsBlogs|msnbot|msnbot-media|NG-Search|lucene.apache.org|NutchCVS|OmniExplorer_Bot|online.link.validator|psbot0|Seekbot|Sensis.Web.Crawler|SEO.search.Crawler|Seoma.\[SEO.Crawler\]|SEOsearch|Snappy|www.urltrends.com|www.tkl.iis.u-tokyo.ac.jp/~crawler|SynooBot|crawleradmin.t-info@telekom.de|TurnitinBot|voyager|W3.SiteSearch.Crawler|W3C-checklink|W3C_Validator|www.WISEnutbot.com|yacybot|Yahoo-MMCrawler|Yahoo\!.DE.Slurp|Yahoo\!.Slurp|YahooSeeker).* [NC]
|
||||
RewriteRule .* - [F]
|
||||
|
||||
Loading…
Reference in New Issue
Block a user