Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
linux
Commits
d033b7ff
Commit
d033b7ff
authored
Feb 15, 2015
by
Seth Forshee
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ima/evm: Allow root in s_user_ns to set xattrs
Signed-off-by:
Seth Forshee
<
seth.forshee@canonical.com
>
parent
3d5a8612
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
security/integrity/evm/evm_main.c
security/integrity/evm/evm_main.c
+1
-1
security/integrity/ima/ima_appraise.c
security/integrity/ima/ima_appraise.c
+1
-1
No files found.
security/integrity/evm/evm_main.c
View file @
d033b7ff
...
...
@@ -278,7 +278,7 @@ static int evm_protect_xattr(struct dentry *dentry, const char *xattr_name,
enum
integrity_status
evm_status
;
if
(
strcmp
(
xattr_name
,
XATTR_NAME_EVM
)
==
0
)
{
if
(
!
capable
(
CAP_SYS_ADMIN
))
if
(
!
ns_capable
(
dentry
->
d_sb
->
s_user_ns
,
CAP_SYS_ADMIN
))
return
-
EPERM
;
}
else
if
(
!
evm_protected_xattr
(
xattr_name
))
{
if
(
!
posix_xattr_acl
(
xattr_name
))
...
...
security/integrity/ima/ima_appraise.c
View file @
d033b7ff
...
...
@@ -345,7 +345,7 @@ static int ima_protect_xattr(struct dentry *dentry, const char *xattr_name,
const
void
*
xattr_value
,
size_t
xattr_value_len
)
{
if
(
strcmp
(
xattr_name
,
XATTR_NAME_IMA
)
==
0
)
{
if
(
!
capable
(
CAP_SYS_ADMIN
))
if
(
!
ns_capable
(
dentry
->
d_sb
->
s_user_ns
,
CAP_SYS_ADMIN
))
return
-
EPERM
;
return
1
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment