Previously, there would be errors when changing the confinement of an AppArmor profile for a snap. This was because these profiles are at /var/lib/snapd/apparmor/profiles, which is not the default place for AppArmor profiles.
I updated CommandCaller, to also look for profiles in this location, before attempting to change their status, and modifying the command appropriately.
Furthermore, I set the CMake script to add a few symbolic links to the /var/lib/snapd/apparmor/profiles directory, to help ensure that future calls to aa-enforce, aa-complain, etc would be successful. If I did not do this, then there would not be the subdirectory abstractions in /var/lib/snapd/apparmor/profiles, and aa-enforce would fail when attempting to change a snap profile's confinement
Previously, there would be errors when changing the confinement of an AppArmor profile for a snap. This was because these profiles are at
/var/lib/snapd/apparmor/profiles
, which is not the default place for AppArmor profiles.I updated CommandCaller, to also look for profiles in this location, before attempting to change their status, and modifying the command appropriately.
Furthermore, I set the CMake script to add a few symbolic links to the
/var/lib/snapd/apparmor/profiles
directory, to help ensure that future calls to aa-enforce, aa-complain, etc would be successful. If I did not do this, then there would not be the subdirectoryabstractions
in/var/lib/snapd/apparmor/profiles
, and aa-enforce would fail when attempting to change a snap profile's confinement