There was technical elaboration in the same ticket.
Vincent43:
AppArmor sandbox is path based and uses whitelist approach by default. Firejail sandbox is also path based and uses blacklist approach by default. It also uses namesapces and rewrites some paths in sandbox which cause denials in AppArmor as you can see. The only case supported by firejail related to AppArmor is using
firejail-defaultgeneric profile which shouldn’t cause issues. Users who want to use app specific profiles with firejail are on their own as there is nothing firejail can do to help them. I can’t and won’t authoritatively force you on anything but avoiding using app specific AppArmor profile with firejail is my best advice.
Vincent43:
I try to reply all questions from first post:
Does libpostexecseccomp.so really have to reside in /run/firejail/lib/libpostexecseccomp.so?
Yes, it’s bind-mounted there from
/usr/lib/firejailand needed there for firejail to work.Ideally firejail would not cause apparmor issues.
This issue is caused by your custom apparmor profile not allowing firejail creating its own sandbox. There are unlimited ways for apparmor to block firejail from functioning and firejail can really prevent this happening on your own.
Maybe the (upcoming deepening on your apparmor version) abstractions/base.d would help?
In this case firejail’s apparmor integration isn’t used at all so all apparmor tweaks belong to your custom profile.
I hope this help understanding the problem better.
@Vincent43 closed this ticket. Therefore has write access to firejail upstream github repository. This makes the statement more authoritative.