Skip to content

Safari websocket compression is broken #731

Closed

Description

@mohamedmansour

Using go v1.17
Using gorilla websocket v1.4.2

iOS Safari 15 enabled by default for all users "NSURLSession WebSocket", by enabling this, it broke my application at (https://watchtheburn.com) if you have a Mac, you can inspect and see it not working (on an iOS device).

Going into Experimental WebKit Features and disabling "NSURLSession WebSocket" it works again.

@ejain opened this up and closed it for #696 Any ideas how I can resolve it?

Activity

  1. mohamedmansour commented on Oct 21, 2021

    @mohamedmansour
    Author

    @mamjsn is there a way to test it?

  2. mohamedmansour commented on Oct 27, 2021

    @mohamedmansour
    Author

    @mamjsn how did you figure this out! thank you for taking your time and looking at the source code of my app!

    I verified that removing compression works on iOS 15.
    mohamedmansour/ethereum-burn-stats@d282823

    I tried re-enabling compression, but it doesn't work, so disabling it instead. Unless I am doing it wrong.
    mohamedmansour/ethereum-burn-stats@ceb5e2e

    Thank you!

  3. nicks commented on Oct 27, 2021

    @nicks

    we're hitting this too in MacOS Monterey 😭 tilt-dev/tilt#4746

    thanks @mamjsn for the workarounds above.

    how hard would it be to have gorilla/websocket detect this scenario and workaround it? Like maybe we could check for Sec-WebSocket-Extensions: permessage-deflate and User-Agent: Safari? would be happy to try to put together a PR if no one is opposed to browser-specific workarounds.

  4. ghost changed the title [-][bug] Gorilla WebSocket does not support iOS 15[/-] [+]Safari websocket compression is broken[/+] on Jan 19, 2022
  5. ghost closed this as completedon Sep 17, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions