account setup should prefer standard protocols over exchange
Categories
(Thunderbird :: Account Manager, defect)
Tracking
(thunderbird_esr68+ fixed, thunderbird75+ fixed)
People
(Reporter: mkmelin, Assigned: mkmelin)
References
(Regression)
Details
(Keywords: regression)
Attachments
(3 files, 3 obsolete files)
6.99 KB,
text/xml
|
Details | |
2.70 KB,
patch
|
Details | Diff | Splinter Review | |
6.62 KB,
patch
|
mkmelin
:
review+
BenB
:
review-
wsmwk
:
approval-comm-beta+
wsmwk
:
approval-comm-esr68+
|
Details | Diff | Splinter Review |
If an exchange account type is detected via autodiscover.xml it will usually (always?) be the listed in the xml above the standard protocols. Therefore it will become the default in the config we use. This is clearly incorrect. If standard protocols are listed they should be preferred. In fact it was never the intention to even show exchange for that case.
Assignee | ||
Updated•5 years ago
|
Assignee | ||
Updated•5 years ago
|
Comment 1•5 years ago
•
|
||
You mean if the AutoDiscover.xml lists both IMAP and Exchange options, then IMAP should be the default?
I'll fix this.
Ben Bucksch
Assignee | ||
Comment 2•5 years ago
|
||
I have a patch I just need to test it some more.
Comment 3•5 years ago
|
||
If the AutoDiscover XML returns both Exchange and IMAP or POP3 configs, then prefer the IMAP config.
I've tested this with normal Office365, but I don't have a test case where this triggers. The code should do the right thing, though.
Assignee | ||
Comment 4•5 years ago
|
||
Assignee | ||
Comment 5•5 years ago
|
||
This is the patch I had.
But I'd like to have a sample autodiscover xml file to test this with.
Comment 6•5 years ago
|
||
Assignee | ||
Comment 7•5 years ago
|
||
(In reply to Ben Bucksch (:BenB) from comment #6)
Drop this line.
Without that it doesn't give you the sorted alternatives.
Comment 8•5 years ago
|
||
Ah, I think you meant: this.incomingAlternatives = alternatives;
Assignee | ||
Comment 9•5 years ago
|
||
Sample response for when imap pop and smtp are set in the autodiscover result.
Assignee | ||
Comment 10•5 years ago
|
||
Fixes some related problems too:
- looks like autodiscover.xml really uses Capitalized "On" or "Off"
- outgoing server auth need to be set to something, otherwise it won't succeed
- far from all callers pass the second argument allErrors, I notice...
Assignee | ||
Comment 11•5 years ago
|
||
To test: apply the debug patch too, and bug 1623398.
Try to set up an account for say foo@localhost - it will check the bugzilla attachment for a configuration.
Comment 12•5 years ago
|
||
Assignee | ||
Comment 13•5 years ago
|
||
Made the suggested changes.
Assignee | ||
Comment 14•5 years ago
|
||
Going to land later today.
Comment 15•5 years ago
•
|
||
I didn't have time to look at it yet, over the last 3 days, due to problems arising from Corona. I'll look at it.
Please give me a chance to review.
Assignee | ||
Comment 16•5 years ago
|
||
So, did you?
Comment 17•5 years ago
|
||
Pushed by mkmelin@iki.fi:
https://hg.mozilla.org/comm-central/rev/0f20836e8455
account setup should prefer standard protocols over exchange. r=aleca
Assignee | ||
Updated•5 years ago
|
Assignee | ||
Updated•5 years ago
|
Comment 18•5 years ago
•
|
||
I said in comment 15: Please give me a chance to review. I cannot give a 1-day response time right now, due to the Corona virus crisis.
Comment 19•5 years ago
|
||
Assignee | ||
Comment 20•5 years ago
|
||
(In reply to Ben Bucksch (:BenB) from comment #19)
- preferStandardProtocols() {
This does not belong here. If you put it here, then make it generic, not
about a specific protocol.
Conceptually it belongs here, should there ever be any other non-standard protocols we could find. I don't really see that ever happening though.
if (allErrors && allErrors.some(e => e.code == 401)) {
Why is this check needed? What is calling this without the
allErrors
?
There are plenty of places it actually happens especially if you set prefs to disable some of the prefs, like https://searchfox.org/comm-central/rev/36361fb3e76ab8f11bc59524f444269ff6ae84d0/mail/components/accountcreation/content/exchangeAutoDiscover.js#57. I think ever having the second parameter is really the wrong thing to do: the standard way for error callbacks is to get one parameters, and the same goes for promise rejections.
::: mail/components/accountcreation/content/exchangeAutoDiscover.js
@@ +297,5 @@server.port = sanitize.integer(protocolX.Port); server.socketType = 1; // plain if ( "SSL" in protocolX &&
protocolX.SSL.toLowerCase() == "on" // "On" or "Off"
The sanitize should stay. If there are values that are neither "on" nor
"off" (in any capitalization), then the file is invalid and it should be
rejected.
I don't see why. Even if sanitation failed we have data that could easily work. With the code we now ignore such invalid values.
Assignee | ||
Updated•5 years ago
|
Comment 21•5 years ago
|
||
Assignee | ||
Updated•5 years ago
|
Comment 22•5 years ago
|
||
bugherder uplift |
Thunderbird 75.0b3:
https://hg.mozilla.org/releases/comm-beta/rev/e99cde50f9d3
Updated•5 years ago
|
Comment 23•5 years ago
|
||
Assignee | ||
Comment 24•5 years ago
|
||
Assignee | ||
Updated•5 years ago
|
Updated•5 years ago
|
Assignee | ||
Comment 25•5 years ago
|
||
Not a regression per se, it was broken since initial exchange support.
Updated•4 years ago
|
Description
•