alias whoiz { sockclose smartwhois* | set %ipwhois $1 | checkwhois | window -do @whois } alias notag { var %x,%y = $regsub($1-,/<[^>]+>/g,,%x) | return %x } alias notag2 { var %x,%y = $regsub($1-,/\[[^\]]+\]/g,,%x) | return %x } alias checkwhois { sockopen smartwhois www.dnsstuff.com 80 } alias checkwhois2 { sockclose smartwhois* sockopen smartwhois2 www.ripe.net 80 } on *:sockopen:smartwhois: { sockwrite -n $sockname GET /tools/whois.ch?ip= [ $+ [ %ipwhois ] ] HTTP/1.1 sockwrite -n $sockname Host: dnsstuff.com $+ $crlf $+ $crlf sockwrite -n $sockname Connection: Keep-Alive } on *:sockread:smartwhois: { sockread %temp echo @whois $notag2($notag(%temp)) } }