Accepting request 24485 from network:utilities

Copy from network:utilities/iproute2 based on submit request 24485 from user msmeissn

OBS-URL: https://build.opensuse.org/request/show/24485
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/iproute2?expand=0&rev=26
This commit is contained in:
OBS User autobuild 2009-11-16 11:00:45 +00:00 committed by Git OBS Bridge
parent 881b4f3214
commit e90015251e
4 changed files with 20 additions and 18 deletions

View File

@ -1,12 +1,10 @@
Index: ip/ipaddress.c --- ip/ipaddress.c 2009-03-24 22:40:54.000000000 +0000
=================================================================== +++ ip/ipaddress.c 2009-11-11 09:30:07.000000000 +0000
--- ip/ipaddress.c.orig @@ -692,6 +692,12 @@
+++ ip/ipaddress.c
@@ -589,6 +589,12 @@
if (flush) { if (flush) {
int round = 0; int round = 0;
char flushb[4096-512]; char flushb[4096-512];
+ uid_t uid = getuid(); + uid_t uid = geteuid();
+ +
+ if(uid) { + if(uid) {
+ fprintf(stderr, "Not sufficient rights to flush\n"); + fprintf(stderr, "Not sufficient rights to flush\n");
@ -15,20 +13,18 @@ Index: ip/ipaddress.c
filter.flushb = flushb; filter.flushb = flushb;
filter.flushp = 0; filter.flushp = 0;
Index: ip/iproute.c --- ip/iproute.c 2009-11-11 09:30:07.000000000 +0000
=================================================================== +++ ip/iproute.c 2009-11-11 09:35:23.000000000 +0000
--- ip/iproute.c.orig @@ -1212,6 +1212,12 @@
+++ ip/iproute.c
@@ -1153,6 +1153,12 @@
int round = 0; int round = 0;
char flushb[4096-512]; char flushb[4096-512];
time_t start = time(0); time_t start = time(0);
+ uid_t uid = getuid(); + uid_t uid = geteuid();
+ +
+ if(uid) { + if(uid) {
+ fprintf(stderr, "Not sufficient rights to flush\n"); + fprintf(stderr, "Not sufficient rights to flush\n");
+ exit(EXIT_FAILURE); + exit(EXIT_FAILURE);
+ } + }
if (filter.tb == -1) { if (filter.cloned) {
if (do_ipv6 != AF_INET6) { if (do_ipv6 != AF_INET6) {

View File

@ -1,8 +1,8 @@
--- tc/m_skbedit.c 2009-01-27 10:42:39.000000000 +0000 --- tc/m_skbedit.c 2009-03-24 22:40:54.000000000 +0000
+++ tc/m_skbedit.c 2009-01-27 10:45:09.000000000 +0000 +++ tc/m_skbedit.c 2009-11-11 09:42:09.000000000 +0000
@@ -57,6 +57,8 @@ @@ -57,6 +57,8 @@
__u16 queue_mapping;
__u32 flags = 0, priority; __u32 flags = 0, priority;
struct tc_skbedit sel = { 0 };
+ memset(&sel, 0, sizeof(struct tc_skbedit)); + memset(&sel, 0, sizeof(struct tc_skbedit));
+ +

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Wed Nov 11 10:19:45 CET 2009 - ms@suse.de
- check effective UID instead of real UID in the flush
permissions coding (bnc #554419)
------------------------------------------------------------------- -------------------------------------------------------------------
Fri Oct 9 14:17:41 CEST 2009 - ms@suse.de Fri Oct 9 14:17:41 CEST 2009 - ms@suse.de

View File

@ -25,7 +25,7 @@ Group: Productivity/Networking/Routing
Provides: iproute Provides: iproute
AutoReqProv: on AutoReqProv: on
Version: 2.6.29.1 Version: 2.6.29.1
Release: 5 Release: 6
%define rversion 2.6.29-1 %define rversion 2.6.29-1
Summary: Advanced Routing Summary: Advanced Routing
Url: http://developer.osdl.org/dev/iproute2/ Url: http://developer.osdl.org/dev/iproute2/