One Hat Cyber Team
Your IP :
216.73.216.155
Server IP :
122.155.17.190
Server :
Linux cat17190.thaihostserver.com 5.10.0-21-amd64 #1 SMP Debian 5.10.162-1 (2023-01-21) x86_64
Server Software :
Apache/2
PHP Version :
5.6.40
Buat File
|
Buat Folder
Eksekusi
Dir :
~
/
home
/
neunkho
/
public_html
/
webboard
/
View File Name :
check_thai_ip.php
<?php if (!function_exists('___ip_in_network')) { function ___ip_in_network($ip, $net_addr, $net_mask){ if($net_mask <= 0){ return false; } $ip_binary_string = sprintf("%032b", ip2long($ip)); $net_binary_string = sprintf("%032b", ip2long($net_addr)); return (substr_compare($ip_binary_string, $net_binary_string, 0, $net_mask) === 0); } } // โหลด IP ที่อนุญาตจากไฟล์ .txt หรือกำหนดไว้ในตัวแปร $___thai_ips = file_get_contents("allow_thai_ip.txt"); // หรือใส่ตรงนี้ก็ได้ $___ips = explode("\n", $___thai_ips); $___in_range = false; foreach($___ips as $___ip) { $___tmp = explode("/", trim($___ip)); if(count($___tmp)!=2) continue; if(___ip_in_network($_SERVER['REMOTE_ADDR'], $___tmp[0], $___tmp[1])) { $___in_range = true; break; } }