We’re integrating ZoomVideoSDKScreenShareService into a ReplayKit broadcast extension for screen sharing. While the extension initializes successfully and broadcastStarted(withSetupInfo:) is called, the app consistently crashes with EXC_BAD_ACCESS when invoking processSampleBuffer(_:with:) for .video buffers — despite using a delayed start and correct app group setup.
Environment
Platform: iOS
Device: iPhone [iPhone XSMAX iOS 18.5]
Deployment Mode: Installed via Xcode (debug build)
ReplayKit Setup: Broadcast Upload Extension only (no custom UI)
isWithDeviceAudio: true (also tested with false)
What Works
The SampleHandler successfully initializes the Zoom service with the given appGroupId.
broadcastStarted(withSetupInfo:) is triggered and completes.
App Group container is verified as accessible from within the extension.
Issue Details
Immediately after the broadcast starts, the first .video sample buffer is passed to the Zoom SDK:
screenShareService?.processSampleBuffer(sampleBuffer, with: sampleBufferType
This causes the extension to crash with:
Thread 8: EXC_BAD_ACCESS (code=1, address=0x78)
We’ve confirmed:
The crash is not in our code — it occurs inside the SDK
A delay (DispatchQueue.main.asyncAfter(deadline: .now() + 3)) before processing does not prevent the crash
Setting isWithDeviceAudio = false does not help consistently
App Group is correctly configured in both main app and extension
No Objective-C exceptions are thrown; it is a native memory crash
Repro Steps
Create a Broadcast Upload Extension
Initialize ZoomVideoSDKScreenShareService with valid appGroupId
Call broadcastStarted(...)
Delay sample buffer processing by 2–3 seconds
Forward .video buffers via processSampleBuffer(...)
Extension crashes with EXC_BAD_ACCESS on the first buffer
Can you please confirm if processSampleBuffer(...) is fully supported in a ReplayKit extension context?
Any guidance to avoid this low-level crash would be appreciated.
The correct method to use will be the “withType” parameter instead. For more information you can referred to our documentation on the samplehandler here.
Kindly check that you have added ZoomVideoScreenShareSDK.xcframework into your broadcast extension app target with “Do not embed” and also both the ZoomVideoSDK.xcframework and CptShare.xcframework added to your main app target with “Embed & Sign”. If the issue still persist, can you provide me with your crash log thru direct message?
Hello @boonjun.tan ,
Thanks for your reply. I’m already implementing it the same way you mentioned. However, I don’t have crash logs because the app continues running, but the crash occurs within the Share Extension’s SampleHandler file. Once the broadcast is stopped, the crash debug point disappears.
We’re integrating ZoomVideoSDKScreenShareService in a ReplayKit broadcast upload extension.
The extension launches, but screen sharing stops immediately with this system error:
“Attempted to start an invalid broadcast session”
This happens even when:
broadcastStarted(...) is called
App Group is valid and accessible
ZoomVideoSDKScreenShareService is initialized without crashing
Sample buffers are delayed by 3–5 seconds before processing
Additionally:
We get CFMessagePort bootstrap_register(): permission denied logs.
*** CFMessagePort: bootstrap_register(): failed 1100 (0x44c) ‘Permission denied’, port = 0x1c21f, name = ‘.1829029404.rpc’
See /usr/include/servers/bootstrap_defs.h for the error codes.
Followed by a crash on processSampleBuffer(...) with EXC_BAD_ACCESS
Suspected Cause:
Zoom SDK may be triggering restricted calls inside the extension (e.g. CFPreferences, IPC, device audio) before session is marked valid.
Request:
Can you confirm if ZoomVideoSDKScreenShareService is fully supported in a ReplayKit extension context?
Any known limitations with isWithDeviceAudio = true or required initialization order?
I have zoom log but I am not able to upload log file, it says
“Sorry, the file you are trying to upload is not authorized (authorized extensions: jpg, jpeg, png, gif).”
The “Attempted to start an invalid broadcast session” error usually appears when there are misconfigured steps within both the Main and Broadcast Extension apps target so it’s hard for me to investigate the issue over here as I will have to look at your whole setup. Have you also tried with our sample app available within the Zoom’s Video SDK folder when you downloaded to see if you have similar issue?
As for logs wise, I will need you to upload to Google Drive and give me the link so that I can access to it.
It looks like the example provided is in Objective-C, whereas I’m working with Swift. However, I’ll definitely try adapting it accordingly.
Would it be possible to schedule a live call or chat session? I’d like to walk you through my project configuration. I’ve followed the steps outlined in the documentation and also cross-checked with the official Zoom sample project, but I’m still encountering the issue.
Thanks for sending me your logs and I have taken a look at it, but it doesn’t contain much on why the screen share failed to start and I am assuming that ReplayKit was not able to get the sampleBuffer on Apple’s end.
Have you tested your scenario mentioned earlier using our sample app to see if the issue occurred? I have tested Zoom’s latest VSDK 2.2.10 version and I got the same issue that you are facing as well, but that was only because I didn’t have the same appGroupID for all the required places. The issue was resolved once I rectified it. Can you check if your appGroupID is consistent for the following:
@boonjun.tan I’ve checked all the relevant places and confirmed that the appGroupID is consistent throughout. However, I’ll cross-verify it with the Zoom sample code as well. At the moment, I’m encountering some build issues with the sample project, and since I haven’t worked with Objective-C in a while, it might take me some time to get it up and running.
I’ll provide an update once I’ve resolved the build issues and completed the comparison.
Hi @boonjun.tan, would it be possible to schedule a quick live call? It might help us share the details more effectively and work towards a solution together.
Can you test without any of ur additional code but the “shareService.processSampleBuffer” and see if it works?
We typically only use this forum for any sharing/troubleshooting unless you are a partner (ISV) or client of us, if so I will need your AE/SE for more information.
@boonjun.tan, Thank you for your support and suggestions.
This is my office email Zoom ID, and we’ve been using the Zoom Video SDK in our application since its first version. Could we use this Zoom ID to connect and discuss the issue further?
As mentioned, we typically only use the Zoom’s dev forum for any sharing/troubleshooting unless you are a partner (ISV) or client of us, if so I will need your AE/SE for more information. Or you can consider having premium developer support.
In addition, the “Attempted to start an invalid broadcast session” error indicates an issue faced with the setup/configuration of your broadcast extension (ReplayKit framework) and we will need to you to check if you have any inconsistent or invalid App Groups across Main and Broadcast Extension target app, problems with the extension’s setup process, or conflicts with other active screen sharing sessions.