Only in m:\bind496t1a/BSD: Diffs
diff --context --recurs m:\bind496t1a/BSD/README m:\bind/BSD/README
*** m:\bind496t1a/BSD/README	Wed May 28 16:30:29 1997
--- m:\bind/BSD/README	Tue Jun 24 05:01:42 1997
***************
*** 2,17 ****
  Paul Vixie
  paul@vix.com
  12-Dec-94 - original
! $Id: README,v 8.1 1994/12/15 06:23:43 vixie Exp $
  
! To integrate BIND into a 4.4BSD or 4.4BSD-Lite system, you need to perform the
! following steps.  You might be doing this if you are maintaining one of the
! BNR2- or 4.4L-based BSD's (BSD/OS, FreeBSD, NetBSD), or if you are running
! 4.4BSD and you want to get the newest BIND cleanly integrated into it.
  
! 1. Apply the diffs in Diffs/lib-libc-net to your lib/libc/net tree, and
!    apply the diffs in Diffs/include(*) to your include tree.  These are roughly
!    the changes that will appear in 4.4BSD-Lite++ so you're on the right track.
  
  2. Rid your system of all vestiges of named, named-xfer, dig, nslookup, or the
     utility scripts, named.reload and named.restart.  Don't forget to update the
--- 2,15 ----
  Paul Vixie
  paul@vix.com
  12-Dec-94 - original
! $Id: README,v 8.1 1994/12/15 06:23:43 vixie Exp vixie $
  
! To integrate BIND into a 4.4BSD or 4.4BSD-Lite system, you need to perform the
! following steps.  You might be doing this if you are maintaining one of the
! BNR2- or 4.4L-based BSD's (BSD/OS, FreeBSD, NetBSD), or if you are running
! 4.4BSD and you want to get the newest BIND cleanly integrated into it.
  
! 1. Compare ../res/* to your lib/libc/net tree and make appropriate changes.
  
  2. Rid your system of all vestiges of named, named-xfer, dig, nslookup, or the
     utility scripts, named.reload and named.restart.  Don't forget to update the
***************
*** 31,43 ****
     is safe (and recommended) to use "make obj" and "make depend" on the subtree
     that includes this integration of BIND.
  
! 7. Watch comp.protocols.tcp-ip.domains and/or the bind@uunet.uu.net mailing
!    list for patches and updates to BIND.  When new kits are made available,
!    grab them and repeat these instructions (or, if you are brave, diff things
     and apply patches by hand).
  
  This package has been brought to you by the Internet Software Consortium.
! For more information about the ISC, send mail to <info@isc.org>.
! 
! (*) no 4.4BSD-Lite include diffs are available yet, use your own judgement and
! do the merge on your own.
--- 29,39 ----
     is safe (and recommended) to use "make obj" and "make depend" on the subtree
     that includes this integration of BIND.
  
! 7. Watch comp.protocols.tcp-ip.domains and/or comp.protocols.dns.* for
!    patches and updates to BIND.  When new kits are made available, grab
!    them and repeat these instructions (or, if you are brave, diff things
     and apply patches by hand).
  
  This package has been brought to you by the Internet Software Consortium.
! For more information about the ISC, send mail to <info@isc.org> or have a
! look at our web page at http://www.isc.org/isc/.
diff --context --recurs m:\bind496t1a/CHANGES m:\bind/CHANGES
*** m:\bind496t1a/CHANGES	Wed May 28 04:27:01 1997
--- m:\bind/CHANGES	Tue Jun 24 02:26:50 1997
***************
*** 1,6 ****
! $Id: CHANGES,v 8.52 1996/12/18 04:09:41 vixie Exp vixie $
! 
! 	--- 4.9.6 released ---
  
  803. [bug]	core leak fixed in ns_resp.c (twice).
  
--- 1,11 ----
! $Id: CHANGES,v 8.53 1997/06/01 20:34:25 vixie Exp vixie $
! 
! 	--- 4.9.6 released ---
! 
! 805. [security]	The server now caches only those response records
! 		that are within the current query domain.  (From BIND-8)
! 
! 804. [security]	another buffer overrun plugged, this time in res_search().
  
  803. [bug]	core leak fixed in ns_resp.c (twice).
  
diff --context --recurs m:\bind496t1a/Makefile m:\bind/Makefile
*** m:\bind496t1a/Makefile	Wed May 28 04:17:59 1997
--- m:\bind/Makefile	Tue Jun 24 03:21:40 1997
***************
*** 1,16 ****
  # Makefile for BIND>=4.9 top level
  # vixie@decwrl December, 1992 [original]
  #
! # $Id: Makefile,v 8.48 1996/11/26 10:11:13 vixie Exp vixie $
  
! ## ++Copyright++ 1989
! ## -
! ## Copyright (c) 1989
! ##    The Regents of the University of California.  All rights reserved.
  ## 
! ## Redistribution and use in source and binary forms, with or without
! ## modification, are permitted provided that the following conditions
! ## are met:
  ## 1. Redistributions of source code must retain the above copyright
  ##    notice, this list of conditions and the following disclaimer.
  ## 2. Redistributions in binary form must reproduce the above copyright
--- 1,14 ----
  # Makefile for BIND>=4.9 top level
  # vixie@decwrl December, 1992 [original]
  #
! # $Id: Makefile,v 8.49 1997/06/01 20:34:25 vixie Exp vixie $
  
! ## Copyright (c) 1989
! ##    The Regents of the University of California.  All rights reserved.
  ## 
! ## Redistribution and use in source and binary forms, with or without
! ## modification, are permitted provided that the following conditions
! ## are met:
  ## 1. Redistributions of source code must retain the above copyright
  ##    notice, this list of conditions and the following disclaimer.
  ## 2. Redistributions in binary form must reproduce the above copyright
***************
*** 35,41 ****
  ## LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  ## OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  ## SUCH DAMAGE.
! ## -
  ## Portions Copyright (c) 1993 by Digital Equipment Corporation.
  ## 
  ## Permission to use, copy, modify, and distribute this software for any
--- 33,39 ----
  ## LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  ## OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  ## SUCH DAMAGE.
! ##
  ## Portions Copyright (c) 1993 by Digital Equipment Corporation.
  ## 
  ## Permission to use, copy, modify, and distribute this software for any
***************
*** 53,62 ****
  ## PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
  ## ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
  ## SOFTWARE.
- ## -
- ## --Copyright--
  
! VER = 4.9.6-T1A
  SHELL = /bin/sh
  MAKE = make
  DESTDIR =
--- 51,58 ----
  ## PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
  ## ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
  ## SOFTWARE.
  
! VER = 4.9.6-REL
  SHELL = /bin/sh
  MAKE = make
  DESTDIR =
***************
*** 301,307 ****
  #otherwise uncomment the next line and hope for the best
  #CC = cc $(CPPFLAGS)
  #CDEBUG = -g
! #CPPPFLAGS = -DSVR4 -D_SYS_STREAM_H
  #CPPFLAGS = $(CPPPFLAGS) $(SOLCOMPAT)
  #INDOT = in.
  #XFER_INDOT =
--- 297,303 ----
  #otherwise uncomment the next line and hope for the best
  #CC = cc $(CPPFLAGS)
  #CDEBUG = -g
! #CPPPFLAGS = -DSVR4 -D_SYS_STREAM_H -DMAXHOSTNAMELEN=256
  #CPPFLAGS = $(CPPPFLAGS) $(SOLCOMPAT)
  #INDOT = in.
  #XFER_INDOT =
diff --context --recurs m:\bind496t1a/README m:\bind/README
*** m:\bind496t1a/README	Wed May 28 16:30:29 1997
--- m:\bind/README	Tue Jun 24 05:11:36 1997
***************
*** 1,227 ****
! The official place to get BIND is <URL:ftp://ftp.vix.com/pub/bind/release>.
  
! The official mailing lists are:		bind-users@vix.com	- users/admins
!   (use *-request@* for admin mail)	bind-workers@vix.com	- developers
! 
! The official Usenet newsgroups are:	comp.protocols.tcp-ip.domains
! 					
! BIND is currently sponsored by:		The Internet Software Consortium
! 					(send to <info@isc.org> for details.)
! 
! ----- 4.9.3 BETA33 - December, 1995 - paul@vix.com
! 
! Take a look around in doc/misc/ and contrib/.  Reread INSTALL.  Have fun.
! 
! ----- 4.9.3 BETA11, BETA12 release - December, 1994 - paul@vix.com
! 
! If you maintain a BSD or are otherwise running a 4.4BSD-based system and want
! to integrate BIND into it, check out BSD/README.
! 
! Read the top of CHANGES for interesting stuff.
! 
! Don't forget to purge all your secondary zone files before upgrading to this
! BIND if your existing one came from a vendor.
! 
! The NOTIFY feature is turned off by default, but it's really cool and you
! should consider turning it on if you are willing to risk having it not work
! after the RFC process is complete (if the protocol has to change at all.)
! It already does not conform to the draft protocol so you should consider it
! "experimental" even if it happens to work fine.
! 
! ----- 4.9.3 BETA10 release - August, 1994 - paul@vix.com
! 
! I recommend reading this ENTIRE FILE before you attempt to build or use BIND.
! However, you can get started quickly by scanning down this file for "QUICK" in
! the right margin and just reading those sections.  You can also look at the
! INSTALL file.  You should look at doc/info/* if you have trouble building.
! 
! There are at least two known bugs in this BIND:
! 
! 1.	if you have two authoritative zones (primary or secondary) where
! 	one is a subzone of the other, e.g.,
! 		primary	pa.dec.com	z/pa.dec.com
! 		primary dec.com		z/dec.com
! 	and you remove or comment out the subzone (pa.dec.com in our example)
! 	and SIGHUP named, the delegation and other RR's at "pa.dec.com" will
! 	be missing from your cache.  to avoid this, you should "named.restart"
! 	rather than SIGHUP ("named.reload") when making changes of this kind.
! 
! 2.	the /HS qualifier doesn't work on "cache" directives.  you will have
! 	to put your hesiod root information into your main "root.cache" file.
! 
! Also, you may find that your utilities will not link with this -lresolv
! unless you also install lib44bsd.a and link with -lresolv -l44bsd.  This
! is because older systems do not include inet_aton() and other functions.
! 
! ----- 4.9.3 BETA6 release - June, 1994 - paul@vix.com
! 
! Several private beta test releases have come and gone, and we've fixed a
! number of things.  See CHANGES for details.
! 
! There is a new Sun Shared Library update mechanism in place, and it works
! quite well.  See shres/*.  
! 
! Versions of NSLOOKUP up through BIND 4.8.3's used IQUERY to ask the local
! server for information about the server's own name.  I assume that this was
! done in a "what the heck, nothing uses these, how can we contrive a need?"
! sort of spirit.  I removed this code as of BIND 4.9's NSLOOKUP and had it
! use the standard gethostbyaddr() mechanisms (which depend on normal queries
! of PTR data).  Disabling INVQ and putting "options fake-iquery" in the boot
! file will cause IQUERY to be answered bogusly but in a way that old nslookup
! programs won't trip on.  INVQ is disabled by default in conf/options.h.
! 
! ----- 4.9.3 BETA2 release - June, 1994 - paul@vix.com
! 
! News flash! BIND development is now funded by the Internet Software Consortium.
! 
! Look at CHANGES to see what's new.  Check out doc/misc to see some interesting
! papers from Purdue (and Bell Labs, if we're lucky) on DNS security that
! motivated many of the security-related changes present in this release.
! 
! Check out shres/Makefile for SunOS4 shared library support.
! 
! INVQ now defaults to "undef".  See OPTIONS and conf/options.h.
  
- ALLOW_UPDATES is no longer available, and will be removed next release.
- 
- You should look hard at the SENSIBLE_DOTS option and convert your serial 
- numbers either to "sensible" ones or ones without dots (YYYYMMDD## preferred).
- SENSIBLE_DOTS will be the default in the next release.
- 
- NCACHE and VALIDATE are _working_ now.
- 
- Read the BOG!  It's been updated since the previous release.
- 
- If you are a vendor and are including some or all of this code in your product,
- please drop me a line to let me know.  I field a lot of questions about BIND
- and it is helpful for me to know which vendor releases contain which versions
- of BIND.  It's also helpful for me to have contacts within the engineering
- groups of the various vendors, since when I find a heinous bug I can let you
- know.
- 
- ----- 4.9.2 FINAL (940221) release - February, 1994 - paul@vix.com
- 
- If you look at the last entry in TODO, you'll see that there are a lot
- of things in the queue waiting to go in.  However, I'm holding the line
- so that 4.9.2-FINAL can be the same as what goes out with 4.4BSD-Lite.
- I expect to open 4.9.3-ALPHA fairly soon, with patches comprising new
- work; 4.9.2-FINAL will have patches released for it only to correct bugs.
- 
- The official way to get BIND 4.9.2 is:	ftp gatekeeper.dec.com	OUT OF DATE!!!
- 					cd pub/misc/vixie	OUT OF DATE!!!
- 					binary			OUT OF DATE!!!
- 					get bind-940221.tar.gz	OUT OF DATE!!!
- 				   or:	get bind-940221.tar.Z	OUT OF DATE!!!
- 
  The official mailing lists are:		bind-users@vix.com	- users/admins
!   (use *-request for admin mail)	bind-workers@vix.com	- developers
  
  The official Usenet newsgroups are:	comp.protocols.tcp-ip.domains
  					
! My official e-mail address is:		paul@vix.com
! 
! ----- 4.9.2 BETA5 (931205) release - December, 1993 - paul@vix.com
! 
! no comments; see CHANGES file.
! 
! ----- 4.9.2 BETA4 (931104) release - November, 1993 - paul@vix.com
! 
! All reported portability problems have been fixed.  All core dumps have
! had changes made for them and we are ready to have them tested again.  As
! usual, I am running this in production on my own zones and I am rather
! confident in it.  Note, again, that this is a BETA release and you should
! not put it up for anon-ftp or otherwise republish it in any way.
! 
! ----- 4.9.2 ALPHA2 (930908) release - September, 1993 - paul@vix.com
! 
! 4.9.2 has fixes for most of the bugs that smb@bellcore's white paper talked
! about, and CERT is going to be knocking on vendor's doors to get it shipped
! with as many operating systems as possible.
  
! ----- 4.9.2 ALPHA1 (930506) release - July, 1993 - Paul Vixie <paul@vix.com>
! 
! I don't work for DEC any more, so note the new e-mail address.  The old
! <bind-4.9@pa.dec.com> list has been moved to <bind-workers@vix.com>; if
! you intend to help hack BIND and you want to be advised of alpha-testing
! releases, send mail to <bind-workers-request@vix.com> and ask to be added
! to the list.
! 
! Note that 4.9.1 was an interrim, nonpublished release intended to catch
! the porting changes needed for 4.4BSD.  It never really existed separately.
! 
! ----- 4.9 release - April, 1993 - Paul Vixie <vixie@pa.dec.com>
! 
! For information on what's new in 4.9, see OPTIONS and CHANGES.  Also note
! that the man page for named(8) in man/named.8, and the entire Bind Operations
! Guide in doc/BOG/*, has been updated for 4.9.  Both make excellent reading.
! 
! Those of you who are thinking of adding features should first read TODO to
! see if someone else has already indicated an intention to work on the same
! thing.  If your feature is significant you should ask <bind-workers@vix.com>
! before you hack, if for no other reason than to tell other maintainers to
! expect a patch soon.
! 
! Note that the resolver has a number of routines that may already be present
! on your system.  Efforts have been made to avoid generating code for them on
! systems where they aren't needed; don't worry about them if they're
! generated unneccessarily since the linker will sort things out.
! 
! This software is protected under the U C Regents' copyright.  Changes made
! by or released through Digital Equipment Corporation are subject to a
! subsidiary copyright.  The entire copyright is as follows:
! 
! ++Copyright++ 1989
! -
! Copyright (c) 1989
!    The Regents of the University of California.  All rights reserved.
! 
! Redistribution and use in source and binary forms, with or without
! modification, are permitted provided that the following conditions
! are met:
! 1. Redistributions of source code must retain the above copyright
!    notice, this list of conditions and the following disclaimer.
! 2. Redistributions in binary form must reproduce the above copyright
!    notice, this list of conditions and the following disclaimer in the
!    documentation and/or other materials provided with the distribution.
! 3. All advertising materials mentioning features or use of this software
!    must display the following acknowledgement:
! 	This product includes software developed by the University of
! 	California, Berkeley and its contributors.
! 4. Neither the name of the University nor the names of its contributors
!    may be used to endorse or promote products derived from this software
!    without specific prior written permission.
! 
! THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
! ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
! IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
! ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
! FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
! DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
! OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
! HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
! LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
! OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
! SUCH DAMAGE.
! -
! Portions Copyright (c) 1993 by Digital Equipment Corporation.
! 
! Permission to use, copy, modify, and distribute this software for any
! purpose with or without fee is hereby granted, provided that the above
! copyright notice and this permission notice appear in all copies, and that
! the name of Digital Equipment Corporation not be used in advertising or
! publicity pertaining to distribution of the document or software without
! specific, written prior permission.
! 
! THE SOFTWARE IS PROVIDED "AS IS" AND DIGITAL EQUIPMENT CORP. DISCLAIMS ALL
! WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES
! OF MERCHANTABILITY AND FITNESS.   IN NO EVENT SHALL DIGITAL EQUIPMENT
! CORPORATION BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
! DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
! PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
! ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
! SOFTWARE.
! -
! --Copyright--
  
  To build this:								QUICK
  
--- 1,20 ----
! The official version of BIND is now 8.1.1.  This is 4.9.6, the last of 4.*
! which we are releasing since it has some important security bugs fixed.
  
! The official place to get BIND is <URL:ftp://ftp.isc.org/isc/bind/src>.
  
  The official mailing lists are:		bind-users@vix.com	- users/admins
!   (use *-request@* for admin mail)	bind-workers@vix.com	- developers
  
  The official Usenet newsgroups are:	comp.protocols.tcp-ip.domains
+ 					comp.protocols.dns.bind
+ 					comp.protocols.dns.ops
+ 					comp.protocols.dns.std
  					
! BIND is currently maintained by:	The Internet Software Consortium
! 					(see <URL:http://www.isc.org/isc>.)
  
! Read the top of CHANGES for interesting stuff.
  
  To build this:								QUICK
  
Only in m:\bind: bind-4.9.6-REL.tar
Only in m:\bind: bind-4.9.6-REL.tar.gz
Only in m:\bind496t1a: bind-4.9.6-T1A.tar
diff --context --recurs m:\bind496t1a/compat/lib/Makefile m:\bind/compat/lib/Makefile
*** m:\bind496t1a/compat/lib/Makefile	Sun May 18 02:29:55 1997
--- m:\bind/compat/lib/Makefile	Tue Jun 24 18:02:23 1997
***************
*** 1,6 ****
  #
  #	from @(#)Makefile	5.16 (Berkeley) 3/14/88
! #	$Id: Makefile,v 8.5 1996/06/02 08:20:33 vixie Exp vixie $
  #
  
  ## ++Copyright++ 1988
--- 1,6 ----
  #
  #	from @(#)Makefile	5.16 (Berkeley) 3/14/88
! #	$Id: Makefile,v 8.6 1997/06/01 20:34:27 vixie Exp $
  #
  
  ## ++Copyright++ 1988
diff --context --recurs m:\bind496t1a/conf/portability.h m:\bind/conf/portability.h
*** m:\bind496t1a/conf/portability.h	Sun May 18 02:29:55 1997
--- m:\bind/conf/portability.h	Tue Jun 24 18:02:18 1997
***************
*** 1,7 ****
  /* portability.h - include or define things that aren't present on all systems
   * vixie@decwrl 26dec92 [new]
   *
!  * $Id: portability.h,v 8.20 1996/11/26 10:11:16 vixie Exp vixie $
   */
  
  /*
--- 1,7 ----
  /* portability.h - include or define things that aren't present on all systems
   * vixie@decwrl 26dec92 [new]
   *
!  * $Id: portability.h,v 8.21 1997/06/01 20:34:27 vixie Exp $
   */
  
  /*
diff --context --recurs m:\bind496t1a/contrib/CATALOGUE m:\bind/contrib/CATALOGUE
*** m:\bind496t1a/contrib/CATALOGUE	Wed May 28 16:30:28 1997
--- m:\bind/contrib/CATALOGUE	Tue Jun 24 18:02:22 1997
***************
*** 1,20 ****
! this directory is full of tools and examples that various individual
! contributors have sent in.  most of them are actually in live production
! use somewhere, though they are not of "publication" quality which is 
! why they are here instead of in comp.sources.unix.  most of them are
! not documented other than with comments in the sources.  all of them
! are fairly clever.
  
! use at your own risk.  neither the U C Regents or Digital Equipment
! Corporation asserts compilation copyright on any of the works in this
! directory; copyright, if any, rests with the contributors whose names appear
! in the source files.  no warranty is expressed or implied by the U C
! Regents or Digital Equipment Corporation.  void where prohibited by law.
! contents may have settled during shipping.
  
  ------------------------------------------------------------------------------
  The following is a short description of the items contained in contrib/
  ------------------------------------------------------------------------------
  umich/
  	dnsstats - A shell script which processes the logging produced by
  	named when it has been built with QRYLOG defined and started with
--- 1,297 ----
! Forwarded: Mon, 23 Jun 1997 20:22:08 -0700
! Forwarded: "halley "
! Received: from seiden.com (seiden.com [207.88.176.68]) 
! 	by gw.home.vix.com (8.8.4/) via SMTP id OAA28822
!         for <bind-bugs@vix.com>; Sat, 14 Jun 1997 14:18:00 -0700
!         env-from (mis@seiden.com)
! Received: by seiden.com (4.1/1.39)
! 	id AA12966; Sat, 14 Jun 97 14:17:57 PDT
! From: mis@seiden.com (Mark Seiden)
! Message-Id: <9706142117.AA12966@seiden.com>
! Subject: revised contrib/CATALOGUE
! To: bind-bugs@vix.com
! Date: Sat, 14 Jun 1997 14:17:56 -0700 (PDT)
! X-Mailer: ELM [version 2.4ME+ PL25 (25)]
! Mime-Version: 1.0
! Content-Type: text/plain; charset=US-ASCII
! Content-Transfer-Encoding: 7bit
  
! greetings.
! 
! i finally got upset with the contrib hierarchy, and catalogued it.
! 
! what do you think about moving a lot of the ancient 4.x-specific stuff
! to old?
! 
! what do you think about providing some opinions on what's useful,
! what's merely redundant, and what's totally obsolete?  (i mean, it's
! hard to distinguish at this point between the n tools for flat-file to
! zone data conversion.)
! 
! what do you think about a functional index?  categories like
! debugging
! administration
! 
! 
! here's what i've got, so far:
  
+ 
+ This directory is full of tools and examples that various individual
+ contributors have sent in.  Most of them are actually in live production
+ use somewhere, though they are not of "publication" quality (which is 
+ why they are here instead of in comp.sources.unix).  Most of them are
+ not documented other than with comments in the sources.  All of them
+ are fairly clever.
+ 
+ Use at your own risk.  Neither the U C Regents or Digital Equipment
+ Corporation asserts compilation copyright on any of the works in this
+ directory; copyright, if any, rests with the contributors whose names appear
+ in the source files.  No warranty is expressed or implied by the U C
+ Regents or Digital Equipment Corporation.  Void where prohibited by law.
+ Contents may have settled during shipping.
+ 
  ------------------------------------------------------------------------------
  The following is a short description of the items contained in contrib/
  ------------------------------------------------------------------------------
+ arlib
+ 	Library routines for doing asynchronous DNS lookups, from Darren Reed.
+ 
+ ckdns
+ 	cron script to check some details about domains 
+ 	listed as primary or secondary in named.boot, and notify about 
+ 	anomalies. From Jim Knutson.
+ 
+ decwrl/
+ 	mkdb.pl
+ 	     builds .data and .zone files from a hosts(5) file.
+ 	gethost.c
+ 	hup-named.c
+ 	mkservers.pl
+ 	*.data 
+ 	     Actual running files in the pa.dec.com domain (as of 
+ 	     April, 1993, that is), so in pre-bind 8.1 format.
+ 
+ dnsparse/
+ 	Some tools (dnsparse) for manipulating Domain Name System
+ 	master files, and for converting to /etc/hosts format (dns2host).  
+ 	Also tools (simphosts, sorthosts) for dealing with host tables.
+ 	From Marion Hakanson.
+ 
+ dnswalk
+ 	dnswalk is a DNS debugger.  It performs zone transfers of specified
+ 	domains, and checks the database in numerous ways for internal
+ 	consistency, as well as accuracy.  From David Barr.
+ 
+ doc
+ 	Doc (domain obscenity control) is a program which diagnoses
+ 	misbehaving domains by sending queries off to the appropriate
+ 	DNS nameservers, and performing simple analysis on the responses.
+ 	From Brad Knowles.
+ 
+ getkeyby
+ 	A library routine, getkeybyname(), which permits cryptographic
+ 	keys to be obtained from DNSm from wherever people have
+ 	published them.  From John Gilmore.
+ 
+ host
+ 	query nameserver about domain names and zones.
+ 	From Eric Wassenaar.
+ 
+ hostmaint
+ 	ndrev.c
+ 	   takes a forward map, and creates PTR records based on the A records.
+ 	   From Douglas E. Nelson.
+ 	bunch of undocumented, nonportable awk scripts, and a driver Makefile 
+ 	which ftps or rdists .txt files, awks them, builds other text files.
+ 
+ inaddrtool
+ 	A tool usable to read email messages containing RIPE-105 database
+ 	objects to test or change in-addr.arpa delegations. 
+ 	From David Kessens.
+ 
+ lamers
+ 	A lame delegation notifier. From Kimmo Suominen.
+ 
+ misc/
+ 	bstat
+ 	  bind statistics display tool. From Paul Albitz.
+ 
+ 	cachebuild
+  	  Builds a new root cache file for you, by querying any 
+ 	  root name server it can still talk to. From Paul Balyoz.
+ 
+ 	checkdns
+ 	  A script to check forward/reverse mapping consistency.
+ 	  From Hans van Staveren.
+ 
+ 	checker 
+ 	A pointer to code, at ftp://caldera.usc.edu/pub/checker
+ 	The Checker Project is an attempt to build onto named the ability to 
+ 	scan the incoming query traffic looking for client machines having
+ 	problems getting their requests satisfied.  C code builds a database 
+ 	from the nameserver query and response traffic.  Whenever a query 
+ 	or response is passed through the checker code its timing and 
+ 	response code is checked against some historical parameters 
+ 	to see if the client's activity falls within some behavioral 
+ 	patterns previously identified with some broken resolver 
+ 	or nameserver implementations.  Reports include such things as: 
+ 	activity summary, client address sorted by number of different 
+ 	queries, query name sorted by number of requests, and client 
+ 	addresses that have had behaviors that fall within the predefined 
+ 	patterns. From Stephen B. Miller, Peter Danzig and Anant Kumar.
+ 	
+ 	checksoa.pl
+ 	  check SOA serial numbers given a local(?) named.boot file.
+ 
+ 	comparezones
+ 	  This script compares the contents of two zone files, excluding the
+ 	  second line (serial) and all comments. From Philip Hazel.
+ 	
+ 	ctldns
+ 	  a shell script to control server functions by sending the
+           signals whose names you don't want to remember. Similar function
+ 	  to ndc. From Randy Bush.
+ 
+ 	ddt
+ 	  a pointer to "domain debug tools".
+ 
+ 	dns-peers
+ 	  a pointer to tools which facilitates agreements between providers 
+ 	  to serve lists of zones managed by each primary provider.
+ 
+ 	dns-setup.doc
+ 	  a 1993 description of how to set up a primary domain server.
+ 
+ 	dnsfind
+ 	  a perl routine (frontend to dig) akin to perl's find -- it calls
+ 	  a user-supplied dnswanted routine with values from all DNS
+ 	  resource records set into global variables. From Tim Cook.
+ 
+ 	dnsrpt
+ 	   reports on hosts by name and address in a format like hosts(5).
+ 	   checks that A and PTR records match. From Don Lewis.
+ 
+ 	dnstools
+ 	   Build and distribute all zone data and /etc/hosts based 
+ 	   on a single input file. From Eric Murray.
+ 
+ 	getcidrzone 
+ 	   generate zone and include files for classless in-addr delegation.
+ 	   From Mathias Koerber.
+ 	
+ 	graphstats
+ 	   awk and sed frontends to xgraph to analyze syslog XSTATS statistics.
+ 	   From Nigel Campbell.
+ 
+ 	hostent
+ 	   Displays the hostent structure for a given hostname or ip address.
+ 	   From Phil Blanchfield.
+ 
+ 	makezones
+ 	   Script to checks forward zone data, generate inverse data.
+ 	   From Philip Hazel.
+ 
+ 	ndrev
+ 	   takes a forward map, and creates PTR records based on the A records.
+ 	   From Douglas E. Nelson.
+ 
+ 	netbsd-shlib
+ 	   makefile diffs for building shared libraries for BIND 4.9.3
+ 	   on SunOS 4.x and NetBSD 1.x.  (obsolete?)
+ 
+ 	nscount
+ 	   asks a server for NS records	and counts them. From Paolo Bevilacqua.
+ 
+ 	reload
+ 	   Similar function as ctldns (q.v.) and ndc.  From Mark Andrews.
+ 
+ 	resparse
+ 	   pointer to c routines to parse the results of a 
+ 	   res_query/res_search call.  From Dave Shield.
+ 
+ 	settransfer*
+ 	   various diffs to bind 4.9.x to implement "transfer".
+ 
+ 	soa-easy
+ 	   a tool for automatic generation of SOA serial numbers based
+ 	   on RCS headers.  From Tim Cook.
+ 
+ 	update-rootcache
+ 	    see cachebuild.  From Fred Condo.
+ 
+ 	update-soa
+ 	    automatically update serial number in SOA. From Craig Leres.
+ 
+ 	update_bindcache
+ 	    see cachebuild. fetches data from ns.internic.net and does
+ 	    some validation.  From Joachim Astel.
+ 
+ 	updatedns
+ 	    /etc/hosts to zonefiles converter from George D M Ross.
+ 
+ 	xdns-info
+ 	    pointer to library that builds/parses DNS packets.
+ 
+ 	xstats-reporter
+ 	    script that produces stats from named XSTATS variables.
+ 	    also see graphstats. From Benoit Grange.
+ 
+ msql
+ 	Patches for bind 4.9.3 to use msql for zone data storage.
+ 	Front-ends to the msql dbms for zone and host data administration. 
+ 	You can (add, remove, edit, list) (zone data, host records).
+ 	From Chris Seawood, David Hughes, Paul Vixie.
+ 
+ multizdb
+ 	patches to 4.9.3 to support multiple zones per database file.
+ 	From Bill Carpenter.
+ 
+ named-lint
+ 	a basic bison parser for 4.x zone data.
+ 
+ next-step
+ 	next patches?
+ 
+ ninit
+ 	named init program.  restarts named if it exits or hangs, and 
+ 	sends it a signal every 5 minutes to dump stats. From Theodore Ts'o.
+ 
+ nslint
+ 	a lint program which performs consistency checks on DNS files.  
+ 	from Craig Leres.
+ 
+ nutshell
+ 	canon.perl
+ 	get_cache
+ 	sum_debug
+ 	check_del
+ 	bind_debug
+ 	ip_to_name
+ 	check_soa
+ 	h2n
+ 	tools referred to in chapter 6-9, 11, 13 of Albitz and Liu.
+ 
+ old
+ 	old versions of contrib code.
+ 
+ os2/emx
+ 	files related to the os/2 EMX port of bind.	
+ 
+ rfc1101
+ 
+ tic
+ 	DNS and NIS management tools from Texas Internet Consulting.
+ 
+ tplb
+ 	notes on load balancing DNS from Tp Brisco.
+ 
+ trnamed
+ 	find broken resolvers from named.run output. From Mike Minnich.
+ 
+ ucsd
+ 	code used to automatically maintain the AMPR.ORG hierarchy.
+ 	From Brian Kantor.
+ 
  umich/
  	dnsstats - A shell script which processes the logging produced by
  	named when it has been built with QRYLOG defined and started with
***************
*** 36,38 ****
--- 313,321 ----
  
  	zt - A shell script which performs zone transfers.  It has a handy
  	flag which allows it to perform recursive zone transfers.
+ 
+ 
+ 
+ -- 
+ mark seiden, mis@seiden.com, 1-(415) 592 8559 (voice)
+ 
diff --context --recurs m:\bind496t1a/doc/bog/file.psf m:\bind/doc/bog/file.psf
*** m:\bind496t1a/doc/bog/file.psf	Wed May 28 04:34:25 1997
--- m:\bind/doc/bog/file.psf	Tue Jun 24 05:15:07 1997
***************
*** 1,6 ****
  %!PS-Adobe-3.0
  %%Creator: groff version 1.10
! %%CreationDate: Tue May 27 21:34:25 1997
  %%DocumentNeededResources: font Times-Bold
  %%+ font Times-Italic
  %%+ font Times-Roman
--- 1,6 ----
  %!PS-Adobe-3.0
  %%Creator: groff version 1.10
! %%CreationDate: Mon Jun 23 22:15:07 1997
  %%DocumentNeededResources: font Times-Bold
  %%+ font Times-Italic
  %%+ font Times-Roman
Only in m:\bind496t1a/doc: i-d
diff --context --recurs m:\bind496t1a/include/netdb.h m:\bind/include/netdb.h
*** m:\bind496t1a/include/netdb.h	Sun May 18 02:30:03 1997
--- m:\bind/include/netdb.h	Tue Jun 24 18:02:17 1997
***************
*** 55,61 ****
  
  /*
   *      @(#)netdb.h	8.1 (Berkeley) 6/2/93
!  *	$Id: netdb.h,v 8.7 1996/05/09 05:59:09 vixie Exp vixie $
   */
  
  #ifndef _NETDB_H_
