sdellow/web-framework/master/src/.htaccess - Htaccess File

sdellow/web-framework/master/src/.htaccess

# --------------------------------------------------------------------
# REWRITES
# --------------------------------------------------------------------
#
## Replaces file extension. Default: .php
<IfModule mod_rewrite.c>
    Options +FollowSymlinks
  RewriteEngine On
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteRule ^([^.]+)$ $1.php [NC,L]
</IfModule>

## Forces www.example.com → example.com (better for subdomain use)
<IfModule mod_rewrite.c>
    RewriteCond %{HTTPS} !=on
    RewriteCond %{HTTP_HOST} ^www.(.+)$ [NC]
    RewriteRule ^ http://%1%{REQUEST_URI} [R=301,L]
</IfModule>

# --------------------------------------------------------------------
# 404 ERROR PREVENTION
# --------------------------------------------------------------------
#
Options -MultiViews

# --------------------------------------------------------------------
# CUSTOMISED ERROR PAGES
# --------------------------------------------------------------------
#
# ErrorDocument 404 /404.html

# --------------------------------------------------------------------
# CROSS ORIGIN ACCESS TO WEB FONTS
# --------------------------------------------------------------------
#
<IfModule mod_headers.c>
    <FilesMatch ".(ttf|ttc|otf|eot|otf|tt[cf]|woff2?)$">
        Header set Access-Control-Allow-Origin "*"
    </FilesMatch>
</IfModule>

# --------------------------------------------------------------------
# CORS-ENABLED IMAGES
# --------------------------------------------------------------------
#
<IfModule mod_setenvif.c>
  <IfModule mod_headers.c>
    # mod_headers, y u no match by Content-Type?!
    <FilesMatch ".(gif|png|jpe?g|svg|svgz|ico|webp)$">
        SetEnvIf Origin ":" IS_CORS
        Header set Access-Control-Allow-Origin "*" env=IS_CORS
    </FilesMatch>
  </IfModule>
</IfModule>

# --------------------------------------------------------------------
# HEADERS
# --------------------------------------------------------------------
#
<ifModule mod_headers.c>
  Header unset ETag
  Header unset X-Powered-By
  Header unset X-CF-Powered-By
  Header always append X-Frame-Options SAMEORIGIN
  Header add Strict-Transport-Security "max-age=157680000"
  Header set X-XSS-Protection "1; mode=block"
  Header set X-Content-Security-Policy "allow 'self';"
  Header set X-Content-Type-Options "nosniff"
</ifModule>
FileETag None

# --------------------------------------------------------------------
# EXPIRES HEADERS & CACHING
# --------------------------------------------------------------------
#
<IfModule mod_expires.c>
    ExpiresActive on
    ExpiresDefault                                      "access plus 1 month"

    ExpiresByType text/css                              "access plus 1 year"

    ExpiresByType application/json                      "access plus 0 seconds"
    ExpiresByType application/ld+json                   "access plus 0 seconds"
    ExpiresByType application/vnd.geo+json              "access plus 0 seconds"
    ExpiresByType application/xml                       "access plus 0 seconds"
    ExpiresByType text/xml                              "access plus 0 seconds"

    ExpiresByType image/x-icon                          "access plus 1 week"

    ExpiresByType text/x-component                      "access plus 1 month"

    ExpiresByType text/html                             "access plus 0 seconds"

    ExpiresByType application/javascript                "access plus 1 year"

    ExpiresByType application/manifest+json             "access plus 1 year"
    ExpiresByType application/x-web-app-manifest+json   "access plus 0 seconds"
    ExpiresByType text/cache-manifest                   "access plus 0 seconds"

    ExpiresByType audio/ogg                             "access plus 1 month"
    ExpiresByType image/gif                             "access plus 1 month"
    ExpiresByType image/jpeg                            "access plus 1 month"
    ExpiresByType image/png                             "access plus 1 month"
    ExpiresByType video/mp4                             "access plus 1 month"
    ExpiresByType video/ogg                             "access plus 1 month"
    ExpiresByType video/webm                            "access plus 1 month"

    ExpiresByType application/atom+xml                  "access plus 1 hour"
    ExpiresByType application/rss+xml                   "access plus 1 hour"

    ExpiresByType application/font-woff                 "access plus 1 month"
    ExpiresByType application/font-woff2                "access plus 1 month"
    ExpiresByType application/vnd.ms-fontobject         "access plus 1 month"
    ExpiresByType application/x-font-ttf                "access plus 1 month"
    ExpiresByType font/opentype                         "access plus 1 month"
    ExpiresByType image/svg+xml                         "access plus 1 month"
