Forum Moderators: phranque
RewriteCond %{HTTP_REFERER} ^http://([^./]\.)+tk(:[0-9]+)/
RewriteRule .* - [F]
If you use a custom 403 error document, add a RewriteCond to this rule to exclude your ErrorDocument URL from being rewritten, in order to avoid an 'infinite' loop:
RewriteCond %{REQUEST_URI} !/path-to-your-403-ErrorDocument
RewriteCond %{HTTP_REFERER} ^http://([^./]\.)+tk(:[0-9]+)/
RewriteRule .* - [F]