--- 55,61 ----
  
  /*
   *      @(#)netdb.h	8.1 (Berkeley) 6/2/93
!  *	$Id: netdb.h,v 8.8 1997/06/01 20:34:32 vixie Exp $
   */
  
  #ifndef _NETDB_H_
diff --context --recurs m:\bind496t1a/include/resolv.h m:\bind/include/resolv.h
*** m:\bind496t1a/include/resolv.h	Tue Jan 07 03:25:10 1997
--- m:\bind/include/resolv.h	Tue Jun 24 18:02:17 1997
***************
*** 55,61 ****
  
  /*
   *	@(#)resolv.h	8.1 (Berkeley) 6/2/93
!  *	$Id: resolv.h,v 8.17 1996/11/26 10:11:20 vixie Exp vixie $
   */
  
  #ifndef _RESOLV_H_
--- 55,61 ----
  
  /*
   *	@(#)resolv.h	8.1 (Berkeley) 6/2/93
!  *	$Id: resolv.h,v 8.18 1997/06/01 20:34:32 vixie Exp $
   */
  
  #ifndef _RESOLV_H_
diff --context --recurs m:\bind496t1a/man/dig.1 m:\bind/man/dig.1
*** m:\bind496t1a/man/dig.1	Sun May 18 02:30:03 1997
--- m:\bind/man/dig.1	Tue Jun 24 18:02:17 1997
***************
*** 1,4 ****
! .\" $Id: dig.1,v 8.1 1994/12/15 06:24:10 vixie Exp vixie $
  .\"
  .\" ++Copyright++ 1993
  .\" -
--- 1,4 ----
! .\" $Id: dig.1,v 8.2 1997/06/01 20:34:33 vixie Exp $
  .\"
  .\" ++Copyright++ 1993
  .\" -
diff --context --recurs m:\bind496t1a/named/Version.c m:\bind/named/Version.c
*** m:\bind496t1a/named/Version.c	Wed Apr 30 10:19:51 1997
--- m:\bind/named/Version.c	Tue Jun 24 18:02:18 1997
***************
*** 1,11 ****
  /*
   *	@(#)Version.c	4.9 (Berkeley) 7/21/90
!  *	$Id: Version.c,v 8.1 1994/12/15 06:24:14 vixie Exp vixie $
!  */
! 
! #ifndef lint
! char sccsid[] = "@(#)named %VERSION% %WHEN% %WHOANDWHERE%";
! char rcsid[] = "$Id: Version.c,v 8.1 1994/12/15 06:24:14 vixie Exp vixie $";
  #endif /* not lint */
  
  char Version[] = "named %VERSION% %WHEN%\n\t%WHOANDWHERE%";
--- 1,11 ----
  /*
   *	@(#)Version.c	4.9 (Berkeley) 7/21/90
!  *	$Id: Version.c,v 8.2 1997/06/01 20:34:34 vixie Exp $
!  */
! 
! #ifndef lint
! char sccsid[] = "@(#)named %VERSION% %WHEN% %WHOANDWHERE%";
! char rcsid[] = "$Id: Version.c,v 8.2 1997/06/01 20:34:34 vixie Exp $";
  #endif /* not lint */
  
  char Version[] = "named %VERSION% %WHEN%\n\t%WHOANDWHERE%";
