[horde] Duplicate calendar entries via ActiveSync on Samsung mobiles - fixed?

Michael J Rubinsky mrubinsk at horde.org
Sun Feb 2 20:14:27 UTC 2014


Quoting Lukas Gradl <horde at ssn.at>:

>> I released a new pear package with some changes that may or may not  
>> help this. I tweaked the order that the calendar tags are sent in -  
>> which is the only difference I can see in your traces. They are now  
>> sent in the order that the protocol docs list them (though they are  
>> explicitly specified as being non-sequential). No idea if this will  
>> help, as I am still unable to reproduce this on any of my test  
>> clients.
>
> I upgraded to 2.12.3 and tested again - no change unfortunatly.
>
> So I created tshark-traces again using Horde->Galaxy Note and (for  
> comparison) Tine20->Galaxy Note.
> No other devices included - just added an appointment via WEB-GUI.
>
> I tried to compare the two traces using Wireshark - unfortunatly I  
> don't know that much about ActiveSync.
> These are the differences I've seen in the WBXML-Data:
>
> - What is the "Error"-Section for? In the Horde trace there is one  
> befor the Folders-Section, in Tine20 it's just inside the  
> Folders-Section.

I assume you mean the <status> node? Some wireshark filters  
erroneously label this as <error>. Either way, Tine is sending an  
invalid response. This is the parsed response from Tine:

<Sync>
   <Collections>
     <Collection>
       <Class>
         'Calendar'
       </Class>
       <SyncKey>
         '15'
       </SyncKey>
       <CollectionId>
         'calendar-root'
       </CollectionId>
       <Status>
        '1'
       </Status>
       <Commands>
.
.
     </Commands>
   </Collection>
  </Collections>
</Sync>

First thing to notice is that it is missing the top-level <Status>  
node. This is a *required* node in a SYNC response, and is required to  
be the first child of <Sync>. The second thing to note is that Tine is  
sending the <Class> node. This node is NOT supposed to be sent when  
ASProtocolVersion is > 12.1 (which it is - Tine is advertising 14.1).

I have no idea what affect this has on the client, but it is  
*definitely* not correct Wbxml for a Sync response under EAS version  
14 or 14.1.

The correct Sync response for EAS version 14(.1) is:

<Sync>
  <Status>
    '1'
  </Staus>
  <Collections>
   <Collection>
     <SyncKey>
       '15'
     </SyncKey>
     <CollectionId>
       'calendar-root'
     </CollectionId>
     <Status>
      '1'
     </Status>
     <Commands>
.
.
.
     </Commands>
   </Collection>
  </Collections>
</Sync>


> - in the Horde trace there are two sections after MeetingStatus my  
> Wireshark titles with "Requested token code page not defined for  
> this content type".

