View Issue Details

IDProjectCategoryView StatusLast Update
0004383SOGoActiveSyncpublic2023-05-23 07:09
ReporterPhilipp Assigned To 
PrioritynormalSeverityminorReproducibilityalways
Status newResolutionopen 
PlatformLinuxOSUbuntuOS Version16.04LTS
Product Versionnightly master 
Summary0004383: iOS invite to event + ActiveSync = RANDOM organizer name with correct email
Description

When inviting to event from iOS via ActiveSync, Outlook user gets invitation with From: <Fixed random name from LDAP> and correct organizer email. Very weird. When Outlook receives invite with ICS attached, it shows that mail is from event organizer, not email From: address, so user thinks another person sent him invite (and affected user, of course, was my boss).

Steps To Reproduce

Using SOGo connected to LDAP/AD, send invite to user and look at invite with Outlook, name is wrong.

Additional Information

Looking sogo/ActiveSync/iCalEvent+ActiveSync.m (at line 813) i see comment:

 //
 // iOS is plain stupid here. It seends event invitations with no Organizer.
 // We check this corner-case and if MeetingStatus == 1 (see http://msdn.microsoft.com/en-us/library/ee219342(v=exchg.80).aspx or details)
 // and there's no organizer, we fake one.
 //

That's the case, and next 'if' code block executes and sets event organizer with cn and email.
I have checked - the name and email IS correct in this place, so perhaps change occurs somewhere further.

TagsNo tags attached.

Activities

Philipp

Philipp

2018-02-05 08:25

reporter   ~0012554

It seems everything works ok EXCEPT sending appointments (named 'meeting.ics', after creating meeting on iOS) to participants - there organiser name is incorrect. In database, in backup - organiser name is correct. It would be great if Inverse devs could point me to place where meeting.ics is generated, then I could dig into problem and try to resolve it.

tfu

tfu

2018-02-05 09:02

reporter   ~0012555

Can you please show the meeting.ics received by outlook and the calendar event stored in sogo.

Philipp

Philipp

2018-02-05 09:17

reporter   ~0012556

ActiveSync request coming from James Smith <james.smith@domain.com> iOS 10 Mail.app inviting John Doe <john.doe@domain.com> to event (as you can see - iOS specific - no organiser):

<!DOCTYPE ActiveSync PUBLIC "-//MICROSOFT//DTD ActiveSync//EN" "http://www.microsoft.com/&quot;>
<Sync xmlns="AirSync:">
<Collections>
<Collection>
<SyncKey>1517564122</SyncKey>
<CollectionId>vevent%2Fpersonal</CollectionId>
<GetChanges/>
<WindowSize>25</WindowSize>
<Options>
<FilterType>5</FilterType>
<BodyPreference xmlns="AirSyncBase:">
<Type>1</Type>
<TruncationSize>32768</TruncationSize>
</BodyPreference>
</Options>
<Commands>
<Add>
<ClientId>1229</ClientId>
<ApplicationData>
<Body xmlns="AirSyncBase:">
<Type>1</Type>
<Data/>
</Body>
<TimeZone xmlns="Calendar:">iP///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAoAAAAFAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
<AllDayEvent xmlns="Calendar:">0</AllDayEvent>
<BusyStatus xmlns="Calendar:">2</BusyStatus>
<DTStamp xmlns="Calendar:">20180202T094111Z</DTStamp>
<EndTime xmlns="Calendar:">20180205T100000Z</EndTime>
<Sensitivity xmlns="Calendar:">0</Sensitivity>
<Subject xmlns="Calendar:">Zopa</Subject>
<StartTime xmlns="Calendar:">20180205T090000Z</StartTime>
<UID xmlns="Calendar:">B1520CFFF12648C9B437B16450029E3B0</UID>
<MeetingStatus xmlns="Calendar:">1</MeetingStatus>
<Attendees xmlns="Calendar:">
<Attendee>
<Attendee_Name>john.doe@domain.com</Attendee_Name>
<Attendee_Email>john.doe@domain.com</Attendee_Email>
</Attendee>
</Attendees>
</ApplicationData>
</Add>
</Commands>
</Collection>
</Collections>
</Sync>