diff --context --recurs m:\bind496t1a/named/db_defs.h m:\bind/named/db_defs.h
*** m:\bind496t1a/named/db_defs.h	Wed Apr 30 10:18:49 1997
--- m:\bind/named/db_defs.h	Tue Jun 24 18:02:17 1997
***************
*** 1,6 ****
  /*
   *	from db.h	4.16 (Berkeley) 6/1/90
!  *	$Id: db_defs.h,v 8.5 1996/08/27 08:33:23 vixie Exp vixie $
   */
  
  /*
--- 1,6 ----
  /*
   *	from db.h	4.16 (Berkeley) 6/1/90
!  *	$Id: db_defs.h,v 8.6 1997/06/01 20:34:34 vixie Exp $
   */
  
  /*
diff --context --recurs m:\bind496t1a/named/db_func.h m:\bind/named/db_func.h
*** m:\bind496t1a/named/db_func.h	Wed Apr 30 10:17:18 1997
--- m:\bind/named/db_func.h	Tue Jun 24 18:02:17 1997
***************
*** 1,6 ****
  /* db_proc.h - prototypes for functions in db_*.c
   *
!  * $Id: db_func.h,v 8.12 1996/09/22 00:13:10 vixie Exp vixie $
   */
  
  /* ++from db_update.c++ */
--- 1,6 ----
  /* db_proc.h - prototypes for functions in db_*.c
   *
!  * $Id: db_func.h,v 8.13 1997/06/01 20:34:34 vixie Exp $
   */
  
  /* ++from db_update.c++ */
diff --context --recurs m:\bind496t1a/named/db_load.c m:\bind/named/db_load.c
*** m:\bind496t1a/named/db_load.c	Sun May 18 02:30:04 1997
--- m:\bind/named/db_load.c	Tue Jun 24 18:02:17 1997
***************
*** 1,6 ****
  #if !defined(lint) && !defined(SABER)
  static char sccsid[] = "@(#)db_load.c	4.38 (Berkeley) 3/2/91";
! static char rcsid[] = "$Id: db_load.c,v 8.31 1996/12/18 04:09:48 vixie Exp vixie $";
  #endif /* not lint */
  
  /*
--- 1,6 ----
  #if !defined(lint) && !defined(SABER)
  static char sccsid[] = "@(#)db_load.c	4.38 (Berkeley) 3/2/91";
! static char rcsid[] = "$Id: db_load.c,v 8.32 1997/06/01 20:34:34 vixie Exp $";
  #endif /* not lint */
  
  /*
diff --context --recurs m:\bind496t1a/named/db_secure.c m:\bind/named/db_secure.c
*** m:\bind496t1a/named/db_secure.c	Tue Jan 07 03:09:12 1997
--- m:\bind/named/db_secure.c	Tue Jun 24 18:02:17 1997
***************
*** 1,5 ****
  #ifndef LINT
! static char rcsid[] = "$Id: db_secure.c,v 8.6 1996/05/17 09:10:46 vixie Exp vixie $";
  #endif
  
  /* this file was contributed by Gregory Neil Shapiro of WPI in August 1993 */
--- 1,5 ----
  #ifndef LINT
! static char rcsid[] = "$Id: db_secure.c,v 8.7 1997/06/01 20:34:34 vixie Exp $";
  #endif
  
  /* this file was contributed by Gregory Neil Shapiro of WPI in August 1993 */
diff --context --recurs m:\bind496t1a/named/db_update.c m:\bind/named/db_update.c
*** m:\bind496t1a/named/db_update.c	Wed Apr 30 10:17:19 1997
--- m:\bind/named/db_update.c	Tue Jun 24 18:02:17 1997
***************
*** 1,6 ****
  #if !defined(lint) && !defined(SABER)
  static char sccsid[] = "@(#)db_update.c	4.28 (Berkeley) 3/21/91";
! static char rcsid[] = "$Id: db_update.c,v 8.18 1996/10/08 04:51:03 vixie Exp vixie $";
  #endif /* not lint */
  
  /*
--- 1,6 ----
  #if !defined(lint) && !defined(SABER)
  static char sccsid[] = "@(#)db_update.c	4.28 (Berkeley) 3/21/91";
! static char rcsid[] = "$Id: db_update.c,v 8.19 1997/06/01 20:34:34 vixie Exp $";
  #endif /* not lint */
  
  /*
diff --context --recurs m:\bind496t1a/named/named-xfer.c m:\bind/named/named-xfer.c
*** m:\bind496t1a/named/named-xfer.c	Mon May 19 22:47:05 1997
--- m:\bind/named/named-xfer.c	Tue Jun 24 18:02:18 1997
***************
*** 92,98 ****
  
  #if !defined(lint) && !defined(SABER)
  static char sccsid[] = "@(#)named-xfer.c	4.18 (Berkeley) 3/7/91";
! static char rcsid[] = "$Id: named-xfer.c,v 8.22 1996/12/02 09:17:21 vixie Exp vixie $";
  #endif /* not lint */
  
  #include <sys/types.h>
--- 92,98 ----
  
  #if !defined(lint) && !defined(SABER)
  static char sccsid[] = "@(#)named-xfer.c	4.18 (Berkeley) 3/7/91";
! static char rcsid[] = "$Id: named-xfer.c,v 8.23 1997/06/01 20:34:34 vixie Exp $";
  #endif /* not lint */
  
  #include <sys/types.h>
