[Bug 10163] New: rsync -X is ineffective when setting owner/group

samba-bugs at samba.org samba-bugs at samba.org
Mon Sep 23 12:23:42 CEST 2013


https://bugzilla.samba.org/show_bug.cgi?id=10163

           Summary: rsync -X is ineffective when setting owner/group
           Product: rsync
           Version: 3.1.0
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P5
         Component: core
        AssignedTo: wayned at samba.org
        ReportedBy: mluscon at redhat.com
         QAContact: rsync-qa at samba.org


Created attachment 9236
  --> https://bugzilla.samba.org/attachment.cgi?id=9236
Patch

Description of problem:
rsync -X preserves extended attributes on files. It works partially; however,
if combined with rsync options which preserve the file owner and/or group, it
is partially ineffective. This is because rsync calls chown(2) after setting
attributes, and chown removes security attributes (as in capabilities(5)).
Steps to Reproduce:

$ touch foo
$ sudo setcap cap_dac_read_search=pe foo
$ getcap foo
foo = cap_dac_read_search+ep
$ sudo rsync -X foo foo.1
$ getcap foo.1
foo.1 = cap_dac_read_search+ep
$ sudo rsync -aX foo foo.2
$ getcap foo.2
$

This report originates from https://bugzilla.redhat.com/show_bug.cgi?id=981797

-- 
Configure bugmail: https://bugzilla.samba.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the rsync mailing list