diff options
author | Daniel J Walsh <dwalsh@redhat.com> | 2020-07-15 16:33:24 -0400 |
---|---|---|
committer | Daniel J Walsh <dwalsh@redhat.com> | 2020-07-22 06:27:20 -0400 |
commit | 4c4a00f63ea5bc7956bf40be457bf86643575dce (patch) | |
tree | a35b4bb94a1c5eb93473bec40d7f9794c59e3d04 /pkg/specgen/generate/oci.go | |
parent | 59bad8bf7176398dbab6b59867b17567691ffda3 (diff) | |
download | podman-4c4a00f63ea5bc7956bf40be457bf86643575dce.tar.gz podman-4c4a00f63ea5bc7956bf40be457bf86643575dce.tar.bz2 podman-4c4a00f63ea5bc7956bf40be457bf86643575dce.zip |
Support default profile for apparmor
Currently you can not apply an ApparmorProfile if you specify
--privileged. This patch will allow both to be specified
simultaniosly.
By default Apparmor should be disabled if the user
specifies --privileged, but if the user specifies --security apparmor:PROFILE,
with --privileged, we should do both.
Added e2e run_apparmor_test.go
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
Diffstat (limited to 'pkg/specgen/generate/oci.go')
-rw-r--r-- | pkg/specgen/generate/oci.go | 7 |
1 files changed, 0 insertions, 7 deletions
diff --git a/pkg/specgen/generate/oci.go b/pkg/specgen/generate/oci.go index 4953735b1..f279aac1c 100644 --- a/pkg/specgen/generate/oci.go +++ b/pkg/specgen/generate/oci.go @@ -285,13 +285,6 @@ func SpecGenToOCI(ctx context.Context, s *specgen.SpecGenerator, rt *libpod.Runt } } - // SECURITY OPTS - g.SetProcessNoNewPrivileges(s.NoNewPrivileges) - - if !s.Privileged { - g.SetProcessApparmorProfile(s.ApparmorProfile) - } - BlockAccessToKernelFilesystems(s.Privileged, s.PidNS.IsHost(), &g) for name, val := range s.Env { |