mirror of
https://github.com/checkpoint-restore/criu.git
synced 2026-07-18 00:58:31 +00:00
lsm: use the user provided lsm label
Currently CRIU has the possibility to specify a LSM label during restore. Unfortunately the information is completely ignored in the case of SELinux. This change selects the lsm label from the user if it is provided and else the label from the checkpoint image is used. Signed-off-by: Adrian Reber <areber@redhat.com>
This commit is contained in:
parent
d35808f5ee
commit
ed6374b48c
1 changed files with 1 additions and 1 deletions
|
|
@ -370,7 +370,7 @@ int render_lsm_profile(char *profile, char **val)
|
|||
case LSMTYPE__APPARMOR:
|
||||
return render_aa_profile(val, profile);
|
||||
case LSMTYPE__SELINUX:
|
||||
if (asprintf(val, "%s", profile) < 0) {
|
||||
if (asprintf(val, "%s", opts.lsm_supplied ? opts.lsm_profile : profile) < 0) {
|
||||
*val = NULL;
|
||||
return -1;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue