From e4734d7592a11fbb206b4da851f7b1cd8d10b7c8 Mon Sep 17 00:00:00 2001 From: epoch Date: Mon, 28 Oct 2013 04:16:16 +0000 Subject: fixed the ns.whois.ano thing... don't remember what I did to whoisd.pl. Oh well. --- contrib/whoisd/whoisd.pl | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'contrib') diff --git a/contrib/whoisd/whoisd.pl b/contrib/whoisd/whoisd.pl index 158c075..67636c9 100755 --- a/contrib/whoisd/whoisd.pl +++ b/contrib/whoisd/whoisd.pl @@ -6,11 +6,17 @@ use strict; +#maybe chroot this whoisd? my $RESDB = "/services/resdb/resdb"; my $HACK=0; my $QUERY=; $QUERY =~ s/\r\n//g; +$QUERY =~ s/\///g; +if($QUERY eq '') { + printf "%% error. no query. wtf?"; + exit 0; +} my $out; my $title; my $value; @@ -97,7 +103,7 @@ if($QUERY =~ m/\./) { } # default to assuming it is a name. -printf "%% user section for %s\n", $QUERY unless $HACK; +printf "%% user section for '%s'\n", $QUERY unless $HACK; chdir("$RESDB/db/usr") || die "%% error"; if(chdir($QUERY)) { -- cgit v1.2.3