My code used to work on iOS versions prior to iOS16, but it no longer does.
I am running iPadOS -not checked on iPhones.
A view based on WKWebView is supposed to show HTML files inside a keyboard extension. It is now not not displaying correctly and any Javascript will lock up the UI. Setting stringByEvaluatingJavaScriptFromString > evaluateJavaScript's completionHandler to nil fixes this, but Javascript is not run.
No errors, but blank space.
Any ideas?
Extensions
RSS for tagGive users access to your app's functionality and content throughout iOS and macOS using extensions.
Posts under Extensions tag
200 Posts
Sort by:
Post
Replies
Boosts
Views
Activity
I've added ShieldConfigurationExtension to my project. The only thing that doesn't work for me is proper color for System Appearance.
Let's say I only wants to change color of title for shield, I create color in Asset Catalog with different light and dark appearance then create ShieldConfiguration as shown:
ShieldConfiguration(title: ShieldConfiguration.Label(
text: "My title", color: UIColor(named: "mycolor") ?? .systemGray
))
This will make the title to be one of the variant of mycolor BUT it looks to be randomly selected. Sometimes it has light appearance, sometimes dark and not always match selected system appearance. Other UI elements that I didn't set are properly changing theirs colors.
On the other hand if I use some system colors, it works as expected:
ShieldConfiguration(title: ShieldConfiguration.Label(
text: "My title", color: .label
))
.label will always has proper color - white for dark mode and black for light
I've tried to use mycolor inside main app and there it works as it should so the problem is happening only in ShieldConfigurationExtension
We are seeing cases where DeviceActivityMonitoring extension is crashing permanently. This is due to a now-fixed bug that was causing a stack overflow. On devices where the extension crashed, it appears permanently unable to recover - even weeks after the crash and after multiple restarts of the device.
It looks like recovery is being attempted, as the same four NSLog activities are emitted roughly every second that the phone is active.
Logs:
Process: DeviceActivityMonitoring
Activity: beginning extension request
Message: NSExtensionPrincipalClass `<private>` does not conform to NSExtensionRequestHandling protocol!
Process: DeviceActivityMonitoring
Activity: Loading Preferences From User Session CFPrefsD
Message:
Process: DeviceActivityMonitoring
Activity: container_system_group_path_for_identifier
Message: Requesting container lookup; class = 13, identifier = <private>, group_identifier = <private>, create = 1, temp = 0, euid = 501, uid = 501
container_query_get_single_result: success
container_system_group_path_for_identifier: success
Process: DeviceActivityMonitoring
Activity: container_create_or_lookup_app_group_path_by_app_group_identifier
Message: Requesting app group container lookup; personaid = 1000, type = DEFAULT, name = 9F7F4BA7-79CF-453C-B81C-568E96ADB711, origin [pid = 29, personaid = 199], proximate [pid = 3505, personaid = 199], identifier = <private>, euid = 501, uid = 501, platform = 2
containermanagerd stat [<private>]: exists: 1, isDirectory: 0, fsNode: <~~~>
containermanagerd <private> is sandboxed. Issuing token for path: [<private>] (extension class: com.apple.sandbox.application-group)
containermanagerd [0] command=38, client=<<~~~>, u=<501/501/~~/0/1000>, uid=501, pid=5595, sandboxed=1, platform=2 (1/1/0) [<~~~>], cached, cs cached>, error=(null)
Consuming sandbox extension; path = [<private>], key = 0
Revoking sandbox extension; key = 0
Can anyone provide some insight into what is going on with the recovery attempt here?
Practically, how can we recover the extension in these cases? Will an app update force the extension to restart properly? Hard reset of the device? Something else?
Is there any way to check on the health of an extension from the main app so that we can deterministically know if the extension is healthy or not before relying on it?
I discovered a multithreading mistake in my use of NSManagedObjects recently and was surprised that I wasn't alerted to this during development, since I had -com.apple.CoreData.ConcurrencyDebug 1 set under "arguments passed on launch" for my macOS and iOS FileProvider extensions. I confirmed that the expected log stating CoreData: annotation: Core Data multi-threading assertions enabled. is NOT present when running these targets (but does appear as expected on my main macOS and iOS applications).
Can anyone advise me on how to get this concurrency debugging functionality to work on my FileProvider extension(s)?
Thanks
I have developed an application to lock selected apps using the Screen Time API (iOS). My app has been registered in Family Control and currently successfully executes app restrictions in both emulators and devices through TestFlight. I intend to incorporate a countdown timer feature to ensure that the app restriction function is activated when the timer stops.
However, the issue I'm facing is I can't get FamilyActivitySelection values from DeviceActivityMonitorExtension, and it causes the selected app always empty and I can't do restrictions.
I have attempted various ways, such as:
Using singleton on MyModel
Using the same App Groups for both App & Extension Target
Using UserDefault to save & load FamilyActivitySelection values (already tested on App and it returns the correct value, but when I call it from DeviceActivityMonitorExtension and show it with local notification, the value is always empty)
Is there any solution to address this matter?
I put my code in here
https://stackoverflow.com/questions/76935721/how-to-get-familyactivityselection-from-deviceactivitymonitorextension-in-ios-sc
In my case my app with built with a deployment target of iOS 15.0 but the embedded packet tunnel provider app extension had a deployment target of iOS 16.2. When I ran the app on iOS 15.7.1, I was able to save a VPN configuration but it wouldn’t start and Settings said “Update Required”.
HI All,
I've created an app with Shared Extension to share URLs from Safari, and other apps, into my app. Problem I've got is, that when I use my sharing option inside Safari, different app will. "hijack" it and display alert if I want to open in inside that app. This different app is PriceNotify.
Dos anyone had similar problem?
I am looking for a way to ensure that every time I close Safari on my mobile device, all open tabs are automatically closed and the browser history is cleared. This is to enhance privacy and keep the browser experience clean each time I access it. I've searched through Safari's settings but haven't found an option for this.
I'm wondering if there is a built-in feature I might have missed, or if it's possible to develop an extension or use any other method to achieve this.
Hi, I would like to enable includeAllNetworks setting in a personal VPN product. If a transparent proxy of other macOS security product (i.e. Avast Security, Cisco AnyConnect) is enabled, the VPN session fails to connect with an error message
nesessionmanager: Failed to register Personal IncludeAllNetworks VPN Session NESMIKEv2VPNSession[...] due to Enterprise VPN session NESMTransparentProxySession[...] (status 3)
nesessionmanager: [com.apple.networkextension:] NESMIKEv2VPNSession[Primary Tunnel:...]: Rejected start command from AVG Secure VPN[3332]
The startVPNTunnel method however doesn't return any error. The product needs to wait until its internal connection timer expires, call stopVPNTunnel and then the NEVPNStatus changes from disconnected to disconnecting followed by disconnected.
Is there a way to programatically detect the error or transparent proxy presence?
Hi all,
I'm working on an app where the core mechanic is to share a URL from a browser to the app. Based on the URL being shared, we enrich some details using a network request which can take 3-10 seconds to load (or more). Currently, we do the following:
Load the share extension
Make the enrichment request
Make the user wait for the result
Enable the "share" button when the result is present.
Update application state
#3 is problematic because it takes our users out of their primary activity and makes them wait on us. We would much rather do the following:
Load the share extension
User clicks "share"
Kick off the enrichment request
Enrichment requests completes and updates application state in the background.
I've gotten the above to work just fine in testing with background sessions, but we can't ship it because only one can run at a time and if a user shares another URL before the first has returned, the session is invalidated and only the new URL will complete and update application state. This post was helpful during troubleshooting to figure out what was going on with cancelled requests, but it seems that what we're trying to do may not be supported.
I've thought about other mechanisms that get us our desired effect, but each comes with drawbacks:
Kick off a server side request as a job in the share extension, then send a data-only push notification back to the device when the data enrichment is complete. Downside is it adds complexity server-side and we have to request notification permission.
Pop the URLs into some sort of queue in the shared container and process them incrementally with a background fetch. Downside here is that we're not in control of the timing and could only get through a few of these requests in the time we have allotted. Janky UX because there becomes an appearance of taking many minutes to enrich, instead of the reality of relatively short processing time but long waiting times between batches.
Any prior experience, thoughts, or advice on how to architect this workflow? I'm relatively new to iOS development, so please feel free to point out anything obvious that I may be missing or misunderstanding!
Thanks,
Jonathan
Hi there - I’m developing a camera extension for macOS. Whenever I up the build number from say 31-33 for 1.0 and install, I’m then unable to uninstall the extension from the previous version on deletion of the app. Should I be reinstalling the extension somehow on every update even if it hasn’t changed or should I not be bumping the version of the extension? is this something that only happens in development or I should expect to deal with this in prod too? I have frustrated users who are having to disable SIP to uninstall the extension.
Thanks for your help!
Buenas a todos
Recibo estos errores al implementar Siri
ITMS-90626: Invalid Siri Support - No se ha proporcionado ninguna frase de ejemplo para INSearchCallHistoryIntent en el idioma 'en'.
ITMS-90626: Invalid Siri Support - No example phrase was provided for INStartAudioCallIntent in the 'en' language.
No entiendo tengo los intent de examples en ingles
<key>NSExtension</key>
<dict>
<key>App Intent Vocabulary Property List</key>
<dict>
<key>Intent Phrases</key>
<array>
<dict>
<key>Intent Name</key>
<string>INStartAudioCallIntent</string>
<key>Intent Examples</key>
<array>
<string>Start a voice call with [contact name].</string>
<string>Call [contact name] using audio.</string>
</array>
</dict>
<dict>
<key>Intent Name</key>
<string>INSearchCallHistoryIntent</string>
<key>Intent Examples</key>
<array>
<string>Show me calls with [contact name].</string>
<string>Find calls from [contact name].</string>
</array>
</dict>
</array>
</dict>
Pero sigo obteniendo el mismo error, aca vez que lanzo una TestFlight.
De antemano les agradezco.
We are developing File Provider for macOS. We followed apple sample app, and are able to create a File Provider with Container app and an extension. We are able to get this working while building from Xcode. But the distributable build does not load the extension and fails with error "Application can not be loaded".
We need help with understanding root cause of the issue, and exact entitlement that we can use for creating distributable builds.
I recently saw Carrot Shopping has a Allow Permissions badge next to its mobile safari extension icon in the toolbar for prompting user to allow permissions. I searched everywhere including the official safari extension documentation for turning this feature on for our extension, but I haven't been able to find anything related to this badge. Has anyone have any experience enabling this badge for their mobile safari extension? Would be super helpful if someone can guide me to the right documentation.
Hello everyone,
I encounter a problem when trying to connect to a VPN server configured in IKEv2 from MacOS (Ventura 13.4.1).
The VPN server is a RRAS hosted in a Windows server 2019, its certificate is signed by my CA which presents the extensions required by Apple (KeyLength = 2048, KeyUsage = 0xA0, [EnhancedKeyUsageExtension] OID=1.3.6.1.5.5. 7.3.1; Server Authentication, etc.), it has the subject name (common name) as well as the alternative name (DNS name) with its public address, the root certificate has been imported and set to always trusted in the container.
I can connect without difficulties Windows clients, Linux (network manager/libstronswan), IpadOS (16.3.1), androids with stongswan app, and on old MacOS I can connect BigSur and Monterey.
I tried many thing in particular on the certificate template, or tried to import in other ways the root CA certificate.
I sniffed the network traffic a little and I can clearly see the flow reaching the RRAS but the latter only sends back a response and then nothing.
I note a detail in passing, when I launch the connection from my Mac it cuts off almost instantly making me think that there is a problem with the system of this Mac, I of course tried to reinstall it completely and also tested it from others Mac than this one also on Ventura, here is the log stack that I obtain during the phase where I try to initiate the connection :
neagent Looking for an extension with identifier com.apple.NetworkExtension.IKEv2Provider and extension point com.apple.networkextension.packet-tunnel
neagent [d <private>] <PKHost:0x7fc32a205b60> Beginning discovery for flags: 0, point: com.apple.networkextension.packet-tunnel
neagent [d <private>] <PKHost:0x7fc32a205b60> Completed discovery. Final # of matches: 1
neagent Found 1 extension(s) with identifier com.apple.NetworkExtension.IKEv2Provider and extension point com.apple.networkextension.packet-tunnel
neagent Beginning extension request with extension com.apple.NetworkExtension.IKEv2Provider
neagent Error acquiring assertion: <Error Domain=RBSAssertionErrorDomain Code=2 "Specified target process does not exist" UserInfo={NSLocalizedFailureReason=Specified target process does not exist}>
neagent [u 60A21109-AF3F-4E41-BD4F-12716689E26E:m (null)] [<private>(<private>)] Ready plugins sent as euid = 501, uid = 501, personaid = -1, type = NOPERSONA, name = <unknown>
neagent [u 60A21109-AF3F-4E41-BD4F-12716689E26E:m (null)] [<private>(<private>)] got pid from ready request: 1824
neagent [u 60A21109-AF3F-4E41-BD4F-12716689E26E:m (null)] [<private>(<private>)] acquired startup assertion
neagent Hit the server for a process handle bd7cb2500000720 that resolved to: [xpcservice<com.apple.NetworkExtension.IKEv2Provider([osservice<com.apple.neagent(501)>:525:525])(501)>:1824]
neagent [u 60A21109-AF3F-4E41-BD4F-12716689E26E:m (null)] [<private>(<private>)] Prepare using sent as euid = 501, uid = 501, personaid = -1, type = NOPERSONA, name = <unknown>
neagent [u 60A21109-AF3F-4E41-BD4F-12716689E26E] [<private>(<private>)] Sending prepareUsing to managed extension; this should launch it if not already running.
neagent [u 60A21109-AF3F-4E41-BD4F-12716689E26E:m (null)] [<private>(<private>)] Begin using sent as euid = 501, uid = 501, personaid = -1, type = NOPERSONA, name = <unknown>
neagent [u 60A21109-AF3F-4E41-BD4F-12716689E26E:m (null)] [<private>(<private>)] plugin loaded and ready for host
neagent [u 60A21109-AF3F-4E41-BD4F-12716689E26E:m (null)] [<private>(<private>)] invalidating startup assertion
neagent +[NSExtensionContext _allowedItemPayloadClasses] not implemented. Setting the allowed payload classes to <private>
neagent Extension request with extension com.apple.NetworkExtension.IKEv2Provider started with identifier 6DFB0610-487E-459D-8197-4DE783566C84
neagent Signature check failed: the code does not conform to the specified code requirements
neagent Signature check failed: the code does not conform to the specified code requirements
neagent Provider is not signed with a Developer ID certificate
neagent [Host com.apple.NetworkExtension.IKEv2Provider]: Starting with options 0x7fc32a10ab90
neagent Scheduing timer for extension failure/exit for (null)
neagent [u 60A21109-AF3F-4E41-BD4F-12716689E26E:m (null)] [<private>(<private>)] Connection to plugin interrupted while in use.
neagent [u 60A21109-AF3F-4E41-BD4F-12716689E26E:m (null)] [<private>(<private>)] all extension sessions ended
neagent [u 60A21109-AF3F-4E41-BD4F-12716689E26E:m (null)] [<private>(<private>)] Connection to plugin invalidated while in use.
neagent [u 60A21109-AF3F-4E41-BD4F-12716689E26E:m (null)] [<private>(<private>)] Emptying requests set
Hello,
I have an iOS app using the DeviceActivityReport app extension. Occasionally, the extension gets terminated (likely due to reaching memory limit**), which in turn disrupts the connection with the main app.
How can the main app detect when the DeviceActivityReport extension has been terminated due to memory constraints, and what's the best way to re-establish the connection afterward?
Thanks in advance for your insights and suggestions!
** I'm also unsure why the extension should be reaching its memory limit. When profiling the extension in XCode, it never reaches above 15MB, and I know the limit is 100MB. It's not doing anything out of the ordinary - and I've seen very similar complaints about DeviceActivityReport terminating on these forums. Any thoughts on how to prevent termination in the first place would also be super helpful!
Hi Team,
I am facing issue in Card provisioning on Apple wallet extension App on last step while attempts to provision the card using the provided PKAddPaymentPassRequest. Please help on this.
Failed to get LSApplicationRecord for <RBSLaunchRequest| xpcservice<————([application<com.apple.Passbook>:**])>; "Launching extension ———————————————— for host **> with error Error Domain=NSOSStatusErrorDomain Code=-10814 "(null)" UserInfo={_LSLine=1569, _LSFunction=runEvaluator}
Hi,
I've successfully implemented the SensitiveContentAnalysis framework in my app for iOS 17 users.
However, when I try to do the same in my Share Extension, the SensitivityAnalyzer analysisPolicy var always return .disabled.
Is it a bug or do the SensitiveContentAnalysis framework doesn't work in App Extensions?
Hello,
I've been working with an app that leverages a DeviceActivityReport app extension. I want to ensure that the main app can gracefully handle scenarios where the connection to the app extension might get terminated unexpectedly.
Can anyone guide me on how to detect from the main app when the connection to the app extension gets terminated? I believe being able to detect this would allow for better error handling and potentially reduce instances where the UI appears blank due to a lost connection.
Thank you for any insights or advice on this topic.
I'm trying to use App Groups to allow my app and my shared extension to use shared containers. Is this possible without having the Apple Developer Program?