Philipp

Philipp

2018-02-05 09:18

reporter   ~0012557

SOGo ActiveSync response (<Organizer> name is not correct here - it somehow become 'Paul Rain', while email is correct - james.smith@domain.com):

<Sync xmlns="AirSync:">
<Collections>
<Collection>
<Class>Email</Class>
<SyncKey>343-893</SyncKey>
<CollectionId>mail%2Fe8d4fd1201e9275a14590000b946885b</CollectionId>
<Status>1</Status>
<Commands>
<Add>
<ServerId>343</ServerId>
<ApplicationData>
<To xmlns="Email:">"john.doe@domain.com" <john.doe@domain.com></To>
<From xmlns="Email:">"James Smith" <james.smith@domain.com></From>
<Subject xmlns="Email:">Zopa</Subject>
<ThreadTopic xmlns="Email:">Zopa</ThreadTopic>
<DateReceived xmlns="Email:">2018-02-02T09:41:12.000Z</DateReceived>
<DisplayTo xmlns="Email:">12078</DisplayTo>
<Importance xmlns="Email:">1</Importance>
<Read xmlns="Email:">1</Read>
<MessageClass xmlns="Email:">IPM.Schedule.Meeting.Request</MessageClass>
<MeetingRequest xmlns="Email:">
<AllDayEvent>0</AllDayEvent>
<StartTime>2018-02-05T09:00:00.000Z</StartTime>
<DTStamp>2018-02-02T09:41:11.000Z</DTStamp>
<EndTime>2018-02-05T10:00:00.000Z</EndTime>
<InstanceType>0</InstanceType>
<Organizer>Paul Rain <james.smith@domain.com></Organizer>
<ResponseRequested>0</ResponseRequested>
<Sensitivity>0</Sensitivity>
<BusyStatus>2</BusyStatus>
<TimeZone>iP///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAoAAAAFAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
<DisallowNewTimeProposal>1</DisallowNewTimeProposal>
<GlobalObjId>BAAAAIIA4AB0xbcQGoLgCAAAAAAAAAAAAAAAAAAAAAAAAAAALQAAAHZDYWwtVWlkAQAAAEIxNTIwQ0ZGRjEyNjQ4QzlCNDM3QjE2NDUwMDI5RTNCMA==</GlobalObjId>
<MeetingMessageType xmlns="Email2:">1</MeetingMessageType>
</MeetingRequest>
<ContentClass xmlns="Email:">urn:content-classes:calendarmessage</ContentClass>
<InternetCPID xmlns="Email:">65001</InternetCPID>
<Body xmlns="AirSyncBase:">
<Type>1</Type>
<Truncated>0</Truncated>
<Preview/>
<Data></Data>
<EstimatedDataSize>1</EstimatedDataSize>
</Body>
<Attachments xmlns="AirSyncBase:">
<Attachment>
<DisplayName>meeting.ics</DisplayName>
<FileReference>mail/Sent/343/2</FileReference>
<Method>1</Method>
<EstimatedDataSize>1409</EstimatedDataSize>
</Attachment>
</Attachments>
<Flag xmlns="Email:">
<FlagStatus>0</FlagStatus>
</Flag>
<Categories xmlns="Email:"/>
<ConversationId xmlns="Email2:">PDYxNkJGMzZDLTNEREQtNDJBNC04RDZFLTg5MENCRTk2QkRCN0BsaXRyYWlsLmx0Pg==</ConversationId>
<LastVerbExecuted xmlns="Email2:">0</LastVerbExecuted>
<NativeBodyType xmlns="AirSyncBase:">1</NativeBodyType>
</ApplicationData>
</Add>
</Commands>
</Collection>
</Collections>
</Sync>

Philipp

Philipp

2018-02-05 09:18

reporter   ~0012558

File meeting.ics contents that was received by John Doe <john.doe@domain.com> (incorrect organizer name):

BEGIN:VCALENDAR
CALSCALE:GREGORIAN
METHOD:REQUEST
PRODID:-//Apple Inc.//iPhone 3.0//EN
VERSION:2.0
BEGIN:VTIMEZONE
TZID:Europe/Vilnius
BEGIN:STANDARD
DTSTART:20171029T040000
RRULE:FREQ=YEARLY;BYMONTH=10;BYDAY=-1SU
TZNAME:EET
TZOFFSETFROM:+0300
TZOFFSETTO:+0200
END:STANDARD
BEGIN:DAYLIGHT
DTSTART:20180325T030000
RRULE:FREQ=YEARLY;BYMONTH=3;BYDAY=-1SU
TZNAME:EEST
TZOFFSETFROM:+0200
TZOFFSETTO:+0300
END:DAYLIGHT
END:VTIMEZONE
BEGIN:VEVENT
ATTENDEE;CN="john.doe@domain.com";CUTYPE=INDIVIDUAL;PARTSTAT=NEE
DS-ACTION;RSVP=TRUE:mailto:john.doe@domain.com
CLASS:PUBLIC
CREATED:20180202T094111Z
DTEND;TZID=Europe/Vilnius:20180205T120000
DTSTAMP:20180202T094111Z
DTSTART;TZID=Europe/Vilnius:20180205T110000
LAST-MODIFIED:20180202T094111Z
LOCATION:
ORGANIZER;CN="Paul Rain";EMAIL="james.smith@domain.com":mailto:ja
mes.smith@domain.com
SEQUENCE:0
SUMMARY:Zopa
TRANSP:OPAQUE
UID:B1520CFFF12648C9B437B16450029E3B0
URL;VALUE=URI:
X-MICROSOFT-CDO-INTENDEDSTATUS:BUSY
BEGIN:VALARM
ACTION:NONE
TRIGGER;VALUE=DATE-TIME:19760401T005545Z
END:VALARM
END:VEVENT
END:VCALENDAR

Philipp

Philipp

2018-02-05 09:19

reporter   ~0012559

Raw event source as seen by organizer James Smith via SOGo webmail:

BEGIN:VCALENDAR
PRODID:-//Inverse inc./SOGo 3.2.10//EN
VERSION:2.0
BEGIN:VTIMEZONE
TZID:Europe/Vilnius
X-LIC-LOCATION:Europe/Vilnius
BEGIN:DAYLIGHT
TZOFFSETFROM:+0200
TZOFFSETTO:+0300
TZNAME:EEST
DTSTART:19700329T030000
RRULE:FREQ=YEARLY;BYMONTH=3;BYDAY=-1SU
END:DAYLIGHT
BEGIN:STANDARD
TZOFFSETFROM:+0300
TZOFFSETTO:+0200
TZNAME:EET
DTSTART:19701025T040000
RRULE:FREQ=YEARLY;BYMONTH=10;BYDAY=-1SU
END:STANDARD
END:VTIMEZONE
BEGIN:VEVENT
UID:B1520CFFF12648C9B437B16450029E3B0
SUMMARY:Zopa
TRANSP:OPAQUE
CLASS:PUBLIC
DTSTART;TZID=Europe/Vilnius:20180205T110000
DTEND;TZID=Europe/Vilnius:20180205T120000
ORGANIZER;PARTSTAT=ACCEPTED;CN=James Smith:mailto:james.smith@domain.com
ATTENDEE;CN=john.doe@domain.com;PARTSTAT=NEEDS-ACTION;RSVP=TRUE:mai
lto:john.doe@domain.com
LAST-MODIFIED:20180202T094112Z
END:VEVENT
END:VCALENDAR

tfu

tfu

2018-02-05 20:48

reporter   ~0012563

So from above it seems that the calender invite in organizer's calendar is ok. right?

Can you check for a SendMail command in sogo.log when sending the invite.
-> PRODID:-//Apple Inc.//iPhone 3.0//EN seems to come from the iphone.

Philipp

Philipp

2018-02-06 05:11

reporter   ~0012564

@tfu yes, alender invite in organizer's calendar. From what I see generated ICS that was sent to invitees is incorrect.

And yes, it happens when creating meeting in iOS Calendar.app (ActiveSync account). I dont' full understand the process, but it seems that:

1) User creates calendar event in Calendar.app with invitees
2) ActiveSync request is sent and response received (see log above)
3) Device sends invitations (meeting.ics) based on response received

I see SendMail command:

Feb 02 11:41:12 sogod [2251]: <0x0x565077db73e0[SOGoActiveSyncDispatcher]> EAS - request for device 6MQJHO4OOD6PJ2FF1EC6N1KFMC: <?xml version="1.0"?>
<!DOCTYPE ActiveSync PUBLIC "-//MICROSOFT//DTD ActiveSync//EN" "http://www.microsoft.com/&quot;>
<SendMail xmlns="ComposeMail:">
<ClientId>616BF36C-3DDD-42A4-8D6E-890CBE96BDB7</ClientId>
<SaveInSentItems/>
<MIME>... base64 encoded mail message containing INCORRECT meeting.ics attachment</MIME>
</SendMail>
2018-02-02 11:41:12.863 sogod[2251] MimeType 'text/*' does not support a parameter named 'x-apple-part-url' with value '86CEDE2F-6E9A-4D24-A3CC-E5CE98DCCC76'

Don't know if last log line is related to my problem.

Philipp

Philipp

2018-02-06 05:12

reporter   ~0012565

@tfu calender invite in organizer's calendar is ok

tfu

tfu

2018-02-06 08:32

reporter   ~0012566

The mail (with the meeting.ics) is created on the phone. So I assume that "Paul Rain" comes from the phone.

Philipp

Philipp

2018-02-06 09:22

reporter   ~0012567

Yes, but as I see it is created automatically from SOGo ActiveSync response (log above), which has:

<Organizer>Paul Rain <james.smith@domain.com></Organizer>

which is incorrect

tfu

tfu

2018-02-06 10:35

reporter   ~0012568

The body of the sendmail requests is created on the phone. Sogo just sends the mail based on this. The response starting with
<SyncKey>343-893</SyncKey>
<CollectionId>mail%2Fe8d4fd1201e9275a14590000b946885b</CollectionId>
is syncing just the received mail to the client.

Philipp

Philipp

2018-02-06 10:58

reporter   ~0012569

But ActiveSync RESPONSE returns

<Organizer>Paul Rain <james.smith@domain.com></Organizer>

I don't believe that phone picking random name (Paul Rain) with by coincidence equals random name (Paul Rain) returned by SOGo in response to ActiveSync 'add vevent' request. Perhaps sendmail request created by the phone based on incorrect information returned by ActiveSync.

mm

mm

2019-12-11 11:12

reporter   ~0013973

Hi,
is someone actively investigating this problem anymore?
We ran into the same issue and have massive problems caused by this:

  • Our employees immediately lose access to their own events they created on iOS because someone RANDOM is set as organisator.
  • Additionally the other random person is confused because they get a reminder for a foreign event they don't know anything about.

You already pinned down the problem, but this ticket wasn't touched since. I assume that the the needed effort to resolve this isn't that high after the good groudwork. So can someone please fix that?

Regarding
// iOS is plain stupid here. It seends event invitations with no Organizer.
// We check this corner-case and if MeetingStatus == 1 (see http://msdn.microsoft.com/en-us/library/ee219342(v=exchg.80).aspx or details)
// and there's no organizer, we fake one.
Why should one fake the organizer with a random value? Why not use the creator of the event?

Thanks

Issue History

Date Modified Username Field Change
2018-02-02 12:56 Philipp New Issue
2018-02-05 08:25 Philipp Note Added: 0012554
2018-02-05 09:02 tfu Note Added: 0012555
2018-02-05 09:17 Philipp Note Added: 0012556
2018-02-05 09:18 Philipp Note Added: 0012557
2018-02-05 09:18 Philipp Note Added: 0012558
2018-02-05 09:19 Philipp Note Added: 0012559
2018-02-05 20:48 tfu Note Added: 0012563
2018-02-06 05:11 Philipp Note Added: 0012564
2018-02-06 05:12 Philipp Note Added: 0012565
2018-02-06 08:32 tfu Note Added: 0012566
2018-02-06 09:22 Philipp Note Added: 0012567
2018-02-06 10:35 tfu Note Added: 0012568
2018-02-06 10:58 Philipp Note Added: 0012569
2019-12-11 11:12 mm Note Added: 0013973