[Bug 10295] New: do_lchown() after set_xattr() causes xattrs to be dropped on Linux 3.10.20.
samba-bugs at samba.org
samba-bugs at samba.org
Wed Nov 27 22:14:15 MST 2013
https://bugzilla.samba.org/show_bug.cgi?id=10295
Summary: do_lchown() after set_xattr() causes xattrs to be
dropped on Linux 3.10.20.
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: caowasteland at gmail.com
QAContact: rsync-qa at samba.org
Created attachment 9489
--> https://bugzilla.samba.org/attachment.cgi?id=9489
Candidate patch on rsync 3.1.0. Please review.
Example:
rsync -Xa /foo /bar
Expected:
Copies will have the same security attributes as the originals.
Reality:
Copies have security attributes cleared.
Please look at rsync-3.1.0/rsync.c lines 492 & 541 in the context of
chown_common() from linux kernel fs/open.c around the 500th line. It appears
that the SET{G,U}ID bits and security attrs are cleared.
Relevant kernel line:
if (!S_ISDIR(inode->i_mode))
newattrs.ia_valid |=
ATTR_KILL_SUID | ATTR_KILL_SGID | ATTR_KILL_PRIV;
Suggestion: move the SUPPORT_XATTRS code invocation after the if (change_uid...
block.
--
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