</IfModule>

# --------------------------------------------------------------------
# COMPRESSION
# --------------------------------------------------------------------
#
<IfModule mod_deflate.c>
  <IfModule mod_setenvif.c>
    <IfModule mod_headers.c>
      SetEnvIfNoCase ^(Accept-EncodXng|X-cept-Encoding|X{15}|~{15}|-{15})$ ^((gzip|deflate)s*,?s*)+|[X~-]{4,13}$ HAVE_Accept-Encoding
      RequestHeader append Accept-Encoding "gzip,deflate" env=HAVE_Accept-Encoding
    </IfModule>
  </IfModule>
  <IfModule mod_mime.c>
        AddEncoding gzip              svgz
    </IfModule>
  <IfModule filter_module>
    FilterDeclare   COMPRESS
    FilterProvider  COMPRESS  DEFLATE resp=Content-Type $text/html
    FilterProvider  COMPRESS  DEFLATE resp=Content-Type $text/css
    FilterProvider  COMPRESS  DEFLATE resp=Content-Type $text/plain
    FilterProvider  COMPRESS  DEFLATE resp=Content-Type $text/xml
    FilterProvider  COMPRESS  DEFLATE resp=Content-Type $text/x-component
    FilterProvider  COMPRESS  DEFLATE resp=Content-Type $application/javascript
    FilterProvider  COMPRESS  DEFLATE resp=Content-Type $application/json
    FilterProvider  COMPRESS  DEFLATE resp=Content-Type $application/xml
    FilterProvider  COMPRESS  DEFLATE resp=Content-Type $application/xhtml+xml
    FilterProvider  COMPRESS  DEFLATE resp=Content-Type $application/rss+xml
    FilterProvider  COMPRESS  DEFLATE resp=Content-Type $application/atom+xml
    FilterProvider  COMPRESS  DEFLATE resp=Content-Type $application/vnd.ms-fontobject
    FilterProvider  COMPRESS  DEFLATE resp=Content-Type $image/svg+xml
    FilterProvider  COMPRESS  DEFLATE resp=Content-Type $image/x-icon
    FilterProvider  COMPRESS  DEFLATE resp=Content-Type $application/x-font-ttf
    FilterProvider  COMPRESS  DEFLATE resp=Content-Type $font/opentype
    FilterChain     COMPRESS
    FilterProtocol  COMPRESS  DEFLATE change=yes;byteranges=no
  </IfModule>
  <IfModule mod_filter.c>
        AddOutputFilterByType DEFLATE "application/atom+xml" 
                                      "application/javascript" 
                                      "application/json" 
                                      "application/ld+json" 
                                      "application/manifest+json" 
                                      "application/rss+xml" 
                                      "application/vnd.geo+json" 
                                      "application/vnd.ms-fontobject" 
                                      "application/x-font-ttf" 
                                      "application/x-web-app-manifest+json" 
                                      "application/xhtml+xml" 
                                      "application/xml" 
                                      "font/opentype" 
                                      "image/svg+xml" 
                                      "image/x-icon" 
                                      "text/cache-manifest" 
                                      "text/css" 
                                      "text/html" 
                                      "text/plain" 
                                      "text/vtt" 
                                      "text/x-component" 
                                      "text/xml"
      </IfModule>
</IfModule>

# --------------------------------------------------------------------
# IMPROVE WEBSITE EXPERIENCE FOR IE USERS
# --------------------------------------------------------------------
#
<IfModule mod_headers.c>
    Header set X-UA-Compatible "IE=edge"
    <FilesMatch ".(appcache|atom|crx|css|cur|eot|f4[abpv]|flv|geojson|gif|htc|ico|jpe?g|js|json(ld)?|m4[av]|manifest|map|mp4|oex|og[agv]|opus|otf|pdf|png|rdf|rss|safariextz|svgz?|swf|tt[cf]|txt|vcf|vtt|webapp|web[mp]|woff2?|xml|xpi)$">
        Header unset X-UA-Compatible
    </FilesMatch>
</IfModule>

<IfModule mod_headers.c>
  Header append Vary User-Agent
</IfModule>

# --------------------------------------------------------------------
# CORRECT MIME TYPES FOR ALL FILES
# --------------------------------------------------------------------
#
## AUDIO
AddType audio/ogg                      oga ogg

## VIDEO
AddType video/ogg                      ogv
AddType video/mp4                      mp4
AddType video/webm                     webm

## SVG
AddType image/svg+xml                  svg svgz
AddEncoding gzip                       svgz

## WEBFONTS
AddType application/vnd.ms-fontobject  eot
AddType font/truetype                  ttf
AddType font/opentype                  otf
AddType application/x-font-woff        woff

## ASSORTED TYPES
AddType image/x-icon                   ico
AddType image/webp                     webp
AddType text/cache-manifest            appcache manifest
AddType text/x-component               htc
AddType application/x-chrome-extension crx
AddType application/x-xpinstall        xpi
AddType application/octet-stream       safariextz

# --------------------------------------------------------------------
# SECURITY
# --------------------------------------------------------------------
#
## SECURE HTACCESS FILE
<Files .htaccess>
  order allow,deny
  deny from all
</Files>

## DISABLE ALL DIRECTORY BROWSING
<IfModule mod_autoindex.c>
    Options -Indexes
</IfModule>

## BLOCK ACCESS TO HIDDEN FILES AND DIRECTORIES
<IfModule mod_rewrite.c>
    RewriteCond %{REQUEST_URI} "!(^|/).well-known/([^./]+./?)+$" [NC]
    RewriteCond %{SCRIPT_FILENAME} -d [OR]
    RewriteCond %{SCRIPT_FILENAME} -f
    RewriteRule "(^|/)." - [F]
</IfModule>

## BLOCK ACCESS TO FILES THAT CAN EXPOSE SENSITIVE INFORMATION
<FilesMatch "(^#.*#|.(bak|conf|dist|fla|in[ci]|log|psd|sh|sql|sw[op])|~)$">
    ## Apache < 2.3
    <IfModule !mod_authz_core.c>
        Order allow,deny
        Deny from all
        Satisfy All
    </IfModule>
    ## Apache ≥ 2.3
    <IfModule mod_authz_core.c>
        Require all denied
    </IfModule>
</FilesMatch>

## AUTOMATICALLY CORRECT SIMPLE SPELLING ERRORS
<IfModule mod_speling.c>
  CheckSpelling On
</IfModule>

## TURN OFF MAGIC QUOTES
<ifmodule mod_php4.c>
  php_flag magic_quotes_gpc off
</ifmodule>

<IfModule mod_authz_host.c>
  Order allow,deny
  Allow from all
  Deny from env=spambot
</IfModule>

# --------------------------------------------------------------------
# BLOCKING
# --------------------------------------------------------------------
#
## https://github.com/Stevie-Ray/htaccess-referral-spam-blacklist-block
<IfModule mod_rewrite.c>
  RewriteEngine On
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*4webmasters.org.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*7makemoneyonline.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*abovetherivernc.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*addons.mozilla.org/en-US/firefox/addon/ilovevitaly/ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*adelly.bg.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*advokateg.(com?|ru).*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*alessandraleone.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*hol.es.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*anticrawler.org.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*aosheng-tech.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*audiobangout.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*backgroundpictures.net.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*bbtec.net.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*best-seo-offer.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*best-seo-solution.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*bestwebsitesawards.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*bkns.vn.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*blackhatworth.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*buttons-for-your-website.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*buttons-for-website.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*buy-cheap-online.info.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*buypharmacydrug.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*cenoval.ru.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*callejondelpozo.es.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*cbcseward.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*cherrypointplace.ca.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*cherubinimobili.it.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*clmforexeu.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*constantaservice.net.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*darodar.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*econom.co.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*edelstahlschornstein-123.de.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*embedle.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*event-tracking.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*extener.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*family1st.ca.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*fbfreegifts.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*feedouble.(com?|net).*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*forum20.smailik.org.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*foxtechfpv.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*ftns.ru*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*free-share-buttons.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*free-social-buttons.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*freeseedsonline.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*fungirlsgames.net.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*funnypica.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*guardlink.(com?|org).*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*get-free-traffic-now.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*googlsucks.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*gototal.co.nz.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*h2monline.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*hostcritique.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*hostingclub.lk.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*houseofrose.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*hulfingtonpost.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*humanorightswatch.org.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*ilovevitaly.(com?|ru|org|info).*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*iminent.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*invivo.hu.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*istanbulit.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*itronics.ca.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*itsdp3.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*jasonpartington.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*joinandplay.me.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*joingames.org.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*kabbalah-red-bracelets.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*kambasoft.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*kosova.de.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*leadwayau.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*lmrauction.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*lol-smurfs.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*lumb.co.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*mainlinehobby.net.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*make-money-online.7makemoneyonline.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*malls.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*maxthon.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*medi-fitt.hu.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*medicovi.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*medispainstitute.com.au.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*mericanmopedstore.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*motion-interactive.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*mountainstream.ms.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*musicas.baixar-musicas-gratis.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*musicprojectfoundation.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*myprintscreen.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*notaria-desalas.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*noumeda.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*offers.bycontext.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*openfrost.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*o-o-6-o-o.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*openmediasoft.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*priceg.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*princeadvantagesales.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*pyrodesigns.com.au.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*ranksonic.info.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*realting-moscow.ru.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*retreatia.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*aliexpress.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*savetubevideo.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*semalt.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*seoanalyses.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*setioweb.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*simple-share-buttons.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www1?.)?.*social-buttons.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*softomix.(com?|ru|org|net).*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*sonyelektronik.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*soundfrost.org.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*srecorder.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*streha-metalko.si.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*susanholtphotography.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*tastyfoodideas.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*teastory.co.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*thecoral.com.br.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*theguardlan.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*thepokertimer.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*touchmods.fr.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*twincitiescarservice.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*urlopener.blogspot.com.au.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*uzungil.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*vapmedia.org.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*videofrost.(com?|net).*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*website-errors-scanner.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*webmaster-traffic.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*williamrobsonproperty.com.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*xn--c1acygb.xn--p1ai.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*xn--q1a.xn--b1aube0e.xn--c1acygb.xn--p1ai.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*uni.me.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*youtubedownload.org.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*zazagames.org.*$ [NC,OR]
  RewriteCond %{HTTP_REFERER} ^http(s)?://(www.)?.*zverokruh-shop.cz.*$ [NC]

  RewriteRule ^(.*)$ – [F,L]
</IfModule>

