Login
Username: Password:
Remember me

[Sign Up] / [Recover Password]

Theme / Language

Popular
New Torrents
new name
Size: 18.40 MB
Most active
new name
S: 74 L: 3
New Posters
BLOCK PROXY WEB *[Complete]
Controls ·  Search New posts · Mark unread

You are in: Forum / Forum / Torrent Trader / v3 Mods Completed

Unknown User
2020-03-29 14:54:31
hello i have made a code to block PROXY WEB all possible PROXY WEBS ! Just edit extremlymtorrents with your site!

<script type="text/javascript">
 if(!location.hostname.match(/(^|\.)extremlymtorrents.ws$/)){
   window.location="https://extremlymtorrents.ws/";
 }
 function shapeSpace_block_proxy_visits() {

   $ports = array(80,81,553,554,1080,3128,4480,6588,8000,8080);

   foreach ($ports as $port) {
       if (@fsockopen($_SERVER['REMOTE_ADDR'], $port, $errno, $errstr, 5)) {
           die('SUCK IT Proxy access not allowed ExtremlymTorrents.ws Rules MMFKR _)_');
       }
   }
}
function shapeSpace_block_proxy_visits() {

   $headers = array('CLIENT_IP','FORWARDED','FORWARDED_FOR','FORWARDED_FOR_IP','VIA','X_FORWARDED','X_FORWARDED_FOR','HTTP_CLIENT_IP','HTTP_FORWARDED','HTTP_FORWARDED_FOR','HTTP_FORWARDED_FOR_IP','HTTP_PROXY_CONNECTION','HTTP_VIA','HTTP_X_FORWARDED','HTTP_X_FORWARDED_FOR');

   foreach ($headers as $header){
       if (isset($_SERVER[$header])) {
           die('SUCK IT Proxy access not allowed ExtremlymTorrents.ws Rules MMFKR _)_');
       }
   }
}
$proxy_headers = array(
   'HTTP_VIA',
   'HTTP_X_FORWARDED_FOR',
   'HTTP_FORWARDED_FOR',
   'HTTP_X_FORWARDED',
   'HTTP_FORWARDED',
   'HTTP_CLIENT_IP',
   'HTTP_FORWARDED_FOR_IP',
   'VIA',
   'X_FORWARDED_FOR',
   'FORWARDED_FOR',
   'X_FORWARDED',
   'FORWARDED',
   'CLIENT_IP',
   'FORWARDED_FOR_IP',
   'HTTP_PROXY_CONNECTION'
);
foreach($proxy_headers as $x){
   if (isset($_SERVER[$x])){ die("You are using a proxy!") };
}
function shapeSpace_block_proxy_visits() {

if (@fsockopen($_SERVER['REMOTE_ADDR'], 80, $errstr, $errno, 1)) {

die('SUCK IT Proxy access not allowed ExtremlymTorrents.ws Rules MMFKR _)_'); } } add_action('after_setup_theme',

'shapeSpace_block_proxy_visits');
</script>
<?php if(@fsockopen($_SERVER['REMOTE_ADDR'], 80, $errstr, $errno, 1))
die("SUCK IT Proxy access not allowed ExtremlymTorrents.ws Rules MMFKR _)_"); ?>


ADD THIS TO account-login.php /  /  account-signup.php / /  account-recover.php first line

this will block all LOGIN SIGNUP RECOVER  acces to your site !!!
2022-11-18 19:25:59
Someone who has tested it?


www.exyusubs.com
TorrentTrader V3.8.3 (SE)
OS: AlmaLinux 9.9 (BC)
Apache version: 2.4.71
PHP version: 8.5.13 (PHP-FPM)
MySQL version: 10.11.18-MariaDB
2022-11-22 20:06:06
I wouldn't. The code is fairly loose and can be done in a single function without all of these different calls.

Never rely on JS regex for domain matching, anyone can edit website source and mess around (should be done in PHP with preg_match() and pass a bool to JSON). The same way they clone, by downloading the source and editing HTML and double clicking on the HTML document. This is why I use cross-origin policies, it blocks local POST/GET requests.

If you need this done, let me know.
2022-11-23 04:42:12
looks expensive but the logic looks ok you would need to open ports

cant remember if its  FORWARDED_FOR that returns false positives. Always thought the best option for vpn detection was a array list/txt file and then in_array. That would be bulletproof as long as the list was up-to-date.
2022-11-23 15:23:32
For VPN I had to use a API, it worked perfectly but this was ~2 years ago and since then I think its important to use a VPN. There just doesn't seem to be a PHP all-solution without some service API that is the holy grail.

2022-11-23 18:07:37
Of course it is necessary these days to use VPN or proxy but there are many who abuse this possibility on private trackers and enjoy registering the double account and that was my purpose of the question. Thanks for all the replies guys


www.exyusubs.com
TorrentTrader V3.8.3 (SE)
OS: AlmaLinux 9.9 (BC)
Apache version: 2.4.71
PHP version: 8.5.13 (PHP-FPM)
MySQL version: 10.11.18-MariaDB
Users online

No users online

Search



Statistics

    Torrents

  • Tracking: 3
  • Todays torrents: 0
  • Seeders: 0
  • Leechers: 0
  • Peers: 0
  • Downloaded: 89.96 GB
  • Uploaded: 9.86 GB

  • Members

  • We have: 838
  • New today: 0
  • Guest today: 9

  • Online

  • Total online: 5
  • Members: 0
  • Guests online: 5
  • Comments: 3
  • Messages: 1,728