Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mke2fs: support gnu.translator xattrs for tarball input #192

Open
josch opened this issue Aug 25, 2024 · 0 comments · May be fixed by #194
Open

mke2fs: support gnu.translator xattrs for tarball input #192

josch opened this issue Aug 25, 2024 · 0 comments · May be fixed by #194

Comments

@josch
Copy link
Contributor

josch commented Aug 25, 2024

Hi,

I'm creating tarballs for GNU Hurd on Linux by making use of the recent change that uses the gnu.translator xattr to store Hurd translator information. For this to work I'm applying the following patch to e2fsprogs:

--- a/misc/create_inode_libarchive.c
+++ b/misc/create_inode_libarchive.c
@@ -442,7 +442,7 @@ static errcode_t set_inode_xattr_tar(ext
 	dl_archive_entry_xattr_reset(entry);
 	while (dl_archive_entry_xattr_next(entry, &name, &value, &value_size) ==
 	       ARCHIVE_OK) {
-		if (strcmp(name, "security.capability") != 0)
+		if (strcmp(name, "security.capability") != 0 && strcmp(name, "gnu.translator"))
 			continue;
 
 		retval = ext2fs_xattr_set(handle, name, value, value_size);

I'm unsure why I limited the allowed xattr to security.capability in the first place. Is that necessary?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant