[PATCH] support for user and group names in tar

Natanael Copa natanael.copa at gmail.com
Thu Apr 20 17:23:19 UTC 2006


I have collected some of the ideas and suggestions from Robert P. J. Day and Glenn L. McGrath (and some more I think) and created an update to the previously posted patch.

The attatched patch does this:
- adds a CONFIG_FEATURE_TAR_UNAME_GNAME option to enable use of user and group names.
- removes the code that strips the trailing '/' in directories.
- display username and groupname if available when listing contents.
- look up /etc/passwd for uid when unpacking with -p option (preserve permissions)

If the CONFIG_FEATURE_TAR_UNAME_GNAME is not defined, the code should be exactly what it was before the patch.

Keeping the trailing '/' in directory names should not break anything, accoroding to path_resolution(2) and my tests, but more testing does not hurt.

rday, since you have experience in testing tar already, and seem to have alot of constructive energy, could you please test if the patch works as expected? ;-)

All comments are welcome.

Thanks!

-- 
Natanael Copa
-------------- next part --------------
A non-text attachment was scrubbed...
Name: tar-uname-gname.patch
Type: text/x-patch
Size: 5017 bytes
Desc: not available
Url : http://lists.busybox.net/pipermail/busybox/attachments/20060420/8f6552a2/attachment.bin 


More information about the busybox mailing list