Hello community, here is the log from the commit of package nss-mdns.666 for openSUSE:12.2:Update checked in at 2012-07-23 15:05:02 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:12.2:Update/nss-mdns.666 (Old) and /work/SRC/openSUSE:12.2:Update/.nss-mdns.666.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "nss-mdns.666", Maintainer is "" Changes: -------- New Changes file: --- /dev/null 2012-07-06 19:40:38.919402255 +0200 +++ /work/SRC/openSUSE:12.2:Update/.nss-mdns.666.new/nss-mdns.changes 2012-07-23 15:05:03.000000000 +0200 @@ -0,0 +1,94 @@ +------------------------------------------------------------------- +Wed Jul 11 13:37:10 CEST 2012 - vu...@opensuse.org + +- Add nss-mdns-config script as a source, and install it in + /usr/sbin: this script can be used to enable/disable mdns in + /etc/nsswitch.conf (-4/-6 can be used to restrict + enabling/disabling to IPv4/IPv6). +- Change %post/%preun scriptlets to use new nss-mdns-config script + instead of custom perl-fu. +- Do not restrict mdns support in /etc/nsswitch.conf to IPv4: just + pass --enable to nss-mdns-config in %post. Fix bnc#710231. +- Only call nss-mdns-config in %post on first install, to avoid + overwriting changes done by users. Fix nss-mdns side of + bnc#729796. +- Do not call sed to change /etc/nsswitch.conf to remove services + not provided by nss-mdns anymore: when we need this, we'll be + able to integrate this in nss-mdns-config. + +------------------------------------------------------------------- +Tue Dec 15 22:28:46 CET 2009 - jeng...@medozas.de + +- Add baselibs.conf as a source + +------------------------------------------------------------------- +Fri May 1 03:32:54 CEST 2009 - vu...@novell.com + +- Remove AutoReqProv: it's default now. +- Also fix a typo in the description. + +------------------------------------------------------------------- +Mon Oct 13 12:49:02 CEST 2008 - r...@suse.de + +- simplify and correct baselibs.conf + +------------------------------------------------------------------- +Wed May 28 15:49:14 CEST 2008 - o...@suse.de + +- change the recommends for XXbit packages to a supplements + add a Conflicts: != version to the XXbit packages, to give a hint + during manual package upgrades (bnc#336678) + +------------------------------------------------------------------- +Tue Apr 22 10:08:38 CEST 2008 - co...@suse.de + +- degrading the requires to recommends. It's very well possible + to install a system with just 64bit + +------------------------------------------------------------------- +Thu Apr 10 12:54:45 CEST 2008 - r...@suse.de + +- added baselibs.conf file to build xxbit packages + for multilib support + +------------------------------------------------------------------- +Thu Apr 3 07:00:56 CEST 2008 - h...@suse.de + +- Upgraded to version 0.10: + + * Ported to FreeBSD. + * Alignment fixes for SPARC. + +------------------------------------------------------------------- +Tue Sep 11 00:36:14 CEST 2007 - r...@suse.de + +- modify last change: + - require 32bit variant on x86_64 and s390x + - require 64bit variant on ppc + +------------------------------------------------------------------- +Mon Sep 10 16:19:55 CEST 2007 - sbra...@suse.cz + +- Fixed invalid dependency for bi-arch (#309193). + +------------------------------------------------------------------- +Thu Sep 6 22:27:24 CEST 2007 - ma...@suse.de + +- Sync the spec with the scripts in the comment #6 of bnc #287583 + +------------------------------------------------------------------- +Thu Sep 6 01:25:07 CEST 2007 - ma...@suse.de + +- The 64 bit version of nss-mdns will require the -32 version to + bugfix bnc #287583. + +------------------------------------------------------------------- +Sat Apr 21 10:51:20 CEST 2007 - sch...@suse.de + +- Fix unaligned access. + +------------------------------------------------------------------- +Tue Feb 20 17:58:09 CET 2007 - sbra...@suse.cz + +- New SuSE package, version 0.9. + New: ---- baselibs.conf nss-mdns-0.10.tar.bz2 nss-mdns-config nss-mdns.changes nss-mdns.spec unaligned.diff ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ nss-mdns.spec ++++++ # # spec file for package nss-mdns # # Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via http://bugs.opensuse.org/ # Name: nss-mdns # lynx is not needed, text version of README is already present #BuildRequires: lynx Version: 0.10 Release: 0 Url: http://0pointer.de/lennart/projects/nss-mdns/ Summary: Host Name Resolution Via Multicast DNS (Zeroconf) for glibc License: LGPL-2.1+ Group: Productivity/Networking/DNS/Utilities Source: %{name}-%{version}.tar.bz2 Source1: nss-mdns-config Source2: baselibs.conf Patch: unaligned.diff # needed by nss-mdns-config PreReq: sed grep Requires: avahi BuildRoot: %{_tmppath}/%{name}-%{version}-build %description nss-mdns is a plug-in for the GNU Name Service Switch (NSS) functionality of the GNU C Library (glibc) providing a hostname resolution via Multicast DNS (aka Zeroconf, aka Apple Rendezvous, aka Apple Bonjour), and effectively allowing name resolution by common Unix/Linux programs in the ad-hoc mDNS domain .local. nss-mdns provides only client functionality, which means that you have to run a mDNS responder daemon separately from nss-mdns if you want to register the local hostname via mDNS. I recommend Avahi. By default, nss-mdns tries to contact a running avahi-daemon to resolve hostnames and addresses and makes use of its superior record cacheing. %prep %setup -q %patch %build %configure --libdir=/%{_lib} %install %makeinstall install -D -m0755 %{SOURCE1} %{buildroot}%{_sbindir}/nss-mdns-config %post /sbin/ldconfig if [ "$1" -eq 1 ] ; then # Only enable on first install, to not overwrite changes done by users nss-mdns-config --enable fi %preun if [ "$1" -eq 0 ] ; then # Completely disable when not upgrading (ie, fully uninstalling) nss-mdns-config --disable fi %postun /sbin/ldconfig %files %defattr(-,root,root) %doc LICENSE README doc/*.html doc/*.css %{_sbindir}/nss-mdns-config /%{_lib}/libnss_mdns.so.2 /%{_lib}/libnss_mdns_minimal.so.2 /%{_lib}/libnss_mdns4.so.2 /%{_lib}/libnss_mdns4_minimal.so.2 /%{_lib}/libnss_mdns6.so.2 /%{_lib}/libnss_mdns6_minimal.so.2 %clean rm -rf $RPM_BUILD_ROOT %changelog ++++++ baselibs.conf ++++++ nss-mdns requires "nss-mdns = <version>" supplements "packageand(nss-mdns:glibc-<targettype>)" ++++++ nss-mdns-config ++++++ #!/bin/sh # vim: set ts=2 sw=2 et: # # Copyright (c) 2012, Novell, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # # * Redistributions of source code must retain the above copyright notice, # this list of conditions and the following disclaimer. # * 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. # * Neither the name of the <ORGANIZATION> 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 COPYRIGHT HOLDERS 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 COPYRIGHT OWNER 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. # # # (Licensed under the simplified BSD license) # # Authors: Vincent Untz <vu...@opensuse.org> # NSSWITCH=/etc/nsswitch.conf function usage() { echo "nss-mdns-config [--enable|--disable] [-4|-6] [--no-backup]" } ENABLE=0 DISABLE=0 IPv4=0 IPv6=0 IPvALL=0 BACKUP=1 while test $# -gt 0; do case "$1" in --enable) ENABLE=1; shift;; --disable) DISABLE=1; shift;; -4) IPv4=1; shift;; -6) IPv6=1; shift;; --no-backup) BACKUP=0; shift;; *) usage; exit 1;; esac done if test "$ENABLE" -eq 1 -a "$DISABLE" -eq 1; then usage exit 1 fi if test "$IPv4" -eq 1 -a "$IPv6" -eq 1; then # Supporting -4 and -6 at the same time would make --enable more complex, # since we'd like it to add both mdns4_minimal and mdns6_minimal. So just # don't do it for now. usage exit 1 fi if test "$IPv4" -ne 1 -a "$IPv6" -ne 1; then IPv4=1 IPv6=1 IPvALL=1 fi if test ! -f "$NSSWITCH"; then if test "$ENABLE" -ne 1 -a "$DISABLE" -ne 1; then echo "No $NSSWITCH file." fi exit 0 fi HOSTS=$(grep -m1 "^\s*hosts:" "$NSSWITCH") if test $? -ne 0; then echo "No hosts configuration in $NSSWITCH." exit 0 fi VALUE=$(echo $HOSTS | sed "s/^\s*hosts:\s*//g") if test "$ENABLE" -ne 1 -a "$DISABLE" -ne 1; then IPv4_ENABLED=0 IPv6_ENABLED=0 ENABLED=0 for ITEM in $VALUE; do if test "$ITEM" == "mdns4_minimal" -o "$ITEM" == "mdns4"; then IPv4_ENABLED=1 elif test "$ITEM" == "mdns6_minimal" -o "$ITEM" == "mdns6"; then IPv6_ENABLED=1 elif test "$ITEM" == "mdns_minimal" -o "$ITEM" == "mdns"; then ENABLED=1 fi done if test "$ENABLED" -eq 1; then echo "Full support for nss-mdns is enabled." elif test "$IPv4_ENABLED" -eq 1 -a "$IPv6_ENABLED" -eq 1; then echo "Support for nss-mdns is enabled for IPv4 and IPv6." elif test "$IPv4_ENABLED" -eq 1; then echo "Support for nss-mdns is enabled for IPv4." elif test "$IPv6_ENABLED" -eq 1; then echo "Support for nss-mdns is enabled for IPv6." else echo "Support for nss-mdns is disabled." fi elif test "$DISABLE" -eq 1; then NEWVALUE="" DROPACTION=0 for ITEM in $VALUE; do if test \( "$ITEM" == "mdns4_minimal" -o "$ITEM" == "mdns4" \) -a "$IPv4" -eq 1; then DROPACTION=1 elif test \( "$ITEM" == "mdns6_minimal" -o "$ITEM" == "mdns6" \) -a "$IPv6" -eq 1; then DROPACTION=1 elif test "$ITEM" == "mdns_minimal" -o "$ITEM" == "mdns"; then if test "$IPvALL" -eq 1; then DROPACTION=1 elif test "$IPv4" -eq 1; then NEWVALUE="$NEWVALUE `echo $ITEM | sed 's:mdns:mdns6:'`" DROPACTION=0 elif test "$IPv6" -eq 1; then NEWVALUE="$NEWVALUE `echo $ITEM | sed 's:mdns:mdns4:'`" DROPACTION=0 else echo "Internal error when disabling $ITEM." exit 1 fi elif test "${ITEM::1}" == "[" -a "$DROPACTION" -eq 1; then DROPACTION=0 else NEWVALUE="$NEWVALUE $ITEM" DROPACTION=0 fi done NEWVALUE=$(echo $NEWVALUE | sed "s/^\s*//;s/^\s*$//") if test "$BACKUP" -eq 1; then cp -a "$NSSWITCH" "${NSSWITCH}bak" fi sed -i "s/\(^\s*hosts:\s*\).*/\1$NEWVALUE/" "$NSSWITCH" elif test "$ENABLE" -eq 1; then NEWVALUE="" FOUND=0 FOUND_DNS=0 DROPACTION=0 for ITEM in $VALUE; do if test \( "$ITEM" == "mdns_minimal" -o "$ITEM" == "mdns4_minimal" -o "$ITEM" == "mdns6_minimal" \); then if test "$FOUND_DNS" -eq 1; then # don't keep *_minimal after dns; it's not desired there DROPACTION=1 else if test "$IPvALL" -eq 1 -a \( "$ITEM" == "mdns4_minimal" -o "$ITEM" == "mdns6_minimal" \); then # no need to keep mdns[46]_minimal since we'll add mdns_minimal DROPACTION=1 else if test "$ITEM" == "mdns_minimal"; then FOUND=1 elif test "$ITEM" == "mdns4_minimal" -a "$IPv4" -eq 1; then FOUND=1 elif test "$ITEM" == "mdns6_minimal" -a "$IPv6" -eq 1; then FOUND=1 fi # force the use of [NOTFOUND=return] after *_minimal NEWVALUE="$NEWVALUE $ITEM [NOTFOUND=return]" DROPACTION=1 fi fi elif test \( "$ITEM" == "mdns" -o "$ITEM" == "mdns4" -o "$ITEM" == "mdns6" \); then # we simply don't use the non-minimal version in our setup, so drop it DROPACTION=1 elif test "$ITEM" == "dns"; then FOUND_DNS=1 DROPACTION=0 if test "$FOUND" -ne 1; then FOUND=1 if test "$IPvALL" -eq 1; then NEWVALUE="$NEWVALUE mdns_minimal [NOTFOUND=return] $ITEM" elif test "$IPv4" -eq 1; then NEWVALUE="$NEWVALUE mdns4_minimal [NOTFOUND=return] $ITEM" elif test "$IPv6" -eq 1; then NEWVALUE="$NEWVALUE mdns6_minimal [NOTFOUND=return] $ITEM" else echo "Internal error when enabling." exit 1 fi else NEWVALUE="$NEWVALUE $ITEM" fi elif test "${ITEM::1}" == "[" -a "$DROPACTION" -eq 1; then DROPACTION=0 else NEWVALUE="$NEWVALUE $ITEM" DROPACTION=0 fi done if test "$FOUND_DNS" -ne 1; then echo "No dns service for hosts configuration in $NSSWITCH." exit 0 fi NEWVALUE=$(echo $NEWVALUE | sed "s/^\s*//;s/^\s*$//") if test "$BACKUP" -eq 1; then cp -a "$NSSWITCH" "${NSSWITCH}bak" fi sed -i "s/\(^\s*hosts:\s*\).*/\1$NEWVALUE/" "$NSSWITCH" fi ++++++ unaligned.diff ++++++ --- src/nss.c +++ src/nss.c @@ -620,7 +620,7 @@ #ifdef MDNS_MINIMAL /* Only query for 169.254.0.0/16 IPv4 in minimal mode */ - if ((af == AF_INET && ((ntohl(*(const uint32_t*) addr) & 0xFFFF0000UL) != 0xA9FE0000UL)) || + if ((af == AF_INET && !(((const uint8_t*) addr)[0] == 169 && (((const uint8_t*) addr)[1] == 254))) || (af == AF_INET6 && !(((const uint8_t*) addr)[0] == 0xFE && (((const uint8_t*) addr)[1] >> 6) == 2))) { *errnop = EINVAL; -- To unsubscribe, e-mail: opensuse-commit+unsubscr...@opensuse.org For additional commands, e-mail: opensuse-commit+h...@opensuse.org