From udo@iml.fhg.de  Wed Sep  6 00:30:12 2000
Return-Path: <udo@iml.fhg.de>
Received: from scan1.fhg.de (scan1.fhg.de [153.96.1.35])
	by hub.freebsd.org (Postfix) with ESMTP id 88AD237B424
	for <FreeBSD-gnats-submit@freebsd.org>; Wed,  6 Sep 2000 00:30:11 -0700 (PDT)
Received: from scan1.fhg.de (localhost [127.0.0.1])
	by scan1.fhg.de (8.9.3/8.9.3) with ESMTP id JAA14517
	for <FreeBSD-gnats-submit@freebsd.org>; Wed, 6 Sep 2000 09:30:09 +0200 (MET DST)
Received: from iml2.iml.fhg.de (iml2.iml.fhg.de [153.96.188.3])
	by scan1.fhg.de (8.9.3/8.9.3) with ESMTP id JAA14511
	for <FreeBSD-gnats-submit@freebsd.org>; Wed, 6 Sep 2000 09:30:09 +0200 (MET DST)
Received: from antivirus.iml.fhg.de (antivirus.iml.fhg.de [153.96.189.119])
	by iml2.iml.fhg.de (8.9.3/8.9.3) with ESMTP id JAA28867
	for <FreeBSD-gnats-submit@freebsd.org>; Wed, 6 Sep 2000 09:30:08 +0200 (MET DST)
Received: (from udo@localhost)
	by antivirus.iml.fhg.de (8.11.0/8.11.0) id e867U6734280;
	Wed, 6 Sep 2000 09:30:06 +0200 (CEST)
	(envelope-from udo)
Message-Id: <200009060730.e867U6734280@antivirus.iml.fhg.de>
Date: Wed, 6 Sep 2000 09:30:06 +0200 (CEST)
From: Udo Erdelhoff <udo@iml.fhg.de>
To: FreeBSD-gnats-submit@freebsd.org
Subject: chkgrp vs group(5) inconsistency
X-Send-Pr-Version: 3.2

>Number:         21074
>Category:       bin
>Synopsis:       chkgrp vs group(5) inconsistency
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Sep 06 00:40:03 PDT 2000
>Closed-Date:    Tue Dec 03 10:38:23 PST 2002
>Last-Modified:  Tue Dec 03 10:38:23 PST 2002
>Originator:     Udo Erdelhoff
>Release:        FreeBSD 4.1-STABLE i386
>Organization:
Fraunhofer IML, Dortmund
>Environment:

4.1-stable, last cvsup 05-SEP-2000

>Description:

group(5) contains the following information
``YP/NIS INTERACTION
     The /etc/group file can be configured to enable the YP/NIS group
     database.  An entry whose name field consists of a plus sign (`+') fol-
     lowed by a group name, will be replaced internally to the C library with
     the YP/NIS group entry for the named group.  An entry whose name field
     consists of a single plus sign with no group name following, will be re-
     placed with the entire YP/NIS ``group.byname'' map.''

My /etc/group contains an entry that consists of a single plus sign and
things work as expected (i.e. the whole YP/NIS map is imported). grpchk
doesn't like this entry at all:
chkgrp: /etc/group: line 23: missing field(s)

>How-To-Repeat:

Add a line with a single plus sign to the end of your /etc/groups file and
run chkgroup.

>Fix:

chkgrp should be changed to accept NIS entries. Until then, the problem
should be mentioned in chkgrp(8):

--- chkgrp.8.orig       Wed Sep  6 09:21:22 2000
+++ chkgrp.8    Wed Sep  6 09:29:22 2000
@@ -82,3 +82,8 @@
 .Sh BUGS
 Should check fields more thoroughly for allowed/disallowed
 characters, and the range of the group ID.
+The
+.Nm
+utility will report errors for valid NIS-related entries,
+especially lines containing a single plus character
+.Po import whole map Pc .



>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->davidn 
Responsible-Changed-By: sheldonh 
Responsible-Changed-When: Wed Sep 6 04:17:52 PDT 2000 
Responsible-Changed-Why:  
Let's see if we can get Mr Nugent to take a look at this. :-) 

http://www.freebsd.org/cgi/query-pr.cgi?pr=21074 
State-Changed-From-To: open->closed 
State-Changed-By: ru 
State-Changed-When: Tue Dec 3 10:03:30 PST 2002 
State-Changed-Why:  
chkgrp(8) is not lying to you; the correct NIS group(5) entry 
might look like this: 

+:*:: 

Please re-read the group(5) manpage, which says, in particular: 

: The file </etc/group> consists of newline separated ASCII 
: records, one per group, containing four colon `:' separated 
: fields.  These fields are as follows: 
:   group     Name of the group. 
:   passwd    Group's encrypted password. 
:   gid       The group's decimal ID. 
:   member    Group members. 

And later on: 

: An entry whose name field consists of a single plus sign 
^^^^^^^^^^^^^^^^ 
: with no group name following, will be replaced with the 
: entire YP/NIS ``group.byname'' map. 

But this certainly does not preclude the other fields from 
being filled in (with something). 


Responsible-Changed-From-To: davidn->freebsd-bugs 
Responsible-Changed-By: ru 
Responsible-Changed-When: Tue Dec 3 10:03:30 PST 2002 
Responsible-Changed-Why:  

http://www.freebsd.org/cgi/query-pr.cgi?pr=21074 
>Unformatted:
