[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug-tar] ACL support, extract and default ACLs
From: |
Markus Steinborn |
Subject: |
[Bug-tar] ACL support, extract and default ACLs |
Date: |
Sun, 05 Jun 2016 21:26:14 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux i686; rv:28.0) Gecko/20100101 Firefox/28.0 SeaMonkey/2.25 |
Hello,
I'd like to remember the following bug report. I've ported the patches
for it to GNU tar 1.29.
Also see https://bugzilla.redhat.com/show_bug.cgi?id=1052876
Storing and restoring ACLs in tar archives should be improved:
(1) tar archive creation with "--numeric-owner" option:
In this case, users are expectiing that the archive does not contain any
symbolic owner name, so it can be extracted to an emoty hard disc on a
system bootet e. g. by a rescue cd from Redhat. Current sitation is that
ACLs still include the symbolic owner and not the numeric owner.
This is quite trivial to fix (not completely contained in the attached
patches):
Replace all ocurences of "val = acl_to_text(acl, &len);" by "val =
acl_to_any_text(acl, 0, ',', (
numeric_owner_option?TEXT_NUMERIC_IDS:0));" and followed by
"len=strlen(val);" after the "if (!val)" error-handling.
Effect: Numeric owner is stored.
I'd like to note that this improvement is essential to me.
(2a) tar archive creation without "--numeric-owner" option:
In GNU tar 1.26, for every file the owner is stored both, symbolic and
numeric. I would expect that ACLs are stored in both ways, too. star
shows us how to do that:
star stores the numeric owner in a forth field of an acl: (e.g.
"u:msteinbo:rwx:500").
(2b) tar extract should use the 4th field (discussed in point 2) in
presence of "-numeric-owner".
This together with point (2) enabled users to restore an backup created
without numeric owner option on a clean hard disc without passwd entries
for the users (let's assume that /etc/passwd is contained in the archive
so the operation makes sense).
I'd like to mention that this point would increase star compatibility a lot.
(see also http://lists.gnu.org/archive/html/bug-tar/2013-03/msg00021.html
upstream maintainer "Paul Eggert" says in
http://lists.gnu.org/archive/html/bug-tar/2013-04/msg00024.html:
"That sort of thing all sounds reasonable, I guess. I'd like Sergey's
opinion though.".
Greetings from Germany
Markus Steinborn
GNU gv maintainer
0001-tar-extract-should-use-the-4th-field-discussed-in-po.patch
Description: Text Data
0002-tar-archive-creation-without-numeric-owner-option.patch
Description: Text Data
0003-Do-not-store-filesystem-dependent-xattrs-i.e.-ACLs-e.patch
Description: Text Data
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Bug-tar] ACL support, extract and default ACLs,
Markus Steinborn <=