[Bug 216127] sbin/restore doesn't honour extended attributes (extattr on ufs)
bugzilla-noreply at freebsd.org
bugzilla-noreply at freebsd.org
Tue Jan 17 01:29:30 UTC 2017
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=216127
Conrad Meyer <cem at freebsd.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |cem at freebsd.org
Assignee|freebsd-bugs at FreeBSD.org |cem at freebsd.org
--- Comment #1 from Conrad Meyer <cem at freebsd.org> ---
It appears that dump just dumps raw extattr data from UFS. The routine in
restore responsible for parsing that raw data and turning it into syscalls on
the receiving filesystem is set_extattr_fd() in tape.c.
The intent of the "system, (16 bytes), mb1946a (unable to set)" print is to
print the namespace, extattr data length, and name of the extattr. The problem
appears to be that restore is using "%*s" rather than "%.*s" to print the
non-null-terminated eap->ea_name. The former is the field width, while the
latter is the precision. Only precision controls the number of characters
printed by a %s format.
The same naive behavior around non-null-terminated ea_name leads to the same
bogus string being passed into extattr_set_fd() (or extattr_set_link, etc for
the other variants) and used to check for ACL attributes.
--
You are receiving this mail because:
You are on the CC list for the bug.
More information about the freebsd-amd64
mailing list