diff --git a/data.h b/data.h index 4ec505e..e5c7b01 100644 --- a/data.h +++ b/data.h @@ -1,8 +1,6 @@ /* * RIPE-like servers. * All of them do not understand -V2.0Md with the exception of RA and RIPN. - * 6bone-derived servers will accept the flag with a warning (the flag must - * match /^V [a-zA-Z]{1,4}\d+[\d\.]{0,5}$/). */ /* servers which accept the new syntax (-V XXn.n) */ @@ -24,31 +22,28 @@ const char *ripe_servers[] = { }; const char *hide_strings[] = { - "NOTICE AND TERMS OF USE: You", "", /* NetSol */ - "NOTICE: The expiration date", "reserves the right", /* crsnic */ - "The data in Register", "", /* Register.Com */ - "The Data in the Tucows", "RECORD DOES NOT", - "The information in this whois database", "", /* DOTSTER */ - "This whois service currently only", "top-level domains.", /* NameSecure */ - "The Data in Gabia", "you agree to abide", - "The data contained in GoDaddy.com", "is not the registrant", - "Disclaimer: The Global Name Registry", "for any commercial", - "Access to America Online", "time. By accessing", /* AOL */ - "# Access and use restricted", "", /* GANDI */ - "% The data in the WHOIS database of 1&1 Internet", "", - "The data in this whois database is", NULL, /* enom, activeregistrar.com */ - "The Data in Moniker's WHOIS database", "of Moniker.", - "The Data in OnlineNIC", " By starting this query", - "Interdomain's WHOIS", "DOES NOT SIGNIFY", - "The Data provided by Stargate Holdings", "(2) enable any", - "; This data is provided by domaindiscount24.com", "", - "%% NOTICE: Access to this information is provided", "%% By submitting", /* bookmyname.com */ - "% NOTICE: Access to the domains information", "% this query", /* CORE */ - "The Data in MarkMonitor.com's", "--", /* MarkMonitor */ + "The data in Networksolutions.com's WHOIS database", NULL, + /* Some registrars like .wang copied the first paragraph of this + * disclaimer, so the detection here needs to be split in two parts. */ + "NOTICE: The expiration date", "", /* crsnic */ + "TERMS OF USE: You are not authorized", "reserves the right", /* crsnic */ + "The data in Register.com's WHOIS database", NULL, + "The Data in the Tucows Registrar WHOIS database", NULL, + "The data in NameSecure.com's WHOIS database", NULL, + "The Data in Gabia's WHOIS database", NULL, + "The data contained in GoDaddy.com", NULL, + "Personal data access and use are governed by French", NULL, /* GANDI */ + "The data in this whois database is provided to you", NULL, /* enom */ + "; Please register your domains at; http://www.", NULL, /* key-systems.net */ + "%% NOTICE: Access to this information is provided", NULL, /* bookmyname.com */ + "% NOTICE: Access to the domains information", NULL, /* CORE */ + "The Data in MarkMonitor.com's", NULL, /* MarkMonitor */ "Corporation Service Company(c) (CSC) The Trusted Partner", "Register your domain name at", /* CSC */ - "The data in Networksolutions.com's", "By submitting this query", /* Networksolutions */ - "% Copyright (c)2003 by Deutsche Telekom AG", "% DOMAIN full", /* Deutsche Telekom */ - "# Welcome to the OVH WHOIS Server", "# soumettant une", /* ovh */ + "The data in Networksolutions.com's", NULL, /* Networksolutions */ + "# Welcome to the OVH WHOIS Server", "", /* ovh */ + "TERMS OF USE OF MELBOURNE IT WHOIS DATABASE", NULL, + "The data contained in this Registrar's Whois", NULL, /* wildwestdomains.com */ + "The data in the FastDomain Inc. WHOIS database", NULL, /* gTLDs */ "Access to .AERO WHOIS information", "", @@ -56,13 +51,13 @@ const char *hide_strings[] = { "The .coop registry WHOIS", "VERIFICATION, NOR DO", "%% puntCAT Whois Server", "%% any time.", "This Registry database contains ONLY .EDU", "type: help", /* edu */ - "Access to AFILIAS WHOIS information is provided", "", /* .info */ + "Access to AFILIAS WHOIS information is provided", NULL, /* .info */ "mTLD WHOIS LEGAL STATEMENT", "integrity of the database.", /* .mobi */ - "Access to .ORG WHOIS information", "", - "Access to RegistryPro's Whois", "All rights", /* .pro */ - "Telnic, Ltd., the Registry Operator", "(b) harass any person;", /* .tel */ - "Tralliance, Inc., the Registry", "", /* .travel */ - "Access to .XXX ICM REGISTRY WHOIS", "", /* .xxx */ + "Access to Public Interest Registry WHOIS information", NULL, /* .org */ + "Access to .PRO REGISTRY WHOIS information", "", + "Telnic, Ltd., the Registry Operator for .TEL", NULL, + "Tralliance, Inc., the Registry Operator for .travel", NULL, + "Access to .XXX ICM REGISTRY WHOIS", NULL, /* .xxx */ /* new gTLDs */ "Terms of Use: Users accessing the Donuts WHOIS", NULL, @@ -72,14 +67,19 @@ const char *hide_strings[] = { "The whois information provided on this site", "", /* mm-registry.com */ "; This data is provided by ", NULL, /* ksregistry.net */ "This whois service is provided by CentralNic Ltd", "", + ".Club Domains, LLC, the Registry Operator", NULL, + "% Except for agreed Internet operational purposes", NULL, /* .berlin */ + "TERMS OF USE: The information in the Whois database", NULL, /* .wang */ + "The WHOIS service offered by Neustar, Inc, on behalf", NULL, + "The WHOIS service offered by the Registry Operator", NULL, /* .science */ /* ccTLDs */ "Access to CCTLD WHOIS information is provided", "", /* Afilias */ - "Access to ASNIC", "by this policy.", /* as */ - "% The WHOIS service offered by DNS.be", "% protect the privacy", /* be */ + "This WHOIS information is provided", NULL, /* as */ + "% The WHOIS service offered by DNS Belgium", "", /* be */ "% The WHOIS service offered by EURid", "% of the database", /* eu */ - "% WHOIS LEGAL STATEMENT AND TERMS & CONDITIONS", "", /* sx */ - "NeuStar, Inc., the Registry", "OF THE AVAILABILITY", /* us */ + "% WHOIS LEGAL STATEMENT AND TERMS & CONDITIONS", NULL, /* sx */ + "NeuStar, Inc., the Registry Administrator for .US", NULL, NULL, NULL }; diff --git a/debian/changelog b/debian/changelog index ea407de..31fc5f0 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,36 @@ +whois (5.2.7) unstable; urgency=medium + + * Removed a bogus disclaimer detection string. + * Updated the list of new gTLDs + + -- Marco d'Itri Wed, 25 Mar 2015 23:04:44 +0100 + +whois (5.2.6) unstable; urgency=medium + + * Added the .edu.ph TLD server. + * Removed the .gov.py TLD server. (Closes: #780562) + * Updated the list of new gTLDs. + * Implemented hiding multiple disclaimers blocks to improve detection. + * Updated the disclaimer detection strings. + + -- Marco d'Itri Mon, 23 Mar 2015 04:28:39 +0100 + +whois (5.2.5) unstable; urgency=medium + + * Added the .xn--90ais (.бел, Belarus) TLD server. + * Updated the .ky TLD server. + * Updated the list of new gTLDs. + * Added new recovered IPv4 allocations. + + -- Marco d'Itri Tue, 03 Mar 2015 02:15:57 +0100 + +whois (5.2.4) unstable; urgency=medium + + * Fixed referrals handling for the .cc, .tv a .jobs TLDs. + * Updated the list of new gTLDs. + + -- Marco d'Itri Sun, 25 Jan 2015 04:07:20 +0100 + whois (5.2.3~bpo70+2) wheezy-backports; urgency=medium * Rebuild for wheezy-backports. diff --git a/ip_del_recovered.h b/ip_del_recovered.h index d10cd0a..04c71d4 100644 --- a/ip_del_recovered.h +++ b/ip_del_recovered.h @@ -2,9 +2,13 @@ { 736886784UL, 737411071UL, "whois.apnic.net" }, { 737476608UL, 738000895UL, "whois.apnic.net" }, { 738066432UL, 738197503UL, "whois.apnic.net" }, +{ 755236864UL, 755499007UL, "whois.lacnic.net" }, +{ 755499008UL, 756023295UL, "whois.ripe.net" }, { 756023296UL, 757071871UL, "whois.arin.net" }, { 757071872UL, 759169023UL, "whois.arin.net" }, { 759169024UL, 759238655UL, "whois.apnic.net" }, +{ 759431168UL, 759693311UL, "whois.lacnic.net" }, +{ 759693312UL, 760217599UL, "whois.arin.net" }, { 760217600UL, 761266175UL, "whois.ripe.net" }, { 761266176UL, 762314751UL, "whois.afrinic.net" }, { 762314752UL, 763363327UL, "whois.apnic.net" }, @@ -12,6 +16,8 @@ { 765460480UL, 767557631UL, "whois.lacnic.net" }, { 767557632UL, 769589247UL, "whois.afrinic.net" }, { 769654784UL, 770703359UL, "whois.lacnic.net" }, +{ 770703360UL, 771227647UL, "whois.afrinic.net" }, +{ 771227648UL, 771751935UL, "whois.apnic.net" }, { 2523594752UL, 2523660287UL, "whois.apnic.net" }, { 2525036544UL, 2525102079UL, "whois.apnic.net" }, { 2532442112UL, 2532507647UL, "whois.apnic.net" }, diff --git a/mkpasswd.c b/mkpasswd.c index ffd887e..ce0c763 100644 --- a/mkpasswd.c +++ b/mkpasswd.c @@ -279,8 +279,10 @@ int main(int argc, char *argv[]) } else { #ifdef HAVE_SOLARIS_CRYPT_GENSALT salt = crypt_gensalt(salt_prefix, NULL); - if (!salt) + if (!salt) { perror("crypt_gensalt"); + exit(2); + } #elif defined HAVE_LINUX_CRYPT_GENSALT void *entropy = get_random_bytes(64); diff --git a/new_gtlds_list b/new_gtlds_list index b9f6d91..6794bee 100644 --- a/new_gtlds_list +++ b/new_gtlds_list @@ -4,11 +4,13 @@ # Any exceptions can be handled in tld_serv_list as usual, since it will # be checked first. +abbott abogado academy accountants active actor +ads adult agency airforce @@ -16,6 +18,7 @@ allfinanz alsace amsterdam android +apartments aquarelle archi army @@ -26,14 +29,19 @@ audio autos axa band +bank bar +barclaycard +barclays bargains bayern +bbc beer berlin best bid bike +bingo bio black blackfriday @@ -41,6 +49,7 @@ bloomberg blue bmw bnpparibas +boats boo boutique brussels @@ -55,6 +64,7 @@ cal camera camp cancerresearch +canon capetown capital caravan @@ -65,12 +75,17 @@ careers cartier casa cash +casino catering +cbn center ceo cern +cfd channel +chat cheap +chloe christmas chrome church @@ -97,6 +112,7 @@ contractors cooking cool country +courses credit creditcard cricket @@ -104,10 +120,13 @@ crs cruises cuisinella cymru +dabur dad dance dating +datsun day +dclk deals degree delivery @@ -115,6 +134,7 @@ democrat dental dentist desi +design dev diamonds diet @@ -136,7 +156,9 @@ energy engineer engineering enterprises +epson equipment +erni esq estate eurovision @@ -147,14 +169,18 @@ exchange expert exposed fail +fan +fans farm fashion feedback +film finance financial firmdale fish fishing +fit fitness flights florist @@ -162,6 +188,8 @@ flowers flsmidth fly foo +football +forex forsale foundation frl @@ -173,6 +201,7 @@ gal gallery garden gbiz +gdn gent ggee gift @@ -185,20 +214,28 @@ globo gmail gmo gmx +gold +goldpoint +golf +goo +goog google gop graphics gratis green gripe +guge guide guitars guru hamburg +hangout haus healthcare help here +hermes hiphop hiv holdings @@ -210,9 +247,11 @@ hosting house how ibm +ifm immo immobilien industries +infiniti ing ink institute @@ -221,22 +260,28 @@ international investments irish iwc +java +jcb jetzt joburg juegos kaufen +kddi kim kitchen kiwi koeln krd kred +kyoto lacaixa land +lat latrobe lawyer lds lease +leclerc legal lgbt lidl @@ -247,16 +292,20 @@ limo link loans london +lotte lotto ltda luxe luxury madrid +maif maison management mango market marketing +markets +marriott media meet melbourne @@ -274,26 +323,35 @@ mortgage moscow motorcycles mov +mtpc nagoya navy network neustar new +news nexus ngo nhk +nico ninja +nissan nra nrw +ntt nyc okinawa +one ong onl +online ooo +oracle organic osaka otsuka ovh +page paris partners parts @@ -303,12 +361,15 @@ photo photography photos physio +piaget pics +pictet pictures pink pizza place plumbing +plus pohl poker porn @@ -349,9 +410,11 @@ saarland sale samsung sarl +saxo sca scb schmidt +school schule schwarz science @@ -361,7 +424,9 @@ sew sexy shiksha shoes +shriram singles +site sky social software @@ -371,6 +436,10 @@ solutions soy space spiegel +spreadbetting +study +style +sucks supplies supply support @@ -383,7 +452,10 @@ taipei tatar tattoo tax +tech technology +temasek +tennis tienda tips tires @@ -392,9 +464,12 @@ today tokyo tools top +toshiba +tours town toys trade +trading training trust tui @@ -433,6 +508,7 @@ works world wtc wtf +xin xn--1qqw23a xn--3bst00m xn--3ds443g @@ -445,6 +521,7 @@ xn--6qq986b3xl xn--80adxhks xn--80asehdb xn--80aswg +xn--b4w605ferd xn--c1avg xn--cg4bki xn--czr694b @@ -459,6 +536,7 @@ xn--i1b6b1a6a2e xn--io0a7i xn--kput3i xn--mgbab2bd +xn--mxtq1m xn--ngbc5azd xn--nqv7f xn--nqv7fs00ema @@ -471,11 +549,13 @@ xn--unup4y xn--vermgensberater-ctb xn--vermgensberatung-pwb xn--vhquv +xn--vuq861b xn--xhq521b xn--zfr164b xyz yachts yandex +yodobashi yoga yokohama youtube diff --git a/tld_serv_list b/tld_serv_list index 46b7c5a..a67f2b5 100644 --- a/tld_serv_list +++ b/tld_serv_list @@ -192,7 +192,7 @@ .kp NONE # NIC? http://www.star.co.kp/ .kr whois.kr .kw WEB http://www.kw/ -.ky WEB http://kynseweb.messagesecure.com/kywebadmin/ # http://www.icta.ky/ +.ky whois.kyregistry.ky .kz whois.nic.kz .la whois.nic.la .lb WEB http://www.aub.edu.lb/lbdr/ @@ -245,6 +245,8 @@ .pe kero.yachay.pe .pf whois.registry.pf .pg NONE # http://www.unitech.ac.pg/ +.edu.ph WEB http://services.ph.net/dns/query.pl +.gov.ph NONE # http://dns.gov.ph/ .ph WEB http://www.dot.ph/whois .pk WEB http://www.pknic.net.pk/ .co.pl whois.co.pl # "unofficial" SLD @@ -270,7 +272,7 @@ .se whois.iis.se .sg whois.sgnic.sg .sh whois.nic.sh -.si whois.arnes.si +.si whois.register.si .sj NONE # http://www.norid.no/domenenavnbaser/bv-sj.html .sk whois.sk-nic.sk .sl whois.nic.sl @@ -296,7 +298,6 @@ .tm whois.nic.tm .tn whois.ati.tn .to whois.tonic.to -.tp NONE # phase out in progress .tr whois.nic.tr .tt WEB http://www.nic.tt/cgi-bin/search.pl .tv VERISIGN tvwhois.verisign-grs.com @@ -353,6 +354,7 @@ .xn--45brj9c whois.inregistry.net # India, Bengali AW .xn--80ao21a whois.nic.kz # Kazakhstan .xn--90a3ac whois.rnids.rs # Serbia +.xn--90ais whois.cctld.by # Belarus .xn--clchc0ea0b2g2a9gcd whois.sgnic.sg # Singapore, Tamil .xn--d1alf whois.marnet.mk # Macedonia .xn--fiqs8s cwhois.cnnic.cn # China, Simplified Chinese diff --git a/whois.c b/whois.c index fdb2824..903a89d 100644 --- a/whois.c +++ b/whois.c @@ -361,6 +361,9 @@ int handle_query(const char *hserver, const char *hport, if (!server) return 1; + if (*server == '\0') + return 0; + query_string = queryformat(server, flags, query); if (verb) { printf(_("Using server %s.\n"), server); @@ -708,13 +711,13 @@ int hide_line(int *hiding, const char *const line) } else if (*hiding > HIDE_NOT_STARTED) { /* hiding something */ if (*hide_strings[*hiding + 1] == '\0') { /*look for a blank line?*/ if (*line == '\n' || *line == '\r' || *line == '\0') { - *hiding = HIDE_DISABLED; /* stop hiding */ + *hiding = HIDE_NOT_STARTED; /* stop hiding */ return 0; /* but do not hide the blank line */ } } else { /*look for a matching string*/ if (strneq(line, hide_strings[*hiding + 1], strlen(hide_strings[*hiding + 1]))) { - *hiding = HIDE_DISABLED; /* stop hiding */ + *hiding = HIDE_NOT_STARTED; /* stop hiding */ return 1; /* but hide the last line */ } } @@ -810,9 +813,10 @@ char *query_crsnic(const int sock, const char *query) is queried */ if (state == 0 && strneq(buf, " Domain Name:", 15)) state = 1; - if (state == 1 && strneq(buf, " Whois Server:", 16)) { - for (p = buf; *p != ':'; p++); /* skip until colon */ - for (p++; *p == ' '; p++); /* skip colon and spaces */ + if (state == 1 && (strneq(buf, " Whois Server:", 16) + || strneq(buf, " WHOIS Server:", 16))) { + for (p = buf; *p != ':'; p++); /* skip until the colon */ + for (p++; *p == ' '; p++); /* skip the spaces */ referral_server = strdup(p); if ((p = strpbrk(referral_server, "\r\n "))) *p = '\0';