diff --git a/obexd/client/map.c b/obexd/client/map.c
index 7ca33cf..ef0bff3 100644
--- a/obexd/client/map.c
+++ b/obexd/client/map.c
#define OBEX_MAS_UUID \
"\xBB\x58\x2B\x40\x42\x0C\x11\xDB\xB0\xDE\x08\x00\x20\x0C\x9A\x66"
#define OBEX_MAS_UUID_LEN 16
+#define SUPPORTED_FEATURES_TAG 0x29
+
+#define NOTIFICATION_REGISTRATION_FEATURE 0x00000001
+#define NOTIFICATION_FEATURE 0x00000002
+#define BROWSING_FEATURE 0x00000004
+#define UPLOADING_FEATURE 0x00000008
+#define DELETE_FEATURE 0x00000010
+#define INSTANCE_INFORMATION_FEATURE 0x00000020
+#define EXTENDED_EVENT_REPORT_1_1 0x00000040
+#define MESSAGES_LISTING_FORMAT_VERSION_1_1 0x00000200
+#define MAPSUPPORTEDFEATURES_IN_CONNECT_REQUEST 0x00080000
#define MAP_INTERFACE "org.bluez.obex.MessageAccess1"
#define MAP_MSG_INTERFACE "org.bluez.obex.Message1"
map->supported_features = 0x0000001f;
}
+static void *map_supported_features(struct obc_session *session)
+{
+ const void *data;
+ uint32_t supported_features;
+
+ /* Supported Feature Bits */
+ data = obc_session_get_attribute(session,
+ SDP_ATTR_MAP_SUPPORTED_FEATURES);
+ if (!data)
+ return NULL;
+
+ supported_features = *(uint32_t *) data;
+ if (!supported_features)
+ return NULL;
+
+ if (supported_features & MAPSUPPORTEDFEATURES_IN_CONNECT_REQUEST)
+ return g_obex_apparam_set_uint32(NULL, SUPPORTED_FEATURES_TAG,
+ NOTIFICATION_REGISTRATION_FEATURE |
+ NOTIFICATION_FEATURE |
+ BROWSING_FEATURE |
+ UPLOADING_FEATURE |
+ DELETE_FEATURE |
+ INSTANCE_INFORMATION_FEATURE |
+ EXTENDED_EVENT_REPORT_1_1 |
+ MESSAGES_LISTING_FORMAT_VERSION_1_1);
+
+ return NULL;
+}
+
static int map_probe(struct obc_session *session)
{
struct map_data *map;
.uuid = MAS_UUID,
.target = OBEX_MAS_UUID,
.target_len = OBEX_MAS_UUID_LEN,
+ .supported_features = map_supported_features,
.probe = map_probe,
.remove = map_remove
};