Browse code

This fixes the scrape data issue that has long plagued this software (2012). Filtering other data is fine, but scrape data ends up going to and from the torrent client and the tracker anyway, and they don't like the custom filters. This was confirmed by finding and going through the original PHPBTTracker software code and comparing it with RivetTracker.

Clarissa Walker authored on 2015/09/10 03:10:09
Showing 1 changed files
... ...
@@ -71,13 +71,13 @@ if (preg_match("/^Mozilla|^Opera|^Links|^Lynx/i", $agent))
71 71
 			if (isset($_GET["info_hash"]))
72 72
 			{
73 73
 				if (get_magic_quotes_gpc())
74
-					$info_hash = stripslashes(trim(strip_tags($_GET["info_hash"])));
74
+					$info_hash = stripslashes($_GET["info_hash"]);
75 75
 				else
76
-					$info_hash = trim(strip_tags($_GET["info_hash"]));
76
+					$info_hash = $_GET["info_hash"];
77 77
 				if (strlen($info_hash) == 20)
78
-					$info_hash = filterChar(bin2hex($info_hash));
78
+					$info_hash = bin2hex($info_hash);
79 79
 				else if (strlen($info_hash) == 40)
80
-					filterInt(verifyHash($info_hash)) or showError("Invalid info hash value.");
80
+					verifyHash($info_hash) or showError("Invalid info hash value.");
81 81
 				else
82 82
 					showError("Invalid info hash value.");
83 83
 				$usehash = true;