-
Notifications
You must be signed in to change notification settings - Fork 700
Previewing new SecureDrop kernel
This procedure allows for a one-time check of the next SecureDrop kernel, in preview mode. If the kernel fails to load, in most cases the server will fall back to the default kernel, allowing this check to be done remotely.
However, if the kernel does load but networking support is not available, it may be necessary to roll back the kernel version to the default at the console (or wait for the next nightly reboot to revert to the default). This procedure is recommended only for Linux admins familiar with GRUB and the Linux boot process.
- connect to
monvia ssh from Admin Workstation -
sudo suor preface commands below withsudo:
- edit
/etc/apt/sources.list.d/apt_freedom_press.list, addingpreviewaftermain, so that it looks as follows:
deb [arch=amd64] https://apt.freedom.press/ focal main preview
- run
apt update - run
apt install linux-headers-5.15.57-grsec-securedrop linux-image-5.15.57-grsec-securedrop
-
update Grub defaults with the editor of your choice, e.g.
vi /etc/default/grub:- change
GRUB_DEFAULTvalue to'saved' - ensure the
GRUB_CMDLINE_LINUXvalue ends withpanic=5, inside existing quotation marks. Add a space beforepanicif there is an existing value.
- change
-
check menuentry options with
grep menuentry /boot/grub/grub.cfg | more, and confirm that entries exist for both 5.15.26 and 5.15.57 -
set the default kernel to the entry for 5.15.26:
grub-set-default "Advanced options for Ubuntu>Ubuntu, with Linux 5.15.26-grsec-securedrop" -
set the next reboot kernel to the entry for 5.15.57, eg:
grub-reboot "Advanced options for Ubuntu>Ubuntu, with Linux 5.15.57-grsec-securedrop" -
update the grub config with
update-grub -
reboot the server with
shutdown -r now
The server should come back up with the 5.15.57 kernel. If the kernel panics, the system will reboot after 5 seconds into the 5.15.26 kernel. Wait for the server to be available again, reconnect, and check the kernel version with uname -r. If you experience issues connecting to the server, or are connected locally, you can verify connectivity via a command such as sudo host freedom.press.
To revert to the current non-preview kernel:
- reboot the monitor server a second time, and confirm that it comes up with the 5.15.26 kernel with
uname -r - uninstall the 5.15.57 kernel packages with:
apt remove linux-headers-5.15.57-grsec-securedrop linux-image-5.15.57-grsec-securedrop - remove the
previewkeyword from/etc/apt/sources.list.d/apt_freedom_press.listand runsudo apt-get update - edit
/etc/default/grub, removing thepanic=5option from theGRUB_CMDLINE_LINUXvalue - revert remaining GRUB changes by running
sudo dpkg-reconfigure securedrop-grsec(this will automatically trigger anotherupdate-grubrun)