[illumos-Advocates] RTI 948 chmod(1M) is not -R friendly when doing ACLs

Gordon Ross gordon.w.ross at gmail.com
Wed May 11 20:55:10 PDT 2011


Could you  please add a test case with "chmod -fR" also?
(add a test using the "-f" option).  Otherwise looks good.

Thanks,
Gordon

On Wed, May 11, 2011 at 7:59 PM, Yuri Pankov <yuri.pankov at gmail.com> wrote:
> Hi,
>
> illumos:yuri:~/ws/948-chmod-r-acl$ hg outgoing -v ssh://anonhg@hg.illumos.org/illumos-gate
> running ssh anonhg at hg.illumos.org "hg -R illumos-gate serve --stdio"
> remote: Not trusting file /export/illumos/hgrepos/illumos-gate/.hg/hgrc from untrusted user hg, group hg
> comparing with ssh://anonhg@hg.illumos.org/illumos-gate
> searching for changes
>
> changeset:   13369:52edb81b418d
> tag:         tip
> user:        Yuri Pankov <yuri.pankov at gmail.com>
> date:        Thu May 12 03:41:48 2011 +0400
>
> description:
>        948 chmod(1M) is not -R friendly when doing ACLs
>        Reviewed by: Jason King <jason.brian.king at gmail.com>
>        Reviewed by: Garrett D'Amore <garrett at damore.org>
>        Reviewed by: Albert Lee <trisk at opensolaris.org>
>
> modified:
>   usr/src/cmd/chmod/chmod.c
>
> remote: Not trusting file /export/illumos/hgrepos/illumos-gate/.hg/hgrc from untrusted user hg, group hg
>
> illumos:yuri:~/ws/948-chmod-r-acl$ hg pbchk
> Copyright check:
>
> C style check:
>
> Header format check:
>
> Java style check:
>
> Mapfile comment check:
>
> File permission check:
>
> Keywords check:
>
> Comments check:
>
> Checking for new tags:
>
> Checking for multiple heads (or branches):
>
> Checking for branch changes:
>
> Checking for uncommitted changes:
>
> Checking for merges:
>
>
> Testing done:
> original chmod - we don't have specified ACE and chmod stops there, not
> trying to remove it from other files/dirs:
>
> illumos:yuri:~$ mkdir -p a/b/c/d; /usr/bin/chmod \
>  A+user:yuri:full_set:allow a/b; /usr/bin/chmod \
>  A=user:root:full_set:allow a/b/c; /usr/bin/chmod -R \
>  A-user:yuri:full_set:allow a; /usr/bin/ls -Vd a/b
> chmod: ERROR: ACL entry doesn't exist
> drwxr-xr-x+  3 yuri     staff          3 May 12 03:49 a/b
>              user:yuri:rwxpdDaARWcCos:-------:allow
>                 owner@:rwxp--aARWcCos:-------:allow
>                 group@:r-x---a-R-c--s:-------:allow
>              everyone@:r-x---a-R-c--s:-------:allow
>
> modified chmod - chmod prints error message but continues to work on
> other files/dirs:
> illumos:yuri:~$ mkdir -p a/b/c/d; \
>  ~/ws/948-chmod-r-acl/usr/src/cmd/chmod/chmod A+user:yuri:full_set:allow \
>  a/b; ~/ws/948-chmod-r-acl/usr/src/cmd/chmod/chmod \
>  A=user:root:full_set:allow a/b/c; \
>  ~/ws/948-chmod-r-acl/usr/src/cmd/chmod/chmod -R \
>  A-user:yuri:full_set:allow a; /usr/bin/ls -Vd a/b
> chmod: ERROR: ACL entry doesn't exist
> chmod: ERROR: ACL entry doesn't exist
> chmod: WARNING: /export/home/yuri/a/b/c: Permission denied
> drwxr-xr-x   3 yuri     staff          3 May 12 03:53 a/b
>                 owner@:rwxp--aARWcCos:-------:allow
>                 group@:r-x---a-R-c--s:-------:allow
>              everyone@:r-x---a-R-c--s:-------:allow
>
>
> Yuri
>
> _______________________________________________
> Advocates mailing list
> Advocates at lists.illumos.org
> http://lists.illumos.org/m/listinfo/advocates
>
>



More information about the Advocates mailing list