pantalaimon: Add a config option to drop old room keys

This patch adds a config option that enables a mode wher a proxy will
only keep the latest room key from a sender in a certain room. This is
useful for bots that use pantalaimon since they are mostly only
interested in the latest messages and don't care about room history.
This commit is contained in:
Damir Jelić 2021-05-28 14:20:18 +02:00
parent 4cdf1be376
commit eabd5f5b51
6 changed files with 71 additions and 4 deletions

View file

@ -51,6 +51,11 @@ This option configures if a proxy instance should use the OS keyring to store
its own access tokens. The access tokens are required for the daemon to resume
operation. If this is set to "No", access tokens are stored in the pantalaimon
database in plaintext. Defaults to "Yes".
.It Cm DropOldKeys
This option configures if a proxy instance should only keep the latest version
of a room key from a certain user around. This effectively means that only newly
incoming messages will be decryptable, the proxy will be unable to decrypt the
room history. Defaults to "No".
.It Cm SearchRequests
This option configures if the proxy should make additional HTTP requests to the
server when clients use the search API endpoint. Some data that is required to

View file

@ -62,6 +62,13 @@ The following keys are optional in the proxy instance sections:
> operation. If this is set to "No", access tokens are stored in the pantalaimon
> database in plaintext. Defaults to "Yes".
**DropOldKeys**
> This option configures if a proxy instance should only keep the latest version
> of a room key from a certain user around. This effectively means that only newly
> incoming messages will be decryptable, the proxy will be unable to decrypt the
> room history. Defaults to "No".
Aditional to the homeserver section a special section with the name
**Default**
can be used to configure the following values for all homeservers:
@ -150,4 +157,4 @@ pantalaimon(8)
was written by
Damir Jelić <[poljar@termina.org.uk](mailto:poljar@termina.org.uk)>.
Linux 5.1.3-arch2-1-ARCH - May 8, 2019
Linux 5.11.16-arch1-1 - May 8, 2019