I guess something like the below may do the trick. The Discourse doesn’t let me attach a text file, thus it’s inline (with broken whitespace, I believe). The debug prints are done on the evolution-addressbook-factory console.
diff --git a/src/EWS/addressbook/ews-oab-decoder.c b/src/EWS/addressbook/ews-oab-decoder.c
index 226e35fa..0ab731fd 100644
--- a/src/EWS/addressbook/ews-oab-decoder.c
+++ b/src/EWS/addressbook/ews-oab-decoder.c
@@ -96,6 +96,32 @@ ews_deffered_populate_physical_address (EwsDeferredSet *dset,
}
}
+static void
+ews_populate_middle_name (EContact *contact,
+ EContactField field,
+ gpointer value,
+ gpointer user_data)
+{
+ const gchar *str = (const gchar *) value;
+ if (str && *str) {
+ EContactName *name = e_contact_get (contact, field);
+ gchar *prev;
+
+ if (!name)
+ name = e_contact_name_new ();
+
+ prev = name->additional;
+ name->additional = (gchar *) str;
+
+ e_contact_set (contact, field, name);
+
+ name->additional = prev;
+ e_contact_name_free (name);
+
+ g_print ("%s: found middle name '%s'\n", __FUNCTION__, str); fflush (stdout);
+ }
+}
+
static void
ews_populate_phone_numbers (EContact *contact,
EContactField field,
@@ -255,6 +281,7 @@ static const struct prop_field_mapping {
{EWS_PT_ACCOUNT, E_CONTACT_NICKNAME, ews_populate_simple_string},
{EWS_PT_SURNAME, E_CONTACT_FAMILY_NAME, ews_populate_simple_string},
{EWS_PT_GIVEN_NAME, E_CONTACT_GIVEN_NAME, ews_populate_simple_string},
+ {EWS_PT_MIDDLE_NAME, E_CONTACT_NAME, ews_populate_middle_name},
{EWS_PT_BUS_TEL_NUMBER, E_CONTACT_PHONE_BUSINESS, ews_populate_simple_string},
{EWS_PT_STREET_ADDRESS, E_CONTACT_ADDRESS_WORK, NULL, ews_deffered_populate_physical_address},
{EWS_PT_LOCALITY, E_CONTACT_ADDRESS_WORK, NULL, ews_deffered_populate_physical_address},
diff --git a/src/EWS/addressbook/ews-oab-props.h b/src/EWS/addressbook/ews-oab-props.h
index 2516757d..6889d2bb 100644
--- a/src/EWS/addressbook/ews-oab-props.h
+++ b/src/EWS/addressbook/ews-oab-props.h
@@ -36,6 +36,7 @@
#define EWS_PT_ACCOUNT 0x3A00001F
#define EWS_PT_SURNAME 0x3A11001F
#define EWS_PT_GIVEN_NAME 0x3A06001F
+#define EWS_PT_MIDDLE_NAME 0x3A44001F
#define EWS_PT_OFFICE_LOCATION 0x3A19001F
#define EWS_PT_BUS_TEL_NUMBER 0x3A08001F
#define EWS_PT_INITIALS 0x3A0A001F