This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "IPFire 2.x development tree".
The branch, master has been updated via 8ba55ea6bbea2d0ab739a882b7569757428e589c (commit) from 850723661e89157f87df9ca2eb654664adee07e4 (commit)
Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below.
- Log ----------------------------------------------------------------- commit 8ba55ea6bbea2d0ab739a882b7569757428e589c Author: Arne Fitzenreiter arne_f@ipfire.org Date: Tue Dec 14 22:12:48 2010 +0100
ipinfo.cgi: Fix for new arin whois protocol.
-----------------------------------------------------------------------
Summary of changes: config/rootfiles/core/44/filelists/files | 1 + html/cgi-bin/ipinfo.cgi | 10 ++++------ 2 files changed, 5 insertions(+), 6 deletions(-)
Difference in files: diff --git a/config/rootfiles/core/44/filelists/files b/config/rootfiles/core/44/filelists/files index 33f781c..44b01ac 100644 --- a/config/rootfiles/core/44/filelists/files +++ b/config/rootfiles/core/44/filelists/files @@ -9,6 +9,7 @@ etc/rc.d/init.d/networking/red.up/99-fireinfo srv/web/ipfire/cgi-bin/extrahd.cgi srv/web/ipfire/cgi-bin/credits.cgi srv/web/ipfire/cgi-bin/index.cgi +srv/web/ipfire/cgi-bin/ipinfo.cgi srv/web/ipfire/cgi-bin/pakfire.cgi srv/web/ipfire/cgi-bin/proxy.cgi srv/web/ipfire/cgi-bin/speed.cgi diff --git a/html/cgi-bin/ipinfo.cgi b/html/cgi-bin/ipinfo.cgi index bc214f0..71098a2 100644 --- a/html/cgi-bin/ipinfo.cgi +++ b/html/cgi-bin/ipinfo.cgi @@ -2,7 +2,7 @@ ############################################################################### # # # IPFire.org - A linux based firewall # -# Copyright (C) 2007 Michael Tremer & Christian Schmidt # +# Copyright (C) 2010 IPFire Team info@ipfire.org # # # # This program is free software: you can redistribute it and/or modify # # it under the terms of the GNU General Public License as published by # @@ -39,8 +39,6 @@ my %cgiparams=(); $ENV{'QUERY_STRING'} =~s/&//g; my @addrs = split(/ip=/,$ENV{'QUERY_STRING'});
-my %whois_servers = ("RIPE"=>"whois.ripe.net","APNIC"=>"whois.apnic.net","LACNIC"=>"whois.lacnic.net"); - &Header::openpage($Lang::tr{'ip info'}, 1, '');
&Header::openbigbox('100%', 'left'); @@ -58,15 +56,15 @@ next if $addr eq ""; my $sock = new IO::Socket::INET ( PeerAddr => $whoisname, PeerPort => 43, Proto => 'tcp'); if ($sock) { - print $sock "$addr\n"; + print $sock "n $addr\n"; while (<$sock>) { - $extraquery = $1 if (/NetType: Allocated to (\S+)\s+/); + $extraquery = $1 if (/ReferralServer: whois://(\S+)\s+/); push(@lines,$_); } close($sock); if ($extraquery) { undef (@lines); - $whoisname = $whois_servers{$extraquery}; + $whoisname = $extraquery; my $sock = new IO::Socket::INET ( PeerAddr => $whoisname, PeerPort => 43, Proto => 'tcp'); if ($sock) {
hooks/post-receive -- IPFire 2.x development tree