Subject: misc/2532: usr/src created with wrong permissions/group
To: None <gnats-bugs@NetBSD.ORG>
From: Arne Henrik Juul <arnej@imf.unit.no>
List: netbsd-bugs
Date: 06/09/1996 04:38:15
>Number:         2532
>Category:       misc
>Synopsis:       usr/src created with wrong permissions/group
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    misc-bug-people (Misc Bug People)
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sat Jun  8 23:05:01 1996
>Last-Modified:
>Originator:     Arne H. Juul
>Organization:
	Norwegian University of Technology and Science
>Release:        1.2_ALPHA
>Environment:
	
System: NetBSD leon.imf.unit.no 1.2_ALPHA NetBSD 1.2_ALPHA (NIKITA) #5: Sat Jun 8 19:31:28 MET DST 1996 arnej@leon.imf.unit.no:/usr/src/sys/arch/i386/compile/NIKITA i386


>Description:
	
	While the "special" mtree file that is used in the security
	cron job wants the /usr/src directory to be specially treated
	(group writable for wsrc), 4.4BSD.dist (which creates this dir
	when installing systems) doesn't do anything special.
$ grep -1 usr/src /usr/src/etc/mtree/4.4BSD.dist
# ./usr/src
src
# ./usr/src
..
$ grep -1 usr/src /usr/src/etc/mtree/special
src		type=dir mode=0775 uname=root gname=wsrc ignore
..	#usr/src
..	#usr

>How-To-Repeat:
	Install the mtree files, run first 4.4BSD.dist then special
	a couple of times. Watch the permissions bounce back
	and forth.
>Fix:
	assuming "special" is correct and /usr/src should be writable
	by group "wsrc", apply patch:

--- /usr/src/etc/mtree/4.4BSD.dist	Sun May 26 08:13:17 1996
+++ /usr/src/etc/mtree/4.4BSD.dist.ahj	Wed Jun  5 08:55:05 1996
@@ -1298,7 +1298,7 @@
 ..
 
 # ./usr/src
-src
+src mode=0775 gname=wsrc
 # ./usr/src
 ..
 
>Audit-Trail:
>Unformatted: