Deleted posts stay inside the DB for some time

Hello,
When someone delete a message, the records are still inside the DB (postgresql in my case) for some time.
I would like to know at what time they get deleted from the DB too and how i could modify this time.

Thanks,
Nikolay

Hi @npetrov,

Deleted posts are not removed from the database. This is because Mattermost was designed to have a complete audit history of messages.

Is there any housekeeping script that could at least let an admin permanently delete a message from the database ?

Our teams sometimes send messages with sensitive information. As there is no volatile room or something similar to anonymous browsing (guarantee that nothing is stored long terms) in mattermost, we would at the very least like that message marked as deleted are permanently deleted.

If not, I’ll probably open a new feature suggestion. I understand my suggestion is the exact opposite of Delete posted messages but, sometimes, for security matters, delete really has to mean delete (now and forever with no way back).

Hi @gwelr, we’ve thought about this before as well and one solution we’re considering implementing is off-the-record messaging which will encrypt your messages so that not even the system admin can see the contents of your message. This could also be combined with not storing the messages for OTR conversations in the database at all, preventing someone from even trying to decrypt your conversation.

I haven’t seen a ton of interest in OTR but if it’s something you’d be interested in having as part of the product then maybe opening a new feature suggestion for it would help garner it some attention.