the case of the dns whois lookup

1. registrars VS hosts

  • DOMAIN REGISTRAR is the subject where domain names are finally purchased
  • DNS HOST is the service / server authoritative for hosting your DNS records
  • there are hosting providers that offer domain registration registrars that offer DNS hosting, but the two should not be confused
  • selecting a domain name is the first step you make when building a web site
  • this semantical layer of the internet, technically, computers are connected with ip addresses
  • registration means going through DNS REGISTRAR, which is a company that directly deals with the REGISTRY OPERATORS FOR THE TOP LEVEL DOMAIN
Image for post
Image for post
  • the global list of domain names is managed by IANA (International Assigned Numbers Authority)

2. IANA

  • IANA is a department of ICANN (Internet Corporation for Assigned Names and Numbers) a nonprofit running the root zone management in the DNS
  • whois command is querying the domain name registry
  • but the registrar is too up in the hierarchy to the common customers
  • usually, a domain name is purchased through a WEB HOSTING PROVIDER that does the work for them and register a domain through the registries on the customer’s behalf
  • DNS HOST are servers hosted by DNS HOSTING PROVIDERS and these servers authoritatively respond for your domain
  • Sometimes, registrars also offer DNS hosting, but it should not be confused
  • DNS Host is mentioned by names of nameservers in the NAMESERVERS part of the whois lookup

3. whois as a protocol

  • whois is a query and response protocol for querying DBs storing registered users/assignees of internet resources (domain names, IP address blocks)
  • whois is a standard drafted by the internet society
  • documented in RFC 3912 — WHOIS Protocol Specification

4. script

  • the following script is creating and parsing a whois request
  • note: it is relying on jsonwhois.io where you need to register to get your own $apiKey

5. demo

6. sources

Written by

today I learnt… | as a support eng of the wonderful Snowplow Analytics, expect everything around modern (postmodern?) business intelligence

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store