Re: [PATCH] t1304: improve setfacl prerequisite setup

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

 



On Wed, Jun 06, 2012 at 09:58:53AM -0700, Junio C Hamano wrote:

> > +test_expect_success 'checking for a working acl setup' '
> > +	if setfacl -m d:m:rwx -m u:root:rwx . &&
> > +	   getfacl . | grep user:root:rwx &&
> > +	   touch should-have-readable-acl &&
> > +	   getfacl should-have-readable-acl | egrep "mask::?rw-"
> 
> At this point of the test, I do not think there is anything that can
> cause this check to be fooled by a user whose name is 'mask', but
> please make it a habit to anchor the pattern at the left.  The tests
> done in check_perms_and_acl do risk getting fooled by a user whose
> name is 'mask', and need to be updated, I think, but that is a
> separate issue.

I intentionally did not anchor it because the tests themselves did not,
and I worried that that there was some subtle portability issue there
(especially because of the magic "let there be two colons" part of the
pattern).

If it was just sloppiness in the original test, then yes, they should
all be fixed.

-Peff
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]