0
0
mirror of https://codeberg.org/crimeflare/cloudflare-tor synced 2024-12-22 15:40:32 +00:00

example.json.is_cloudflare.php

This commit is contained in:
Christian Paulus 2021-04-02 07:42:16 +02:00
parent 87adff59c1
commit 3486043827

View File

@ -18,7 +18,7 @@ How to use json file
*/ */
function is_listed_cf($domain) function is_listed_cf($domain)
{ {
if (!in_array(substr($domain, 0, 1), ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z'], true)) { if (!in_array($domain[0], ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z'], true)) {
return [false, false]; return [false, false];
} }
$got = @json_decode(file_get_contents('/path/to/jsonfiles/cloudflare_' . $domain[0] . '.json'), true); $got = @json_decode(file_get_contents('/path/to/jsonfiles/cloudflare_' . $domain[0] . '.json'), true);