-
Notifications
You must be signed in to change notification settings - Fork 704
Description
Description
Initially raised during review of #4114, we should consolidate the PaX flag management logic. We are using both paxctl and paxctld for management of PaX flags, it would be best to maintain a single paxctld.conf file with all flags. It will also simplify some of the install logic, and allow us to more consistenly apply these flags to binaries and persist reboots (as an added feature, it might also help address #3916).
We could also evaluate and reuse what was done as part of the SecureDrop Workstation as an example: https://github.com/freedomofpress/securedrop-debian-packaging/tree/master/securedrop-workstation-svs-disp
UPDATE 2020-11-16
The following based on a conversation with @conorsch, as part of the current sprint commitments:
The paxctl header formats/commands are different in Focal from Xenial, and as a result, some existing paxctl logic from Xenial will not work in Focal. Specifically, updates to the flags for grub binaries (grub-probe, grub-mkdevicemap, grub-script-check) will not work in Focal under the current logic[1]. If grub is updated, PaX flags won't be applied, leading to cascading failures (grub update will fail, kernel update will fail, packages may be held back/broken)
Based on our conversation, we went through various approaches and decided on the following:
- Fork securedrop-grsec for Focal only (and leave the existing version for Xenial unchanged, because it works and we aren't supporting Xenial for much longer)
- Add
paxctldto theRequiresfield in the Control file. Since we are installing from scratch on Focal, it's a good opportunity to add, but also make 1. easier. - Add a securedrop-managed
paxctld.conffile to the Focal-specific metapackage, to configure the pax flags as we would expect them. - Remove kernel postinst file from the metapackage, since use of paxctld makes use of paxctl moot
User Stories
As a SecureDrop administrator or developer, I would like to manage all PaX flags in a single place and would like to consistently apply them across the system.