How can I protect my site from HTTrack or other software's ripping?

后端 未结 5 1730
终归单人心
终归单人心 2021-02-01 09:27

I recently got a Site Template approved on Themeforest. I am getting just too much traffic on my site and noticed that my demo on Themeforest is getting ripped by some softwares

5条回答
  •  感情败类
    2021-02-01 09:49

    At least, you can try any of these though user agent can be tricked.

    (1) In .htaccess

    RewriteCond %{HTTP_USER_AGENT} ^HTTrack [OR]
    RewriteCond %{HTTP_USER_AGENT} ^SiteSucker [OR]
    RewriteCond %{HTTP_USER_AGENT} ^WebZip [OR]
    RewriteCond %{HTTP_USER_AGENT} ^WebCopier [OR]
    RewriteCond %{HTTP_USER_AGENT} ^Zeus
    RewriteRule ^.*$ no_download.html [L]
    

    Add additional Spam_bot by adding RewriteCond %{HTTP_USER_AGENT} ^Other_Spam_bot after [OR]

    (2) In robots.txt

    User-agent: AhrefsBot
    User-agent: Baiduspider
    User-agent: EasouSpider
    User-agent: Ezooms
    User-agent: YandexBot
    User-agent: MJ12bot
    User-agent: SiteSucker
    User-agent: HTTrack
    Disallow: /
    

    Add additional Spam_bot by adding User-agent: Other_Spam_bot before Disallow: /

提交回复
热议问题