debian/0000755000000000000000000000000012265466741007203 5ustar debian/watch0000644000000000000000000000012012265465562010225 0ustar version=3 http://0pointer.de/lennart/projects/nss-mdns/nss-mdns-([\d.]+).tar.gz debian/source/0000755000000000000000000000000012265465562010503 5ustar debian/source/format0000644000000000000000000000001412265465562011711 0ustar 3.0 (quilt) debian/rules0000755000000000000000000000100312265465562010255 0ustar #!/usr/bin/make -f export DEB_CFLAGS_MAINT_APPEND=-Wall export DEB_LDFLAGS_MAINT_APPEND=-Wl,-z,defs include /usr/share/dpkg/default.mk %: dh $@ --with autoreconf override_dh_auto_configure: dh_auto_configure -- \ --prefix=/ \ --mandir=/usr/share/man \ --infodir=/usr/share/info \ --sysconfdir=/etc \ --localstatedir=/var \ --libexecdir=/lib/nss-mdns \ --disable-legacy \ $(NULL) override_dh_auto_install: dh_auto_install --destdir=debian/tmp override_dh_install: dh_install --list-missing debian/patches/0000755000000000000000000000000012265465562010632 5ustar debian/patches/series0000644000000000000000000000003012265465562012040 0ustar 01_ia64_alignment.patch debian/patches/01_ia64_alignment.patch0000644000000000000000000000265412265465562014763 0ustar From: Steve Kowalik Date: Sat, 10 Sep 2011 17:04:29 +1000 Subject: Fix unaligned access on successful lookups on interesting 64-bit systems Origin: vendor, Debian Bug-Debian: http://bugs.debian.org/521184 Forwarded: no --- a/src/nss.c 2007-05-13 00:43:48.000000000 +1000 +++ b/src/nss.c 2009-03-26 02:08:57.944206926 +1100 @@ -69,7 +69,7 @@ #define ALIGN(idx) do { \ if (idx % sizeof(void*)) \ - idx += (sizeof(void*) - idx % sizeof(void*)); /* Align on 32 bit boundary */ \ + idx += (sizeof(void*) - idx % sizeof(void*)); /* Align on word boundary */ \ } while(0) struct userdata { @@ -514,7 +514,7 @@ result->h_length = address_length; /* Check if there's enough space for the addresses */ - if (buflen < idx+u.data_len+sizeof(char*)*(u.count+1)) { + if (buflen < idx+u.data_len+sizeof(char*)*(u.count+1)+sizeof(void*)) { *errnop = ERANGE; *h_errnop = NO_RECOVERY; status = NSS_STATUS_TRYAGAIN; @@ -525,9 +525,10 @@ astart = idx; l = u.count*address_length; memcpy(buffer+astart, &u.data, l); - /* address_length is a multiple of 32bits, so idx is still aligned - * correctly */ idx += l; + /* realign, whilst the address is a multiple of 32bits, we + * frequently lose alignment for 64bit systems */ + ALIGN(idx); /* Address array address_lenght is always a multiple of 32bits */ for (i = 0; i < u.count; i++) debian/libnss-mdns.postrm0000644000000000000000000000245712265465562012712 0ustar #!/bin/sh set -e #DEBHELPER# log() { echo "libnss-mdns.postrm: $*" } remove_mdns() { log "Checking NSS setup..." # abort if /etc/nsswitch.conf does not exist if ! [ -e /etc/nsswitch.conf ]; then log "Could not find /etc/nsswitch.conf." return fi log "Removing mdns from NSS setup" perl -i -pe ' my @remove=( "mdns4_minimal [NOTFOUND=return]", "mdns4_minimal", "mdns4", "mdns6_minimal [NOTFOUND=return]", "mdns6_minimal", "mdns6", "mdns_minimal [NOTFOUND=return]", "mdns_minimal", "mdns", ); sub remove { my $s=shift; foreach my $bit (@remove) { $s=~s/\s+\Q$bit\E//g; } return $s; } s/^(hosts:)(.*)/$1.remove($2)/e; ' /etc/nsswitch.conf } action="$1" if [ "$action" = remove ]; then # as recommended by # instances="$(dpkg-query -f '${db:Status-Abbrev} ${binary:Package}\n' -W libnss-mdns | grep -v '^.n' | wc -l)" if [ "$instances" = 1 ]; then remove_mdns else log "Not removing mdns from nsswitch.conf, $(( $instances - 1 )) architecture(s) still installed" fi fi debian/libnss-mdns.postinst0000644000000000000000000000623712265465562013251 0ustar #!/bin/sh set -e #DEBHELPER# log() { echo "$*" } # try to insert mdns entries to the "hosts" line in /etc/nsswitch.conf to # automatically enable nss-mdns support; do not change the configuration if the # "hosts" line already references some mdns lookups insert_mdns() { log "Checking NSS setup..." # abort if /etc/nsswitch.conf does not exist if ! [ -e /etc/nsswitch.conf ]; then log "Could not find /etc/nsswitch.conf." return fi perl -i -pe ' sub insert { # this also splits on tab my @bits=split(" ", shift); # do not break configuration if the "hosts" line already references # mdns if (grep { $_ eq "mdns4_minimal" || $_ eq "mdns4" || $_ eq "mdns" || $_ eq "mdns_minimal" || $_ eq "mdns6" || $_ eq "mdns6_minimal"} @bits) { return join " ", @bits; } # change "dns" into "mdns4_minimal [NOTFOUND=return] dns" return join " ", map { $_ eq "dns" ? ("mdns4_minimal","[NOTFOUND=return]",$_) : $_ } @bits; } s/^(hosts:\s+)(.*)/$1.insert($2)/e; ' /etc/nsswitch.conf } action="$1" if [ configure = "$action" ]; then if [ -z "$2" ]; then log "First installation detected..." # first install: setup the recommended configuration (unless # nsswitch.conf already contains mdns entries) insert_mdns else # upgrade version="$2" if dpkg --compare-versions "$version" lt 0.8-4.2; then log "Upgrade from unconfigured version detected." # versions prior to 0.8-4.2 did not setup nss-mdns automatically, # do it now insert_mdns elif dpkg --compare-versions "$version" lt 0.8-6; then log "Already configured version detected, skipping NSS setup." # versions 0.8-4.2 and 0.8-5 installed the same configuration as # this postinst, so nothing needs to be done : elif dpkg --compare-versions "$version" lt 0.8-6.1; then log "Upgrade from possibly broken version detected." if [ -e /etc/nsswitch.conf ]; then # version 0.8-6 broke the configuration in multiple ways: 1) # for systems which were upgraded from 0.8-4.2 or 0.8-5 to # 0.8-6, the hosts line will look like: # hosts: files dns # cleanup from this specially formatted line into the default # one: sed -i \ 's/^hosts: files dns $/hosts: files dns/' \ /etc/nsswitch.conf # 2) for systems which re-installed 0.8-6 or installed 0.8-6 as the # first version, the hosts line will look like: # hosts: files mdns_minimal dns mdns # cleanup from this specially formatted line into the default one: sed -i -r \ '/^hosts:/s/\/dns/' \ /etc/nsswitch.conf fi insert_mdns fi fi fi debian/libnss-mdns.lintian-overrides0000644000000000000000000000034212265465562015013 0ustar # these are all NSS plugins, not libraries intended for normal linking libnss-mdns: package-name-doesnt-match-sonames libnss-mdns2 libnss-mdns4-2 libnss-mdns4-minimal2 libnss-mdns6-2 libnss-mdns6-minimal2 libnss-mdns-minimal2 debian/libnss-mdns.install0000644000000000000000000000001512265465562013020 0ustar lib/*/*.so.* debian/libnss-mdns.docs0000644000000000000000000000003612265465562012305 0ustar doc/style.css doc/README.html debian/gbp.conf0000644000000000000000000000012012265465562010613 0ustar [DEFAULT] pristine-tar = True debian-branch = master upstream-branch = upstream debian/copyright0000644000000000000000000000153712265465562011144 0ustar Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Source: http://0pointer.de/lennart/projects/nss-mdns/#download Files: * Copyright: © 2004-2007 Lennart Poettering License: LGPL-2+ License: LGPL-2+ nss-mdns is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. . nss-mdns is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. Comment: On Debian systems, the complete text of the GNU Lesser General Public License can be found in "/usr/share/common-licenses/LGPL-2". debian/control0000644000000000000000000000463512265465562010616 0ustar Source: nss-mdns Section: admin Priority: optional Maintainer: Utopia Maintenance Team Uploaders: Loic Minier , Sjoerd Simons , Simon McVittie Build-Depends: debhelper (>= 9), dh-autoreconf, dpkg-dev (>= 1.16.1~), lynx Standards-Version: 3.9.5 Package: libnss-mdns Pre-Depends: ${misc:Pre-Depends} Depends: ${shlibs:Depends}, ${misc:Depends}, base-files (>= 3.1.10), avahi-daemon (>= 0.6.16-1) Suggests: avahi-autoipd | zeroconf Breaks: lib32nss-mdns (<< ${source:Version}) Replaces: lib32nss-mdns (<< ${source:Version}) Architecture: any Multi-Arch: same Description: NSS module for Multicast DNS name resolution nss-mdns is a plugin for the GNU Name Service Switch (NSS) functionality of the GNU C Library (glibc) providing host name resolution via Multicast DNS (using Zeroconf, aka Apple Bonjour / Apple Rendezvous ), effectively allowing name resolution by common Unix/Linux programs in the ad-hoc mDNS domain .local. Package: lib32nss-mdns Section: oldlibs Priority: extra Pre-Depends: ${misc:Pre-Depends} Depends: libnss-mdns-i386 (= ${binary:Version}), ${misc:Depends} Architecture: amd64 Description: NSS module for mDNS name resolution (amd64 transitional package) nss-mdns is a plugin for the GNU Name Service Switch (NSS) functionality of the GNU C Library (glibc) providing host name resolution via Multicast DNS. . This transitional package exists to upgrade amd64 systems from lib32nss-mdns:amd64 to libnss-mdns:i386. Because direct cross-architecture dependencies are not yet supported, it depends on an intermediate package, libnss-mdns-i386, which is only available on i386. Package: libnss-mdns-i386 Section: oldlibs Priority: extra Pre-Depends: ${misc:Pre-Depends} Depends: libnss-mdns (= ${binary:Version}), ${misc:Depends} Architecture: i386 Multi-Arch: foreign Description: NSS module for mDNS name resolution (i386 transitional package) nss-mdns is a plugin for the GNU Name Service Switch (NSS) functionality of the GNU C Library (glibc) providing host name resolution via Multicast DNS. . This transitional package exists to upgrade amd64 systems from lib32nss-mdns:amd64 to libnss-mdns:i386. It is a workaround for lack of support for direct cross-architecture dependencies in the Debian archive. debian/compat0000644000000000000000000000000212265465562010401 0ustar 9 debian/changelog0000644000000000000000000003214712265465562011064 0ustar nss-mdns (0.10-6) unstable; urgency=low * Bring back a transitional lib32nss-mdns on amd64. It depends on a new transitional libnss-mdns-i386 on i386, which in turn depends on libnss-mdns. This is necessary because a direct dependency on libnss-mdns:i386 by an amd64 package is not yet allowed: -- Simon McVittie Wed, 15 Jan 2014 11:05:02 +0000 nss-mdns (0.10-5) unstable; urgency=low * Remove transitional lib32nss-mdns for now, since it looks as though an automatic upgrade will need a second transitional package and a trip through the NEW queue * Override lintian warning for a ${source:Version}-based relation on lib32nss-mdns, which is not built from this package but will come back later * Override lintian warning for package-name-doesnt-match-sonames: the objects in this package are plugins, not normal libraries * Standards-Version: 3.9.5 (no changes needed) * Redo copyright file in DEP-5 format * Only remove nss-mdns from nsswitch.conf if no more instances are installed (Closes: #712029) * Release to unstable -- Simon McVittie Wed, 15 Jan 2014 10:22:10 +0000 nss-mdns (0.10-4) experimental; urgency=low * Add myself to Uploaders * Acknowledge NMUs * Remove 00_dns_unaligned_access.patch, already applied upstream in 0.10 * Convert to 3.0 (quilt) format, with 01_ia64_alignment.patch applied as a patch by dpkg * Bring debhelper compat up to 9 * Use dpkg's default.mk for architecture and hardening flags * Use dh and dh_autoreconf * Make libnss-mdns Multi-arch: same (Closes: #686984, #710232) * Switch lib32nss-mdns from a biarch package built on amd64 to a transitional package built on i386: this means users of wheezy's multiarch Wine packages, who already have i386 as a foreign architecture, should automatically get cross-graded from lib32nss-mdns:amd64 to lib32nss-mdns:i386 and hence to libnss-mdns:i386 * Simplify build system now that there is only one "flavour" * debian/control: remove duplicate Section * Standards-Version: 3.9.4 (no further changes) * Run dh_install with --list-missing * Add gbp.conf * Add debian/source/local-options to unapply patches when built from git * On new installations, do not add "mdns4" to nsswitch.conf, only "mdns4_minimal [NOTFOUND=return]". This means we can't perform reverse DNS using mDNS for addresses outside 169.254.x.x and fe80::/10, but avoids a 5 second delay if such addresses do not have a PTR record in DNS (Closes: #412714, #414569, #561622 for new installations). * Document the alternative configuration with mdns4 in README.Debian -- Simon McVittie Wed, 12 Jun 2013 09:57:13 +0100 nss-mdns (0.10-3.2) unstable; urgency=low * NMU. * Drop perl dependancy, only perl-base is needed. (Closes: #580394, #603581) * Include a patch that fixes unaligned access on successful lookups on interesting 64-bit systems. (Closes: #521184) -- Steve Kowalik Sat, 10 Sep 2011 17:04:29 +1000 nss-mdns (0.10-3.1) unstable; urgency=low * NMU * Move biarch files to /usr/lib32. closes: #533013. * Have lib32nss-mdns conflict with libc6-i386 (<= 2.9-18). * Bump to Standards-Version 3.8.2. -- Clint Adams Sun, 02 Aug 2009 11:54:57 -0400 nss-mdns (0.10-3) unstable; urgency=low * Upload to unstable. -- Loic Minier Tue, 10 Jul 2007 13:38:15 +0200 nss-mdns (0.10-2) experimental; urgency=low * Rework the build process completely to be able to build multiple flavors; build a "main" flavor and an addition "m32" flavor for amd64 which is installed in a new lib32nss-mdns package for 32-bits compatibility; build-depend on gcc-mutilib; initial patch proposed by Goswin von Brederlow; closes: #410052. -- Loic Minier Mon, 02 Jul 2007 21:42:31 +0200 nss-mdns (0.10-1) unstable; urgency=low * Set Utopia Maintenance Team as Maintainer and add Sjoerd and myself as Uploaders. * Ack NMU. * Bump Debhelper compatibility level to 5. * Misc cleanups. * Wrap fields in control. * Add ${misc:Depends}. * Switch to a multi-binaries layout for the packaging. * Split the definition of configure flags and LDFLAGS. * Drop -DNDEBUG=1 from CFLAGS; seems risky in a package build. * Only pass --host to configure if DEB_HOST_GNU_TYPE and DEB_BUILD_GNU_TYPE differ. * Add watch file. -- Loic Minier Fri, 22 Jun 2007 18:28:22 +0200 nss-mdns (0.10-0.1) unstable; urgency=high * NMU * New upstream release * Fixes alignment problems on sparc causing sigBUS (Closes: #423222) -- Sjoerd Simons Sun, 13 May 2007 10:23:16 +0200 nss-mdns (0.9-0.2) unstable; urgency=high * Non-maintainer upload to fix a RC bug. * Configure with a prefix of / instead of /usr as libnss-mdns needs to be in /lib for the resolver to work correctly during boot; this is also needed for chrooted processes such as Postfix's smtpd which uses a copy of the NSS libs as well of the NSS configuration and fails when mdns is missing in the chroot but referenced in nsswitch.conf. Update other configured dirs (mandir, infodir, sysconfdir) as well, but these are currently not used. -- Loic Minier Thu, 22 Feb 2007 14:48:45 +0100 nss-mdns (0.9-0.1) unstable; urgency=high * Non-maintainer upload to fix broken dependencies in the 0.8-6.1 NMU. * Fix Depends on perl and avahi-daemon. * Bump up dependency on avahi-daemon to >= 0.6.16-1 for the auto-disabling functionality on sites with a .local SOA. * New upstream release. - Does not export unnecessary symbols and fixes segfault in nmbclient which had symbols with the same name; closes: #404266. - Does not use the "search" keyword of resolv.conf anymore; closes: #404534, #405327. * Re-add a postrm to cleanup the mdns_* entries from nsswitch.conf but act on package removal instead of purge to avoid breaking the DNS when the lib is removed and to ensure perl is still present; closes: #406198. * Document the changes made to postinst in NOTES.Debian and document the history of the postrm as well. * Updates to README.Debian; add upstream URL for troubleshooting. -- Loic Minier Tue, 9 Jan 2007 18:45:27 +0100 nss-mdns (0.8-6.1) unstable; urgency=low * Non-maintainer upload to fix a long-standing RC bug and to beat the package into shape before etch with suggestions from upstream; thanks Lennart Poettering. * Configure with --disable-legacy, as recommended by upstream for security reasons; the legacy mode might be offered in a separate binary package for the corner cases where it can be useful; see full discussion in #393711; depend on avahi-daemon as nss-mdns will not work without avahi when compiled like this; closes: #399297. * Only suggest zeroconf instead of Recommending it: even if it can act as a nice complement to nss-mdns, it is intrusive and orthogonal to nss-mdns and conflicts with avahi-autoipd; closes: #353131, #392590. * Suggest avahi-autoipd as an alternative to zeroconf. * Remove offensive comments in postinst and README.Debian. * Document the history of postinst snippets in debian/NOTES.Debian to permit handling all upgrade paths. * Depend on Perl for the postinst snippets using the perl interpreter. * Rewrite postinst to handle all upgrade paths. - Does not wipe NSS configuration which matches the upstream recommended configuration during upgrades from versions 0.8-4.2 or 0.8-5; closes: #393608. - Install the upstream recommended configuration for first installs and upgrades from versions which did not automatically insert mdns in the NSS setup (unless mdns is already setup); closes: #393711. - Keep configuration intact when upgrading from versions which installed the upstream recommended configuration. - Remove whitespaces added in upgrades from version 0.8-4.2 or 0.8-5 to 0.8-6. - For upgrades from 0.8-6, attempt to revert the problematic "mdns_minimal dns mdns" configuration and to install the upstream recommended configuration. * Update README.Debian to match the above changes and a planned changes in avahi-daemon which should disable itself if a .local SOA is found after a change in the DNS settings. -- Loic Minier Sun, 24 Dec 2006 20:27:30 +0100 nss-mdns (0.8-6) unstable; urgency=medium * Revert hostile package takeover. * "Unbreak the world" (Closes: #392813) "So whether nss-mdns does or doesn't support "search local" is of no concern to me -- I just doesn't want it to interfere with my otherwise working setup." Walter Hofmann on Joey Hess and Sjoerd Simons' period of maintainence * Revert switch to CDBS. * Switch to using a sane /etc/nsswitch.conf so we don't break existing setups, or those over which the user has no control. * Revert "clarifications" as well. * Recommend, once again, zeroconf. -- Anand Kumria Mon, 16 Oct 2006 12:18:55 +1000 nss-mdns (0.8-5) unstable; urgency=low * Take over the package for the pkg-utopia team. T * Acknowledge NMU's (Closes: #388864, #351990, #353131, #378608) * Switch to cdbs. As a side-effect the sysconfdir and localstatedir are set correctly (Closes: #387231) * debian/patches/00_dns_unaligned_access.patch: - Added. Prevent unaligned access when creating/parsing dns packets. -- Sjoerd Simons Wed, 11 Oct 2006 11:32:46 +0200 nss-mdns (0.8-4.2) unstable; urgency=low * NMU * Add postinst that will add mdns entries to /etc/nsswitch.conf on new installs and on upgrades from the previous version. Closes: #388864, #351990 * Add postrm to remove mdns entries from /etc/nsswitch.conf when the package is removed. * Local modifications to the file will be preserved accross upgrades. * Depend on base-files 3.1.10 or higher to get a nsswitch.conf that is not a conffile and that doesn't have mdns entries from base-files in it. * Switch to nsswitch line recommended by upstream in #388864 after getting clarification from upstream, and update README.Debian. * Remove recommends on zeroconf. Closes: #353131 -- Joey Hess Fri, 22 Sep 2006 21:10:25 -0400 nss-mdns (0.8-4.1) unstable; urgency=low * NMU * Clear out the diff.gz so it doesn't patch the various autotools files, which makes everything explode on build (Closes: #378608) -- Sjoerd Simons Fri, 8 Sep 2006 09:51:57 +0200 nss-mdns (0.8-4) unstable; urgency=low * Forget about using CDBS and use debhelper directly so we have control of what is being built and updated. (Closes: #378608) -- Anand Kumria Sun, 13 Aug 2006 12:24:32 +1000 nss-mdns (0.8-3) unstable; urgency=low * Regenerate the Debian .diff.gz so the Debian build system doesn't barf and die -- Anand Kumria Sun, 13 Aug 2006 09:49:39 +1000 nss-mdns (0.8-2) unstable; urgency=low * Copy 'configure' from the upstream tarball since the CDBS regeneration has gone awry and does not work. This is the simple fix -- a more robust one will be in place shortly. Thanks to Sam Morris for the diagnosis. (Closes: #378608) -- Anand Kumria Sun, 13 Aug 2006 09:40:48 +1000 nss-mdns (0.8-1) unstable; urgency=low * New upstream release (Closes: #369827) * Enable "minimal" mDNS mode -- Debian has had this for a while but upstream have now incorporated it. This should mean that mdns can now be mentioned in /etc/nsswitch.conf without issue. (Closes: #348578, #348580) * Suggest avahi-daemon rather than nscd (Closes: #367275) -- Anand Kumria Mon, 3 Jul 2006 03:55:05 +1000 nss-mdns (0.7-1) unstable; urgency=low * New upstream release -- Anand Kumria Tue, 27 Dec 2005 06:42:42 +1100 nss-mdns (0.6-2) unstable; urgency=low * Enable Avahi connections -- Anand Kumria Mon, 12 Sep 2005 20:59:52 +1000 nss-mdns (0.6-1) unstable; urgency=low * New upstream release -- Anand Kumria Fri, 2 Sep 2005 03:58:34 +1000 nss-mdns (0.5-1) unstable; urgency=low * New upstream release (Closes: #313024) -- Anand Kumria Thu, 16 Jun 2005 17:38:13 +1000 nss-mdns (0.4-1) unstable; urgency=low * New upstream release * Fix endian issues (Closes: #305465) -- Anand Kumria Mon, 16 May 2005 05:12:09 +1000 nss-mdns (0.3-2) unstable; urgency=low * Modify Maintainer to point to me. * Recommend 'zeroconf' * Remove i386 specific int3 debug hack. * Update to standard 3.6.1 * Reclose RFP (Closes: #284497) -- Anand Kumria Mon, 7 Mar 2005 01:27:04 +1100 nss-mdns (0.3-1) unstable; urgency=low * Update to current upstream -- Lennart Poettering Sun, 16 Jan 2005 14:57:28 +0100 nss-mdns (0.1-0) unstable; urgency=low * Initial Release (Closes: #284497). -- Jeff Waugh Tue, 07 Dec 2004 12:42:51 +0100 debian/README.Debian0000644000000000000000000000343412265465562011250 0ustar Packages automagically modifies /etc/nsswitch.conf -------------------------------------------------- Previously the base-files package shipped /etc/nsswitch.conf and specified: hosts: files dns mdns However, due to bug#351990, this is no longer the case. /etc/nsswitch.conf is now generated post-installation. Upon installation of nss-mdns, if the strings 'mdns', 'mdns_minimal', 'mdns4', 'mdns4_minimal', 'mdns6' or 'mdns6_minimal' appear on the hosts line, your /etc/nsswitch.conf file will not be updated, otherwise it will updated to match the upstream recommended configuration which usually looks like: hosts: files mdns4_minimal [NOTFOUND=return] dns Other possible configurations ----------------------------- In versions older than 0.10-4 we used this configuration: hosts: files mdns4_minimal [NOTFOUND=return] dns mdns4 This looks in mDNS whenever a non-link-local address does not have a PTR (reverse DNS) record in DNS. If the host with that address is local and available in mDNS, this means it becomes reverse-resolvable, but if the host with that address is not local, it causes a 5 second delay, so this is no longer enabled by default. If a local administrator wishes to reinstate mdns4, they can do so. Sites with a .local DNS zone ---------------------------- Making nss-mdns authoritative for .local breaks resolution on networks where .local is a real domain name. To workaround this, avahi-daemon should be restarted when the DNS settings change (for example via resolvconf and dhclient hooks) and disable itself when a SOA for the .local zone is found. This is not currently implemented at the time of writing, but should soon be. See also this excellent summary on the upstream website: debian/NOTES.Debian0000644000000000000000000001065412265465562011205 0ustar Upgrade implementation notes ============================ The first version in Debian was 0.3-2. Postinst ======== Starting with version 0.8-4.2 inclusive, the package started touching /etc/nsswitch.conf in debian/postinst. In versions 0.8-4.2, for first installs and upgrades from versions lower or equal to 0.8-4.1, the postinst would: - avoid doing anything if any of "mdns4_minimal", "mdns4", "mdns", "mdns_minimal", "mdns6", "mdns6_minimal" was found in the hosts line; that is, manually configured /etc/nsswitch.conf were kept intact - otherwise change the "dns" entry in /etc/hosts into: "mdns4_minimal [NOTFOUND=return] dns mdns4" Problems with this version: 1) does not preserve spacing ("foo bar" becomes "foo bar") 2) breaks local reaction overrides ("[STATUS=ACTION]") In version 0.8-5, the postinst is identical to the postinst of version 0.8-4.2. In version 0.8-6, the postinst was really messed up: * for first installs: - avoid doing anything if any of "mdns4_minimal", "mdns4", "mdns", "mdns_minimal", "mdns6", "mdns6_minimal" was found in the hosts line; that is, manually configured /etc/nsswitch.conf were kept intact - otherwise change the "dns" entry in /etc/hosts into: "mdns_minimal dns mdns" - if the hosts line contained "... mdns4_minimal [NOTFOUND=return] ... dns ... mdns4 ...", remove these "mdns4_minimal [NOTFOUND=return]" and "mdns4" entries * for upgrades from versions lower or equal to 0.8-4.1: - avoid doing anything if any of "mdns4_minimal", "mdns4", "mdns", "mdns_minimal", "mdns6", "mdns6_minimal" was found in the hosts line; that is, manually configured /etc/nsswitch.conf were kept intact - otherwise change the "dns" entry in /etc/hosts into: "mdns_minimal dns mdns" * for upgrades from versions 0.8-4.2 and 0.8-5: - if the hosts line contained "... mdns4_minimal [NOTFOUND=return] ... dns ... mdns4 ...", remove these "mdns4_minimal [NOTFOUND=return]" and "mdns4" entries * for upgrades from versions higher or equal to 0.8-6 (i.e. reinstalls of 0.8-6!): - avoid doing anything if any of "mdns4_minimal", "mdns4", "mdns", "mdns_minimal", "mdns6", "mdns6_minimal" was found in the hosts line; that is, manually configured /etc/nsswitch.conf were kept intact - otherwise change the "dns" entry in /etc/hosts into: "mdns_minimal dns mdns" Problems with this version: 1) does not preserve spacing ("foo bar" becomes "foo bar") in many cases 2) breaks local reaction overrides ("[STATUS=ACTION]") in many cases 3) does not handle all versions (e.g. local versions, versions from Ubuntu) 4) installs a configuration which does not match the upstream recommendations for new installs or upgrades from >= 0.8-4.1 5) removes any local or automatic configuration and breaks the mdns setup when upgrading from versions 0.8-4.2 and 0.8-5 6) results in ugly spacing when upgrading from versions 0.8-4.2 and 0.8-5 (note the trailing space and the double space between files and dns): hosts: files dns In version 0.8-6.1 and later, the postinst would: - if upgrading from 0.8-6: - revert breakage introduced in 0.8-6 - avoid doing anything if any of "mdns4_minimal", "mdns4", "mdns", "mdns_minimal", "mdns6", "mdns6_minimal" was found in the hosts line; that is, manually configured /etc/nsswitch.conf were kept intact - otherwise change the "dns" entry in /etc/hosts into: "mdns4_minimal [NOTFOUND=return] dns mdns4" - for first installs and upgrades from versions lower than 0.8-4.2, the postinst would: - avoid doing anything if any of "mdns4_minimal", "mdns4", "mdns", "mdns_minimal", "mdns6", "mdns6_minimal" was found in the hosts line; that is, manually configured /etc/nsswitch.conf were kept intact - otherwise change the "dns" entry in /etc/hosts into: "mdns4_minimal [NOTFOUND=return] dns mdns4" In version 0.10-4 and later, the logic is the same as for 0.8-6.1, except that the "otherwise" case is to change "dns" into "mdns4_minimal [NOTFOUND=return] dns" (without "mdns4" as per Lennart's recommendation on #433943). Postrm ====== Concerning postrm, one was introduced in version 0.8-4.2 to remove any keyword from a set of mdns keywords from the "hosts:" line of nsswitch.conf during purge. This postinst snippet was dropped in 0.8-6. In version 0.9-0.1, the same snippet was reintroduced, but is run on package removal instead of purge to ensure perl is still present and to avoid DNS issues in case of a removed package.