diff --context --recurs m:\bind496t1a/named/ns_defs.h m:\bind/named/ns_defs.h
*** m:\bind496t1a/named/ns_defs.h	Tue Jan 07 02:55:03 1997
--- m:\bind/named/ns_defs.h	Tue Jun 24 18:02:17 1997
***************
*** 1,6 ****
  /*
   *	from ns.h	4.33 (Berkeley) 8/23/90
!  *	$Id: ns_defs.h,v 8.8 1996/09/22 00:13:10 vixie Exp vixie $
   */
  
  /*
--- 1,6 ----
  /*
   *	from ns.h	4.33 (Berkeley) 8/23/90
!  *	$Id: ns_defs.h,v 8.8 1996/09/22 00:13:10 vixie Exp $
   */
  
  /*
diff --context --recurs m:\bind496t1a/named/ns_forw.c m:\bind/named/ns_forw.c
*** m:\bind496t1a/named/ns_forw.c	Wed May 28 04:21:27 1997
--- m:\bind/named/ns_forw.c	Tue Jun 24 18:02:17 1997
***************
*** 1,6 ****
  #if !defined(lint) && !defined(SABER)
  static char sccsid[] = "@(#)ns_forw.c	4.32 (Berkeley) 3/3/91";
! static char rcsid[] = "$Id: ns_forw.c,v 8.19 1996/12/02 09:27:36 vixie Exp vixie $";
  #endif /* not lint */
  
  /*
--- 1,6 ----
  #if !defined(lint) && !defined(SABER)
  static char sccsid[] = "@(#)ns_forw.c	4.32 (Berkeley) 3/3/91";
! static char rcsid[] = "$Id: ns_forw.c,v 8.20 1997/06/01 20:34:34 vixie Exp $";
  #endif /* not lint */
  
  /*
diff --context --recurs m:\bind496t1a/named/ns_glob.h m:\bind/named/ns_glob.h
*** m:\bind496t1a/named/ns_glob.h	Wed Apr 30 10:19:51 1997
--- m:\bind/named/ns_glob.h	Tue Jun 24 18:02:17 1997
***************
*** 1,6 ****
  /*
   *	from ns.h	4.33 (Berkeley) 8/23/90
!  *	$Id: ns_glob.h,v 8.11 1996/11/11 06:36:49 vixie Exp vixie $
   */
  
  /*
--- 1,6 ----
  /*
   *	from ns.h	4.33 (Berkeley) 8/23/90
!  *	$Id: ns_glob.h,v 8.12 1997/06/01 20:34:34 vixie Exp $
   */
  
  /*
diff --context --recurs m:\bind496t1a/named/ns_init.c m:\bind/named/ns_init.c
*** m:\bind496t1a/named/ns_init.c	Wed Apr 30 10:06:14 1997
--- m:\bind/named/ns_init.c	Tue Jun 24 18:02:17 1997
***************
*** 1,6 ****
  #if !defined(lint) && !defined(SABER)
  static char sccsid[] = "@(#)ns_init.c	4.38 (Berkeley) 3/21/91";
! static char rcsid[] = "$Id: ns_init.c,v 8.24 1996/12/02 09:17:21 vixie Exp vixie $";
  #endif /* not lint */
  
  /*
--- 1,6 ----
  #if !defined(lint) && !defined(SABER)
  static char sccsid[] = "@(#)ns_init.c	4.38 (Berkeley) 3/21/91";
! static char rcsid[] = "$Id: ns_init.c,v 8.25 1997/06/01 20:34:34 vixie Exp $";
  #endif /* not lint */
  
  /*
diff --context --recurs m:\bind496t1a/named/ns_main.c m:\bind/named/ns_main.c
*** m:\bind496t1a/named/ns_main.c	Wed Apr 30 10:02:43 1997
--- m:\bind/named/ns_main.c	Tue Jun 24 18:02:18 1997
***************
*** 1,6 ****
  #if !defined(lint) && !defined(SABER)
  static char sccsid[] = "@(#)ns_main.c	4.55 (Berkeley) 7/1/91";
! static char rcsid[] = "$Id: ns_main.c,v 8.24 1996/11/26 10:11:22 vixie Exp vixie $";
  #endif /* not lint */
  
  /*
--- 1,6 ----
  #if !defined(lint) && !defined(SABER)
  static char sccsid[] = "@(#)ns_main.c	4.55 (Berkeley) 7/1/91";
! static char rcsid[] = "$Id: ns_main.c,v 8.25 1997/06/01 20:34:34 vixie Exp $";
  #endif /* not lint */
  
  /*
diff --context --recurs m:\bind496t1a/named/ns_req.c m:\bind/named/ns_req.c
*** m:\bind496t1a/named/ns_req.c	Sun May 18 02:30:04 1997
--- m:\bind/named/ns_req.c	Tue Jun 24 18:02:17 1997
***************
*** 1,6 ****
  #if !defined(lint) && !defined(SABER)
  static char sccsid[] = "@(#)ns_req.c	4.47 (Berkeley) 7/1/91";
! static char rcsid[] = "$Id: ns_req.c,v 8.27 1996/10/08 04:51:03 vixie Exp vixie $";
  #endif /* not lint */
  
  /*
--- 1,6 ----
  #if !defined(lint) && !defined(SABER)
  static char sccsid[] = "@(#)ns_req.c	4.47 (Berkeley) 7/1/91";
! static char rcsid[] = "$Id: ns_req.c,v 8.28 1997/06/01 20:34:34 vixie Exp $";
  #endif /* not lint */
  
  /*
diff --context --recurs m:\bind496t1a/named/ns_resp.c m:\bind/named/ns_resp.c
*** m:\bind496t1a/named/ns_resp.c	Wed May 28 04:24:26 1997
--- m:\bind/named/ns_resp.c	Tue Jun 24 02:25:30 1997
***************
*** 1,15 ****
  #if !defined(lint) && !defined(SABER)
  static char sccsid[] = "@(#)ns_resp.c	4.65 (Berkeley) 3/3/91";
! static char rcsid[] = "$Id: ns_resp.c,v 8.37 1996/12/02 09:17:21 vixie Exp vixie $";
! #endif /* not lint */
  
! /*
!  * ++Copyright++ 1986, 1988, 1990
   * -
!  * Copyright (c) 1986, 1988, 1990
!  *    The Regents of the University of California.  All rights reserved.
   * 
!  * Redistribution and use in source and binary forms, with or without
   * modification, are permitted provided that the following conditions
   * are met:
   * 1. Redistributions of source code must retain the above copyright
--- 1,15 ----
  #if !defined(lint) && !defined(SABER)
  static char sccsid[] = "@(#)ns_resp.c	4.65 (Berkeley) 3/3/91";
! static char rcsid[] = "$Id: ns_resp.c,v 8.38 1997/06/01 20:34:34 vixie Exp vixie $";
! #endif /* not lint */
  
! /*
!  * ++Copyright++ 1986, 1988, 1990
   * -
!  * Copyright (c) 1986, 1988, 1990
!  *    The Regents of the University of California.  All rights reserved.
   * 
!  * Redistribution and use in source and binary forms, with or without
   * modification, are permitted provided that the following conditions
   * are met:
   * 1. Redistributions of source code must retain the above copyright
***************
*** 246,252 ****
  	int qtype, qclass, dbflags;
  	int restart;	/* flag for processing cname response */
  	int validanswer;
! 	int cname, lastwascname;
  	int count, founddata, foundname;
  	int buflen;
  	int newmsglen;
--- 246,252 ----
  	int qtype, qclass, dbflags;
  	int restart;	/* flag for processing cname response */
  	int validanswer;
! 	int cname, lastwascname, externalcname;
  	int count, founddata, foundname;
  	int buflen;
  	int newmsglen;
***************
*** 768,773 ****
--- 768,774 ----
  	nscount = 0;
  	cname = 0;
  	lastwascname = 0;