You are probably using an old/outdated version of Wireshark that  
doesn't understand the newer additions to the protocol. After  
MeetingStatus is the Body structure and ResponseType. The following is  
the full parsed response from my local Wireshark:


             0 | Tag   | T   0    |   Known Tag 0x05           (.C) |  <Sync>
             1 | Tag   | T   0    |   Known Tag 0x0E           (.C) |   
   <Status>
             1 | Tag   | T   0    | STR_I (Inline string)           |    '1'
             1 | Tag   | T   0    | END (Known Tag 0x0E)            |   
   </Status>
             1 | Tag   | T   0    |   Known Tag 0x1C           (.C) |   
   <Collections>
             2 | Tag   | T   0    |   Known Tag 0x0F           (.C) |   
     <Collection>
             3 | Tag   | T   0    |   Known Tag 0x0B           (.C) |   
       <SyncKey>
             3 | Tag   | T   0    | STR_I (Inline string)           |   
       '{52ebddd5-fc80-4b03-8eaa-745553892d46}25'
             3 | Tag   | T   0    | END (Known Tag 0x0B)            |   
       </SyncKey>
             3 | Tag   | T   0    |   Known Tag 0x12           (.C) |   
       <CollectionId>
             3 | Tag   | T   0    | STR_I (Inline string)           |   
       '@Calendar@'
             3 | Tag   | T   0    | END (Known Tag 0x12)            |   
       </CollectionId>
             3 | Tag   | T   0    |   Known Tag 0x0E           (.C) |   
       <Status>
             3 | Tag   | T   0    | STR_I (Inline string)           |   
       '1'
             3 | Tag   | T   0    | END (Known Tag 0x0E)            |   
       </Status>
             3 | Tag   | T   0    |   Known Tag 0x16           (.C) |   
       <Commands>
             4 | Tag   | T   0    |   Known Tag 0x07           (.C) |   
         <Add>
             5 | Tag   | T   0    |   Known Tag 0x0D           (.C) |   
           <ServerId>
             5 | Tag   | T   0    | STR_I (Inline string)           |   
           '20140202122249.NSUTiYPyb_9zEb8zWILz7Q1 at horde.ssn.at'
             5 | Tag   | T   0    | END (Known Tag 0x0D)            |   
           </ServerId>
             5 | Tag   | T   0    |   Known Tag 0x1D           (.C) |   
           <ApplicationData>
               | Tag   | T -->  4 | SWITCH_PAGE (Tag code page)     |
             6 | Tag   | T   4    |   Known Tag 0x05           (.C) |   
             <TimeZone>
         [truncated]     6 | Tag   | T   4    | STR_I (Inline string)   
          |               
'xP///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAoAAAAFAAMAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
             6 | Tag   | T   4    | END (Known Tag 0x05)            |   
             </TimeZone>
             6 | Tag   | T   4    |   Known Tag 0x0D           (.C) |   
             <BusyStatus>
             6 | Tag   | T   4    | STR_I (Inline string)           |   
             '2'
             6 | Tag   | T   4    | END (Known Tag 0x0D)            |   
             </BusyStatus>
             6 | Tag   | T   4    |   Known Tag 0x11           (.C) |   
             <DTStamp>
             6 | Tag   | T   4    | STR_I (Inline string)           |   
             '20140202T111934Z'
             6 | Tag   | T   4    | END (Known Tag 0x11)            |   
             </DTStamp>
             6 | Tag   | T   4    |   Known Tag 0x12           (.C) |   
             <EndTime>
             6 | Tag   | T   4    | STR_I (Inline string)           |   
             '20140202T160000Z'
             6 | Tag   | T   4    | END (Known Tag 0x12)            |   
             </EndTime>
             6 | Tag   | T   4    |   Known Tag 0x25           (.C) |   
             <Sensitivity>
             6 | Tag   | T   4    | STR_I (Inline string)           |   
             '0'
             6 | Tag   | T   4    | END (Known Tag 0x25)            |   
             </Sensitivity>
             6 | Tag   | T   4    |   Known Tag 0x26           (.C) |   
             <Subject>
             6 | Tag   | T   4    | STR_I (Inline string)           |   
             'Test Horde2Note'
             6 | Tag   | T   4    | END (Known Tag 0x26)            |   
             </Subject>
             6 | Tag   | T   4    |   Known Tag 0x27           (.C) |   
             <StartTime>
             6 | Tag   | T   4    | STR_I (Inline string)           |   
             '20140202T150000Z'
             6 | Tag   | T   4    | END (Known Tag 0x27)            |   
             </StartTime>
             6 | Tag   | T   4    |   Known Tag 0x28           (.C) |   
             <UID>
             6 | Tag   | T   4    | STR_I (Inline string)           |   
              
