vapier      15/04/25 00:09:50

  Added:                iputils-99999999-tftpd-syslog.patch
                        iputils-99999999-openssl.patch
  Removed:              iputils-20100418-makefile.patch
                        iputils-20100418-aliasing.patch
                        iputils-20071127-infiniband.patch
                        iputils-20071127-kernel-ifaddr.patch
                        iputils-20100418-proper-libs.patch
                        iputils-20100418-printf-size.patch
                        iputils-20100418-openssl.patch
                        iputils-20101006-owl-pingsock.diff
                        iputils-20070202-idn.patch
  Log:
  Update patches against latest git.
  
  (Portage version: 2.2.18/cvs/Linux x86_64, signed Manifest commit with key 
D2E96200)

Revision  Changes    Path
1.1                  net-misc/iputils/files/iputils-99999999-tftpd-syslog.patch

file : 
http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-misc/iputils/files/iputils-99999999-tftpd-syslog.patch?rev=1.1&view=markup
plain: 
http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-misc/iputils/files/iputils-99999999-tftpd-syslog.patch?rev=1.1&content-type=text/plain

Index: iputils-99999999-tftpd-syslog.patch
===================================================================
>From e88ed3752872d7c7ca37d95eb4d434ca4d3c4eae Mon Sep 17 00:00:00 2001
From: Mike Frysinger <vap...@gentoo.org>
Date: Sat, 19 Apr 2014 10:39:39 -0400
Subject: [PATCH iputils] tftpd: fix syslog setup

Commit d81a44625b04d487c895473aa77af13420b7afdd added support for checking
the set*id calls, but would call syslog() before it had called openlog().
Move the call up earlier to fix that.

Signed-off-by: Mike Frysinger <vap...@gentoo.org>
---
 tftpd.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/tftpd.c b/tftpd.c
index e3af2f4..7ddc8eb 100644
--- a/tftpd.c
+++ b/tftpd.c
@@ -109,6 +109,8 @@ int main(int ac, char **av)
        register int n = 0;
        int on = 1;
 
+       openlog("tftpd", LOG_PID, LOG_DAEMON);
+
        /* Sanity. If parent forgot to setuid() on us. */
        if (geteuid() == 0) {
                if (setgid(65534)) {
@@ -125,7 +127,6 @@ int main(int ac, char **av)
        while (ac-- > 0 && n < MAXARG)
                dirs[n++] = *av++;
 
-       openlog("tftpd", LOG_PID, LOG_DAEMON);
        if (ioctl(0, FIONBIO, &on) < 0) {
                syslog(LOG_ERR, "ioctl(FIONBIO): %m\n");
                exit(1);
-- 
2.3.5




1.1                  net-misc/iputils/files/iputils-99999999-openssl.patch

file : 
http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-misc/iputils/files/iputils-99999999-openssl.patch?rev=1.1&view=markup
plain: 
http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-misc/iputils/files/iputils-99999999-openssl.patch?rev=1.1&content-type=text/plain

Index: iputils-99999999-openssl.patch
===================================================================
>From 321d64b9f94653322e678e34ac214ddb73a71db8 Mon Sep 17 00:00:00 2001
From: Mike Frysinger <vap...@gentoo.org>
Date: Thu, 24 Jan 2013 23:32:39 -0500
Subject: [PATCH iputils] ping6: allow disabling of openssl support

Signed-off-by: Mike Frysinger <vap...@gentoo.org>
---
 Makefile         |  5 ++++-
 iputils_md5dig.h |  4 +++-
 ping6.c          | 10 ++++++++++
 3 files changed, 17 insertions(+), 2 deletions(-)

diff --git a/Makefile b/Makefile
index 54e5a6d..7147f08 100644
--- a/Makefile
+++ b/Makefile
@@ -36,7 +36,7 @@ ARPING_DEFAULT_DEVICE=
 
 # Libgcrypt (for MD5) for ping6 [yes|no|static]
 USE_GCRYPT=yes
-# Crypto library for ping6 [shared|static]
+# Crypto library for ping6 [shared|static|no]
 USE_CRYPTO=shared
 # Resolv library for ping6 [yes|static]
 USE_RESOLV=yes
@@ -63,7 +63,10 @@ ifneq ($(USE_GCRYPT),no)
        LIB_CRYPTO = $(call FUNC_LIB,$(USE_GCRYPT),$(LDFLAG_GCRYPT))
        DEF_CRYPTO = -DUSE_GCRYPT
 else
+ifneq ($(USE_CRYPTO),no)
        LIB_CRYPTO = $(call FUNC_LIB,$(USE_CRYPTO),$(LDFLAG_CRYPTO))
+       DEF_CRYPTO = -DUSE_OPENSSL
+endif
 endif
 
 # USE_RESOLV: LIB_RESOLV
diff --git a/iputils_md5dig.h b/iputils_md5dig.h
index 4cec866..d6c4d46 100644
--- a/iputils_md5dig.h
+++ b/iputils_md5dig.h
@@ -5,8 +5,10 @@
 # include <stdlib.h>
 # include <gcrypt.h>
 # define IPUTILS_MD5DIG_LEN    16
-#else
+# define USE_CRYPTO
+#elif defined(USE_OPENSSL)
 # include <openssl/md5.h>
+# define USE_CRYPTO
 #endif
 
 #ifdef USE_GCRYPT
diff --git a/ping6.c b/ping6.c
index 7085f31..7b7c1af 100644
--- a/ping6.c
+++ b/ping6.c
@@ -324,6 +324,7 @@ static void niquery_init_nonce(void)
 #if !PING6_NONCE_MEMORY
 static int niquery_nonce(__u8 *nonce, int fill)
 {
+# ifdef USE_CRYPTO
        static __u8 digest[MD5_DIGEST_LENGTH];
        static int seq = -1;
 
@@ -346,6 +347,10 @@ static int niquery_nonce(__u8 *nonce, int fill)
                        return -1;
                return ntohsp((__u16 *)nonce);
        }
+# else
+       fprintf(stderr, "ping6: function not available; crypto disabled\n");
+       exit(3);
+# endif
 }
 #endif
 
@@ -500,6 +505,7 @@ static int niquery_option_subject_addr_handler(int index, 
const char *arg)
 
 static int niquery_option_subject_name_handler(int index, const char *arg)
 {
+#ifdef USE_CRYPTO
        static char nigroup_buf[INET6_ADDRSTRLEN + 1 + IFNAMSIZ];
        unsigned char *dnptrs[2], **dpp, **lastdnptr;
        int n;
@@ -625,6 +631,10 @@ errexit:
        free(idn);
        free(name);
        exit(1);
+#else
+       fprintf(stderr, "ping6: function not available; crypto disabled\n");
+       exit(3);
+#endif
 }
 
 int niquery_option_help_handler(int index, const char *arg)
-- 
2.3.5





Reply via email to