Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
lxc
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Chen Yisong
lxc
Commits
ab373bdf
Commit
ab373bdf
authored
Jun 05, 2017
by
Christian Brauner
Committed by
GitHub
Jun 05, 2017
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #1578 from 0x0916/export-seccomp-filter-to-log
seccomp: export the seccomp filter after load it into kernel successful
parents
9795e880
5107af32
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
0 deletions
+12
-0
seccomp.c
src/lxc/seccomp.c
+12
-0
No files found.
src/lxc/seccomp.c
View file @
ab373bdf
...
@@ -791,6 +791,18 @@ int lxc_seccomp_load(struct lxc_conf *conf)
...
@@ -791,6 +791,18 @@ int lxc_seccomp_load(struct lxc_conf *conf)
ERROR
(
"Error loading the seccomp policy: %s."
,
strerror
(
-
ret
));
ERROR
(
"Error loading the seccomp policy: %s."
,
strerror
(
-
ret
));
return
-
1
;
return
-
1
;
}
}
/* After load seccomp filter into the kernel successfully, export the current seccomp
* filter to log file */
#if HAVE_SCMP_FILTER_CTX
if
((
lxc_log_get_level
()
<=
LXC_LOG_PRIORITY_TRACE
||
conf
->
loglevel
<=
LXC_LOG_PRIORITY_TRACE
)
&&
lxc_log_fd
>=
0
)
{
ret
=
seccomp_export_pfc
(
conf
->
seccomp_ctx
,
lxc_log_fd
);
/* Just give an warning when export error */
if
(
ret
<
0
)
WARN
(
"Failed to export seccomp filter to log file: %s."
,
strerror
(
-
ret
));
}
#endif
return
0
;
return
0
;
}
}
...
...
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