Wowza Community

IOS 15 WebRTC problem

We have a problem that our WebRTC application is not supported in Safari on iOS 15. It works fine on iOS 14.x.
Both on our production and test environment we get the same error in Safari developer console:
“WebSocket connection to ‘wss://[our servers ip address]:443/webrtc-session.json’ failed. The operation could not be completed. Socket is not connected.”

Anyone else have this problem? anyone found a solution?

Support case is submitted to wowza support and wowza support has reproduced and confirmed the problem but not yet provided us with any workaround or solutions

We are also having this problem. It would be great to know how to fix this?

1 Like

Hey there @Mark_Malmros I see you are waiting on an update for this in your ticket and I sent a mesage to technical support letting them know you are eager for a solution.

What I can suggest is you hop over to our public WebRTC slack channel where we have over 3000 developers and engineers from around the world discussing what they have built and obstacles they have overcome with their own WebRTC applications. Might be worth asking in there. They do discuss mobile a lot and webrtc can be a bit tricky depending on the OS as you are finding out.

You can join here:

we dont get email’s when signing up for / slack - it does provide us after entering email with a message " to check mail" but nothing ever arrives in my inbox ? - any suggestion ?

So I have an update for you on the WebRTC iOS 15 issue:

Apple has posted about this bug in their forums:

Wowza will do what we can in the meantime of course. I can share a possible workaround as well at the bottom of this post. NOTE: THIS IS NOT A SOLUTION RECOMMENDED BY WOWZA OR TECHNICAL SUPPORT.

(Thank you to our Community Member, Viesturs, for providing this suggestion for many of you to try out!!)


https://developer.apple.com/forums/thread/689293


The issue is basically that iOS 15 is using fragmented websockets which will not work with Engine WebRTC setup. What you can try is this and some developers have reported this solved it for them- is convert it to single frames.


Putting middleware which converts all fragmented to single-frames between clients and WSE engine for both-directions eliminates the issue

By putting in-front of WSE a WSS middleware which never fragments messages sent to WSE (https://datatracker.ietf.org/doc/html/rfc6455#section-5.7) issue is resolved.

datatracker.ietf.orgdatatracker.ietf.org

The WebSocket Protocol (RFC )

So, iOS 15 sends fragmented, but middleware receives and sends further single-frame, WSE happy, iOS 15 happy.

we have the same ISSUE.

Hi Alex sorry your post was caught up in the queue awaiting approval. It does that for a first post that is short. I hope the option provided works for you, If you need help setting that up, please send a support ticket.

Hey! How are you?
Are there any news - do you plan fix this problem on WSE backend? Or we should create Middlware for fixing this problem, We believe that you can solve problem in 1-2 weeks on your side or its unreal?

Hi Alex, no that suggestion for middleware is not supported by Wowza and we have not tested it. That was just a suggestion from a comumunity developer. I was just sharing that in case it helps some of you.

Wowza is investigating this issue with Apple’s bug and I have not yet been given a timeline for a solution.

Hi,

Any update here from Wowza side? Or did anybody managed to solve it using the middleware implementation and can share his solution?
The link mentioned in this thread, didn’t help me to understand the solution (https://datatracker.ietf.org/doc/html/rfc6455#section-5.7)
And I couldn’t find any other mentions of this middleware to convert fragmented to single-frames, over the net.

Thanks.

This is an Apple Bug and Wowza has no workaround yet. But, TheoPlayer did post this as a workaround:

The links in this thread are far from beeing related to the Websocket issues. Or am I missing something?

Hi @Frank_Otten that’s a fair question. The websocket error message is thrown by Streaming Engine when attempting to publish or playback a stream on iOS 15. The Apple webkit/websocket bug is discussed here in more detail. Basically, it sends fragmented and Streaming Engine requires single frame.

https://bugs.webkit.org/show_bug.cgi?id=228296

While sending a websocket response from Websocket-sharp c# implemented websocket server, which is having mutiple fragments writing into the socket stream, connection at the client instance is getting closed. WebSocket connection to 'ws://:/’ failed: The operation couldn’t be completed. (kNWErrorDomainPOSIX error 100 - Protocol error)


There is a request in to fix this in Streaming Engine and I have no ETA on this.


If you’d like, you can join the webrtc channel here in our pubic slack and see the developers from around the world discussing this problem and what they have been attempting as a fix. Just register here with your email and go to the webrtc channel.

Hi all, finally we managed to solve the issue using cordova plugin with Native web socket.
“cordova-plugin-advanced-websocket”.
(Our app is using Ionic with cordova)

So for iOS 15 and up, we connect to the websocket using the Native plugin (and not in Javascript which runs on Safari and is blocked).
For Android, or desktop we use Javascript websocket as before.

1 Like

Awesome! Really appreciate you sharing that info with the community.

We are also experiencing this issue. Is there any word on a patch from wowza (I mean, come on guys, it has been over a month). Barring wowza actually fixing this (because we know apple won’t budge), has anyone found a middleware solution?

1 Like

Is there any news on the ETA ?

Raising this today again to the engineering director.

We are very dependent on the low latency provided by the WebRTC integration. Not being able to serve streams to safari on iOS15 and MacOS Monterrey is crippling to our product. I hope the seriousness of this issue is understood. I think an ETA or indication that this is being worked on would be appreciated by all.

Thanks for your reply, we are very much looking forward to and ETA on this issue, It is very business critical for us that this issue is fixed for the christmas rush, else we may have to go forward with a total engine replacement and leave wowza after 14 years wich is not what we want to do :frowning: