]> www.infradead.org Git - users/jedix/linux-maple.git/commit
security,overlayfs: Provide security hook for copy up of xattrs for overlay file
authorVivek Goyal <vgoyal@redhat.com>
Wed, 13 Jul 2016 14:44:49 +0000 (10:44 -0400)
committerAnand Jain <anand.jain@oracle.com>
Thu, 26 Oct 2017 08:15:29 +0000 (16:15 +0800)
commite7c5afa30425cef05b4654589cd0056185891a1a
treea2b87223392a101134fdb61adcd4d33d04905cd1
parent12576c41441b5aa69eb9a1b432f865e3a9c517d1
security,overlayfs: Provide security hook for copy up of xattrs for overlay file

Provide a security hook which is called when xattrs of a file are being
copied up. This hook is called once for each xattr and LSM can return
0 if the security module wants the xattr to be copied up, 1 if the
security module wants the xattr to be discarded on the copy, -EOPNOTSUPP
if the security module does not handle/manage the xattr, or a -errno
upon an error.

Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: Vivek Goyal <vgoyal@redhat.com>
Acked-by: Stephen Smalley <sds@tycho.nsa.gov>
[PM: whitespace cleanup for checkpatch.pl]
Signed-off-by: Paul Moore <paul@paul-moore.com>
Orabug: 25684456

(backport upstream commit 121ab822ef21914adac2fa3730efeeb8fd762473)

Signed-off-by: Anand Jain <anand.jain@oracle.com>
Acked-by: James Morris <james.l.morris@oracle.com>
Reviewed-by: James Morris <james.l.morris@oracle.com>
conflict fix
include/linux/security.h
security/capability.c
security/security.c
fs/overlayfs/copy_up.c
include/linux/security.h
security/capability.c
security/security.c