-
Notifications
You must be signed in to change notification settings - Fork 297
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
K9-Mail Compatibility: list special-use type error #357
Comments
This sounds like a bug with K9 mail. The RFC specifies:
|
This my first time every hearing about ABNF, but shouldn't
I created an issue for k9 mail. thunderbird/thunderbird-android#4729 Feel free to ignore my questions if they are grossly misinformed. |
K-9 Mail 5.600 will only send the extended LIST command when the SPECIAL-USE extension is advertised. My reading of the spec was (and really still is), that the SPECIAL-USE capability may only be advertised if the server also supports LIST-EXTENDED. K-9 Mail versions 5.7xx+ will check for both capabilities before sending the extended LIST command. See also emersion/hydroxide#41 |
Ah, right. Sorry, I didn't remember about this. |
This should not be closed as it is not fixed. It relates to this: emersion/go-imap-specialuse#1 As per https://tools.ietf.org/html/rfc6154#page-7 When
I did a hackish solution here: exander77@f85eae3 |
Your link doesn't justify this. |
@emersion Why do you think that? |
@emersion: I tried to illustrate in this comment that announcing the SPECIAL-USE capability doesn't make sense if all you support is the regular LIST command with special-use attributes. The spec specifically states that this feature is not associated with a capability string:
|
@cketti You covered it well here: emersion/hydroxide#41 I do think it is way worse than it doesn't make sense to advertise it, it breaks RFC6154. The capability SPECIAL-USE is there only and only if the extended LIST command supports SPECIAL-USE. Having special flags for special use folders is no capability at all. Flags are already supported. Uf, this is going on from 2018? The RFC is extremely clear. |
@emersion So... what are we going to do about it? I have a kind of dirty patch (mentioned above) as I don't see an easy way how to implemented using extensions. And I think We can all agree that this is wrong and breaking RFC6154.
The RFC guy actually confirms it. He is saying that it is ok to support special-use without an extended list and We all agree with that. Special-use folders are just flags. What is wrong is announcing There are 4 different meanings of special-use in RFC6154:
Case 1. is just an extension of RFC5464 and is not announced (these are just flags):
Cases 2. and 3. and 4. are bound together:
|
I have been reading more in: emersion/hydroxide#41 And there are misconceptions there:
No, there is no bug in the example. RFC5258 clearly states:
This is exactly the case of And:
No,
What they mean here is:
It confuses the reader with Extended K-9 does not assume There are commands and there are responses, there are selection options, there are return options and there are capabilities. |
That's a stretch. K-9 Mail 5.600 does assume the server supports the extended RFCs are often not great at mentioning error cases. They state what you should do and hope you make the correct assumptions about what not to do. Technically, the behavior of go-imap falls into undefined behavior territory.
Paragraph 1 states that there's no capability associated with including the attributes in the regular list response. It does not say you MUST NOT use the Paragraph 2 deals with an extension to the extended LIST command. It doesn't apply to go-imap because go-imap doesn't support the extended LIST command. Unfortunately, the spec doesn't explicitly spell out what servers have to do when the |
You cannot advertise capabilities without actually supporting them. Isn't this obvious? Why are We even talking about this? This is registered IANA IMAP 4 Capability and you can use it only as defined. I can look it up, but it is definitely part of IMAP specs. From the top of my had, you cannot even strap a custom capability there without prefixing it with
If what you are suggesting was the case then you can just advertise all registered IANA IMAP 4 Capabilities and issue errors if needed. We may do it in the next release. :) Capability registry: https://www.iana.org/assignments/imap-capabilities/imap-capabilities.xhtml |
Btw, this talks about supporting the extension, not advertising the capability. There is one thing to support RFC 6154, which you do, and the other thing which is announcing |
I do not think it is stretch I think they could do it better as well. Like fallback... But this:
is not Extended
|
The standard LIST command (RFC 3501, section 6.3.8, RFC 3501, page 85, RFC 6154 does not create a special version of the LIST command. It (optionally) extends the extended LIST command as defined in RFC 5258. If a server doesn't support the extended LIST command the sections in RFC 6154 about extending the extended LIST command don't apply. |
There is some truth to that, but that is not really a problem. The problem is the advertisement for the My interpretation is that you can support this command without supporting RFC6154 Extended You are assuming that Extended |
I think the main problem and confusion here is that it was intended for servers who both support or don't support |
Well, section 2 contains this:
If you read it that way, there's indeed some confusion. Section 2, paragraph 1 deals with the response to the regular LIST command. It may include special-use attributes. See example 5.1. Side note: Please try to be more considerate when posting comments. The fact that you post multiple subsequent comments and edit each of them multiple times is a good indication that your thought process isn't finished when you hit "Comment". |
Yes, that is true, it adds those options for Extended
Sorry about this, it is not about the thought process, but that I reread comments several times to remove anything imprecise and make it as clear as is possible. I am never able to do it without at least ten edits. |
I'm not convinced by @exander77, however @cketti's comment makes me think I'm wrong. go-imap uses the cap to advertise that it'll return SPECIAL-USE attributes in the regular LIST command, and the RFC citation says it's wrong. |
@emersion I agree with @cketti as well. The discussion about extended |
Related: #342 |
@emersion, if we can get this PR merged I might look into implementing extended list support this weekeed. |
@foxcpp That would be really nice,. |
Uhhh, why is this closed again? We have now SPECIAL-USE in go-imap directly but no EXTENDED-LIST yet so... K-9 will still cause errors? |
SPECIAL-USE in go-imap doesn't advertise the cap. |
@foxcpp |
Okay, I see. Going to take a look at what's needed for EXTENDED-LIST... |
Note to self: CHILDREN works differently and the cap is advertised. |
To get K-9 Mail working, I changed the follwing
to line: https://github.com/emersion/go-imap/blob/master/commands/list.go#L41
Please excuse my go. I've only been writing it for one day.
references: https://stackoverflow.com/questions/44027826/convert-interface-to-string-in-golang
The text was updated successfully, but these errors were encountered: