University of Southern California

DNS Calculator

DNS Calculator:

How NOT to use the DNS:

The original concept was first presented at the 2001 Sigcomm Conference Outrageous Opinions session in San Diego, CA. It's an example of what NOT to do with the DNS:

  • Lookup x.y.op.CALC.POSTEL.ORG (where x=0..99, y=0.99, op={ADD,SUB,MUL,DIV})
  • Result is computed as a decimal with digits: abcd.efgh, and output as the IPv4 IP address "Sab.cd.ef.gh"
  • When S=1, the result is a negative number
  • When S=2, the result is "not a number" (i.e., divide by zero error)
  • Other constants are supported as lookups only: PI.CALC.POSTEL.ORG, E.CALC.POSTEL.ORG, and GOLDEN.CALC.POSTEL.ORG

Classes where this has been used as an example:

NOTES:

If you have problems with the domain not being found, direct your requests to dns.postel.org directly.

Example using dig:

dig @dns.postel.org 3.4.add.calc.postel.org

Example using nslookup:

 nslookup

>server dns.postel.org

>3.4.add.calc.postel.org

0.7.0.0
 
Groups: