-
Notifications
You must be signed in to change notification settings - Fork 36
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
FL-3261: add ne iptuils that building with libressl. masked
- Loading branch information
Oleg Vinichenko
committed
Aug 29, 2016
1 parent
c512ad3
commit f10fbae
Showing
14 changed files
with
625 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,4 @@ | ||
DIST iputils-20160308.tar.gz 195348 SHA256 803d11b14af1bd3852c83111cc29e904bc3ca936c093dbb419d0671d3c9d964b SHA512 6b4d6e58ab8f1218f3ab52da695f252bd3e0004ffce755f2378b44fc3b4fbf9beb9beef51ff12f14348a07f6fe8525e64dba7f5d7b70997423d2c98c5ff7dde2 WHIRLPOOL 8a5691fdb70c6a9741adfc09206a4fac041616c6e81e9ef918435fed09c6085a35592eb72055dfbe2a237ab8ed1a018aa824968ff15ad842b923e28743f5cdbf | ||
DIST iputils-s20121221-manpages.tar.bz2 23778 SHA256 6fc7ed7d281b7a2ee00e4f75e5465c90498c685bcc988afdff74db4eaa736d1c SHA512 006be62e61bf1555c99dbd5aac270cbd8d1074a3016fdde3aeed47e5c9b1acd326aa30a596c532d6688827f7f61966a6e3141eaa3b6f4f943eb21ac227282d8c WHIRLPOOL da0ccb577c4b2189553419df2c093404752fb2865eb3e0bfececfc242d930ceb44f96b32d945cfdd0c9ca060359651b2ec8479db5cc9220cda412dfeee5e910d | ||
DIST iputils-s20121221.tar.bz2 155344 SHA256 450f549fc5b620c23c5929aa6d54b7ddfc7ee1cb1e8efdc5e8bb21d8d0c5319f SHA512 693d240becd766c345c3af2053fc0699b9358e54d667d40738c21d731b70e779112d81476a220d8300ca54250120385414a13610d445996f95a90571047389f4 WHIRLPOOL 64529180eb4b8e2f7a60c18df7cac49e10a4b7702514252d418b16dcdc10a85ccb0a7f8beb51274cc9d708be2026c4c136e720986795fd39d314e4f9d5590ec9 | ||
DIST iputils-s20160308-manpages.tar.xz 22684 SHA256 e21ef842d2eb4fa21f64cb872101bc9f979d24127fb680247d4a95ffc94a3958 SHA512 fe55ee334f1a99c6d93f4d18d97666d307676ced77175b73139f888af8f4f0ddc0f1d0511ab71d234f57909def606bf5c3aede2db28a0f73eb5628b9c8e16cac WHIRLPOOL 2675551b615efdf54a77bcb1dbe22c89b1ae5cd783c7bf33c703b81f54239096c1a7e13e7c8d6abd8b4ed5b0cbbd6f3b59d4102279c8cfb6f0a0bf6e070aab93 |
74 changes: 74 additions & 0 deletions
74
net-misc/iputils/files/iputils-20121221-parallel-doc.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
From 4e322b85a12ba3ef5e8118724e3442b2ebb0f6d6 Mon Sep 17 00:00:00 2001 | ||
From: Mike Frysinger <vapier@gentoo.org> | ||
Date: Wed, 1 Aug 2012 11:43:34 -0400 | ||
Subject: [PATCH iputils] doc: fix parallel build of html/man pages | ||
|
||
The use of the same tempdir prevents building of these files in parallel. | ||
So build all of them in unique tempdirs so we can do them in parallel. | ||
|
||
Signed-off-by: Mike Frysinger <vapier@gentoo.org> | ||
--- | ||
doc/Makefile | 37 ++++++++++++++++++++++++------------- | ||
1 file changed, 24 insertions(+), 13 deletions(-) | ||
|
||
diff --git a/doc/Makefile b/doc/Makefile | ||
index 7ec4f1c..4f930a3 100644 | ||
--- a/doc/Makefile | ||
+++ b/doc/Makefile | ||
@@ -12,29 +12,40 @@ man: $(MANFILES) | ||
# lots of some strange temporary junk directories and files. | ||
# So, scope it to a temporary dir and clean all after each run. | ||
|
||
-$(HTMLFILES): index.db | ||
- @-rm -rf tmp.db2html | ||
- @mkdir tmp.db2html | ||
- @set -e; cd tmp.db2html; docbook2html ../$< ; mv *.html .. | ||
- @-rm -rf tmp.db2html | ||
+SETUP_TMPDIR = \ | ||
+ t="tmp.db2html.$@"; \ | ||
+ rm -rf $$t; \ | ||
+ mkdir $$t; \ | ||
+ cd $$t | ||
+CLEAN_TMPDIR = \ | ||
+ cd ..; \ | ||
+ rm -rf $$t | ||
+ | ||
+MAKE_HTML = \ | ||
+ @set -e; \ | ||
+ $(SETUP_TMPDIR); \ | ||
+ docbook2html ../$<; \ | ||
+ mv *.html ..; \ | ||
+ $(CLEAN_TMPDIR) | ||
|
||
+$(HTMLFILES): index.db | ||
+ $(MAKE_HTML) | ||
iputils.html: iputils.db | ||
- @-rm -rf tmp.db2html | ||
- @mkdir tmp.db2html | ||
- @set -e; cd tmp.db2html; docbook2html -u -o html ../$< ; mv html/$@ .. | ||
- @-rm -rf tmp.db2html | ||
+ $(MAKE_HTML) | ||
|
||
# docbook2man produces utterly ugly output and I did not find | ||
# any way to customize this but hacking backend perl script a little. | ||
# Well, hence... | ||
|
||
$(MANFILES): index.db | ||
- @-mkdir tmp.db2man | ||
- @set -e; cd tmp.db2man; nsgmls ../$< | sgmlspl ../docbook2man-spec.pl ; mv $@ .. | ||
- @-rm -rf tmp.db2man | ||
+ @set -e; \ | ||
+ $(SETUP_TMPDIR); \ | ||
+ nsgmls ../$< | sgmlspl ../docbook2man-spec.pl; \ | ||
+ mv $@ ..; \ | ||
+ $(CLEAN_TMPDIR) | ||
|
||
clean: | ||
- @rm -rf $(MANFILES) $(HTMLFILES) iputils.html tmp.db2html tmp.db2man | ||
+ @rm -rf $(MANFILES) $(HTMLFILES) iputils.html tmp.db2html* tmp.db2man* | ||
|
||
snapshot: | ||
@date "+%y%m%d" > snapshot.db | ||
-- | ||
2.3.5 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
https://bugs.gentoo.org/472592 | ||
|
||
From dd0aa192626f94d08e399fc2a743ee72c50853fb Mon Sep 17 00:00:00 2001 | ||
From: Mike Frysinger <vapier@gentoo.org> | ||
Date: Fri, 24 Apr 2015 20:41:31 -0400 | ||
Subject: [PATCH iputils] ping: fix -i number parsing in locales | ||
|
||
Always use #.# format for the -i flag even when the current locale uses | ||
a different separator. Locale de_DE which uses #,# normally. | ||
|
||
Simple testcase: | ||
$ make USE_IDN=1 | ||
$ LANG=de_DE.UTF8 ./ping -i 0.5 localhost | ||
|
||
Reported-by: Sergey Fionov <fionov@gmail.com> | ||
Signed-off-by: Mike Frysinger <vapier@gentoo.org> | ||
--- | ||
ping_common.c | 8 ++++++++ | ||
1 file changed, 8 insertions(+) | ||
|
||
diff --git a/ping_common.c b/ping_common.c | ||
index 62f53a6..0a37e09 100644 | ||
--- a/ping_common.c | ||
+++ b/ping_common.c | ||
@@ -269,9 +269,17 @@ void common_options(int ch) | ||
double dbl; | ||
char *ep; | ||
|
||
+#ifdef USE_IDN | ||
+ setlocale(LC_ALL, "C"); | ||
+#endif | ||
+ | ||
errno = 0; | ||
dbl = strtod(optarg, &ep); | ||
|
||
+#ifdef USE_IDN | ||
+ setlocale(LC_ALL, ""); | ||
+#endif | ||
+ | ||
if (errno || *ep != '\0' || | ||
!finite(dbl) || dbl < 0.0 || dbl >= (double)INT_MAX / 1000 - 1.0) { | ||
fprintf(stderr, "ping: bad timing interval\n"); | ||
-- | ||
2.3.5 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
From d81a44625b04d487c895473aa77af13420b7afdd Mon Sep 17 00:00:00 2001 | ||
From: YOSHIFUJI Hideaki <hideaki.yoshifuji@miraclelinux.com> | ||
Date: Thu, 19 Jun 2014 17:25:49 +0900 | ||
Subject: [PATCH iputils] tftpd: Exit if setuid()/setgid() failed. | ||
|
||
Signed-off-by: YOSHIFUJI Hideaki <hideaki.yoshifuji@miraclelinux.com> | ||
--- | ||
tftpd.c | 10 ++++++++-- | ||
1 file changed, 8 insertions(+), 2 deletions(-) | ||
|
||
diff --git a/tftpd.c b/tftpd.c | ||
index 2a39ec4..e3af2f4 100644 | ||
--- a/tftpd.c | ||
+++ b/tftpd.c | ||
@@ -111,8 +111,14 @@ int main(int ac, char **av) | ||
|
||
/* Sanity. If parent forgot to setuid() on us. */ | ||
if (geteuid() == 0) { | ||
- setgid(65534); | ||
- setuid(65534); | ||
+ if (setgid(65534)) { | ||
+ syslog(LOG_ERR, "setgid"); | ||
+ exit(1); | ||
+ } | ||
+ if (setuid(65534)) { | ||
+ syslog(LOG_ERR, "setuid"); | ||
+ exit(1); | ||
+ } | ||
} | ||
|
||
ac--; av++; | ||
-- | ||
2.3.5 | ||
|
38 changes: 38 additions & 0 deletions
38
net-misc/iputils/files/iputils-20121221-tftpd-syslog.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
From e88ed3752872d7c7ca37d95eb4d434ca4d3c4eae Mon Sep 17 00:00:00 2001 | ||
From: Mike Frysinger <vapier@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 <vapier@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 | ||
|
28 changes: 28 additions & 0 deletions
28
net-misc/iputils/files/iputils-20150815-defines_and_libs.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
From ba739daf98450fe725569724eefc64a2afdeb909 Mon Sep 17 00:00:00 2001 | ||
From: =?UTF-8?q?Pavel=20=C5=A0imerda?= <psimerda@redhat.com> | ||
Date: Thu, 20 Aug 2015 16:16:14 +0200 | ||
Subject: [PATCH] ping: fix defines and libs in Makefile | ||
|
||
--- | ||
Makefile | 8 ++++---- | ||
1 file changed, 4 insertions(+), 4 deletions(-) | ||
|
||
diff --git a/Makefile b/Makefile | ||
index 9b0b70f..4eea516 100644 | ||
--- a/Makefile | ||
+++ b/Makefile | ||
@@ -153,10 +153,10 @@ DEF_clockdiff = $(DEF_CAP) | ||
LIB_clockdiff = $(LIB_CAP) | ||
|
||
# ping / ping6 | ||
-DEF_ping_common = $(DEF_CAP) $(DEF_IDN) | ||
-DEF_ping6_common = $(DEF_CAP) $(DEF_IDN) | ||
-DEF_ping = $(DEF_CAP) $(DEF_IDN) $(DEF_WITHOUT_IFADDRS) | ||
-LIB_ping = $(LIB_CAP) $(LIB_IDN) $(LIB_RESOLV) | ||
+DEF_ping = $(DEF_CAP) $(DEF_IDN) $(DEF_CRYPTO) $(DEF_WITHOUT_IFADDRS) | ||
+DEF_ping_common = $(DEF_ping) | ||
+DEF_ping6_common = $(DEF_ping) | ||
+LIB_ping = $(LIB_CAP) $(LIB_IDN) $(LIB_CRYPTO) $(LIB_RESOLV) | ||
|
||
ping: ping_common.o ping6_common.o | ||
ping.o ping_common.o ping6_common.o: ping.h in6_flowlabel.h |
70 changes: 70 additions & 0 deletions
70
net-misc/iputils/files/iputils-20150815-handle_single_protocol_system.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
From 9fd870a4bac0b8b2070c38452f378ef1eb7d460a Mon Sep 17 00:00:00 2001 | ||
From: =?UTF-8?q?Pavel=20=C5=A0imerda?= <psimerda@redhat.com> | ||
Date: Fri, 21 Aug 2015 00:55:56 +0200 | ||
Subject: [PATCH] ping: handle single protocol systems | ||
|
||
--- | ||
ping.c | 28 ++++++++++++++++++---------- | ||
1 file changed, 18 insertions(+), 10 deletions(-) | ||
|
||
diff --git a/ping.c b/ping.c | ||
index ec9708e..95a10a7 100644 | ||
--- a/ping.c | ||
+++ b/ping.c | ||
@@ -110,26 +110,26 @@ static struct sockaddr_in source = { .sin_family = AF_INET }; | ||
static char *device; | ||
static int pmtudisc = -1; | ||
|
||
-static void create_socket(socket_st *sock, int family, int socktype, int protocol) | ||
+static void create_socket(socket_st *sock, int family, int socktype, int protocol, int requisite) | ||
{ | ||
errno = 0; | ||
|
||
sock->fd = socket(family, socktype, protocol); | ||
|
||
- /* Fallback to raw socket when ping socket failed */ | ||
- if (sock->fd == -1 && socktype == SOCK_DGRAM) { | ||
+ /* Attempt creating a raw socket when ping socket failed */ | ||
+ if (sock->fd == -1 && errno != EAFNOSUPPORT && socktype == SOCK_DGRAM) { | ||
if (options & F_VERBOSE) | ||
fprintf(stderr, "ping: socket: %s, attempting raw socket...\n", strerror(errno)); | ||
- create_socket(sock, family, SOCK_RAW, protocol); | ||
+ create_socket(sock, family, SOCK_RAW, protocol, requisite); | ||
return; | ||
} | ||
|
||
if (sock->fd == -1) { | ||
- if (socktype == SOCK_RAW) | ||
- fprintf(stderr, "ping: socket: %s (raw socket required by specified options).\n", strerror(errno)); | ||
- else | ||
+ if (requisite || errno != EAFNOSUPPORT || options & F_VERBOSE) | ||
fprintf(stderr, "ping: socket: %s\n", strerror(errno)); | ||
- exit(2); | ||
+ if (requisite) | ||
+ exit(2); | ||
+ return; | ||
} | ||
|
||
sock->socktype = socktype; | ||
@@ -442,11 +442,19 @@ main(int argc, char **argv) | ||
/* Create sockets */ | ||
enable_capability_raw(); | ||
if (hints.ai_family != AF_INET6) | ||
- create_socket(&sock4, AF_INET, hints.ai_socktype, IPPROTO_ICMP); | ||
+ create_socket(&sock4, AF_INET, hints.ai_socktype, IPPROTO_ICMP, hints.ai_family == AF_INET); | ||
if (hints.ai_family != AF_INET) | ||
- create_socket(&sock6, AF_INET6, hints.ai_socktype, IPPROTO_ICMPV6); | ||
+ create_socket(&sock6, AF_INET6, hints.ai_socktype, IPPROTO_ICMPV6, sock4.fd == -1); | ||
disable_capability_raw(); | ||
|
||
+ /* Limit address family on single-protocol systems */ | ||
+ if (hints.ai_family == AF_UNSPEC) { | ||
+ if (sock4.fd == -1) | ||
+ hints.ai_family = AF_INET6; | ||
+ else if (sock6.fd == -1) | ||
+ hints.ai_family = AF_INET; | ||
+ } | ||
+ | ||
/* Set socket options */ | ||
if (settos) | ||
set_socket_option(&sock4, IPPROTO_IP, IP_TOS, &settos, sizeof settos); |
11 changes: 11 additions & 0 deletions
11
net-misc/iputils/files/iputils-20150815-nonroot-floodping.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
--- iputils-s20150815/ping.h | ||
+++ iputils-s20150815/ping.h | ||
@@ -61,7 +61,7 @@ | ||
|
||
#define MAXWAIT 10 /* max seconds to wait for response */ | ||
#define MININTERVAL 10 /* Minimal interpacket gap */ | ||
-#define MINUSERINTERVAL 200 /* Minimal allowed interval for non-root */ | ||
+#define MINUSERINTERVAL 0 /* Minimal allowed interval for non-root */ | ||
|
||
#define SCHINT(a) (((a) <= MININTERVAL) ? MININTERVAL : (a)) | ||
|
Oops, something went wrong.