DNS Games

Description:Some games you can play with resolvers (if you control a DNS server) Phillip Jaenke shows some examples.
Author:"Phillip R. Jaenke" <prj@NLS.NET>
Compromise:Trick resolvers
Vulnerable Systems:Those with flaky resolvers (like gethostbyname()) (I guess). It is a wierd sort of problem.
Date:6 October 1997

Date: Mon, 6 Oct 1997 12:52:27 -0400
From: "Phillip R. Jaenke" <prj@NLS.NET>
Subject: Flaw in DNS

    [The following text is in the "ISO-8859-1" character set]
    [Your display is set for the "US-ASCII" character set]
    [Some characters may be displayed incorrectly]

This is a fun little flaw, and it applies to all daemons. Even NT's

gw: {1} % nslookup
Server:  gw.pcimporters.com


Believe it or not, this WILL resolve on most systems. is my
routed IP reserved for the other machines I have here. So, basically, I can
hop on IRC as root@ Doesn't do much, except for vanity.

Now, think carefully about this. What happens if I do something like this?:

gw: {1} % nslookup
Server:  gw.pcimporters.com


With a former coworker, we've seen that this WILL resolve 99% of the time.
It will also cause various maladies. Hop on IRC, it tries to send an identd
request to the resolved host. It gets an unreachable.

Ping the box. If it resolves, and tries to reply to the resolved address...
well, let's just say it could be quite painful.

And it's dangerously easy to implement. Just add an A record for your IP
that points to another. There's various ways you can do it to cause

Unroutable IPs
Localhost IPs
ARPA's (ie;
Invalid Names (ie; nice.try)

-Phillip R. Jaenke  [InterNIC Handle: PRJ5]  (prj@nls.net)
MIS Department, PC Importers, Inc. 800.319.9284, x4262
"Why do you pay tax on Spam? It's a non-food product!"

More Exploits!

The master index of all exploits is available here (Very large file)
Or you can pick your favorite operating system:
All OS's Linux Solaris/SunOS Micro$oft
*BSD Macintosh AIX IRIX
ULTRIX/Digital UNIX HP/UX SCO Remote exploits

This page is part of Fyodor's exploit world. For a free program to automate scanning your network for vulnerable hosts and services, check out my network mapping tool, nmap. Or try these Insecure.Org resources: