Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/netbsd-3]: src/dist/ntp/ntpd Pull up revision 1.8 (requested by elad in ...



details:   https://anonhg.NetBSD.org/src/rev/77bf7fcd68ca
branches:  netbsd-3
changeset: 577346:77bf7fcd68ca
user:      jdc <jdc%NetBSD.org@localhost>
date:      Fri Oct 14 06:53:34 2005 +0000

description:
Pull up revision 1.8 (requested by elad in ticket #889):

Use group-id from ``gr'' and not ``pw''.

Fixes security issue addressed by CAN-2005-2496.
Thanks to Adrian Portelli for notifying me about this.

diffstat:

 dist/ntp/ntpd/ntpd.c |  4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diffs (18 lines):

diff -r abafce56213c -r 77bf7fcd68ca dist/ntp/ntpd/ntpd.c
--- a/dist/ntp/ntpd/ntpd.c      Wed Oct 12 00:43:25 2005 +0000
+++ b/dist/ntp/ntpd/ntpd.c      Fri Oct 14 06:53:34 2005 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ntpd.c,v 1.6.2.1 2005/04/07 11:22:04 tron Exp $        */
+/*     $NetBSD: ntpd.c,v 1.6.2.2 2005/10/14 06:53:34 jdc Exp $ */
 
 /*
  * ntpd.c - main program for the fixed point NTP daemon
@@ -865,7 +865,7 @@
                } else {
 getgroup:      
                        if ((gr = getgrnam(group)) != NULL) {
-                               sw_gid = pw->pw_gid;
+                               sw_gid = gr->gr_gid;
                        } else {
                                errno = 0;
                                msyslog(LOG_ERR, "Cannot find group `%s'", group);



Home | Main Index | Thread Index | Old Index