Move most whois related code from the core into cmd_whois