敬业的IT人 >> 网站建设 >> Web编程 >> CGI/Perl >> perl 域名查询程序

perl 域名查询程序

敬业的IT人 互联网 佚名 2008-4-15 10:38:29
#  perl 国内域名查询程序
#  flybird@chinaasp.com
#  2000-9-22
#  perl 写socket程序确实很简单。

use IO::Socket::INET;
$fqdn="ourstory.com.cn";
$server = 'whois.cnnic.net.cn';
$sock  = IO::Socket::INET->new("$server:43") || die "fail";
print $sock "$fqdn\n";
@ret=<$sock>;
print "@ret";  
粤ICP备06119539号
Copyright CiscoSky.Org,Some Rights Reserved.
Email:me1228#tom.com