If someone breaks into a server, the logs are the first thing they would edit. Forward Secure Sealing in journald makes that kind of change detectable.
Persistent storage has to be on. Then generate a key pair:
sudo journalctl --setup-keys
This stores a sealing key on the machine in /var/log/journal/<machine-id>/fss and prints a verification key, which looks something like 681746-e361ee-5684d0-a2c0ff/1e735c-35a4e900. On a terminal it also shows a QR code. I’d write that verification key down somewhere off the server, in a password manager for example. journald seals the files at a regular interval, 15 minutes by default, and the sealing key moves forward each time so old seals can not be recreated.
To check the files later:
sudo journalctl --verify --verify-key='681746-e361ee-5684d0-a2c0ff/1e735c-35a4e900'
A healthy file comes back with PASS and a line saying from when to when the data was validated.
Sealing proves nothing about lines written after an attacker got root; they can write lies in real time. It also can not stop someone from deleting whole files. What it catches is changes to entries that were already sealed. And if the verification key only lives on the server, it is worthless, so keep it elsewhere.
Further reading: journalctl man page, journald.conf man page (Seal=)