+ 	externalcname = 0;
  	strcpy(aname, qname);
  
  	if (count) {
***************
*** 800,814 ****
  		type = dp->d_type;
  		if (i < ancount) {
  			/* Answer section. */
! 			if (strcasecmp(name, aname) != 0) {
! 				syslog(LOG_DEBUG, "wrong ans. name (%s != %s)",
! 				       name, aname);
  				db_free(dp);
  				continue;
  			}
  			if (type == T_CNAME &&
  			    qtype != T_CNAME && qtype != T_ANY) {
  				strcpy(aname, (char *)dp->d_data);
  				cname = 1;
  				lastwascname = 1;
  			} else {
--- 801,823 ----
  		type = dp->d_type;
  		if (i < ancount) {
  			/* Answer section. */
! 			if (externalcname || strcasecmp(name, aname) != 0) {
! 				if (!externalcname)
! 					syslog(LOG_DEBUG,
! 					       "wrong ans. name (%s != %s)",
! 					       name, aname);
! 				else
! 					dprintf(3, (ddt,
! 				 "ignoring answer '%s' after external cname\n",
! 						    name));
  				db_free(dp);
  				continue;
  			}
  			if (type == T_CNAME &&
  			    qtype != T_CNAME && qtype != T_ANY) {
  				strcpy(aname, (char *)dp->d_data);
+ 				if (!samedomain(aname, qp->q_domain))
+ 					externalcname = 1;
  				cname = 1;
  				lastwascname = 1;
  			} else {
***************
*** 827,832 ****
--- 836,843 ----
  		} else {
  			/* After answer section. */
  			if (lastwascname) {
+ 				dprintf(3, (ddt,
+ 				 "last was cname, ignoring auth. and add.\n"));
  				db_free(dp);
  				break;
  			}
***************
*** 842,855 ****
  						       name[0] ? name : ".");
  						db_free(dp);
  						continue;
! 					} else if (!cname &&
! 						   !samedomain(name,
  							       qp->q_domain)) {
! 						syslog(LOG_DEBUG,
    					            "bad referral (%s !< %s)",
! 						       name[0] ? name : ".",
! 						       qp->q_domain[0] ?
! 						       qp->q_domain : ".");
  						db_free(dp);
  						continue;
  					}
--- 853,866 ----
  						       name[0] ? name : ".");
  						db_free(dp);
  						continue;
! 					} else if (!samedomain(name,
  							       qp->q_domain)) {
! 						if (!externalcname)
! 						    syslog(LOG_DEBUG,
    					            "bad referral (%s !< %s)",
! 							 name[0] ? name : ".",
! 							 qp->q_domain[0] ?
! 							 qp->q_domain : ".");
  						db_free(dp);
  						continue;
  					}
***************
*** 875,880 ****
--- 886,899 ----
  				switch (type) {
  				case T_A:
  				case T_AAAA:
+ 					if (externalcname ||
+ 					    !samedomain(name, qp->q_domain)) {
+ 						dprintf(3, (ddt,
+ 				     "ignoring additional info '%s' type %s\n",
+ 						       name, p_type(type)));
+ 						db_free(dp);
+ 						continue;
+ 					}
  					if (!related_additional(name)) {
  						syslog(LOG_DEBUG,
  			     "unrelated additional info '%s' type %s from %s",
***************
*** 910,916 ****
  				free(flushset[i].fs_name);
  		free((char*)flushset);
  	}
! 	if (lastwascname)
  		syslog(LOG_DEBUG, "%s (%s)", danglingCname, aname);
  
  	if (cp > eom) {
--- 929,935 ----
  				free(flushset[i].fs_name);
  		free((char*)flushset);
  	}
! 	if (lastwascname && !externalcname)
  		syslog(LOG_DEBUG, "%s (%s)", danglingCname, aname);
  
  	if (cp > eom) {
diff --context --recurs m:\bind496t1a/res/Makefile m:\bind/res/Makefile
*** m:\bind496t1a/res/Makefile	Sun May 18 02:30:04 1997
--- m:\bind/res/Makefile	Tue Jun 24 18:02:18 1997
***************
*** 1,6 ****
  #
  #	from @(#)Makefile	5.16 (Berkeley) 3/14/88
! #	$Id: Makefile,v 8.13 1996/08/08 22:49:48 vixie Exp vixie $
  #
  
  ## ++Copyright++ 1988, 1995
--- 1,6 ----
  #
  #	from @(#)Makefile	5.16 (Berkeley) 3/14/88
! #	$Id: Makefile,v 8.14 1997/06/01 20:34:37 vixie Exp $
  #
  
  ## ++Copyright++ 1988, 1995
diff --context --recurs m:\bind496t1a/res/gethnamaddr.c m:\bind/res/gethnamaddr.c
*** m:\bind496t1a/res/gethnamaddr.c	Mon May 19 22:46:12 1997
--- m:\bind/res/gethnamaddr.c	Tue Jun 24 18:02:18 1997
***************
*** 55,61 ****
  
  #if defined(LIBC_SCCS) && !defined(lint)
  static char sccsid[] = "@(#)gethostnamadr.c	8.1 (Berkeley) 6/4/93";
! static char rcsid[] = "$Id: gethnamaddr.c,v 8.20 1996/09/28 06:51:07 vixie Exp vixie $";
  #endif /* LIBC_SCCS and not lint */
  
  #include <sys/types.h>
--- 55,61 ----
  
  #if defined(LIBC_SCCS) && !defined(lint)
  static char sccsid[] = "@(#)gethostnamadr.c	8.1 (Berkeley) 6/4/93";
! static char rcsid[] = "$Id: gethnamaddr.c,v 8.21 1997/06/01 20:34:37 vixie Exp $";
  #endif /* LIBC_SCCS and not lint */
  
  #include <sys/types.h>
diff --context --recurs m:\bind496t1a/res/getnetent.c m:\bind/res/getnetent.c
*** m:\bind496t1a/res/getnetent.c	Tue Jan 07 03:09:13 1997
--- m:\bind/res/getnetent.c	Tue Jun 24 18:02:18 1997
***************
*** 43,49 ****
  
  #if defined(LIBC_SCCS) && !defined(lint)
  static char sccsid[] = "@(#)getnetent.c	8.1 (Berkeley) 6/4/93";
! static char rcsid[] = "$Id: getnetent.c,v 8.3 1996/08/05 08:31:35 vixie Exp vixie $";
  #endif /* LIBC_SCCS and not lint */
  
  #include <sys/types.h>
--- 43,49 ----
  
  #if defined(LIBC_SCCS) && !defined(lint)
  static char sccsid[] = "@(#)getnetent.c	8.1 (Berkeley) 6/4/93";
! static char rcsid[] = "$Id: getnetent.c,v 8.4 1997/06/01 20:34:37 vixie Exp $";
  #endif /* LIBC_SCCS and not lint */
  
  #include <sys/types.h>
diff --context --recurs m:\bind496t1a/res/getnetnamadr.c m:\bind/res/getnetnamadr.c
*** m:\bind496t1a/res/getnetnamadr.c	Tue Jan 07 03:09:13 1997
--- m:\bind/res/getnetnamadr.c	Tue Jun 24 18:02:18 1997
***************
*** 41,47 ****
  #if defined(LIBC_SCCS) && !defined(lint)
  static char sccsid[] = "@(#)getnetbyaddr.c	8.1 (Berkeley) 6/4/93";
  static char sccsid_[] = "from getnetnamadr.c	1.4 (Coimbra) 93/06/03";
! static char rcsid[] = "$Id: getnetnamadr.c,v 8.7 1996/08/05 08:31:35 vixie Exp vixie $";
  #endif /* LIBC_SCCS and not lint */
  
  #include <sys/types.h>
--- 41,47 ----
  #if defined(LIBC_SCCS) && !defined(lint)
  static char sccsid[] = "@(#)getnetbyaddr.c	8.1 (Berkeley) 6/4/93";
  static char sccsid_[] = "from getnetnamadr.c	1.4 (Coimbra) 93/06/03";
! static char rcsid[] = "$Id: getnetnamadr.c,v 8.8 1997/06/01 20:34:37 vixie Exp $";
  #endif /* LIBC_SCCS and not lint */
  
  #include <sys/types.h>
diff --context --recurs m:\bind496t1a/res/res_comp.c m:\bind/res/res_comp.c
*** m:\bind496t1a/res/res_comp.c	Tue Jan 07 03:47:11 1997
--- m:\bind/res/res_comp.c	Tue Jun 24 18:02:18 1997
***************
*** 55,61 ****
  
  #if defined(LIBC_SCCS) && !defined(lint)
  static char sccsid[] = "@(#)res_comp.c	8.1 (Berkeley) 6/4/93";
! static char rcsid[] = "$Id: res_comp.c,v 8.11 1996/12/02 09:17:22 vixie Exp vixie $";
  #endif /* LIBC_SCCS and not lint */
  
  #include <sys/types.h>
--- 55,61 ----
  
  #if defined(LIBC_SCCS) && !defined(lint)
  static char sccsid[] = "@(#)res_comp.c	8.1 (Berkeley) 6/4/93";
! static char rcsid[] = "$Id: res_comp.c,v 8.12 1997/06/01 20:34:37 vixie Exp $";
  #endif /* LIBC_SCCS and not lint */
  
  #include <sys/types.h>
diff --context --recurs m:\bind496t1a/res/res_debug.c m:\bind/res/res_debug.c
*** m:\bind496t1a/res/res_debug.c	Sun May 18 02:30:05 1997
--- m:\bind/res/res_debug.c	Tue Jun 24 18:02:18 1997
***************
*** 77,83 ****
  
  #if defined(LIBC_SCCS) && !defined(lint)
  static char sccsid[] = "@(#)res_debug.c	8.1 (Berkeley) 6/4/93";
! static char rcsid[] = "$Id: res_debug.c,v 8.19 1996/11/26 10:11:23 vixie Exp vixie $";
  #endif /* LIBC_SCCS and not lint */
  
  #include <sys/param.h>
--- 77,83 ----
  
  #if defined(LIBC_SCCS) && !defined(lint)
  static char sccsid[] = "@(#)res_debug.c	8.1 (Berkeley) 6/4/93";
! static char rcsid[] = "$Id: res_debug.c,v 8.20 1997/06/01 20:34:37 vixie Exp $";
  #endif /* LIBC_SCCS and not lint */
  
  #include <sys/param.h>
diff --context --recurs m:\bind496t1a/res/res_init.c m:\bind/res/res_init.c
*** m:\bind496t1a/res/res_init.c	Tue Jan 07 03:09:13 1997
--- m:\bind/res/res_init.c	Tue Jun 24 18:02:18 1997
***************
*** 55,61 ****
  
  #if defined(LIBC_SCCS) && !defined(lint)
  static char sccsid[] = "@(#)res_init.c	8.1 (Berkeley) 6/7/93";
! static char rcsid[] = "$Id: res_init.c,v 8.7 1996/09/28 06:51:07 vixie Exp vixie $";
  #endif /* LIBC_SCCS and not lint */
  
  #include <sys/types.h>
--- 55,61 ----
  
  #if defined(LIBC_SCCS) && !defined(lint)
  static char sccsid[] = "@(#)res_init.c	8.1 (Berkeley) 6/7/93";
! static char rcsid[] = "$Id: res_init.c,v 8.8 1997/06/01 20:34:37 vixie Exp $";
  #endif /* LIBC_SCCS and not lint */
  
  #include <sys/types.h>
diff --context --recurs m:\bind496t1a/res/res_query.c m:\bind/res/res_query.c
*** m:\bind496t1a/res/res_query.c	Tue Jan 07 02:55:06 1997
--- m:\bind/res/res_query.c	Tue Jun 24 18:02:18 1997
***************
*** 55,70 ****
  
  #if defined(LIBC_SCCS) && !defined(lint)
  static char sccsid[] = "@(#)res_query.c	8.1 (Berkeley) 6/4/93";
! static char rcsid[] = "$Id: res_query.c,v 8.9 1996/09/22 00:13:28 vixie Exp vixie $";
! #endif /* LIBC_SCCS and not lint */
  
! #include <sys/types.h>
! #include <sys/param.h>
! #include <netinet/in.h>
! #include <arpa/inet.h>
! #include <arpa/nameser.h>
  
! #include <stdio.h>
  #include <netdb.h>
  #include <resolv.h>
  #include <ctype.h>
--- 55,70 ----
  
  #if defined(LIBC_SCCS) && !defined(lint)
  static char sccsid[] = "@(#)res_query.c	8.1 (Berkeley) 6/4/93";
! static char rcsid[] = "$Id: res_query.c,v 8.10 1997/06/01 20:34:37 vixie Exp $";
! #endif /* LIBC_SCCS and not lint */
  
! #include <sys/types.h>
! #include <sys/param.h>
! #include <netinet/in.h>
! #include <arpa/inet.h>
! #include <arpa/nameser.h>
  
! #include <stdio.h>
  #include <netdb.h>
  #include <resolv.h>
  #include <ctype.h>
***************
*** 323,329 ****
  {
  	char nbuf[MAXDNAME];
  	const char *longname = nbuf;
! 	int n;
  
  	if ((_res.options & RES_INIT) == 0 && res_init() == -1) {
  		h_errno = NETDB_INTERNAL;
--- 323,329 ----
  {
  	char nbuf[MAXDNAME];
  	const char *longname = nbuf;
! 	int n, d;
  
  	if ((_res.options & RES_INIT) == 0 && res_init() == -1) {
  		h_errno = NETDB_INTERNAL;
***************
*** 339,353 ****
  		 * Check for trailing '.';
  		 * copy without '.' if present.
  		 */
! 		n = strlen(name) - 1;
! 		if (n != (0 - 1) && name[n] == '.' && n < sizeof(nbuf) - 1) {
! 			bcopy(name, nbuf, n);
  			nbuf[n] = '\0';
  		} else
  			longname = name;
! 	} else
! 		sprintf(nbuf, "%.*s.%.*s", MAXDNAME, name, MAXDNAME, domain);
! 
  	return (res_query(longname, class, type, answer, anslen));
  }
  
--- 339,364 ----
  		 * Check for trailing '.';
  		 * copy without '.' if present.
  		 */
! 		n = strlen(name);
! 		if (n >= MAXDNAME) {
! 			h_errno = NO_RECOVERY;
! 			return (-1);
! 		}
! 		n--;
! 		if (n >= 0 && name[n] == '.') {
! 			strncpy(nbuf, name, n);
  			nbuf[n] = '\0';
  		} else
  			longname = name;
! 	} else {
! 		n = strlen(name);
! 		d = strlen(domain);
! 		if (n + d + 1 >= MAXDNAME) {
! 			h_errno = NO_RECOVERY;
! 			return (-1);
! 		}
! 		sprintf(nbuf, "%s.%s", name, domain);
! 	}
  	return (res_query(longname, class, type, answer, anslen));
  }
  
diff --context --recurs m:\bind496t1a/res/res_send.c m:\bind/res/res_send.c
*** m:\bind496t1a/res/res_send.c	Sun May 18 02:30:05 1997
--- m:\bind/res/res_send.c	Tue Jun 24 18:02:18 1997
***************
*** 55,61 ****
  
  #if defined(LIBC_SCCS) && !defined(lint)
  static char sccsid[] = "@(#)res_send.c	8.1 (Berkeley) 6/4/93";
! static char rcsid[] = "$Id: res_send.c,v 8.12 1996/10/08 04:51:06 vixie Exp vixie $";
  #endif /* LIBC_SCCS and not lint */
  
  	/* change this to "0"
--- 55,61 ----
  
  #if defined(LIBC_SCCS) && !defined(lint)
  static char sccsid[] = "@(#)res_send.c	8.1 (Berkeley) 6/4/93";
! static char rcsid[] = "$Id: res_send.c,v 8.13 1997/06/01 20:34:37 vixie Exp $";
  #endif /* LIBC_SCCS and not lint */
  
  	/* change this to "0"
diff --context --recurs m:\bind496t1a/tools/host.c m:\bind/tools/host.c
*** m:\bind496t1a/tools/host.c	Tue Jan 07 02:55:07 1997
--- m:\bind/tools/host.c	Tue Jun 24 18:02:18 1997
***************
*** 67,73 ****
   */
  
  #ifndef lint
! static char rcsid[] = "$Id: host.c,v 8.12 1996/10/08 04:51:07 vixie Exp vixie $";
  #endif /* not lint */
  
  #include <sys/types.h>
--- 67,73 ----
   */
  
  #ifndef lint
! static char rcsid[] = "$Id: host.c,v 8.12 1996/10/08 04:51:07 vixie Exp $";
  #endif /* not lint */
  
  #include <sys/types.h>
diff --context --recurs m:\bind496t1a/tools/nslookup/getinfo.c m:\bind/tools/nslookup/getinfo.c
*** m:\bind496t1a/tools/nslookup/getinfo.c	Tue Jan 07 02:55:06 1997
--- m:\bind/tools/nslookup/getinfo.c	Tue Jun 24 18:02:18 1997
***************
*** 55,61 ****
  
  #ifndef lint
  static char sccsid[] = "@(#)getinfo.c	5.26 (Berkeley) 3/21/91";
! static char rcsid[] = "$Id: getinfo.c,v 8.6 1996/12/02 09:17:24 vixie Exp vixie $";
  #endif /* not lint */
  
  /*
--- 55,61 ----
  
  #ifndef lint
  static char sccsid[] = "@(#)getinfo.c	5.26 (Berkeley) 3/21/91";
! static char rcsid[] = "$Id: getinfo.c,v 8.6 1996/12/02 09:17:24 vixie Exp $";
  #endif /* not lint */
  
  /*
diff --context --recurs m:\bind496t1a/tools/nslookup/send.c m:\bind/tools/nslookup/send.c
*** m:\bind496t1a/tools/nslookup/send.c	Sun May 18 02:30:06 1997
--- m:\bind/tools/nslookup/send.c	Tue Jun 24 18:02:18 1997
***************
*** 55,61 ****
  
  #ifndef lint
  static char sccsid[] = "@(#)send.c	5.18 (Berkeley) 3/2/91";
! static char rcsid[] = "$Id: send.c,v 8.1 1994/12/15 06:24:31 vixie Exp vixie $";
  #endif /* not lint */
  
  /*
--- 55,61 ----
  
  #ifndef lint
  static char sccsid[] = "@(#)send.c	5.18 (Berkeley) 3/2/91";
! static char rcsid[] = "$Id: send.c,v 8.2 1997/06/01 20:34:40 vixie Exp $";
  #endif /* not lint */
  
  /*
