Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/netbsd-1-4]: src/dist/bind/bin Pull up revision 1.1 (new) (requested by ...
details: https://anonhg.NetBSD.org/src/rev/9f29bde73a82
branches: netbsd-1-4
changeset: 469781:9f29bde73a82
user: he <he%NetBSD.org@localhost>
date: Sat Dec 04 16:52:57 1999 +0000
description:
Pull up revision 1.1 (new) (requested by christos and veego):
Update to BIND 8.2.2-P5.
diffstat:
dist/bind/bin/irpd/version.c | 27 +
dist/bind/bin/mkservdb/mkservdb.c | 171 ++
dist/bind/bin/named/db_defs.h | 311 ++++
dist/bind/bin/named/db_dump.c | 665 +++++++++
dist/bind/bin/named/db_func.h | 215 +++
dist/bind/bin/named/db_glob.h | 105 +
dist/bind/bin/named/db_glue.c | 658 +++++++++
dist/bind/bin/named/db_ixfr.c | 863 ++++++++++++
dist/bind/bin/named/db_load.c | 2602 +++++++++++++++++++++++++++++++++++++
dist/bind/bin/named/db_lookup.c | 333 ++++
dist/bind/bin/named/db_save.c | 213 +++
dist/bind/bin/named/db_sec.c | 1099 +++++++++++++++
dist/bind/bin/named/db_tsig.c | 160 ++
dist/bind/bin/named/db_update.c | 995 ++++++++++++++
14 files changed, 8417 insertions(+), 0 deletions(-)
diffs (truncated from 8473 to 300 lines):
diff -r d76076b72b03 -r 9f29bde73a82 dist/bind/bin/irpd/version.c
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/dist/bind/bin/irpd/version.c Sat Dec 04 16:52:57 1999 +0000
@@ -0,0 +1,27 @@
+/* $NetBSD: version.c,v 1.1.1.1.2.2 1999/12/04 16:52:57 he Exp $ */
+
+/*
+ * Copyright (c) 1996 by Internet Software Consortium.
+ *
+ * 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.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM DISCLAIMS
+ * ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL INTERNET SOFTWARE
+ * CONSORTIUM 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.
+ */
+
+#ifndef lint
+char sccsid[] = "@(#)named %VERSION% %WHEN% %WHOANDWHERE%";
+char rcsid[] = "Id: version.c,v 1.1 1999/01/18 07:47:17 vixie Exp";
+#endif /* not lint */
+
+char Version[] = "named %VERSION% %WHEN%\n\t%WHOANDWHERE%";
+char ShortVersion[] = "%VERSION%";
+
diff -r d76076b72b03 -r 9f29bde73a82 dist/bind/bin/mkservdb/mkservdb.c
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/dist/bind/bin/mkservdb/mkservdb.c Sat Dec 04 16:52:57 1999 +0000
@@ -0,0 +1,171 @@
+/* $NetBSD: mkservdb.c,v 1.1.1.1.2.2 1999/12/04 16:53:02 he Exp $ */
+
+#if !defined(lint) && !defined(SABER)
+static const char rcsid[] = "Id: mkservdb.c,v 1.6 1999/10/13 16:39:00 vixie Exp";
+#endif /* not lint */
+
+/*
+ * Copyright (c) 1998,1999 by Internet Software Consortium.
+ *
+ * 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.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM DISCLAIMS
+ * ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL INTERNET SOFTWARE
+ * CONSORTIUM 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.
+ */
+
+#include "port_before.h"
+
+#include <sys/types.h>
+#include <netinet/in.h>
+#include <arpa/nameser.h>
+#include <resolv.h>
+
+#include <ctype.h>
+#ifdef IRS_LCL_SV_DB
+#include <db.h>
+#endif
+#include <fcntl.h>
+#include <limits.h>
+#include <netdb.h>
+#include <pwd.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+
+#include "../../include/irs.h"
+#include "../../lib/irs/irs_p.h"
+
+#include "port_after.h"
+
+#ifdef SPRINTF_CHAR
+# define SPRINTF(x) strlen(sprintf/**/x)
+#else
+# define SPRINTF(x) ((size_t)sprintf x)
+#endif
+
+#ifndef IRS_LCL_SV_DB
+main(int argc, char **argv) {
+ fprintf(stderr, "%s: not supported on this architecture\n", argv[0]);
+ exit(1);
+}
+
+#else
+
+#define _PATH_SERVICES_DB_TMP _PATH_SERVICES_DB ".new"
+
+struct servent *getnextent(FILE *);
+
+main(int argc, char **argv) {
+ DB *db;
+ DBT key;
+ DBT data;
+ char *filename = _PATH_SERVICES;
+ char *tmpdatabase = _PATH_SERVICES_DB_TMP;
+ char *database = _PATH_SERVICES_DB;
+ char dbuf[1024];
+ char kbuf[512];
+ u_short *ports;
+ struct lcl_sv lcl_sv;
+ struct servent *sv;
+ int n, r;
+ char *p;
+
+ unlink(tmpdatabase);
+
+ if (argc > 1)
+ filename = argv[1];
+
+ lcl_sv.fp = fopen(filename, "r");
+ if (lcl_sv.fp == NULL)
+ err(1, "%s", filename);
+
+ db = dbopen(tmpdatabase, O_CREAT|O_RDWR, 0444, DB_BTREE, NULL);
+ if (db == NULL)
+ err(1, "%s", tmpdatabase);
+
+ while ((sv = irs_lclsv_fnxt(&lcl_sv)) != NULL) {
+ if (sv->s_proto == NULL)
+ continue;
+
+ key.data = kbuf;
+ data.data = dbuf;
+
+ /* Note that (sizeof "/") == 2. */
+ if (strlen(sv->s_name) + sizeof "/" + strlen(sv->s_proto)
+ > sizeof kbuf)
+ continue;
+ key.size = SPRINTF((kbuf, "%s/%s", sv->s_name, sv->s_proto))+1;
+
+ ((u_short *)dbuf)[0] = sv->s_port;
+ p = dbuf;
+ p += sizeof(u_short);
+ if (sv->s_aliases)
+ for (n = 0; sv->s_aliases[n]; ++n) {
+ strcpy(p, sv->s_aliases[n]);
+ p += strlen(p) + 1;
+ }
+ data.size = p - dbuf;
+
+ if ((r = db->put(db, &key, &data, R_NOOVERWRITE)))
+ if (r < 0)
+ errx(1, "failed to write %s", key.data);
+ else
+ warnx("will not overwrite %s", key.data);
+ for (n = 0; sv->s_aliases[n]; ++n) {
+ if (strlen(sv->s_aliases[n]) + sizeof "/"
+ + strlen(sv->s_proto) > sizeof kbuf)
+ continue;
+ key.size = SPRINTF((kbuf, "%s/%s",
+ sv->s_aliases[n], sv->s_proto))+1;
+ if ((r = db->put(db, &key, &data, R_NOOVERWRITE)))
+ if (r < 0)
+ errx(1, "failed to write %s",
+ key.data);
+ else
+ warnx("will not overwrite %s",
+ key.data);
+ }
+
+ ports = (u_short *)kbuf;
+ ports[0] = 0;
+ ports[1] = sv->s_port;
+ strcpy((char *)(ports+2), sv->s_proto);
+ key.size = sizeof(u_short) * 2 + strlen((char *)(ports+2)) + 1;
+
+ if (strlen(sv->s_name) + sizeof "/" + strlen(sv->s_proto)
+ > sizeof dbuf)
+ continue;
+ p = dbuf;
+ p += SPRINTF((p, "%s/%s", sv->s_name, sv->s_proto)) + 1;
+ if (sv->s_aliases != NULL)
+ for (n = 0; sv->s_aliases[n] != NULL; n++)
+ if ((p + strlen(sv->s_aliases[n]) + 1) - dbuf
+ <= sizeof dbuf) {
+ strcpy(p, sv->s_aliases[n]);
+ p += strlen(p) + 1;
+ }
+ data.size = p - dbuf;
+
+ if ((r = db->put(db, &key, &data, R_NOOVERWRITE)))
+ if (r < 0)
+ errx(1, "failed to write %d/%s",
+ ntohs(sv->s_port), sv->s_proto);
+ else
+ warnx("will not overwrite %d/%s",
+ ntohs(sv->s_port), sv->s_proto);
+ }
+ db->close(db);
+ if (rename(tmpdatabase, database))
+ err(1, "rename %s -> %s", tmpdatabase, database);
+ exit(0);
+}
+
+#endif
diff -r d76076b72b03 -r 9f29bde73a82 dist/bind/bin/named/db_defs.h
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/dist/bind/bin/named/db_defs.h Sat Dec 04 16:52:57 1999 +0000
@@ -0,0 +1,311 @@
+/* $NetBSD: db_defs.h,v 1.1.1.1.2.2 1999/12/04 16:53:06 he Exp $ */
+
+/*
+ * from db.h 4.16 (Berkeley) 6/1/90
+ * Id: db_defs.h,v 8.36 1999/08/26 18:42:32 vixie Exp
+ */
+
+/*
+ * Copyright (c) 1985, 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
+ * 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.
+ */
+
+/*
+ * Portions Copyright (c) 1996-1999 by Internet Software Consortium.
+ *
+ * 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.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM DISCLAIMS
+ * ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL INTERNET SOFTWARE
+ * CONSORTIUM 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.
+ */
+
+/*
+ * Global definitions for data base routines.
+ */
+
+ /* max length of data in RR data field */
+#define MAXDATA (2*MAXDNAME + 5*INT32SZ)
+
+ /* max length of data in a TXT RR segment */
+#define MAXCHARSTRING 255
+
+#define DB_ROOT_TIMBUF 3600
+#define TIMBUF 300
+
Home |
Main Index |
Thread Index |
Old Index