2021-01-26 15:45:02 +08:00
|
|
|
From 2b27e392632fa0506fef9d5d882ed72a92973e27 Mon Sep 17 00:00:00 2001
|
2020-09-10 18:24:16 +08:00
|
|
|
From: yangfeiyu <yangfeiyu2@huawei.com>
|
2021-01-26 15:45:02 +08:00
|
|
|
Date: Tue, 26 Jan 2021 15:24:39 +0800
|
2020-09-10 18:24:16 +08:00
|
|
|
Subject: [PATCH] xattr: support ima and evm
|
|
|
|
|
|
|
|
|
|
reason: support ima and evm
|
|
|
|
|
|
|
|
|
|
Signed-off-by: yangfeiyu <yangfeiyu2@huawei.com>
|
|
|
|
|
---
|
2021-01-26 15:45:02 +08:00
|
|
|
vendor/github.com/containers/storage/pkg/archive/archive.go | 2 +-
|
|
|
|
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
2020-09-10 18:24:16 +08:00
|
|
|
|
|
|
|
|
diff --git a/vendor/github.com/containers/storage/pkg/archive/archive.go b/vendor/github.com/containers/storage/pkg/archive/archive.go
|
2021-01-26 15:45:02 +08:00
|
|
|
index 4472511..479ade8 100644
|
2020-09-10 18:24:16 +08:00
|
|
|
--- a/vendor/github.com/containers/storage/pkg/archive/archive.go
|
|
|
|
|
+++ b/vendor/github.com/containers/storage/pkg/archive/archive.go
|
2021-11-29 10:50:42 +08:00
|
|
|
@@ -397,7 +397,7 @@ func ReadSecurityXattrToTarHeader(path string, hdr *tar.Header) error {
|
2020-09-10 18:24:16 +08:00
|
|
|
if hdr.Xattrs == nil {
|
|
|
|
|
hdr.Xattrs = make(map[string]string)
|
|
|
|
|
}
|
|
|
|
|
- for _, xattr := range []string{"security.capability", "security.ima"} {
|
|
|
|
|
+ for _, xattr := range []string{"security.capability", "security.ima", "security.evm"} {
|
|
|
|
|
capability, err := system.Lgetxattr(path, xattr)
|
2021-11-29 10:50:42 +08:00
|
|
|
if err != nil && !errors.Is(err, system.EOPNOTSUPP) && err != system.ErrNotSupportedPlatform {
|
2020-09-10 18:24:16 +08:00
|
|
|
return errors.Wrapf(err, "failed to read %q attribute from %q", xattr, path)
|
|
|
|
|
--
|
2021-01-26 15:45:02 +08:00
|
|
|
2.27.0
|
2020-09-10 18:24:16 +08:00
|
|
|
|