分页: 1 / 1

精确到楼层的ip查询?

发表于 : 2009-04-03 11:37
eexpress

代码: 全选

☎ cat apnic.pl 
#!/usr/bin/perl

my ($ip1,$ip2)=split(/\./,$ARGV[0]);
my $ip="$ip1.$ip2";
print $ARGV[0];
open(who, "whois -h whois.apnic.net $ARGV[0]|");
my $l;
while(<who>){
        last if /$ip/;
}
while(<who>){
        chomp;
        s/$&:\s*//,print " ► $_" if /^descr|^country/;
}
close(who);

Re: 精确到楼层的ip查询?

发表于 : 2009-04-03 12:00
leeaman
传说中的马甲杀手? :em06

Re: 精确到楼层的ip查询?

发表于 : 2009-04-03 12:08
bones7456
不直观,不明显

Re: 精确到楼层的ip查询?

发表于 : 2009-04-03 12:21
sammysun
:em06 怎么用?

Re: 精确到楼层的ip查询?

发表于 : 2009-04-03 12:22
greco
:em04

Re: 精确到楼层的ip查询?

发表于 : 2009-04-03 12:48
jioyo源
sammysun 写了::em06 怎么用?

Re: 精确到楼层的ip查询?

发表于 : 2009-04-03 13:38
bigdomain
保存代码
chmod +x ./apnic.pl
./apnic.pl 122.231.2.115
122.231.2.115 ► CN ► CHINANET-ZJ Jiaxing node network ► Zhejiang Telecom ► CN ►

Re: 精确到楼层的ip查询?

发表于 : 2009-04-03 13:50
xiooli

代码: 全选

whois -h whois.apnic.net ip
更详细阿

Re: 精确到楼层的ip查询?

发表于 : 2009-04-04 1:48
windwiny
who 是什么玩艺? 还少发了一些东西吧

Re: 精确到楼层的ip查询?

发表于 : 2009-04-04 15:04
jyz19880823
:em06 :em09