foxcpp / maddy

✉️ Composable all-in-one mail server.
https://maddy.email
GNU General Public License v3.0
5.14k stars 249 forks source link

SORT should return UIDs but returns none #697

Closed stellarpower closed 6 months ago

stellarpower commented 7 months ago

Describe the bug

Apologies for a lack of detail - I know nothing about the IMAP protocol, but am going off comments here from the author of the webmail I am using - SnappyMail (based off Rainloop, so I expect core functionality to be similar; SnappyMail is mostly a stripped-down fork)

I pasted full logs in that thread, for what they believe is the specific issue; quoting:

> TAG3 SELECT "INBOX"\r\n
< * FLAGS (\Seen \Answered \Flagged \Deleted \Draft)\r\n
< * OK [PERMANENTFLAGS (\Seen \Answered \Flagged \Deleted \Draft \*)] Flags permitted.\r\n
< * OK [UNSEEN 1] Message 1 is first unseen\r\n
< * 0 RECENT\r\n
< * OK [UIDNEXT 4] Predicted next UID\r\n
< * OK [UIDVALIDITY 680226926] UIDs valid\r\n
< * 1 EXISTS\r\n
< TAG3 OK [READ-WRITE] SELECT completed\r\n
> TAG4 UID SORT (REVERSE DATE) UTF-8 UNDELETED\r\n
< * SORT\r\n
< TAG4 OK UID SORT completed\r\n

SORT should return the UID's but returns none. So this is a bug in maddy.

Steps to reproduce

I log into my webmail ,and I can see the number of messages in my inbox. But when I go to view the message list, it's empty. SnappyMail works well with another IMAP mailserver, so it sounds like this may be a bug in Maddy's implementation of the protocol.

Log files

Not sure if server-side logs will be this detailed; if there's something I can do to get hold of these, happy to do so.

Configuration file

Will provide if relevant; sounds like it may not be needed as this relates to the protocol implementation

Environment information

Related: https://github.com/foxcpp/maddy/issues/549

stellarpower commented 6 months ago

Looks like this may have bee na non-issue. Not entirely sure what was going on, but when I checked out the source code and worked out how to query directly with IMAP commands, I see the correct output. An unrelated change and suddenly snappymail is working again, so will close this as invalid.