Created attachment 242630 [details] Dev Tool Ouput Opening a websocket connection using IOS (tested with 8.1, but I suspect the issue is there for all version) after going offline (Plane mode off/on) cause Safari to crash with WebSocket connection to 'ws://10.0.1.12:8080/chat?X-Atmosphere-tracking-id=c884a896-1944-4793-b2ed-6563e218f407&X-Atmosphere-Framework=2.2.6-javascript&X-Atmosphere-Transport=websocket&X-Atmosphere-TrackMessageSize=true&Content-Type=application/json&X-atmo-protocol=true' failed: Invalid UTF-8 sequence in header value Before going offline, the same URL just works: Using URL: ws://10.0.1.12:8080/chat?X-Atmosphere-tracking-id=0&X-Atmosphere-Framework=2.2.6-javascript&X-Atmosphere-Transport=websocket&X-Atmosphere-TrackMessageSize=true&Content-Type=application/json&X-atmo-protocol=true atmosphere.js:3171 The issue seems to be with the length of the query String. For example, doing ws://10.0.1.12:8080/chat?X-Atmosphere-tracking-id=0 will works. But doing ws://10.0.1.12:8080/chat?X-Atmosphere-tracking-id=0dsdasdasdasdsa won't. Attached is the Safari Dev Console output. This can be easily tested using the console.
I *think* Alexey fixed that
The only related thing that I recently fixed would be bug 137009, which is not obviously the same thing. Please test with iOS 8.1.1 though.
Same issue with 8.1.1
Seems that the Blink guys fixed a similar issue that was triggered by empty response headers: https://code.google.com/p/chromium/issues/detail?id=380075 We managed to reproduce this on iOS also with an empty response header and work around it by ensuring that the header value is never empty.
BTW, This has never been solved. If you try https://speech-to-text-demo.mybluemix.net/ on Safari 9, you receive a "Invalid UTF-8 sequence in header value" In this case I think the problem is the Content-type being empty. Another example is here: http://stackoverflow.com/questions/34679134/websocket-safari-9-invalid-utf-8-sequence-in-header-value . The `Set-Cookie` is empty