apparmor: cleanup - #61695
Open
Duncaen wants to merge 2 commits into
Open
Conversation
Duncaen
force-pushed
the
apparmor
branch
5 times, most recently
from
July 28, 2026 19:05
45a361e to
d7e1818
Compare
- cleanup template - enable more checks - remove old custom php-fpm profile - allow cross building perl library - move apparmor syscall and library man pages to libapparmor-devel - add missing python dependencies
Duncaen
force-pushed
the
apparmor
branch
2 times, most recently
from
July 29, 2026 20:22
9d6bf26 to
e2eb698
Compare
Remove the mode switch in the /etc/runit/core-services/09-apparmor.sh script that causes issues. The `apparmor_parser -C` flag that was used to set the profiles into complain mode will force profiles that have the `unconfined` flag set into complain mode instead, which enables further restrictions that may break things. And there is no alternative flag to only set profiles that have the enforce flag to complain. The native kernel module parameter apparmor.mode should be used instead. As it puts apparmor into complain mode instead of trying to force profiles into complain mode. This fixes bwrap when executed by flatpak which has a profile with the unconfined flag set.
CameronNemo
reviewed
Jul 31, 2026
| printf '! AppArmor installation problem - ensure you have installed apparmor package\n' | ||
| fi | ||
| if [ -d /etc/apparmor.d -a -x /usr/bin/apparmor_parser ]; then | ||
| find -L /etc/apparmor.d -maxdepth 1 -type f ! -name '*.new-*_*' -exec apparmor_parser -a -- {} + |
Contributor
There was a problem hiding this comment.
shame we don't have upstream support for skipping these files (https://gitlab.com/apparmor/apparmor/-/blob/master/utils/apparmor/common.py#L171). AIUI the apparmor tooling has some optimizations when you just run it against the whole directory vs. profile by profile.
Contributor
There was a problem hiding this comment.
once upon a time I added the support, but I guess it got lost in the mix https://gitlab.com/apparmor/apparmor/-/merge_requests/230/diffs#diff-content-2d7d631567a2e800da349ed4e174f9680adc563d
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.