diff options
author | ceri <ceri@FreeBSD.org> | 2004-12-11 13:14:07 +0000 |
---|---|---|
committer | ceri <ceri@FreeBSD.org> | 2004-12-11 13:14:07 +0000 |
commit | d0eb6b1f7e45b5f35b2024d1ae7d9b2444667781 (patch) | |
tree | 70b74b6af38a1ec8a1996d482639796c26cb4e0f /usr.bin/whois | |
parent | fe016ce224c283ad12f86190ade43b96eabd4ddc (diff) | |
download | FreeBSD-src-d0eb6b1f7e45b5f35b2024d1ae7d9b2444667781.zip FreeBSD-src-d0eb6b1f7e45b5f35b2024d1ae7d9b2444667781.tar.gz |
Add a -k flag for querying whois.krnic.net (the National Internet
Development Agency of Korea) which hold details of IP address
allocations within Korea.
Approved by: bms
Diffstat (limited to 'usr.bin/whois')
-rw-r--r-- | usr.bin/whois/whois.1 | 8 | ||||
-rw-r--r-- | usr.bin/whois/whois.c | 8 |
2 files changed, 13 insertions, 3 deletions
diff --git a/usr.bin/whois/whois.1 b/usr.bin/whois/whois.1 index 28efda1..6977cf2 100644 --- a/usr.bin/whois/whois.1 +++ b/usr.bin/whois/whois.1 @@ -40,7 +40,7 @@ .Nd "Internet domain name and network number directory service" .Sh SYNOPSIS .Nm -.Op Fl aAbdgiIlmQrR6 +.Op Fl aAbdgiIklmQrR6 .Op Fl c Ar country-code | Fl h Ar host .Op Fl p Ar port .Ar name ... @@ -157,6 +157,12 @@ Use the Internet Assigned Numbers Authority .Pq Tn IANA database. It contains network information for top-level domains. +.It Fl k +Use the National Internet Development Agency of Korea's +.Pq Tn KRNIC +database. +It contains network numbers and domain contact information +for Korea. .It Fl l Use the Latin American and Caribbean IP address Regional Registry .Pq Tn LACNIC diff --git a/usr.bin/whois/whois.c b/usr.bin/whois/whois.c index def4fdf..51ca8c8 100644 --- a/usr.bin/whois/whois.c +++ b/usr.bin/whois/whois.c @@ -67,6 +67,7 @@ __FBSDID("$FreeBSD$"); #define GNICHOST "whois.nic.gov" #define ANICHOST "whois.arin.net" #define LNICHOST "whois.lacnic.net" +#define KNICHOST "whois.krnic.net" #define RNICHOST "whois.ripe.net" #define PNICHOST "whois.apnic.net" #define MNICHOST "whois.ra.net" @@ -107,7 +108,7 @@ main(int argc, char *argv[]) country = host = qnichost = NULL; flags = use_qnichost = 0; - while ((ch = getopt(argc, argv, "aAbc:dgh:iIlmp:QrR6")) != -1) { + while ((ch = getopt(argc, argv, "aAbc:dgh:iIklmp:QrR6")) != -1) { switch (ch) { case 'a': host = ANICHOST; @@ -136,6 +137,9 @@ main(int argc, char *argv[]) case 'I': host = IANAHOST; break; + case 'k': + host = KNICHOST; + break; case 'l': host = LNICHOST; break; @@ -351,7 +355,7 @@ static void usage(void) { fprintf(stderr, - "usage: whois [-aAbdgiIlmQrR6] [-c country-code | -h hostname] " + "usage: whois [-aAbdgiIklmQrR6] [-c country-code | -h hostname] " "[-p port] name ...\n"); exit(EX_USAGE); } |