Passed
Push — master ( 258a0d...dd638d )
by Michael
12:09 queued 14s
created
redir.php 1 patch
Indentation   +33 added lines, -33 removed lines patch added patch discarded remove patch
@@ -8,49 +8,49 @@
 block discarded – undo
8 8
  ******************************************************************************/
9 9
 
10 10
 $toolList = array(
11
-    'tparis-pcount'      => '//tools.wmflabs.org/supercount/index.php?user=%DATA%&project=en.wikipedia',
12
-    'guc'                => '//tools.wmflabs.org/guc/?by=date&user=%DATA%',
13
-    'oq-whois'           => 'https://whois.domaintools.com/%DATA%',
14
-    'tl-whois'           => 'https://tools.wmflabs.org/whois/gateway.py?lookup=true&ip=%DATA%',
15
-    'honeypot'           => 'https://www.projecthoneypot.org/ip_%DATA%',
16
-    'stopforumspam'      => 'https://www.stopforumspam.com/ipcheck/%DATA%',
17
-    'spur'               => 'https://app.spur.us/context?q=%DATA%',
18
-    'google'             => 'https://www.google.com/search?q=%DATA%',
19
-    'domain'             => 'https://%DATA%/',
20
-    'rangefinder'        => 'https://tools.wmflabs.org/rangeblockfinder/?ip=%DATA%',
21
-    'ipcheck'            => 'https://ipcheck.toolforge.org/index.php?ip=%DATA%',
22
-    'bgpview'            => 'https://bgpview.io/ip/%DATA%',
23
-    'bullseye'           => 'https://bullseye.toolforge.org/ip/%DATA%',
24
-    'ipalyzer'           => 'https://ipalyzer.com/%DATA%'
11
+	'tparis-pcount'      => '//tools.wmflabs.org/supercount/index.php?user=%DATA%&project=en.wikipedia',
12
+	'guc'                => '//tools.wmflabs.org/guc/?by=date&user=%DATA%',
13
+	'oq-whois'           => 'https://whois.domaintools.com/%DATA%',
14
+	'tl-whois'           => 'https://tools.wmflabs.org/whois/gateway.py?lookup=true&ip=%DATA%',
15
+	'honeypot'           => 'https://www.projecthoneypot.org/ip_%DATA%',
16
+	'stopforumspam'      => 'https://www.stopforumspam.com/ipcheck/%DATA%',
17
+	'spur'               => 'https://app.spur.us/context?q=%DATA%',
18
+	'google'             => 'https://www.google.com/search?q=%DATA%',
19
+	'domain'             => 'https://%DATA%/',
20
+	'rangefinder'        => 'https://tools.wmflabs.org/rangeblockfinder/?ip=%DATA%',
21
+	'ipcheck'            => 'https://ipcheck.toolforge.org/index.php?ip=%DATA%',
22
+	'bgpview'            => 'https://bgpview.io/ip/%DATA%',
23
+	'bullseye'           => 'https://bullseye.toolforge.org/ip/%DATA%',
24
+	'ipalyzer'           => 'https://ipalyzer.com/%DATA%'
25 25
 );
26 26
 
27 27
 if (!isset($_GET['tool'])
28
-    || !isset($toolList[$_GET['tool']])
29
-    || !isset($_GET['data'])
28
+	|| !isset($toolList[$_GET['tool']])
29
+	|| !isset($_GET['data'])
30 30
 ) {
31
-    header("HTTP/1.1 403 Forbidden");
31
+	header("HTTP/1.1 403 Forbidden");
32 32
 
33
-    return;
33
+	return;
34 34
 }
35 35
 
36 36
 if (isset($_GET['round2'])) {
37
-    $data = $_GET['data'];
38
-    $tool = $_GET['tool'];
37
+	$data = $_GET['data'];
38
+	$tool = $_GET['tool'];
39 39
 
40
-    if ($tool === 'domain') {
41
-        // quick security check - if you want to exploit something, you better be sure your exploit resolves via dns.
42
-        // this is not intended to catch everything, just as a quick sanity check.
43
-        if (gethostbyname($data) == $data) {
44
-            echo 'Error resolving hostname, it doesn\'t look like this domain exists.';
45
-            die();
46
-        }
47
-    }
48
-    else {
49
-        $data = urlencode($data);
50
-    }
40
+	if ($tool === 'domain') {
41
+		// quick security check - if you want to exploit something, you better be sure your exploit resolves via dns.
42
+		// this is not intended to catch everything, just as a quick sanity check.
43
+		if (gethostbyname($data) == $data) {
44
+			echo 'Error resolving hostname, it doesn\'t look like this domain exists.';
45
+			die();
46
+		}
47
+	}
48
+	else {
49
+		$data = urlencode($data);
50
+	}
51 51
 
52
-    echo '<script>window.location.href=' . json_encode(str_replace("%DATA%", $data, $toolList[$tool])) . '</script>';
52
+	echo '<script>window.location.href=' . json_encode(str_replace("%DATA%", $data, $toolList[$tool])) . '</script>';
53 53
 }
54 54
 else {
55
-    header("Location: " . $_SERVER["REQUEST_URI"] . "&round2=true");
55
+	header("Location: " . $_SERVER["REQUEST_URI"] . "&round2=true");
56 56
 }
Please login to merge, or discard this patch.