Wed Jul 29 13:59:59 2009 UTC ()
when switching to the "icecast" uid/gid, drop root's supplementary
group memberships,
bump PKGREVISION
(drochner)
diff -r1.47 -r1.48 pkgsrc/audio/icecast/Makefile
diff -r1.17 -r1.18 pkgsrc/audio/icecast/distinfo
diff -r0 -r1.1 pkgsrc/audio/icecast/patches/patch-ad
--- pkgsrc/audio/icecast/Makefile 2008/11/08 21:13:27 1.47
+++ pkgsrc/audio/icecast/Makefile 2009/07/29 13:59:59 1.48
| @@ -1,18 +1,18 @@ | | | @@ -1,18 +1,18 @@ |
1 | # $NetBSD: Makefile,v 1.47 2008/11/08 21:13:27 bjs Exp $ | | 1 | # $NetBSD: Makefile,v 1.48 2009/07/29 13:59:59 drochner Exp $ |
2 | # | | 2 | # |
3 | | | 3 | |
4 | DISTNAME= icecast-2.3.2 | | 4 | DISTNAME= icecast-2.3.2 |
5 | PKGREVISION= 1 | | 5 | PKGREVISION= 2 |
6 | CATEGORIES= audio | | 6 | CATEGORIES= audio |
7 | MASTER_SITES= http://downloads.xiph.org/releases/icecast/ | | 7 | MASTER_SITES= http://downloads.xiph.org/releases/icecast/ |
8 | | | 8 | |
9 | MAINTAINER= kim@tac.nyc.ny.us | | 9 | MAINTAINER= kim@tac.nyc.ny.us |
10 | HOMEPAGE= http://www.icecast.org/ | | 10 | HOMEPAGE= http://www.icecast.org/ |
11 | COMMENT= Live streaming audio server | | 11 | COMMENT= Live streaming audio server |
12 | | | 12 | |
13 | PKG_DESTDIR_SUPPORT= user-destdir | | 13 | PKG_DESTDIR_SUPPORT= user-destdir |
14 | | | 14 | |
15 | USE_PKGLOCALEDIR= yes | | 15 | USE_PKGLOCALEDIR= yes |
16 | USE_LIBTOOL= yes | | 16 | USE_LIBTOOL= yes |
17 | GNU_CONFIGURE= yes | | 17 | GNU_CONFIGURE= yes |
18 | PTHREAD_AUTO_VARS= yes | | 18 | PTHREAD_AUTO_VARS= yes |
--- pkgsrc/audio/icecast/distinfo 2008/09/08 05:32:59 1.17
+++ pkgsrc/audio/icecast/distinfo 2009/07/29 13:59:59 1.18
| @@ -1,8 +1,9 @@ | | | @@ -1,8 +1,9 @@ |
1 | $NetBSD: distinfo,v 1.17 2008/09/08 05:32:59 dholland Exp $ | | 1 | $NetBSD: distinfo,v 1.18 2009/07/29 13:59:59 drochner Exp $ |
2 | | | 2 | |
3 | SHA1 (icecast-2.3.2.tar.gz) = a52b13505548c2eff2c64aab95a42dcafda11227 | | 3 | SHA1 (icecast-2.3.2.tar.gz) = a52b13505548c2eff2c64aab95a42dcafda11227 |
4 | RMD160 (icecast-2.3.2.tar.gz) = ec14553cce652fb80823316c9705f4cb6179cc2a | | 4 | RMD160 (icecast-2.3.2.tar.gz) = ec14553cce652fb80823316c9705f4cb6179cc2a |
5 | Size (icecast-2.3.2.tar.gz) = 1152319 bytes | | 5 | Size (icecast-2.3.2.tar.gz) = 1152319 bytes |
6 | SHA1 (patch-aa) = 2d85cabe25cf3860e42110eaf3fa5e2b1775e0cf | | 6 | SHA1 (patch-aa) = 2d85cabe25cf3860e42110eaf3fa5e2b1775e0cf |
7 | SHA1 (patch-ab) = 3b9ecb2caf222f6c08646d856419595f3585f70b | | 7 | SHA1 (patch-ab) = 3b9ecb2caf222f6c08646d856419595f3585f70b |
8 | SHA1 (patch-ac) = 5637f0cd10dc4b8d03e674b701bcb16f45339eaa | | 8 | SHA1 (patch-ac) = 5637f0cd10dc4b8d03e674b701bcb16f45339eaa |
| | | 9 | SHA1 (patch-ad) = 9b6388d99bae8239138689673dc26286323ae803 |
$NetBSD: patch-ad,v 1.1 2009/07/29 13:59:59 drochner Exp $
--- src/main.c.orig 2008-04-23 07:18:53.000000000 +0200
+++ src/main.c
@@ -398,6 +398,10 @@ static void _ch_root_uid_setup(void)
fprintf(stdout, "Changed groupid to %i.\n", (int)gid);
else
fprintf(stdout, "Error changing groupid: %s.\n", strerror(errno));
+ if(!setgroups(1, &gid))
+ fprintf(stdout, "Dropped root's group memberships.\n");
+ else
+ fprintf(stdout, "Error dropping group memberships.\n");
}
if(uid != -1) {