From owner-p4-projects@FreeBSD.ORG Wed Nov 26 13:44:23 2008 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id D87071065710; Wed, 26 Nov 2008 13:44:22 +0000 (UTC) Delivered-To: perforce@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9AB731065708 for ; Wed, 26 Nov 2008 13:44:22 +0000 (UTC) (envelope-from trasz@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id 7DAF98FC0C for ; Wed, 26 Nov 2008 13:44:22 +0000 (UTC) (envelope-from trasz@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.3/8.14.3) with ESMTP id mAQDiM2O040843 for ; Wed, 26 Nov 2008 13:44:22 GMT (envelope-from trasz@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.14.3/8.14.3/Submit) id mAQDiMZF040841 for perforce@freebsd.org; Wed, 26 Nov 2008 13:44:22 GMT (envelope-from trasz@freebsd.org) Date: Wed, 26 Nov 2008 13:44:22 GMT Message-Id: <200811261344.mAQDiMZF040841@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to trasz@freebsd.org using -f From: Edward Tomasz Napierala To: Perforce Change Reviews Cc: Subject: PERFORCE change 153605 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 26 Nov 2008 13:44:23 -0000 http://perforce.freebsd.org/chv.cgi?CH=153605 Change 153605 by trasz@trasz_victim7 on 2008/11/26 13:43:55 Make sure we really require WRITE_OWNER in order to change owner. Affected files ... .. //depot/projects/soc2008/trasz_nfs4acl/tools/regression/fstest/tests/granular/04.t#2 edit Differences ... ==== //depot/projects/soc2008/trasz_nfs4acl/tools/regression/fstest/tests/granular/04.t#2 (text+ko) ==== @@ -5,7 +5,7 @@ dir=`dirname $0` . ${dir}/../misc.sh -echo "1..44" +echo "1..52" n0=`namegen` n1=`namegen` @@ -17,16 +17,24 @@ # ACL_WRITE_OWNER permits to set gid to our own only. expect 0 create ${n0} 0644 +expect 0,0 lstat ${n0} uid,gid +expect EPERM -u 65534 -g 65532,65531 chown ${n0} -1 65532 +expect 0,0 lstat ${n0} uid,gid expect 0 prependacl ${n0} user:65534:write_owner::allow -expect 0,0 lstat ${n0} uid,gid expect EPERM -u 65534 -g 65532,65531 chown ${n0} -1 65530 expect 0,0 lstat ${n0} uid,gid expect 0 -u 65534 -g 65532,65531 chown ${n0} -1 65532 expect 0,65532 lstat ${n0} uid,gid +expect 0 unlink ${n0} # ACL_WRITE_OWNER permits to set uid to our own only. +expect 0 create ${n0} 0644 +expect 0,0 lstat ${n0} uid,gid +expect EPERM -u 65534 -g 65532,65531 chown ${n0} 65534 65531 +expect 0,0 lstat ${n0} uid,gid +expect 0 prependacl ${n0} user:65534:write_owner::allow expect EPERM -u 65534 -g 65532,65531 chown ${n0} 65530 65531 -expect 0,65532 lstat ${n0} uid,gid +expect 0,0 lstat ${n0} uid,gid expect 0 -u 65534 -g 65532,65531 chown ${n0} 65534 65531 expect 65534,65531 lstat ${n0} uid,gid expect 0 unlink ${n0}