deltachat-core-rust icon indicating copy to clipboard operation
deltachat-core-rust copied to clipboard

Don't prefetch Chat-Version header and don't copy it into outer part

Open iequidoo opened this issue 1 month ago • 1 comments

Chat-Version is used sometimes by Sieve filters to move messages to DeltaChat folder: https://github.com/mailcow/mailcow-dockerized/blob/37beed6ad93f259b97cad41877982bce95295629/data/conf/dovecot/global_sieve_before This probably prevents notifications to MUAs that don't watch DeltaChat but watch INBOX.

There are however disadvantages to exposing Chat-Version: 1. Spam filters may not like this header and it is difficult or impossible to tell if Chat-Version plays role in rejecting the message or delivering it into Spam folder. If there is no such header visible to the spam filter, this possibility can be ruled out. 2. Replies to chat messages may have no Chat-Version but have to be moved anyway. 3. The user may have no control over the Sieve filter, but it comes preconfigured in mailcow, so it is not possible to disable it on the client.

Thanks to link2xt for providing this motivation.

NOTE: Old Delta Chat will assign partially downloaded replies to an ad-hoc group with the sender instead of the 1:1 chat, but we're removing partial downloads anyway.

Also there are some other changes done to not depened on Chat-Version presense in the outer headers:

  • Now we don't prefetch Chat-Version at all and try to find out message encryption state looking at other headers. Basically, we consider encrypted messages as chat messages.
  • Move all encrypted messages to mvbox if MvboxMove is on.

Also copying Auto-Submitted to the outer headers is removed.

iequidoo avatar Nov 05 '25 22:11 iequidoo

This is ready for review and all the tests work, but should be merged after #7373 apparently because this adds a check for is_partial_download to is_probably_private_reply() which we don't want. EDIT: Marking as draft as this can't be merged right now.

iequidoo avatar Nov 10 '25 09:11 iequidoo