'32303134303230323132323234392E4E53555469595079625F397A4562387A57494C7A37513140686F7264652E73736E2E6174'
             6 | Tag   | T   4    | END (Known Tag 0x28)            |   
             </UID>
             6 | Tag   | T   4    |   Known Tag 0x18           (.C) |   
             <MeetingStatus>
             6 | Tag   | T   4    | STR_I (Inline string)           |   
             '0'
             6 | Tag   | T   4    | END (Known Tag 0x18)            |   
             </MeetingStatus>
               | Tag   | T --> 17 | SWITCH_PAGE (Tag code page)     |
             6 | Tag   | T  17    |   Known Tag 0x0A           (.C) |   
             <Body>
             7 | Tag   | T  17    |   Known Tag 0x06           (.C) |   
               <Type>
             7 | Tag   | T  17    | STR_I (Inline string)           |   
               '1'
             7 | Tag   | T  17    | END (Known Tag 0x06)            |   
               </Type>
             7 | Tag   | T  17    |   Known Tag 0x0C           (.C) |   
               <EstimatedDataSize>
             7 | Tag   | T  17    | STR_I (Inline string)           |   
               '0'
             7 | Tag   | T  17    | END (Known Tag 0x0C)            |   
               </EstimatedDataSize>
             6 | Tag   | T  17    | END (Known Tag 0x0A)            |   
             </Body>
               | Tag   | T -->  4 | SWITCH_PAGE (Tag code page)     |
             6 | Tag   | T   4    |   Known Tag 0x36           (.C) |   
             <ResponseType>
             6 | Tag   | T   4    | STR_I (Inline string)           |   
             '3'
             6 | Tag   | T   4    | END (Known Tag 0x36)            |   
             </ResponseType>
             5 | Tag   | T   4    | END (Known Tag 0x1D)            |   
           </ApplicationData>
             4 | Tag   | T   4    | END (Known Tag 0x07)            |   
         </Add>
             3 | Tag   | T   4    | END (Known Tag 0x16)            |   
       </Commands>
             2 | Tag   | T   4    | END (Known Tag 0x0F)            |   
     </Collection>
               | Tag   | T -->  0 | SWITCH_PAGE (Tag code page)     |
             2 | Tag   | T   0    |   Known Tag 0x0F           (.C) |   
     <Collection>
             3 | Tag   | T   0    |   Known Tag 0x0B           (.C) |   
       <SyncKey>
             3 | Tag   | T   0    | STR_I (Inline string)           |   
       '{52ebdf62-b330-4290-a9c1-733953892d46}2'
             3 | Tag   | T   0    | END (Known Tag 0x0B)            |   
       </SyncKey>
             3 | Tag   | T   0    |   Known Tag 0x12           (.C) |   
       <CollectionId>
             3 | Tag   | T   0    | STR_I (Inline string)           |   
       'Fd400e4e9'
             3 | Tag   | T   0    | END (Known Tag 0x12)            |   
       </CollectionId>
             3 | Tag   | T   0    |   Known Tag 0x0E           (.C) |   
       <Status>
             3 | Tag   | T   0    | STR_I (Inline string)           |   
       '1'
             3 | Tag   | T   0    | END (Known Tag 0x0E)            |   
       </Status>
             2 | Tag   | T   0    | END (Known Tag 0x0F)            |   
     </Collection>
             1 | Tag   | T   0    | END (Known Tag 0x1C)            |   
   </Collections>
             0 | Tag   | T   0    | END (Known Tag 0x05)            |  </Sync>



> - What's that second "Folder"-Section in Horde-Trace for?

Not sure what you mean. If you mean the Last <Collection> Node in the  
above trace, that's the response for an Email collection. Multiple  
collection results can be returned in a single Sync response.

> As a next step I'll play around with debugging on the Galaxy Note -  
> perhaps there's something to find there.
> There are so many Samsung devices around - I would be glad if this  
> will work properly, so if I can help in any aspect...

I have a Galaxy Note and am unable to reproduce this on it (or any  
other device for that matter). I know that at least one other  
developer has a Galaxy S3 or 4 and has not reported this either.

-- 
mike
The Horde Project
http://www.horde.org
https://www.facebook.com/hordeproject
https://www.twitter.com/hordeproject

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5849 bytes
Desc: S/MIME Signature
URL: <http://lists.horde.org/archives/horde/attachments/20140202/9020d822/attachment.bin>


More information about the horde mailing list