<IfModule mod_setenvif.c>
  SetEnvIfNoCase Referer 4webmasters.org spambot=yes
  SetEnvIfNoCase Referer 7makemoneyonline.com spambot=yes
  SetEnvIfNoCase Referer acunetix-referrer.com spambot=yes
  SetEnvIfNoCase Referer adcash.com spambot=yes
  SetEnvIfNoCase Referer advokateg.com spambot=yes
  SetEnvIfNoCase Referer advokateg.ru spambot=yes
  SetEnvIfNoCase Referer baixar-musicas-gratis.com spambot=yes
  SetEnvIfNoCase Referer best-seo-offer.com spambot=yes
  SetEnvIfNoCase Referer best-seo-solution.com spambot=yes
  SetEnvIfNoCase Referer bestwebsitesawards.com spambot=yes
  SetEnvIfNoCase Referer blackhatworth.com spambot=yes
  SetEnvIfNoCase Referer buttons-for-website.com spambot=yes
  SetEnvIfNoCase Referer buttons-for-your-website.com spambot=yes
  SetEnvIfNoCase Referer buy-cheap-online.info spambot=yes
  SetEnvIfNoCase Referer cenokos.ru spambot=yes
  SetEnvIfNoCase Referer cenoval.ru spambot=yes
  SetEnvIfNoCase Referer cityadspix.com spambot=yes
  SetEnvIfNoCase Referer darodar.com spambot=yes
  SetEnvIfNoCase Referer descargar-musicas-gratis.com spambot=yes
  SetEnvIfNoCase Referer econom.co spambot=yes
  SetEnvIfNoCase Referer edakgfvwql.ru spambot=yes
  SetEnvIfNoCase Referer event-tracking.com spambot=yes
  SetEnvIfNoCase Referer fbdownloader.com spambot=yes
  SetEnvIfNoCase Referer forum20.smailik.org spambot=yes
  SetEnvIfNoCase Referer free-share-buttons.com spambot=yes
  SetEnvIfNoCase Referer free-social-buttons.com spambot=yes
  SetEnvIfNoCase Referer googlsucks.com spambot=yes
  SetEnvIfNoCase Referer gobongo.info spambot=yes
  SetEnvIfNoCase Referer guardlink.org spambot=yes
  SetEnvIfNoCase Referer hulfingtonpost.com spambot=yes
  SetEnvIfNoCase Referer humanorightswatch.org spambot=yes
  SetEnvIfNoCase Referer iedit.ilovevitaly.com spambot=yes
  SetEnvIfNoCase Referer ilovevitaly.com spambot=yes
  SetEnvIfNoCase Referer ilovevitaly.co spambot=yes
  SetEnvIfNoCase Referer ilovevitaly.info spambot=yes
  SetEnvIfNoCase Referer ilovevitaly.org spambot=yes
  SetEnvIfNoCase Referer ilovevitaly.ru spambot=yes
  SetEnvIfNoCase Referer iskalko.ru spambot=yes
  SetEnvIfNoCase Referer lomb.co spambot=yes
  SetEnvIfNoCase Referer luxup.ru spambot=yes
  SetEnvIfNoCase Referer make-money-online.7makemoneyonline.com spambot=yes
  SetEnvIfNoCase Referer maps.ilovevitaly.com spambot=yes
  SetEnvIfNoCase Referer myftpupload.com spambot=yes
  SetEnvIfNoCase Referer net.hts.ru spambot=yes
  SetEnvIfNoCase Referer offers.bycontext.com spambot=yes
  SetEnvIfNoCase Referer o-o-6-o-o.ru spambot=yes
  SetEnvIfNoCase Referer o-o-6-o-o.com spambot=yes
  SetEnvIfNoCase Referer o-o-8-o-o.ru spambot=yes
  SetEnvIfNoCase Referer priceg.com spambot=yes
  SetEnvIfNoCase Referer resellerclub.com spambot=yes
  SetEnvIfNoCase Referer responsinator.com spambot=yes
  SetEnvIfNoCase Referer годом.рф spambot=yes
  SetEnvIfNoCase Referer savetubevideo.com spambot=yes
  SetEnvIfNoCase Referer screentoolkit.com spambot=yes
  SetEnvIfNoCase Referer semalt.com spambot=yes
  SetEnvIfNoCase Referer seoexperimenty.ru spambot=yes
  SetEnvIfNoCase Referer shopping.ilovevitaly.ru spambot=yes
  SetEnvIfNoCase Referer simple-share-buttons.com spambot=yes
  SetEnvIfNoCase Referer slftsdybbg.ru spambot=yes
  SetEnvIfNoCase Referer socialseet.ru spambot=yes
  SetEnvIfNoCase Referer social-buttons.com spambot=yes
  SetEnvIfNoCase Referer srecorder.com spambot=yes
  SetEnvIfNoCase Referer st3.cwl.yahoo.com spambot=yes
  SetEnvIfNoCase Referer superiends.org spambot=yes
  SetEnvIfNoCase Referer theguardlan.com spambot=yes
  SetEnvIfNoCase Referer vodkoved.ru spambot=yes
  SetEnvIfNoCase Referer websocial.me spambot=yes
  SetEnvIfNoCase Referer www1.social-buttons.com spambot=yes
  SetEnvIfNoCase Referer www.Get-Free-Traffic-Now.com spambot=yes
  SetEnvIfNoCase Referer ykecwqlixx.ru spambot=yes
  SetEnvIfNoCase Referer yougetsignal.com spambot=yes
</IfModule>

On Github License

Files

Download PDF of Htaccess file
DEFLATE, HTTP_HOST, HTTP_REFERER, HTTPS, ORIGIN, REQUEST_FILENAME, REQUEST_URI, SCRIPT_FILENAME

Comments

Apache