diff options
author | Robert Peichaer <rpe@cvs.openbsd.org> | 2016-11-25 21:13:59 +0000 |
---|---|---|
committer | Robert Peichaer <rpe@cvs.openbsd.org> | 2016-11-25 21:13:59 +0000 |
commit | ddd3ce536710674455690f45130d5337d7f33d78 (patch) | |
tree | 7b40be58ad6ee225538a97f06485ff715c2d615c | |
parent | d1aae231af94c862dbb24d36f06042015f1210b5 (diff) |
The build systems now uses the user build and the group wobj.
Add them to bsd.rd and set the ownership and permissions of
/usr/obj and /usr/xobj accordingly.
feedback and OK tb@
Looks good deraadt@
-rw-r--r-- | distrib/miniroot/group | 1 | ||||
-rw-r--r-- | distrib/miniroot/install.sub | 16 | ||||
-rw-r--r-- | distrib/miniroot/master.passwd | 1 |
3 files changed, 11 insertions, 7 deletions
diff --git a/distrib/miniroot/group b/distrib/miniroot/group index 95a445f734d..ca0748802d2 100644 --- a/distrib/miniroot/group +++ b/distrib/miniroot/group @@ -6,6 +6,7 @@ tty:*:4:root operator:*:5:root bin:*:7: wsrc:*:9: +wobj:*:21: _ping:*:51: _shadow:*:65: _dhcp:*:77: diff --git a/distrib/miniroot/install.sub b/distrib/miniroot/install.sub index b995f18ccd9..749edadf123 100644 --- a/distrib/miniroot/install.sub +++ b/distrib/miniroot/install.sub @@ -1,5 +1,5 @@ #!/bin/ksh -# $OpenBSD: install.sub,v 1.932 2016/11/24 14:35:43 krw Exp $ +# $OpenBSD: install.sub,v 1.933 2016/11/25 21:13:58 rpe Exp $ # # Copyright (c) 1997-2015 Todd Miller, Theo de Raadt, Ken Westerback # Copyright (c) 2015, Robert Peichaer <rpe@openbsd.org> @@ -2422,13 +2422,15 @@ finish_up() { rm -f /mnt/var/run/ld.so.hints # Conditionally create /usr/{src,obj,xobj} directories and set - # proper ownership (root:wsrc) and permissions during install. + # proper ownership and permissions during install. if [[ $MODE == install ]]; then - for _d in /mnt/usr/{obj,src,xobj}; do - mkdir -p $_d - chmod 775 $_d - chown root:wsrc $_d - done + mkdir -p /mnt/usr/{src,{,x}obj} && ( + cd /mnt/usr + chmod 770 {,x}obj + chown build:wobj {,x}obj + chmod 775 src + chown root:wsrc src + ) fi [[ -x /mnt/$MODE.site ]] && chroot /mnt /$MODE.site diff --git a/distrib/miniroot/master.passwd b/distrib/miniroot/master.passwd index 94dc0bbc595..a2b3d08c6a2 100644 --- a/distrib/miniroot/master.passwd +++ b/distrib/miniroot/master.passwd @@ -2,6 +2,7 @@ root::0:0:daemon:0:0:Charlie &:/root:/bin/ksh daemon:*:1:1::0:0:The devil himself:/root:/sbin/nologin operator:*:2:5::0:0:System &:/operator:/sbin/nologin bin:*:3:7::0:0:Binaries Commands and Source:/:/sbin/nologin +build:*:21:21::0:0:base and xenocara build:/var/empty:/bin/ksh _ping:*:51:51::0:0:ping privdrop user:/var/empty:/sbin/nologin _dhcp:*:77:77::0:0:DHCP programs:/var/empty:/sbin/nologin _sndio:*:99:99::0:0:sndio privsep:/var/empty:/sbin/nologin |