On 22 Jul 2021, at 21:55, Oswald Buddenhagen <oswald.buddenha...@gmx.de> wrote:
> On Thu, Jul 22, 2021 at 08:20:04PM +0100, Sabahattin Gucukoglu via 
> isync-devel wrote:
>> Without the workaround script below, CAPABILITY is never issued by mbsync, 
>> therefore the bodging is still in effect and I got bogus response [...]
> 
> ok, from what i gather the short version is that that proxy (?) simply 
> replaces the first five occurrences of "CAPABILITY" sent by the server with 
> "CAPABILITY XAPPLEPUSHSERVICE”.

Sorry, no, that was just an example, to illustrate that pre-login there is no 
change and after login there is. There is a state transition that happens after 
login, such that the output to the capability command is rewritten one last 
time, and then it becomes transparent. Until the state change occurs, 
CAPABILITY is always and everywhere followed by XAPPLEPUSHSERVICE and “ 
STARTTLS” is deleted.

> what would be interesting is figuring out whether that count is influenced by 
> anything, e.g., the login, or starttls. to figure that out, you'd need to 
> issue different numbers of capability commmands before the aforementioned 
> commands and see how many subsequent capability commands are botched 
> afterwards. knowing that is important for making the workaround reliable.

Here’s “mbsync -a -l -V -DnN” run through the wrapper. The untagged CAPABILITY 
response (not automatic response code, i.e. “* CAPABILITY …”) only appears once 
in response to the wrapper issuing a CAPABILITY request once after login. 
Notice that I have silenced my request and the tagged response, but not the 
untagged response, so that it appears to be in response to the LIST command. 
Even though the response contains “XAPPLEPUSHSERVICE”, the server is now 
transparent—this is how I’m reliably syncing my mail. Hope this clarifies, but 
if not, I can try to find explicit examples of messages.

Reading configuration file /Users/sgucukoglu/.mbsyncrc
Channel sync
Opening far side store iCloud...
Starting tunnel '/Users/sgucukoglu/wrapper'... ok
Opening near side store local...
* OK [CAPABILITY XAPPLEPUSHSERVICE IMAP4 IMAP4rev1 SASL-IR AUTH=ATOKEN 
AUTH=PLAIN] (2114B34-a748bbbd8277) pv50p00im-tygg10020201.me.com
Logging in...
*** IMAP Warning *** Password is being sent in the clear
>>> 1 LOGIN <user> <pass>
* OK [CAPABILITY XAPPLEPUSHSERVICE IMAP4 IMAP4rev1 ACL RIGHTS=tekx QUOTA 
LITERAL+ NAMESPACE UIDPLUS CHILDREN BINARY UNSELECT SORT CATENATE URLAUTH 
LANGUAGE ESEARCH ESORT THREAD=ORDEREDSUBJECT THREAD=REFERENCES CONDSTORE ENABLE 
QRESYNC CONTEXT=SEARCH CONTEXT=SORT WITHIN SASL-IR SEARCHRES METADATA ID 
LIST-STATUS SPECIAL-USE CREATE-SPECIAL-USE MULTISEARCH SORT=DISPLAY 
LOGIN-REFERRALS UTF8=ACCEPT URL-PARTIAL STATUS=SIZE XSNIPPET=FUZZY X-SUN-SORT 
ANNOTATE-EXPERIMENT-1 X-SUN-IMAP XUM1 X-ORCL-AS IDLE AUTH=PLAIN AUTH=ATOKEN 
AUTH=WSTOKEN AUTH=WETOKEN AUTH=PTOKEN] ms72055.mac.com IMAP4 service (Oracle 
Communications Messaging Server 8.0.2.5.20200127 64bit (built Jan 27 2020))
1 OK User sgucukoglu logged in
>>> 2 LIST "" "*"
* CAPABILITY XAPPLEPUSHSERVICE IMAP4 IMAP4rev1 ACL RIGHTS=tekx QUOTA LITERAL+ 
NAMESPACE UIDPLUS CHILDREN BINARY UNSELECT SORT CATENATE URLAUTH LANGUAGE 
ESEARCH ESORT THREAD=ORDEREDSUBJECT THREAD=REFERENCES CONDSTORE ENABLE QRESYNC 
CONTEXT=SEARCH CONTEXT=SORT WITHIN SASL-IR SEARCHRES METADATA ID LIST-STATUS 
SPECIAL-USE CREATE-SPECIAL-USE MULTISEARCH SORT=DISPLAY LOGIN-REFERRALS 
UTF8=ACCEPT URL-PARTIAL STATUS=SIZE XSNIPPET=FUZZY X-SUN-SORT 
ANNOTATE-EXPERIMENT-1 X-SUN-IMAP XUM1 X-ORCL-AS IDLE
* LIST (\NoInferiors) "/" INBOX
* LIST (\HasNoChildren) "/" @SaneNews
* LIST (\HasNoChildren) "/" @SaneSecurity
* LIST (\HasNoChildren) "/" Archive
* LIST (\HasNoChildren) "/" BlindFaith
* LIST (\HasNoChildren) "/" Deal
* LIST (\HasNoChildren) "/" Deal2
* LIST (\HasNoChildren) "/" "Deleted Messages"
* LIST (\HasNoChildren) "/" Discussion
* LIST (\HasNoChildren) "/" Drafts
* LIST (\HasNoChildren) "/" Games
* LIST (\HasNoChildren) "/" IETF-SMTP
* LIST (\HasNoChildren) "/" Junk
* LIST (\HasNoChildren) "/" Notes
* LIST (\HasNoChildren) "/" Obelisk
* LIST (\HasNoChildren) "/" "Sent Messages"
* LIST (\HasNoChildren) "/" Unprocessed
* LIST (\HasNoChildren) "/" Unprocessed2
* LIST (\HasNoChildren) "/" Untidy
* LIST (\HasNoChildren) "/" Untidy2
2 OK Completed
INBOX
@SaneNews
@SaneSecurity
Archive
BlindFaith
Deal
Deal2
Deleted Messages
Discussion
Drafts
Games
IETF-SMTP
Junk
Notes
Obelisk
Sent Messages
Unprocessed
Unprocessed2
Untidy
Untidy2
>>> 3 LOGOUT
* BYE LOGOUT received
3 OK Completed

Cheers,
Sabahattin



_______________________________________________
isync-devel mailing list
isync-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/isync-devel

Reply via email to