Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # This incomplete apache vhost config will demonstrate how futile domain and ip bans are.
- # Remember that this is only one of the many, many, many ways to go around the problem :)
- # This should work out of the box if you just enable the following apache mods:
- # rewrite
- # proxy
- # proxy_html
- # Just replace yourdomain.com with the domain of your choosing.
- # TPB will be accessible from yourdomain.com/main/ (trailing / is needed)
- <VirtualHost *:80>
- <Proxy *>
- Order deny,allow
- Allow from all
- </Proxy>
- # Change to your domain
- ServerName yourdomain.com
- # Just to fix a few links...
- RewriteEngine On
- RewriteRule \/main\/\/static\.thepiratebay\.org\/(.*)$ /static/$1 [R=302,L]
- ProxyRequests off
- ProxyPass /main/ http://thepiratebay.org/
- ProxyPass /static/ http://static.thepiratebay.org/
- ProxyPass /torrents/ http://torrents.thepiratebay.org/
- ProxyHTMLURLMap http://thepiratebay.org /main
- ProxyHTMLURLMap http://([a-z]*).thepiratebay.org /$1 R
- <Location /main/>
- ProxyPassReverse /
- SetOutputFilter proxy-html
- ProxyHTMLURLMap / /main/
- RequestHeader unset Accept-Encoding
- </Location>
- <Location /static/>
- ProxyPassReverse /
- SetOutputFilter proxy-html
- ProxyHTMLURLMap / /static/
- RequestHeader unset Accept-Encoding
- </Location>
- <Location /torrents/>
- ProxyPassReverse /
- SetOutputFilter proxy-html
- ProxyHTMLURLMap / /torrents/
- RequestHeader unset Accept-Encoding
- </Location>
- </VirtualHost>
Advertisement
Add Comment
Please, Sign In to add comment