journalctl: verify that old entries are not sealed with too recent key (#28885)
authorfelixdoerre <felixdoerre@users.noreply.github.com>
Fri, 6 Oct 2023 03:18:21 +0000 (05:18 +0200)
committerGitHub <noreply@github.com>
Fri, 6 Oct 2023 03:18:21 +0000 (12:18 +0900)
commit3846d3aa292a6daa1916f667bdd79ebee9cb4ac4
tree4ef7a07ed5ff05e2f53a46956d9856190fd2045e
parent09ff0aadf9f6ac2097121c522ece66e89fd0b06b
journalctl: verify that old entries are not sealed with too recent key (#28885)

When verifying seals produced with forward secure sealing, the verification
currently does not check that old entries are only sealed with the key for
their epoch and not a more recent one. This missing check allows an attacker
to remove seals, and create new ones with the currently available key, and
verify will claim everything is in order, although all entries could have
been modified.

This resolves CVE-2023-31439.

Co-authored-by: Felix Dörre <felix.doerre@kit.edu>
src/libsystemd/sd-journal/journal-verify.c