From 6a2ec4517a0c8ec70289823acbd130d520f1ce80 Mon Sep 17 00:00:00 2001 From: epochqwert Date: Sat, 7 Jul 2018 23:07:29 +0000 Subject: claimed n.ano for link shortener. some minor changes to whoisd and I guess pulled a new copy of marc.db. --- contrib/marc/marc.db | Bin 1840750 -> 0 bytes contrib/whoisd/whoisd-cached.sh | 7 +++++++ contrib/whoisd/whoisd.pl | 2 +- 3 files changed, 8 insertions(+), 1 deletion(-) create mode 100755 contrib/whoisd/whoisd-cached.sh (limited to 'contrib') diff --git a/contrib/marc/marc.db b/contrib/marc/marc.db index 890d0a4..e69de29 100644 Binary files a/contrib/marc/marc.db and b/contrib/marc/marc.db differ diff --git a/contrib/whoisd/whoisd-cached.sh b/contrib/whoisd/whoisd-cached.sh new file mode 100755 index 0000000..248fad6 --- /dev/null +++ b/contrib/whoisd/whoisd-cached.sh @@ -0,0 +1,7 @@ +#!/bin/sh +cd /var/db/resdb +commit=$(git log -1 | head -n1 | tr -cd 'a-f0-9') +query=$(head -n1 | tr -cd 'a-zA-Z0-9.:_-') +if ! cat "/var/cache/whois/${commit}-${query}" 2>/dev/null;then + printf "%s\n" "${query}" | /var/db/resdb/contrib/whoisd/whoisd.pl | tee "/var/cache/whois/${commit}-${query}" +fi diff --git a/contrib/whoisd/whoisd.pl b/contrib/whoisd/whoisd.pl index 19af889..de9d768 100755 --- a/contrib/whoisd/whoisd.pl +++ b/contrib/whoisd/whoisd.pl @@ -1,4 +1,4 @@ -#!/usr/bin/perl +#!/usr/pkg/bin/perl # ncat -klp 43 -e ./whoisd.pl # use inetd or tcpserver or ncat -- cgit v1.2.3