.htaccess
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 |
# 検索エンジン回避 # MSN SetEnvIfNoCase User-Agent "msnbot" shutout SetEnvIf Referer "^http://search\.msn\..*/results\.aspx\?" shutout SetEnvIf Referer "^http://search\.live\..*/results\.aspx\?" shutout # Google SetEnvIfNoCase User-Agent "Googlebot" shutout SetEnvIf User-Agent "Googlebot-Image" shutout SetEnvIf Referer "^http://www\.google\..*/search" shutout SetEnvIf Referer "^http://images\.google\..*/images" shutout Deny from 66.249.64.0/19 # Yahoo SetEnvIfNoCase User-Agent "Yahoo" shutout SetEnvIfNoCase User-Agent "Slurp" shutout SetEnvIfNoCase User-Agent "Y!J" shutout SetEnvIf Referer "^http.*search\.yahoo\..*\?" shutout Deny from 72.30.0.0/16 Deny from 74.6.0.0/16 # その他 SetEnvIf User-Agent "inktomi" shutout SetEnvIf User-Agent "moget" shutout SetEnvIf User-Agent "ichiro" shutout SetEnvIf User-Agent "ia_archiver" shutout SetEnvIfNoCase User-Agent "MarkAgent" shutout SetEnvIfNoCase User-Agent "marsflag" shutout SetEnvIfNoCase User-Agent "spider" shutout SetEnvIfNoCase User-Agent "Baiduspider" shutout SetEnvIfNoCase User-Agent "Crawler" shutout SetEnvIfNoCase User-Agent "Yeti" shutout SetEnvIfNoCase User-Agent "MJ12bot" shutout SetEnvIfNoCase User-Agent "SemrushBot" shutout SetEnvIfNoCase User-Agent "YandexAntivirus" shutout SetEnvIfNoCase User-Agent "YandexBot" shutout SetEnvIfNoCase User-Agent "YandexImages" shutout SetEnvIfNoCase User-Agent "Baiduspider" shutout SetEnvIf Referer "^http://baidu\." shutout SetEnvIf Referer "^http.*\.baidu\." shutout Deny from 220.88.0.0/13 Deny from 61.247.192.0/19 Deny from 202.108.0.0/16 Deny from 60.24.0.0/13 Deny from 122.152.128.0/23 Deny from 202.106.0.0/16 Deny from 221.216.0.0/13 Deny from 61.135.0.0/16 Deny from 203.192.149.0/24 # 魚拓 Deny from 46.166.136.0/21 Deny from 78.46.0.0/15 Deny from 78.108.176.0/20 Deny from 139.162.192.0/19 Deny from 146.0.72.0/24 Deny from 146.0.75.0/24 Deny from 178.62.128.0/17 Deny from 104.16.0.0/12 #WordPressパクリ対策 SetEnvIfNoCase User-Agent "FeedWordPress" shutout SetEnvIf Referer "^http(s)?://site\.ru" shutout # 検索エンジン固有UA SetEnvIf User-Agent "http" shutout order Allow,Deny Allow from all Deny from env=shutout |
Anonymous Proxyサービス対策追加
#コピー対策
SetEnvIf User-Agent “.*AppEngine-Google.*” block_AppEngine
order allow,deny
allow from all
deny from env=block_AppEngine
Bot一覧 アルファベット順
・・・悪質・お行儀の悪いBot
AhrefsBot SEO関連クローラー 英語圏
AlphaBot SEO関連クローラー 英語圏
BacklinkCrawler
Baidu 百度 (検索エンジン)中国産クローラー 頻度が多く負荷も高くかなり迷惑
Baiduspider 百度 (検索エンジン)中国産クローラー 頻度が多く負荷も高くかなり迷惑
Barkrowler
bingbot bingクローラー
BingPreview bingクローラー
BLEXBot SEO関連クローラー 英語圏
Browserlet
BUbiNG
CCBot
Cliqzbot
Crawler
DnyzBot
DotBot
Exabot
ExtLinksBot
Facebot
FeedWordPress
Google favicon
Google Web Preview
Googlebot
Google-Site-Verification
GrapeshotCrawler
GroupHigh
Hatena
http
ia_archiver
ICC-Crawler
ichiro
inktomi
Linguee Bot
linkdexbot
Mappy 株式会社Core (Webマーケティング企業)のコンテンツデータ収集・解析用クローラー
MarkAgent
marsflag
MauiBot 詳細不明 頻度が多く注意
MegaIndex.ru MegaIndex SEO分析英語・ロシア語有料のコンテンツデータ収集・解析用クローラー
Megalodon
MJ12bot イギリスのMajestic12社による分散型Webクローラー 頻度が多くうざいタイプ
moget
msnbot
naver
NaverBot
NetcraftSurveyAgent
OutclicksBot
PhantomJS
ShortLinkTranslate
Pinterest
rogerbot
SemrushBot SEMrush SEO・マーケティングツール英語・有料情報を収集しているクローラー
SEOkicks-Robot
siclab
SiteExplorer
Slurp
SMTBot
Sottopop
spbot
spider
Steeler
Turnitin
Twitterbot
uCrawler
W3C_Validator
Website Explorer
Wotbox
Y!J
YaK
Yandex Yandex (検索エンジン)ロシア産クローラー
YandexAntivirus Yandex (検索エンジン)ロシア産クローラー
YandexBot Yandex (検索エンジン)ロシア産クローラー
YandexImages Yandex (検索エンジン)ロシア産クローラー
Yeti
yodaobot
robot.txt
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 |
User-agent: * Disallow: /eternall/ User-agent: * Disallow: /snow/ User-agent: * Disallow: /indefinitely/ User-agent: * Disallow: /indefinitely-g/ User-agent: * Disallow: /faith3/ User-agent: * Disallow: /lunaetsol/ User-agent: * Disallow: / User-agent: Mediapartners-Google Disallow: / User-agent: Googlebot Disallow: / User-agent: Adsbot-Google Disallow: / User-agent: Googlebot-Image Disallow: / User-agent: Googlebot-Mobile Disallow: / User-agent: Yandex Disallow: / User-agent: BLEXBot Disallow: / User-agent: AhrefsBot Disallow: / User-agent: MJ12bot Disallow: / User-agent: baiduspider Disallow: / User-agent: SemrushBot Disallow: / User-agent: Pinterest Disallow: / User-Agent:Megalodon Disallow: / |
ここからは、興味のある方のみどうぞ
htaccessに限らず、HTML/CSSファイル・PHP/JAVAなどのプログラムを作る時には
テキストエディタというものを使います
Windowsには、メモ帳というテキストエディタが付属しています
HTML/CSSファイルを作成する分にはメモ帳で十分です
ですが、htaccessやPHP/JAVAなどのプログラムファイル系の物を作成する場合
【UTF-8 Bomなし】という文字コードで保存する必要性があり
メモ帳では、UTF-8 Bomなし保存できません
その為、別途テキストエディタが必要になります
個人的所感ですが、初心者でも使いやすい「TeraPad」というエディタがありますので
こちらの使用をお勧めします
以下 htaccessファイルの簡単な作成・設置方法
htaccessなんてわからないという方は、上の内容をコピペしてください
1. TeraPadを起動し、上のhtaccess見本から必要部分をコピーしTeraPadに張り付け
2. TeraPad内メニューより、ファイル→文字/改行コード指定保存 を選択
3. 文字コード UTF-8N(UTF-8 Bomなしという意味になります UTF-8はBomありという意味です)
改行コード CR+LF に変更しOKをClick
4. TeraPad内メニューより、ファイル→名前を付けて保存 ファイル名はhtaccess 形式はtxtで保存します
5. 転送ソフトなどを用いて、サーバーにアップロードします
6. アップロード完了後に、リネームを行います .htaccessに変更し txtなどの部分は削除してください
7. パーミッション(属性)の変更を行います 基本は、644 共用レンタルサーバーなどの場合は、604
以上で設置完了です