mirror of
https://github.com/matrix-org/matrix-rust-sdk.git
synced 2026-08-02 02:47:05 -04:00
[As Damir pointed out][0]:
> You are supposed to use the table name as the first argument, this
> will ensure that, if you encode the same room ID in two different
> tables, they won't produce the same hash.
>
> This prevents correlation between tables.
>
> Though, sometimes you will need to have a stable hash between two
> tables.
This patch adds the `table_name` argument to `encode_event_id` and
`encode_room_id`, and explain why `keys::EVENTS` is used for the
`EventId` when necessary.
[0]: 733349d656 (r3587244126)
The file is empty.