Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/games/banner Drop setgid privs passed from dm(6).
details: https://anonhg.NetBSD.org/src/rev/4fe528e77b4a
branches: trunk
changeset: 474753:4fe528e77b4a
user: hubertf <hubertf%NetBSD.org@localhost>
date: Mon Jul 19 00:42:59 1999 +0000
description:
Drop setgid privs passed from dm(6).
Patch submitted in PR 5945 by Joseph S. Myers <jsm28%cam.ac.uk@localhost>
diffstat:
games/banner/banner.c | 7 +++++--
1 files changed, 5 insertions(+), 2 deletions(-)
diffs (28 lines):
diff -r ee645d163ad4 -r 4fe528e77b4a games/banner/banner.c
--- a/games/banner/banner.c Mon Jul 19 00:33:58 1999 +0000
+++ b/games/banner/banner.c Mon Jul 19 00:42:59 1999 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: banner.c,v 1.8 1998/09/14 09:30:57 hubertf Exp $ */
+/* $NetBSD: banner.c,v 1.9 1999/07/19 00:42:59 hubertf Exp $ */
/*
* Copyright (c) 1980, 1993, 1994
@@ -43,7 +43,7 @@
#if 0
static char sccsid[] = "@(#)banner.c 8.4 (Berkeley) 4/29/95";
#else
-__RCSID("$NetBSD: banner.c,v 1.8 1998/09/14 09:30:57 hubertf Exp $");
+__RCSID("$NetBSD: banner.c,v 1.9 1999/07/19 00:42:59 hubertf Exp $");
#endif
#endif /* not lint */
@@ -1039,6 +1039,9 @@
{
int ch;
+ /* revoke setgid privileges */
+ setregid(getgid(), getgid());
+
while ((ch = getopt(argc, argv, "w:td")) != -1)
switch (ch) {
case 'd':
Home |
Main Index |
Thread Index |
Old Index