New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Seen/Unseen Flag not working correctly if sharedseen of a shared mailbox is not set to true #3240
Comments
Hi, this issue affects Cyrus-Imapd 3.2.x |
@elliefm: hi, did you see this issue ? |
I've just tried reproducing the issue with the following Cassandane test: cyrusimap/cassandane@master...elliefm:v32/3240-sharedseen-on-shared-mailbox But the test passes okay on both 3.2 and master, so I can't see an obvious problem here...
It would be useful to know whether this "shared mailbox" is a mailbox at the top level namespace (not belonging to any particular user), or whether it is a mailbox belonging to a second user that they have given the first user access to.
It would be useful to know exactly what the ACL is set to. |
Hi, it seems we encounter a similar problem with version 3.2 on Debian. We have recently updated 2 of our cyrusimap servers from 2.5 to 3.2.6 and our Thunderbird clients are losing Seen/Unseen status when using shared mailboxes. We have activated imap debug log to try to figure out the problem and it seems to come from the UID STORE command which is acting like SILENT option is always enable when using shared mailboxes. For example in Cyrus 2.5, STORE command result was :
And with Cyrus 3.2.6, the result is :
As Thunderbird didn't receive the expected result, its cache is losing its head and only a stop/start of TB can recover correct operation. This situation only produce when we're using shared mailboxes as others mailboxes work well in TB. PS: A precision, as I checked the cassandane test, the problem isn't in writing the flag, as the flag is correctly positioned on the message by the server. The problem is only in the result of the STORE command which doesn't FETCH the flags. PPS: RFC 3501 (https://datatracker.ietf.org/doc/html/rfc3501#section-6.4.6) says
We're available for more tests or info if necessary |
After a search in the code, here is the observation we made :
But for the \Seen flag, when "sharedseen" is disabled, the change of the flag doesn't update the value of
And in 2.5 : https://github.com/cyrusimap/cyrus-imapd/blob/cyrus-imapd-2.5/imap/index.c#L3576
As |
Fixing problem when using \Seen flag with shared seen disable, modseq isn't updated so store command never return the fetch flags
Fixing problem when using \Seen flag with shared seen disable, modseq isn't updated so store command never return the fetch flags Signed-off-by: Thomas P <thomas.payen@i-carre.net>
Oh that's good intel, thanks. I thought the problem was that the flag was either not saved or lost, not that the response confused the client. I think my test case from a few weeks ago was only looking for the OK status, but not the untagged response. I'll update it and see if I can finally reproduce this! |
Thanks to @tpayen's info I've been able to update my test branch to reproduce the problem. It affects 3.4 and master too, not just 3.2. I've also run it with @tpayen's patch in #3577 and it does seem to fix it -- I'll comment briefly there too, but I'm trying to keep the discussion in one place. I'm about to add similar "check the untagged responses" logic to the rest of our flags tests, to see whether the regression is isolated to the \Seen flag on shared mailboxes without sharedseen, or if it goes deeper than that. |
Regression test for cyrusimap#3240
A while ago I mentioned having tests for this, but the link stopped working when we stopped keeping cassandane on its own repo. Those tests are here now: master...elliefm:cyrus-imapd:v35/3240-sharedseen-on-shared-mailbox |
Fixing issue #3240 Seen/Unseen Flag not working correctly if sharedseen of a shared mailbox is not set to true
From Debian #972079:
The text was updated successfully, but these errors were encountered: