XML Autoconfig clientid support
Categories
(Thunderbird :: Account Manager, enhancement)
Tracking
(Not tracked)
People
(Reporter: danielf, Assigned: danielf)
Details
Attachments
(1 file)
|
5.22 KB,
patch
|
mkmelin
:
review-
|
Details | Diff | Splinter Review |
User Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:78.0) Gecko/20100101 Firefox/78.0
Expected results:
Hello Thunderbird team,
LinuxMagic is looking to expand the Clientid implementation of Thunderbird.
We would like to start the next step with an enhancement to the XML autoconfig system, we are looking to add a field which would allow clientid to be pre-emptively enabled via the XML autoconfig file.
I have attached a patch which would allow a new field "clientidEnabled" to be parsed out of the autoconfig XML files as a boolean for whether the feature should be enabled for the given account.
The purpose of the changes in the patch are:
-
Addition of clientid + clientidEnabled fields to the AccountConfig object thereby allowing the readFromXML() function to parse the clientidEnabled field in the XML file.
-
Addition of logic to readFromXML() to parse the clientidEnabled field into the AccountConfig incoming/outgoing clientidEnabled fields
-
Modification of the clientid provisioning logic in createInBackend which will use the clientidEnabled and clientid values that were generated in the new AccountConfig object -- rather than generating an entirely new one. This will ensure the clientid used for the account is the same one used by verifyConfig to test the authentication on the server at the last step of autoconfig.
-
Addition of logic to verifyConfig to pass along the clientid/clientidEnabled values from the AccountConfig object to the temporary incoming server that is used to launch the incoming server authentication test. This will ensure that if clientid was enabled, that it will be utilized in the final config test where Tbird actually tries to authenticate with the server.
All together these changes shouldn't affect anything pre-existing.
For example, if the clientidEnabled field is missing from the XML file it should not cause any issues.
One might point out that the clientid UUID was already being generated within the function createInBackend() -- so why add another piece of logic in AccountConfig to generate the clientid?
The answer to that is: the function verifyConfig is only passed the temporary AccountConfig object in order to test the connection, therefore in order to ensure the same clientid is used for both the final probe and the final account, it is necessary to move the generation of the clientid to an earlier stage where it can be passed to verifyConfig, and to createInBackend.
The clientid generation code left over in createInBackend is just a last resort in case something goes wrong earlier, it will ensure a clientid is always generated for the given account.
Addendum:
This page will need to be updated at some point too:
https://wiki.mozilla.org/Thunderbird:Autoconfiguration:ConfigFileFormat
Comment 2•5 years ago
|
||
Updated•5 years ago
|
Comment 3•2 years ago
|
||
I don't think we'd want to add something like this to the xml.
Do you agree?
(Daniel's email address bounces)
Agreed. I don't think this should be part of autoconfig.
Comment 5•2 years ago
|
||
I'm not knowledgeable enough on clientid so deferring to cketti.
Updated•2 years ago
|
Description
•