Uploaded image for project: 'Realm Core'
  1. Realm Core
  2. RCORE-1427

Update websocket protocol strings to replace "/" with some other character

    • Type: Icon: Task Task
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: Sync
    • None

      Once the server update for BAAS-12633 has been released, update the Sync Client connection to send the supported websocket protocol version list string sent in the Sec-WebSocket-Protocol field to use a different character instead of /, since a forward slash (/) is not supported by the websocket protocol spec and some custom websocket implementations may not work properly with the current format. The ClientImpl::Connection should also be updated to support parsing this new format in the websocket_connected_handler() callback function.

      The current format of the strings is com.mongodb.realm-sync/# for PBS and com.mongodb.realm-query-sync/# for FLX, and an example new format could be com.mongodb.realm-sync-# for PBS and com.mongodb.realm-query-sync-# for FLX (where # is the supported protocol number).

      Refer to BAAS-12633 for the actual character used for the protocol type and version delimiter. It could be - or #.

      Once the server is updated, it will accept both the original format (with a /) and the new format - the reason for the change is because the / delimiter is not an allowed character for the Sec-WebSocket-Protocol field.

            Assignee:
            Unassigned Unassigned
            Reporter:
            michael.wilkersonbarker@mongodb.com Michael Wilkerson-Barker (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: