oxen-io / oxen-storage-server

Storage server for Oxen Service Nodes
MIT License
29 stars 50 forks source link

Remove timestamp/ttl from message hash #465

Closed jagerman closed 1 year ago

jagerman commented 1 year ago

Currently calculated messages hashes use the storage timestamp and expiry timestamp to compute the message hash. This was fine when message were immutable, but they aren't anymore we have the ability to extend and shorten expiries. Moreover libsession-util expects to be able to store the same content and get deduplication, but currently that doesn't work because of the timestamp/expiry use in the message hash.

We don't want this anymore and should remove it so that hashes are based just on the other fields that can't change (netid, public, namespace, data).