Date: Sun, 23 Nov 2008 05:39:50 +0000 (UTC) From: Kip Macy <kmacy@FreeBSD.org> To: src-committers@freebsd.org, svn-src-projects@freebsd.org Subject: svn commit: r185198 - in projects/releng_7_xen: . bin/chio contrib contrib/bind9 contrib/bind9/bin/dig contrib/bind9/bin/named contrib/bind9/bin/rndc contrib/bind9/doc/arm contrib/bind9/lib/bind co... Message-ID: <200811230539.mAN5doPk041734@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: kmacy Date: Sun Nov 23 05:39:49 2008 New Revision: 185198 URL: http://svn.freebsd.org/changeset/base/185198 Log: IF_RELENG_7 184527:185197 Added: projects/releng_7_xen/contrib/traceroute/as.c projects/releng_7_xen/contrib/traceroute/as.h projects/releng_7_xen/lib/libc/string/ffsll.c projects/releng_7_xen/lib/libc/string/flsll.c projects/releng_7_xen/share/man/man4/igb.4 Modified: projects/releng_7_xen/Makefile.inc1 (contents, props changed) projects/releng_7_xen/bin/chio/ (props changed) projects/releng_7_xen/bin/chio/chio.c projects/releng_7_xen/contrib/ (props changed) projects/releng_7_xen/contrib/bind9/ (props changed) projects/releng_7_xen/contrib/bind9/CHANGES projects/releng_7_xen/contrib/bind9/COPYRIGHT projects/releng_7_xen/contrib/bind9/bin/dig/dighost.c projects/releng_7_xen/contrib/bind9/bin/named/client.c projects/releng_7_xen/contrib/bind9/bin/named/config.c projects/releng_7_xen/contrib/bind9/bin/named/controlconf.c projects/releng_7_xen/contrib/bind9/bin/named/interfacemgr.c projects/releng_7_xen/contrib/bind9/bin/named/lwresd.c projects/releng_7_xen/contrib/bind9/bin/named/named.conf.docbook projects/releng_7_xen/contrib/bind9/bin/named/server.c projects/releng_7_xen/contrib/bind9/bin/rndc/rndc.c projects/releng_7_xen/contrib/bind9/configure.in projects/releng_7_xen/contrib/bind9/doc/arm/Bv9ARM-book.xml projects/releng_7_xen/contrib/bind9/lib/bind/configure.in projects/releng_7_xen/contrib/bind9/lib/bind9/check.c projects/releng_7_xen/contrib/bind9/lib/dns/api projects/releng_7_xen/contrib/bind9/lib/dns/dispatch.c projects/releng_7_xen/contrib/bind9/lib/dns/include/dns/dispatch.h projects/releng_7_xen/contrib/bind9/lib/dns/request.c projects/releng_7_xen/contrib/bind9/lib/dns/resolver.c projects/releng_7_xen/contrib/bind9/lib/dns/xfrin.c projects/releng_7_xen/contrib/bind9/lib/isc/api projects/releng_7_xen/contrib/bind9/lib/isc/include/isc/resource.h projects/releng_7_xen/contrib/bind9/lib/isc/include/isc/socket.h projects/releng_7_xen/contrib/bind9/lib/isc/include/isc/timer.h projects/releng_7_xen/contrib/bind9/lib/isc/timer.c projects/releng_7_xen/contrib/bind9/lib/isc/unix/app.c projects/releng_7_xen/contrib/bind9/lib/isc/unix/resource.c projects/releng_7_xen/contrib/bind9/lib/isc/unix/socket.c projects/releng_7_xen/contrib/bind9/lib/isc/unix/socket_p.h projects/releng_7_xen/contrib/bind9/lib/isccfg/api projects/releng_7_xen/contrib/bind9/lib/isccfg/namedconf.c projects/releng_7_xen/contrib/bind9/version projects/releng_7_xen/contrib/traceroute/ (props changed) projects/releng_7_xen/contrib/traceroute/traceroute.8 projects/releng_7_xen/contrib/traceroute/traceroute.c projects/releng_7_xen/include/ (props changed) projects/releng_7_xen/include/strings.h projects/releng_7_xen/include/time.h projects/releng_7_xen/include/unistd.h projects/releng_7_xen/lib/bind/ (props changed) projects/releng_7_xen/lib/bind/config.h projects/releng_7_xen/lib/libc/ (props changed) projects/releng_7_xen/lib/libc/amd64/SYS.h projects/releng_7_xen/lib/libc/amd64/gen/_setjmp.S projects/releng_7_xen/lib/libc/amd64/gen/fabs.S projects/releng_7_xen/lib/libc/amd64/gen/modf.S projects/releng_7_xen/lib/libc/amd64/gen/rfork_thread.S projects/releng_7_xen/lib/libc/amd64/gen/setjmp.S projects/releng_7_xen/lib/libc/amd64/gen/sigsetjmp.S projects/releng_7_xen/lib/libc/amd64/stdlib/div.S projects/releng_7_xen/lib/libc/amd64/stdlib/ldiv.S projects/releng_7_xen/lib/libc/amd64/stdlib/lldiv.S projects/releng_7_xen/lib/libc/amd64/string/bcmp.S projects/releng_7_xen/lib/libc/amd64/string/bcopy.S projects/releng_7_xen/lib/libc/amd64/string/bzero.S projects/releng_7_xen/lib/libc/amd64/string/memcmp.S projects/releng_7_xen/lib/libc/amd64/string/memset.S projects/releng_7_xen/lib/libc/amd64/string/strcat.S projects/releng_7_xen/lib/libc/amd64/string/strcmp.S projects/releng_7_xen/lib/libc/amd64/string/strcpy.S projects/releng_7_xen/lib/libc/amd64/sys/brk.S projects/releng_7_xen/lib/libc/amd64/sys/exect.S projects/releng_7_xen/lib/libc/amd64/sys/getcontext.S projects/releng_7_xen/lib/libc/amd64/sys/pipe.S projects/releng_7_xen/lib/libc/amd64/sys/ptrace.S projects/releng_7_xen/lib/libc/amd64/sys/reboot.S projects/releng_7_xen/lib/libc/amd64/sys/sbrk.S projects/releng_7_xen/lib/libc/amd64/sys/setlogin.S projects/releng_7_xen/lib/libc/amd64/sys/vfork.S projects/releng_7_xen/lib/libc/i386/SYS.h projects/releng_7_xen/lib/libc/i386/gen/_ctx_start.S projects/releng_7_xen/lib/libc/i386/gen/_setjmp.S projects/releng_7_xen/lib/libc/i386/gen/fabs.S projects/releng_7_xen/lib/libc/i386/gen/modf.S projects/releng_7_xen/lib/libc/i386/gen/rfork_thread.S projects/releng_7_xen/lib/libc/i386/gen/setjmp.S projects/releng_7_xen/lib/libc/i386/gen/sigsetjmp.S projects/releng_7_xen/lib/libc/i386/stdlib/abs.S projects/releng_7_xen/lib/libc/i386/stdlib/div.S projects/releng_7_xen/lib/libc/i386/stdlib/labs.S projects/releng_7_xen/lib/libc/i386/stdlib/ldiv.S projects/releng_7_xen/lib/libc/i386/string/bcmp.S projects/releng_7_xen/lib/libc/i386/string/bcopy.S projects/releng_7_xen/lib/libc/i386/string/bzero.S projects/releng_7_xen/lib/libc/i386/string/ffs.S projects/releng_7_xen/lib/libc/i386/string/index.S projects/releng_7_xen/lib/libc/i386/string/memchr.S projects/releng_7_xen/lib/libc/i386/string/memcmp.S projects/releng_7_xen/lib/libc/i386/string/memset.S projects/releng_7_xen/lib/libc/i386/string/rindex.S projects/releng_7_xen/lib/libc/i386/string/strcat.S projects/releng_7_xen/lib/libc/i386/string/strchr.S projects/releng_7_xen/lib/libc/i386/string/strcmp.S projects/releng_7_xen/lib/libc/i386/string/strcpy.S projects/releng_7_xen/lib/libc/i386/string/strlen.S projects/releng_7_xen/lib/libc/i386/string/strncmp.S projects/releng_7_xen/lib/libc/i386/string/strrchr.S projects/releng_7_xen/lib/libc/i386/string/swab.S projects/releng_7_xen/lib/libc/i386/string/wcschr.S projects/releng_7_xen/lib/libc/i386/string/wcscmp.S projects/releng_7_xen/lib/libc/i386/string/wcslen.S projects/releng_7_xen/lib/libc/i386/string/wmemchr.S projects/releng_7_xen/lib/libc/i386/sys/Ovfork.S projects/releng_7_xen/lib/libc/i386/sys/brk.S projects/releng_7_xen/lib/libc/i386/sys/exect.S projects/releng_7_xen/lib/libc/i386/sys/getcontext.S projects/releng_7_xen/lib/libc/i386/sys/pipe.S projects/releng_7_xen/lib/libc/i386/sys/ptrace.S projects/releng_7_xen/lib/libc/i386/sys/reboot.S projects/releng_7_xen/lib/libc/i386/sys/sbrk.S projects/releng_7_xen/lib/libc/i386/sys/setlogin.S projects/releng_7_xen/lib/libc/i386/sys/syscall.S projects/releng_7_xen/lib/libc/stdlib/malloc.3 projects/releng_7_xen/lib/libc/stdlib/malloc.c projects/releng_7_xen/lib/libc/string/Makefile.inc projects/releng_7_xen/lib/libc/string/Symbol.map projects/releng_7_xen/lib/libc/string/ffs.3 projects/releng_7_xen/lib/libcam/ (props changed) projects/releng_7_xen/lib/libcam/camlib.c projects/releng_7_xen/libexec/rtld-elf/ (props changed) projects/releng_7_xen/libexec/rtld-elf/rtld.c projects/releng_7_xen/release/Makefile projects/releng_7_xen/release/doc/en_US.ISO8859-1/hardware/article.sgml projects/releng_7_xen/release/doc/en_US.ISO8859-1/relnotes/article.sgml projects/releng_7_xen/release/doc/zh_CN.GB2312/hardware/article.sgml projects/releng_7_xen/release/doc/zh_CN.GB2312/relnotes/article.sgml projects/releng_7_xen/sbin/geom/ (props changed) projects/releng_7_xen/sbin/geom/class/part/ (props changed) projects/releng_7_xen/sbin/geom/class/part/Makefile projects/releng_7_xen/sbin/geom/class/part/geom_part.c projects/releng_7_xen/sbin/geom/class/part/gpart.8 projects/releng_7_xen/sbin/geom/misc/ (props changed) projects/releng_7_xen/share/man/man4/ (props changed) projects/releng_7_xen/share/man/man4/Makefile projects/releng_7_xen/share/man/man4/em.4 projects/releng_7_xen/sys/ (props changed) projects/releng_7_xen/sys/compat/freebsd32/freebsd32_misc.c projects/releng_7_xen/sys/compat/linux/linux_emul.c projects/releng_7_xen/sys/dev/aac/aac_pci.c projects/releng_7_xen/sys/dev/bce/if_bce.c projects/releng_7_xen/sys/dev/bce/if_bcefw.h projects/releng_7_xen/sys/dev/bce/if_bcereg.h projects/releng_7_xen/sys/dev/esp/esp_sbus.c projects/releng_7_xen/sys/dev/esp/ncr53c9x.c projects/releng_7_xen/sys/dev/esp/ncr53c9xreg.h projects/releng_7_xen/sys/dev/esp/ncr53c9xvar.h projects/releng_7_xen/sys/dev/et/if_et.c projects/releng_7_xen/sys/dev/le/if_le_ledma.c projects/releng_7_xen/sys/dev/mfi/mfi.c projects/releng_7_xen/sys/dev/mfi/mfi_ioctl.h projects/releng_7_xen/sys/dev/mfi/mfi_pci.c projects/releng_7_xen/sys/dev/mfi/mfireg.h projects/releng_7_xen/sys/dev/mfi/mfivar.h projects/releng_7_xen/sys/dev/mii/atphy.c projects/releng_7_xen/sys/dev/pccbb/pccbb_pci.c projects/releng_7_xen/sys/geom/part/g_part_gpt.c projects/releng_7_xen/sys/kern/kern_proc.c projects/releng_7_xen/sys/kern/kern_time.c projects/releng_7_xen/sys/kern/subr_smp.c projects/releng_7_xen/sys/kern/vfs_subr.c projects/releng_7_xen/sys/kern/vfs_vnops.c projects/releng_7_xen/sys/modules/cxgb/ (props changed) projects/releng_7_xen/sys/net/if_atmsubr.c projects/releng_7_xen/sys/net/if_fwsubr.c projects/releng_7_xen/sys/net/if_iso88025subr.c projects/releng_7_xen/sys/net/route.c projects/releng_7_xen/sys/net/route.h projects/releng_7_xen/sys/net80211/ieee80211_freebsd.h projects/releng_7_xen/sys/netinet/if_ether.c projects/releng_7_xen/sys/netinet/in_rmx.c projects/releng_7_xen/sys/netinet/in_var.h projects/releng_7_xen/sys/netinet/tcp_input.c projects/releng_7_xen/sys/netinet/tcp_sack.c projects/releng_7_xen/sys/netinet/tcp_syncache.c projects/releng_7_xen/sys/sparc64/sbus/dma_sbus.c projects/releng_7_xen/sys/sparc64/sbus/lsi64854.c projects/releng_7_xen/sys/sparc64/sbus/lsi64854var.h projects/releng_7_xen/sys/sparc64/sparc64/db_trace.c projects/releng_7_xen/sys/sparc64/sparc64/stack_machdep.c projects/releng_7_xen/sys/sun4v/sun4v/db_trace.c projects/releng_7_xen/sys/sun4v/sun4v/stack_machdep.c projects/releng_7_xen/sys/sys/time.h projects/releng_7_xen/sys/sys/user.h projects/releng_7_xen/sys/ufs/ffs/ffs_snapshot.c projects/releng_7_xen/sys/ufs/ffs/ffs_vnops.c projects/releng_7_xen/sys/ufs/ufs/ufs_vnops.c projects/releng_7_xen/usr.bin/sed/ (props changed) projects/releng_7_xen/usr.bin/sed/compile.c projects/releng_7_xen/usr.sbin/ (props changed) projects/releng_7_xen/usr.sbin/portsnap/ (props changed) projects/releng_7_xen/usr.sbin/portsnap/portsnap/portsnap.8 projects/releng_7_xen/usr.sbin/sysinstall/dist.c projects/releng_7_xen/usr.sbin/traceroute/ (props changed) projects/releng_7_xen/usr.sbin/traceroute/Makefile Modified: projects/releng_7_xen/Makefile.inc1 ============================================================================== --- projects/releng_7_xen/Makefile.inc1 Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/Makefile.inc1 Sun Nov 23 05:39:49 2008 (r185198) @@ -487,6 +487,9 @@ distribute32 install32: .if ${MK_CRYPT} != "no" cd ${.CURDIR}/secure/lib; ${LIB32IMAKE} ${.TARGET:S/32$//} .endif +.if ${MK_KERBEROS} != "no" + cd ${.CURDIR}/kerberos5/lib; ${LIB32IMAKE} ${.TARGET:S/32$//} +.endif cd ${.CURDIR}/libexec/rtld-elf; \ PROG=ld-elf32.so.1 ${LIB32IMAKE} ${.TARGET:S/32$//} cd ${.CURDIR}/usr.bin/ldd; PROG=ldd32 ${LIB32IMAKE} ${.TARGET:S/32$//} Modified: projects/releng_7_xen/bin/chio/chio.c ============================================================================== --- projects/releng_7_xen/bin/chio/chio.c Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/bin/chio/chio.c Sun Nov 23 05:39:49 2008 (r185198) @@ -69,7 +69,7 @@ static const char *bits_to_string(ces_st static void find_element(char *, uint16_t *, uint16_t *); static struct changer_element_status *get_element_status - (unsigned int, unsigned int); + (unsigned int, unsigned int, int); static int do_move(const char *, int, char **); static int do_exchange(const char *, int, char **); @@ -969,7 +969,8 @@ do_return(const char *cname, int argc, c ++argv; --argc; /* Get the status */ - ces = get_element_status((unsigned int)type, (unsigned int)element); + ces = get_element_status((unsigned int)type, (unsigned int)element, + CHET_VT == type); if (NULL == ces) errx(1, "%s: null element status pointer", cname); @@ -1004,7 +1005,7 @@ usage: * should free() it when done. */ static struct changer_element_status * -get_element_status(unsigned int type, unsigned int element) +get_element_status(unsigned int type, unsigned int element, int use_voltags) { struct changer_element_status_request cesr; struct changer_element_status *ces; @@ -1020,7 +1021,8 @@ get_element_status(unsigned int type, un cesr.cesr_element_type = (uint16_t)type; cesr.cesr_element_base = (uint16_t)element; cesr.cesr_element_count = 1; /* Only this one element */ - cesr.cesr_flags |= CESR_VOLTAGS; /* Grab voltags as well */ + if (use_voltags) + cesr.cesr_flags |= CESR_VOLTAGS; /* Grab voltags as well */ cesr.cesr_element_status = ces; if (ioctl(changer_fd, CHIOGSTATUS, (char *)&cesr) == -1) { Modified: projects/releng_7_xen/contrib/bind9/CHANGES ============================================================================== --- projects/releng_7_xen/contrib/bind9/CHANGES Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/CHANGES Sun Nov 23 05:39:49 2008 (r185198) @@ -1,3 +1,47 @@ + --- 9.4.2-P2 released --- + +2406. [bug] Some operating systems have FD_SETSIZE set to a + low value by default, which can cause resource + exhaustion when many simultaneous connections are + open. Linux in particular makes it difficult to + increase this value. To use more sockets with + select(), set ISC_SOCKET_FDSETSIZE. Example: + STD_CDEFINES="-DISC_SOCKET_FDSETSIZE=4096" ./configure + (This should not be necessary in most cases, and + never for an authoritative-only server.) [RT #18328] + +2404. [port] hpux: files unlimited support. + +2403. [bug] TSIG context leak. [RT #18341] + +2402. [port] Support Solaris 2.11 and over. [RT #18362] + +2401. [bug] Expect to get E[MN]FILE errno internal_accept() + (from accept() or fcntl() system calls). [RT #18358] + +2399. [bug] Abort timeout queries to reduce the number of open + UDP sockets. [RT #18367] + +2398. [bug] Improve file descriptor management. New, + temporary, named.conf option reserved-sockets, + default 512. [RT #18344] + +2396. [bug] Don't set SO_REUSEADDR for randomized ports. + [RT #18336] + +2395. [port] Avoid warning and no effect from "files unlimited" + on Linux when running as root. [RT #18335] + +2394. [bug] Default configuration options set the limit for + open files to 'unlimited' as described in the + documentation. [RT #18331] + +2392. [bug] remove 'grep -q' from acl test script, some platforms + don't support it. [RT #18253] + +2322. [port] MacOS: work around the limitation of setrlimit() + for RLIMIT_NOFILE. [RT #17526] + --- 9.4.2-P1 released --- 2375. [security] Fully randomize UDP query ports to improve @@ -33,7 +77,7 @@ [RT #17113] 2249. [bug] Only set Authentic Data bit if client requested - DNSSEC, per RFC 3655 [RT #17175] + DNSSEC, per RFC 3655 [RT #17175] 2248. [cleanup] Fix several errors reported by Coverity. [RT #17160] Modified: projects/releng_7_xen/contrib/bind9/COPYRIGHT ============================================================================== --- projects/releng_7_xen/contrib/bind9/COPYRIGHT Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/COPYRIGHT Sun Nov 23 05:39:49 2008 (r185198) @@ -1,4 +1,4 @@ -Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") +Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") Copyright (C) 1996-2003 Internet Software Consortium. Permission to use, copy, modify, and/or distribute this software for any @@ -13,7 +13,7 @@ LOSS OF USE, DATA OR PROFITS, WHETHER IN OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. -$Id: COPYRIGHT,v 1.9.18.4 2007/08/28 07:19:54 tbox Exp $ +$Id: COPYRIGHT,v 1.9.18.4.10.1 2008/07/23 07:28:54 tbox Exp $ Portions Copyright (C) 1996-2001 Nominum, Inc. Modified: projects/releng_7_xen/contrib/bind9/bin/dig/dighost.c ============================================================================== --- projects/releng_7_xen/contrib/bind9/bin/dig/dighost.c Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/bin/dig/dighost.c Sun Nov 23 05:39:49 2008 (r185198) @@ -1,5 +1,5 @@ /* - * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 2000-2003 Internet Software Consortium. * * Permission to use, copy, modify, and/or distribute this software for any @@ -15,7 +15,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: dighost.c,v 1.259.18.43 2007/08/28 07:19:55 tbox Exp $ */ +/* $Id: dighost.c,v 1.259.18.43.10.3 2008/07/23 23:16:43 marka Exp $ */ /*! \file * \note @@ -2217,14 +2217,15 @@ send_tcp_connect(dig_query_t *query) { sockcount++; debug("sockcount=%d", sockcount); if (specified_source) - result = isc_socket_bind(query->sock, &bind_address); + result = isc_socket_bind(query->sock, &bind_address, + ISC_SOCKET_REUSEADDRESS); else { if ((isc_sockaddr_pf(&query->sockaddr) == AF_INET) && have_ipv4) isc_sockaddr_any(&bind_any); else isc_sockaddr_any6(&bind_any); - result = isc_socket_bind(query->sock, &bind_any); + result = isc_socket_bind(query->sock, &bind_any, 0); } check_result(result, "isc_socket_bind"); bringup_timer(query, TCP_TIMEOUT); @@ -2271,11 +2272,12 @@ send_udp(dig_query_t *query) { sockcount++; debug("sockcount=%d", sockcount); if (specified_source) { - result = isc_socket_bind(query->sock, &bind_address); + result = isc_socket_bind(query->sock, &bind_address, + ISC_SOCKET_REUSEADDRESS); } else { isc_sockaddr_anyofpf(&bind_any, isc_sockaddr_pf(&query->sockaddr)); - result = isc_socket_bind(query->sock, &bind_any); + result = isc_socket_bind(query->sock, &bind_any, 0); } check_result(result, "isc_socket_bind"); Modified: projects/releng_7_xen/contrib/bind9/bin/named/client.c ============================================================================== --- projects/releng_7_xen/contrib/bind9/bin/named/client.c Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/bin/named/client.c Sun Nov 23 05:39:49 2008 (r185198) @@ -1,5 +1,5 @@ /* - * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1999-2003 Internet Software Consortium. * * Permission to use, copy, modify, and/or distribute this software for any @@ -15,7 +15,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: client.c,v 1.219.18.28.10.1 2008/05/22 21:28:04 each Exp $ */ +/* $Id: client.c,v 1.219.18.28.10.2 2008/07/23 07:28:54 tbox Exp $ */ #include <config.h> Modified: projects/releng_7_xen/contrib/bind9/bin/named/config.c ============================================================================== --- projects/releng_7_xen/contrib/bind9/bin/named/config.c Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/bin/named/config.c Sun Nov 23 05:39:49 2008 (r185198) @@ -1,5 +1,5 @@ /* - * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 2001-2003 Internet Software Consortium. * * Permission to use, copy, modify, and/or distribute this software for any @@ -15,7 +15,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: config.c,v 1.47.18.32 2007/09/13 05:04:01 each Exp $ */ +/* $Id: config.c,v 1.47.18.32.10.3 2008/07/23 23:48:17 tbox Exp $ */ /*! \file */ @@ -52,7 +52,7 @@ options {\n\ #ifndef WIN32 " coresize default;\n\ datasize default;\n\ - files default;\n\ + files unlimited;\n\ stacksize default;\n" #endif " deallocate-on-exit true;\n\ @@ -99,6 +99,7 @@ options {\n\ use-ixfr true;\n\ edns-udp-size 4096;\n\ max-udp-size 4096;\n\ + reserved-sockets 512;\n\ \n\ /* view */\n\ allow-notify {none;};\n\ Modified: projects/releng_7_xen/contrib/bind9/bin/named/controlconf.c ============================================================================== --- projects/releng_7_xen/contrib/bind9/bin/named/controlconf.c Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/bin/named/controlconf.c Sun Nov 23 05:39:49 2008 (r185198) @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004-2006 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004-2006, 2008 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 2001-2003 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or 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. * @@ -15,7 +15,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: controlconf.c,v 1.40.18.10 2006/12/07 04:53:02 marka Exp $ */ +/* $Id: controlconf.c,v 1.40.18.10.40.3 2008/07/23 23:16:43 marka Exp $ */ /*! \file */ @@ -1151,8 +1151,8 @@ add_listener(ns_controls_t *cp, controll type, &listener->sock); if (result == ISC_R_SUCCESS) - result = isc_socket_bind(listener->sock, - &listener->address); + result = isc_socket_bind(listener->sock, &listener->address, + ISC_SOCKET_REUSEADDRESS); if (result == ISC_R_SUCCESS && type == isc_sockettype_unix) { listener->perm = cfg_obj_asuint32(cfg_tuple_get(control, Modified: projects/releng_7_xen/contrib/bind9/bin/named/interfacemgr.c ============================================================================== --- projects/releng_7_xen/contrib/bind9/bin/named/interfacemgr.c Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/bin/named/interfacemgr.c Sun Nov 23 05:39:49 2008 (r185198) @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004-2006 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004-2006, 2008 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1999-2002 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or 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. * @@ -15,7 +15,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: interfacemgr.c,v 1.76.18.8 2006/07/20 01:10:30 marka Exp $ */ +/* $Id: interfacemgr.c,v 1.76.18.8.44.3 2008/07/23 23:16:43 marka Exp $ */ /*! \file */ @@ -307,7 +307,8 @@ ns_interface_accepttcp(ns_interface_t *i #ifndef ISC_ALLOW_MAPPED isc_socket_ipv6only(ifp->tcpsocket, ISC_TRUE); #endif - result = isc_socket_bind(ifp->tcpsocket, &ifp->addr); + result = isc_socket_bind(ifp->tcpsocket, &ifp->addr, + ISC_SOCKET_REUSEADDRESS); if (result != ISC_R_SUCCESS) { isc_log_write(IFMGR_COMMON_LOGARGS, ISC_LOG_ERROR, "binding TCP socket: %s", Modified: projects/releng_7_xen/contrib/bind9/bin/named/lwresd.c ============================================================================== --- projects/releng_7_xen/contrib/bind9/bin/named/lwresd.c Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/bin/named/lwresd.c Sun Nov 23 05:39:49 2008 (r185198) @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004-2006 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004-2006, 2008 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 2000-2003 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or 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. * @@ -15,7 +15,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: lwresd.c,v 1.46.18.7 2006/03/02 00:37:21 marka Exp $ */ +/* $Id: lwresd.c,v 1.46.18.7.52.3 2008/07/23 23:16:43 marka Exp $ */ /*! \file * \brief @@ -576,7 +576,8 @@ listener_bind(ns_lwreslistener_t *listen return (result); } - result = isc_socket_bind(sock, &listener->address); + result = isc_socket_bind(sock, &listener->address, + ISC_SOCKET_REUSEADDRESS); if (result != ISC_R_SUCCESS) { char socktext[ISC_SOCKADDR_FORMATSIZE]; isc_sockaddr_format(&listener->address, socktext, Modified: projects/releng_7_xen/contrib/bind9/bin/named/named.conf.docbook ============================================================================== --- projects/releng_7_xen/contrib/bind9/bin/named/named.conf.docbook Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/bin/named/named.conf.docbook Sun Nov 23 05:39:49 2008 (r185198) @@ -2,7 +2,7 @@ "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd" [<!ENTITY mdash "—">]> <!-- - - Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + - Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") - - Permission to use, copy, modify, and/or distribute this software for any - purpose with or without fee is hereby granted, provided that the above @@ -17,7 +17,7 @@ - PERFORMANCE OF THIS SOFTWARE. --> -<!-- $Id: named.conf.docbook,v 1.1.2.29 2007/08/28 07:20:01 tbox Exp $ --> +<!-- $Id: named.conf.docbook,v 1.1.2.29.12.2 2008/07/23 23:48:17 tbox Exp $ --> <refentry> <refentryinfo> <date>Aug 13, 2004</date> @@ -40,6 +40,7 @@ <year>2005</year> <year>2006</year> <year>2007</year> + <year>2008</year> <holder>Internet Systems Consortium, Inc. ("ISC")</holder> </copyright> </docinfo> @@ -201,6 +202,7 @@ options { port <replaceable>integer</replaceable>; querylog <replaceable>boolean</replaceable>; recursing-file <replaceable>quoted_string</replaceable>; + reserved-sockets <replaceable>integer</replaceable>; random-device <replaceable>quoted_string</replaceable>; recursive-clients <replaceable>integer</replaceable>; serial-query-rate <replaceable>integer</replaceable>; Modified: projects/releng_7_xen/contrib/bind9/bin/named/server.c ============================================================================== --- projects/releng_7_xen/contrib/bind9/bin/named/server.c Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/bin/named/server.c Sun Nov 23 05:39:49 2008 (r185198) @@ -1,5 +1,5 @@ /* - * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1999-2003 Internet Software Consortium. * * Permission to use, copy, modify, and/or distribute this software for any @@ -15,7 +15,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: server.c,v 1.419.18.57.10.1 2008/05/22 21:28:04 each Exp $ */ +/* $Id: server.c,v 1.419.18.57.10.3 2008/07/23 12:04:32 marka Exp $ */ /*! \file */ @@ -2696,27 +2696,29 @@ static isc_result_t load_configuration(const char *filename, ns_server_t *server, isc_boolean_t first_time) { - isc_result_t result; - isc_interval_t interval; - cfg_parser_t *parser = NULL; + cfg_aclconfctx_t aclconfctx; cfg_obj_t *config; - const cfg_obj_t *options; - const cfg_obj_t *views; + cfg_parser_t *parser = NULL; + const cfg_listelt_t *element; + const cfg_obj_t *builtin_views; + const cfg_obj_t *maps[3]; const cfg_obj_t *obj; + const cfg_obj_t *options; const cfg_obj_t *v4ports, *v6ports; - const cfg_obj_t *maps[3]; - const cfg_obj_t *builtin_views; - const cfg_listelt_t *element; + const cfg_obj_t *views; dns_view_t *view = NULL; dns_view_t *view_next; - dns_viewlist_t viewlist; dns_viewlist_t tmpviewlist; - cfg_aclconfctx_t aclconfctx; - isc_uint32_t interface_interval; - isc_uint32_t heartbeat_interval; - isc_uint32_t udpsize; + dns_viewlist_t viewlist; in_port_t listen_port; int i; + isc_interval_t interval; + isc_resourcevalue_t files; + isc_result_t result; + isc_uint32_t heartbeat_interval; + isc_uint32_t interface_interval; + isc_uint32_t reserved; + isc_uint32_t udpsize; cfg_aclconfctx_init(&aclconfctx); ISC_LIST_INIT(viewlist); @@ -2797,6 +2799,43 @@ load_configuration(const char *filename, set_limits(maps); /* + * Sanity check on "files" limit. + */ + result = isc_resource_curlimit(isc_resource_openfiles, &files); + if (result == ISC_R_SUCCESS && files < FD_SETSIZE) { + isc_log_write(ns_g_lctx, NS_LOGCATEGORY_GENERAL, + NS_LOGMODULE_SERVER, ISC_LOG_WARNING, + "the 'files' limit (%" ISC_PRINT_QUADFORMAT "u) " + "is less than FD_SETSIZE (%d), increase " + "'files' in named.conf or recompile with a " + "smaller FD_SETSIZE.", files, FD_SETSIZE); + if (files > FD_SETSIZE) + files = FD_SETSIZE; + } else + files = FD_SETSIZE; + + /* + * Set the number of socket reserved for TCP, stdio etc. + */ + obj = NULL; + result = ns_config_get(maps, "reserved-sockets", &obj); + INSIST(result == ISC_R_SUCCESS); + reserved = cfg_obj_asuint32(obj); + if (files < 128U) /* Prevent underflow. */ + reserved = 0; + else if (reserved > files - 128U) /* Mimimum UDP space. */ + reserved = files - 128; + if (reserved < 128U) /* Mimimum TCP/stdio space. */ + reserved = 128; + if (reserved + 128U > files) { + isc_log_write(ns_g_lctx, NS_LOGCATEGORY_GENERAL, + NS_LOGMODULE_SERVER, ISC_LOG_WARNING, + "less than 128 UDP sockets available after " + "applying 'reserved-sockets' and 'files'"); + } + isc__socketmgr_setreserved(ns_g_socketmgr, reserved); + + /* * Configure various server options. */ configure_server_quota(maps, "transfers-out", &server->xfroutquota); Modified: projects/releng_7_xen/contrib/bind9/bin/rndc/rndc.c ============================================================================== --- projects/releng_7_xen/contrib/bind9/bin/rndc/rndc.c Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/bin/rndc/rndc.c Sun Nov 23 05:39:49 2008 (r185198) @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004-2006 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004-2006, 2008 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 2000-2003 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or 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. * @@ -15,7 +15,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: rndc.c,v 1.96.18.17 2006/08/04 03:03:41 marka Exp $ */ +/* $Id: rndc.c,v 1.96.18.17.42.3 2008/07/23 23:16:43 marka Exp $ */ /*! \file */ @@ -400,10 +400,10 @@ rndc_startconnect(isc_sockaddr_t *addr, DO("create socket", isc_socket_create(socketmgr, pf, type, &sock)); switch (isc_sockaddr_pf(addr)) { case AF_INET: - DO("bind socket", isc_socket_bind(sock, &local4)); + DO("bind socket", isc_socket_bind(sock, &local4, 0)); break; case AF_INET6: - DO("bind socket", isc_socket_bind(sock, &local6)); + DO("bind socket", isc_socket_bind(sock, &local6, 0)); break; default: break; Modified: projects/releng_7_xen/contrib/bind9/configure.in ============================================================================== --- projects/releng_7_xen/contrib/bind9/configure.in Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/configure.in Sun Nov 23 05:39:49 2008 (r185198) @@ -1,4 +1,4 @@ -# Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") +# Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") # Copyright (C) 1998-2003 Internet Software Consortium. # # Permission to use, copy, modify, and/or distribute this software for any @@ -18,7 +18,7 @@ AC_DIVERT_PUSH(1)dnl esyscmd([sed "s/^/# /" COPYRIGHT])dnl AC_DIVERT_POP()dnl -AC_REVISION($Revision: 1.355.18.71 $) +AC_REVISION($Revision: 1.355.18.71.8.2 $) AC_INIT(lib/dns/name.c) AC_PREREQ(2.59) @@ -1839,7 +1839,7 @@ case "$host" in [*-solaris2.[89]]) hack_shutup_pthreadonceinit=yes ;; - *-solaris2.10) + *-solaris2.1[0-9]) hack_shutup_pthreadonceinit=yes ;; esac Modified: projects/releng_7_xen/contrib/bind9/doc/arm/Bv9ARM-book.xml ============================================================================== --- projects/releng_7_xen/contrib/bind9/doc/arm/Bv9ARM-book.xml Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/doc/arm/Bv9ARM-book.xml Sun Nov 23 05:39:49 2008 (r185198) @@ -2,7 +2,7 @@ "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd" [<!ENTITY mdash "—">]> <!-- - - Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + - Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") - Copyright (C) 2000-2003 Internet Software Consortium. - - Permission to use, copy, modify, and/or distribute this software for any @@ -18,7 +18,7 @@ - PERFORMANCE OF THIS SOFTWARE. --> -<!-- File: $Id: Bv9ARM-book.xml,v 1.241.18.82.8.1 2008/05/22 21:28:04 each Exp $ --> +<!-- File: $Id: Bv9ARM-book.xml,v 1.241.18.82.8.3 2008/07/23 12:04:32 marka Exp $ --> <book xmlns:xi="http://www.w3.org/2001/XInclude"> <title>BIND 9 Administrator Reference Manual</title> @@ -28,6 +28,7 @@ <year>2005</year> <year>2006</year> <year>2007</year> + <year>2008</year> <holder>Internet Systems Consortium, Inc. ("ISC")</holder> </copyright> <copyright> @@ -4441,6 +4442,7 @@ category notify { null; }; <optional> max-transfer-idle-in <replaceable>number</replaceable>; </optional> <optional> max-transfer-idle-out <replaceable>number</replaceable>; </optional> <optional> tcp-clients <replaceable>number</replaceable>; </optional> + <optional> reserved-sockets <replaceable>number</replaceable>; </optional> <optional> recursive-clients <replaceable>number</replaceable>; </optional> <optional> serial-query-rate <replaceable>number</replaceable>; </optional> <optional> serial-queries <replaceable>number</replaceable>; </optional> @@ -6606,6 +6608,23 @@ query-source-v6 address * port *; </varlistentry> <varlistentry> + <term><command>reserved-sockets</command></term> + <listitem> + <para> + The number of file descriptors reserved for TCP, stdio, + etc. This needs to be big enough to cover the number of + interfaces named listens on, tcp-clients as well as + to provide room for outgoing TCP queries and incoming zone + transfers. The default is <literal>512</literal>. + The minimum value is <literal>128</literal> and the + maximum value is <literal>128</literal> less than + 'files' or FD_SETSIZE (whichever is smaller). This + option may be removed in the future. + </para> + </listitem> + </varlistentry> + + <varlistentry> <term><command>max-cache-size</command></term> <listitem> <para> Modified: projects/releng_7_xen/contrib/bind9/lib/bind/configure.in ============================================================================== --- projects/releng_7_xen/contrib/bind9/lib/bind/configure.in Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/lib/bind/configure.in Sun Nov 23 05:39:49 2008 (r185198) @@ -1,4 +1,4 @@ -# Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") +# Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") # Copyright (C) 2001, 2003 Internet Software Consortium. # # Permission to use, copy, modify, and/or distribute this software for any @@ -13,7 +13,7 @@ # OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR # PERFORMANCE OF THIS SOFTWARE. -AC_REVISION($Revision: 1.90.18.34 $) +AC_REVISION($Revision: 1.90.18.34.10.2 $) AC_INIT(resolv/herror.c) AC_PREREQ(2.13) @@ -2590,7 +2590,7 @@ case "$host" in *-solaris2.9) hack_shutup_in6addr_init_macros=yes ;; - *-solaris2.10) + *-solaris2.1[0-9]) hack_shutup_in6addr_init_macros=yes ;; esac Modified: projects/releng_7_xen/contrib/bind9/lib/bind9/check.c ============================================================================== --- projects/releng_7_xen/contrib/bind9/lib/bind9/check.c Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/lib/bind9/check.c Sun Nov 23 05:39:49 2008 (r185198) @@ -1015,10 +1015,10 @@ check_zoneconf(const cfg_obj_t *zconfig, isc_buffer_add(&b, strlen(zname)); tresult = dns_name_fromtext(dns_fixedname_name(&fixedname), &b, dns_rootname, ISC_TRUE, NULL); - if (tresult != ISC_R_SUCCESS) { + if (result != ISC_R_SUCCESS) { cfg_obj_log(zconfig, logctx, ISC_LOG_ERROR, "zone '%s': is not a valid name", zname); - result = ISC_R_FAILURE; + tresult = ISC_R_FAILURE; } else { char namebuf[DNS_NAME_FORMATSIZE]; Modified: projects/releng_7_xen/contrib/bind9/lib/dns/api ============================================================================== --- projects/releng_7_xen/contrib/bind9/lib/dns/api Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/lib/dns/api Sun Nov 23 05:39:49 2008 (r185198) @@ -1,3 +1,3 @@ LIBINTERFACE = 35 -LIBREVISION = 0 +LIBREVISION = 1 LIBAGE = 0 Modified: projects/releng_7_xen/contrib/bind9/lib/dns/dispatch.c ============================================================================== --- projects/releng_7_xen/contrib/bind9/lib/dns/dispatch.c Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/lib/dns/dispatch.c Sun Nov 23 05:39:49 2008 (r185198) @@ -1,5 +1,5 @@ /* - * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1999-2003 Internet Software Consortium. * * Permission to use, copy, modify, and/or distribute this software for any @@ -15,7 +15,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: dispatch.c,v 1.116.18.19.12.1 2008/05/22 21:28:06 each Exp $ */ +/* $Id: dispatch.c,v 1.116.18.19.12.5 2008/07/23 23:16:43 marka Exp $ */ /*! \file */ @@ -276,7 +276,26 @@ request_log(dns_dispatch_t *disp, dns_di } /* - * ARC4 random number generator obtained from OpenBSD + * ARC4 random number generator derived from OpenBSD. + * Only dispatch_arc4random() and dispatch_arc4uniformrandom() are expected + * to be called from general dispatch routines; the rest of them are subroutines + * for these two. + * + * The original copyright follows: + * Copyright (c) 1996, David Mazieres <dm@uun.org> + * Copyright (c) 2008, Damien Miller <djm@openbsd.org> + * + * 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 THE AUTHOR DISCLAIMS ALL WARRANTIES + * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR 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. */ static void dispatch_arc4init(arc4ctx_t *actx) { @@ -1172,7 +1191,7 @@ destroy_mgr(dns_dispatchmgr_t **mgrp) { static isc_result_t create_socket(isc_socketmgr_t *mgr, isc_sockaddr_t *local, - isc_socket_t **sockp) + unsigned int options, isc_socket_t **sockp) { isc_socket_t *sock; isc_result_t result; @@ -1186,7 +1205,7 @@ create_socket(isc_socketmgr_t *mgr, isc_ #ifndef ISC_ALLOW_MAPPED isc_socket_ipv6only(sock, ISC_TRUE); #endif - result = isc_socket_bind(sock, local); + result = isc_socket_bind(sock, local, options); if (result != ISC_R_SUCCESS) { isc_socket_detach(&sock); return (result); @@ -1917,7 +1936,7 @@ dispatch_createudp(dns_dispatchmgr_t *mg attributes &= ~DNS_DISPATCHATTR_RANDOMPORT; goto getsocket; } - result = create_socket(sockmgr, &localaddr_bound, &sock); + result = create_socket(sockmgr, &localaddr_bound, 0, &sock); if (result == ISC_R_ADDRINUSE) { if (++k == 1024) attributes &= ~DNS_DISPATCHATTR_RANDOMPORT; @@ -1925,7 +1944,8 @@ dispatch_createudp(dns_dispatchmgr_t *mg } localport = prt; } else - result = create_socket(sockmgr, localaddr, &sock); + result = create_socket(sockmgr, localaddr, + ISC_SOCKET_REUSEADDRESS, &sock); if (result != ISC_R_SUCCESS) goto deallocate_dispatch; if ((attributes & DNS_DISPATCHATTR_RANDOMPORT) == 0 && Modified: projects/releng_7_xen/contrib/bind9/lib/dns/include/dns/dispatch.h ============================================================================== --- projects/releng_7_xen/contrib/bind9/lib/dns/include/dns/dispatch.h Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/lib/dns/include/dns/dispatch.h Sun Nov 23 05:39:49 2008 (r185198) @@ -1,5 +1,5 @@ /* - * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004, 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1999-2003 Internet Software Consortium. * * Permission to use, copy, modify, and/or distribute this software for any @@ -15,7 +15,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: dispatch.h,v 1.48.18.5.12.1 2008/05/22 21:28:06 each Exp $ */ +/* $Id: dispatch.h,v 1.48.18.5.12.2 2008/07/23 07:28:56 tbox Exp $ */ #ifndef DNS_DISPATCH_H #define DNS_DISPATCH_H 1 Modified: projects/releng_7_xen/contrib/bind9/lib/dns/request.c ============================================================================== --- projects/releng_7_xen/contrib/bind9/lib/dns/request.c Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/lib/dns/request.c Sun Nov 23 05:39:49 2008 (r185198) @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004-2006 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004-2006, 2008 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 2000-2002 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or 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. * @@ -15,7 +15,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: request.c,v 1.72.18.5 2006/08/21 00:40:53 marka Exp $ */ +/* $Id: request.c,v 1.72.18.5.42.2 2008/07/23 07:28:56 tbox Exp $ */ /*! \file */ @@ -518,11 +518,11 @@ create_tcp_dispatch(dns_requestmgr_t *re if (srcaddr == NULL) { isc_sockaddr_anyofpf(&bind_any, isc_sockaddr_pf(destaddr)); - result = isc_socket_bind(socket, &bind_any); + result = isc_socket_bind(socket, &bind_any, 0); } else { src = *srcaddr; isc_sockaddr_setport(&src, 0); - result = isc_socket_bind(socket, &src); + result = isc_socket_bind(socket, &src, 0); } if (result != ISC_R_SUCCESS) goto cleanup; Modified: projects/releng_7_xen/contrib/bind9/lib/dns/resolver.c ============================================================================== --- projects/releng_7_xen/contrib/bind9/lib/dns/resolver.c Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/lib/dns/resolver.c Sun Nov 23 05:39:49 2008 (r185198) @@ -1,5 +1,5 @@ /* - * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1999-2003 Internet Software Consortium. * * Permission to use, copy, modify, and/or distribute this software for any @@ -15,7 +15,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: resolver.c,v 1.284.18.66.8.1 2008/05/22 21:28:06 each Exp $ */ +/* $Id: resolver.c,v 1.284.18.66.8.4 2008/07/24 05:00:48 jinmei Exp $ */ /*! \file */ @@ -1123,7 +1123,7 @@ fctx_query(fetchctx_t *fctx, dns_adbaddr goto cleanup_query; #ifndef BROKEN_TCP_BIND_BEFORE_CONNECT - result = isc_socket_bind(query->tcpsocket, &addr); + result = isc_socket_bind(query->tcpsocket, &addr, 0); if (result != ISC_R_SUCCESS) goto cleanup_socket; #endif @@ -2689,6 +2689,8 @@ fctx_destroy(fetchctx_t *fctx) { static void fctx_timeout(isc_task_t *task, isc_event_t *event) { fetchctx_t *fctx = event->ev_arg; + isc_timerevent_t *tevent = (isc_timerevent_t *)event; + resquery_t *query; REQUIRE(VALID_FCTX(fctx)); @@ -2704,8 +2706,18 @@ fctx_timeout(isc_task_t *task, isc_event fctx->timeouts++; /* * We could cancel the running queries here, or we could let - * them keep going. Right now we choose the latter... - */ + * them keep going. Since we normally use separate sockets for + * different queries, we adopt the former approach to reduce + * the number of open sockets: cancel the oldest query if it + * expired after the query had started (this is usually the + * case but is not always so, depending on the task schedule + * timing). + */ + query = ISC_LIST_HEAD(fctx->queries); + if (query != NULL && + isc_time_compare(&tevent->due, &query->start) >= 0) { + fctx_cancelquery(&query, NULL, NULL, ISC_TRUE); + } fctx->attributes &= ~FCTX_ATTR_ADDRWAIT; /* * Our timer has triggered. Reestablish the fctx lifetime Modified: projects/releng_7_xen/contrib/bind9/lib/dns/xfrin.c ============================================================================== --- projects/releng_7_xen/contrib/bind9/lib/dns/xfrin.c Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/lib/dns/xfrin.c Sun Nov 23 05:39:49 2008 (r185198) @@ -1,5 +1,5 @@ /* - * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1999-2003 Internet Software Consortium. * * Permission to use, copy, modify, and/or distribute this software for any @@ -15,7 +15,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: xfrin.c,v 1.135.18.16 2007/10/31 01:59:47 marka Exp $ */ +/* $Id: xfrin.c,v 1.135.18.16.10.3 2008/07/23 23:16:43 marka Exp $ */ /*! \file */ @@ -862,7 +862,8 @@ xfrin_start(dns_xfrin_ctx_t *xfr) { isc_sockettype_tcp, &xfr->socket)); #ifndef BROKEN_TCP_BIND_BEFORE_CONNECT - CHECK(isc_socket_bind(xfr->socket, &xfr->sourceaddr)); + CHECK(isc_socket_bind(xfr->socket, &xfr->sourceaddr, + ISC_SOCKET_REUSEADDRESS)); #endif CHECK(isc_socket_connect(xfr->socket, &xfr->masteraddr, xfr->task, xfrin_connect_done, xfr)); Modified: projects/releng_7_xen/contrib/bind9/lib/isc/api ============================================================================== --- projects/releng_7_xen/contrib/bind9/lib/isc/api Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/lib/isc/api Sun Nov 23 05:39:49 2008 (r185198) @@ -1,3 +1,3 @@ -LIBINTERFACE = 32 -LIBREVISION = 5 +LIBINTERFACE = 35 +LIBREVISION = 0 LIBAGE = 0 Modified: projects/releng_7_xen/contrib/bind9/lib/isc/include/isc/resource.h ============================================================================== --- projects/releng_7_xen/contrib/bind9/lib/isc/include/isc/resource.h Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/lib/isc/include/isc/resource.h Sun Nov 23 05:39:49 2008 (r185198) @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004, 2005 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004, 2005, 2008 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 2000, 2001 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or 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. * @@ -15,7 +15,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: resource.h,v 1.5.18.2 2005/04/29 00:17:02 marka Exp $ */ +/* $Id: resource.h,v 1.5.18.2.52.2 2008/07/23 23:48:17 tbox Exp $ */ #ifndef ISC_RESOURCE_H #define ISC_RESOURCE_H 1 @@ -81,6 +81,19 @@ isc_resource_getlimit(isc_resource_t res *\li #ISC_R_NOTIMPLEMENTED 'resource' is not a type known by the OS. */ +isc_result_t +isc_resource_curlimit(isc_resource_t resource, isc_resourcevalue_t *value); +/* + * Get the current limit on a resource. + * + * Requires: + * 'resource' is a valid member of the isc_resource_t enumeration. + * + * Returns: + * ISC_R_SUCCESS Success. + * ISC_R_NOTIMPLEMENTED 'resource' is not a type known by the OS. + */ + ISC_LANG_ENDDECLS #endif /* ISC_RESOURCE_H */ Modified: projects/releng_7_xen/contrib/bind9/lib/isc/include/isc/socket.h ============================================================================== --- projects/releng_7_xen/contrib/bind9/lib/isc/include/isc/socket.h Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/lib/isc/include/isc/socket.h Sun Nov 23 05:39:49 2008 (r185198) @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004-2006 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004-2006, 2008 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1998-2002 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or 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. * @@ -15,7 +15,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: socket.h,v 1.57.18.6 2006/06/07 00:29:45 marka Exp $ */ +/* $Id: socket.h,v 1.57.18.6.46.4 2008/07/23 23:16:43 marka Exp $ */ #ifndef ISC_SOCKET_H #define ISC_SOCKET_H 1 @@ -77,6 +77,12 @@ ISC_LANG_BEGINDECLS */ #define ISC_SOCKET_MAXSCATTERGATHER 8 +/*% + * In isc_socket_bind() set socket option SO_REUSEADDR prior to calling + * bind() if a non zero port is specified (AF_INET and AF_INET6). + */ +#define ISC_SOCKET_REUSEADDRESS 0x01U + /*** *** Types ***/ @@ -312,7 +318,8 @@ isc_socket_detach(isc_socket_t **socketp */ isc_result_t -isc_socket_bind(isc_socket_t *sock, isc_sockaddr_t *addressp); +isc_socket_bind(isc_socket_t *sock, isc_sockaddr_t *addressp, + unsigned int options); /*%< * Bind 'socket' to '*addressp'. * @@ -747,6 +754,12 @@ isc_socket_permunix(isc_sockaddr_t *sock * \li #ISC_R_FAILURE */ +void +isc__socketmgr_setreserved(isc_socketmgr_t *mgr, isc_uint32_t); +/*%< + * Temporary. For use by named only. + */ + ISC_LANG_ENDDECLS #endif /* ISC_SOCKET_H */ Modified: projects/releng_7_xen/contrib/bind9/lib/isc/include/isc/timer.h ============================================================================== --- projects/releng_7_xen/contrib/bind9/lib/isc/include/isc/timer.h Sun Nov 23 01:51:14 2008 (r185197) +++ projects/releng_7_xen/contrib/bind9/lib/isc/include/isc/timer.h Sun Nov 23 05:39:49 2008 (r185198) @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004, 2005 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004, 2005, 2008 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1998-2002 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or 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. * @@ -15,7 +15,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: timer.h,v 1.31.18.3 2005/10/26 06:50:50 marka Exp $ */ +/* $Id: timer.h,v 1.31.18.3.52.2 2008/07/24 23:48:09 tbox Exp $ */ #ifndef ISC_TIMER_H #define ISC_TIMER_H 1 @@ -76,6 +76,7 @@ #include <isc/event.h> #include <isc/eventclass.h> #include <isc/lang.h> +#include <isc/time.h> ISC_LANG_BEGINDECLS @@ -93,6 +94,7 @@ typedef enum { *** DIFF OUTPUT TRUNCATED AT 1000 LINES ***
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200811230539.mAN5doPk041734>