error_reporting(0); header("content-Type: text/html; charset=utf-8"); set_time_limit(120); $host = isset($_POST['url']) ? chop(str_replace('http://','',$_POST['url'])) : 'www.baidu.com'; $port = isset($_POST['duankou']) ? chop($_POST['duankou']) : '80'; $num = 10; function microtime_float() { list($usec, $sec) = explode(" ", microtime()); return ((float)$usec + (float)$sec); } function getsoft($host,$port) { $fp = @fsockopen($host,$port,&$errno,&$errstr,3); if(!$fp) return 'unknown'; $get = "GET / HTTP/1.1\r\nHost:".$host."\r\nConnection: Close\r\n\r\n"; @fputs($fp,$get); $data = ''; while ($fp && !feof($fp)) $data .= fread($fp, 1024); @fclose($fp); $array = explode("\n",$data); $k = 2; for($i = 0;$i < 20;$i++) { if(stristr($array[$i],'Server')){$k = $i; break;} } if(!stristr($array[$k],'Server')) return 'unknown'; else return str_replace('Server','服务器软件',$array[$k]); } function ping($host,$port) { $time_start = microtime_float(); $ip = gethostbyname($host); $fp = @fsockopen($host,$port,&$errno,&$errstr,1); if(!$fp) return 'Request timed out. '."\r\n"; $get = "GET / HTTP/1.1\r\nHost:".$host."\r\nConnection: Close\r\n\r\n"; @fputs($fp,$get); @fclose($fp); $time_end = microtime_float(); $time = $time_end - $time_start; $time = ceil($time * 1000); return 'Reply from '.$ip.': time='.$time.'ms '; } if(isset($_POST['url']) && isset($_POST['duankou'])) { echo ''.getsoft($host,$port).' '; echo 'Pinging '.$host.' ['.gethostbyname($host).'] with Port:'.$port.' of data: '."\r\n"; ob_flush(); flush(); for($i = 0;$i < $num;$i++) { echo ping($host,$port); ob_flush(); flush(); sleep(1); } } ?>域名/IP: 端口:

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

Dreamweaver Mac version
Visual web development tools

MinGW - Minimalist GNU for Windows
This project is in the process of being migrated to osdn.net/projects/mingw, you can continue to follow us there. MinGW: A native Windows port of the GNU Compiler Collection (GCC), freely distributable import libraries and header files for building native Windows applications; includes extensions to the MSVC runtime to support C99 functionality. All MinGW software can run on 64-bit Windows platforms.

MantisBT
Mantis is an easy-to-deploy web-based defect tracking tool designed to aid in product defect tracking. It requires PHP, MySQL and a web server. Check out our demo and hosting services.

Atom editor mac version download
The most popular open source editor

Notepad++7.3.1
Easy-to-use and free code editor
