From: Geliang Tang <geliangtang@gmail.com>
To: Phillip Lougher <phillip@squashfs.org.uk>,
Andrew Morton <akpm@linux-foundation.org>,
Kees Cook <keescook@chromium.org>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Coly Li <colyli@suse.de>
Cc: Geliang Tang <geliangtang@gmail.com>,
linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH v4 0/2] squashfs/squashfs-tools: Add posix acl support
Date: Fri, 25 Jan 2019 16:27:46 +0800 [thread overview]
Message-ID: <cover.1548403955.git.geliangtang@gmail.com> (raw)
When we use mksquashfs tool to create a squashfs image from the files which
have POSIX ACLs(Access Control Lists), we get these errors:
Unrecognised xattr prefix system.posix_acl_access
Unrecognised xattr prefix system.posix_acl_default
This patcheset adds posix acl support to squashfs to fix this problem. Patch
#1 for kerenl tree and patch #2 for squashfs-tools tree.
---
Testcase:
$ mkdir root
$ getfacl root
# file: root
# owner: tgl
# group: tgl
user::rwx
group::r-x
other::r-x
$ setfacl -m u:tgl:rw root
$ setfacl -m d:tgl:rw root
$ getfacl root
# file: root
# owner: tgl
# group: tgl
user::rwx
user:tgl:rw-
group::r-x
mask::rwx
other::r-x
default:user::rwx
default:user:tgl:rw-
default:group::r-x
default:mask::rwx
default:other::r-x
$ getfattr -m . -d root
# file: root
system.posix_acl_access=0sAgAAAAEABwD/////AgAGAOgDAAAEAAUA/////xAABwD/////IAAFAP////8=
system.posix_acl_default=0sAgAAAAEABwD/////AgAGAOgDAAAEAAUA/////xAABwD/////IAAFAP////8=
$ mksquashfs root root.img
$ sudo mount root.img /mnt/squash/
$ cd /mnt
$ getfacl squash
# file: squash
# owner: tgl
# group: tgl
user::rwx
user:tgl:rw-
group::r-x
mask::rwx
other::r-x
default:user::rwx
default:user:tgl:rw-
default:group::r-x
default:mask::rwx
default:other::r-x
$ getfattr -m . -d squash
# file: squash
system.posix_acl_access=0sAgAAAAEABwD/////AgAGAOgDAAAEAAUA/////xAABwD/////IAAFAP////8=
system.posix_acl_default=0sAgAAAAEABwD/////AgAGAOgDAAAEAAUA/////xAABwD/////IAAFAP////8=
---
Geliang Tang (1):
squashfs: Add posix acl support
Documentation/filesystems/squashfs.txt | 2 -
fs/squashfs/Kconfig | 11 ++++
fs/squashfs/Makefile | 1 +
fs/squashfs/acl.c | 69 ++++++++++++++++++++++++++
fs/squashfs/acl.h | 31 ++++++++++++
fs/squashfs/inode.c | 4 +-
fs/squashfs/namei.c | 6 ++-
fs/squashfs/squashfs_fs.h | 12 +++--
fs/squashfs/super.c | 3 ++
fs/squashfs/symlink.c | 6 ++-
fs/squashfs/xattr.c | 31 +++++++++++-
fs/squashfs/xattr.h | 8 +++
12 files changed, 171 insertions(+), 13 deletions(-)
create mode 100644 fs/squashfs/acl.c
create mode 100644 fs/squashfs/acl.h
---
Geliang Tang (1):
squashfs-tools: Add posix acl support
squashfs-tools/read_xattrs.c | 2 ++
squashfs-tools/squashfs_fs.h | 12 +++++++-----
2 files changed, 9 insertions(+), 5 deletions(-)
--
2.17.1
next reply other threads:[~2019-01-25 8:28 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-01-25 8:27 Geliang Tang [this message]
2019-01-25 8:27 ` [PATCH v4 1/2] squashfs: Add posix acl support Geliang Tang
2019-01-25 8:40 ` Greg Kroah-Hartman
2019-01-25 8:27 ` [PATCH v4 2/2] squashfs-tools: " Geliang Tang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=cover.1548403955.git.geliangtang@gmail.com \
--to=geliangtang@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=colyli@suse.de \
--cc=gregkh@linuxfoundation.org \
--cc=keescook@chromium.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=phillip@squashfs.org.uk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.