Posts under App & System Services topic

Post

Replies

Boosts

Views

Activity

DeviceActivityReportExtension / ScreenTimeBriefReport does not localize strings
Hello, In one of our apps we use DeviceActivityReportExtension to show the user how much screen time is remaining. The calculation is working as expected, but we have noticed that the labels in our ScreenTimeBriefReport are not localized to the device language. Example: Device with language set to Swedish App fully translated to English and Swedish Result: All labels in app are using the Swedish translations, except the strings in our ScreenTimeBriefReport instance. These labels are using the English localization. I've verified it's using the English localization from our Localizable.xcstrings file. I tried logging device language from our ScreenTimeBriefReport instance, but I could not see anything in Console.app. I guess this is intentional so no sensitive user information can be extracted. Is this a known feature or bug? If it's the latter, is there a known workaround? Sincerely, César
1
0
558
Jan ’25
IPad connected to DSLR captures incomplete image
At present, I am using the avfoundation external device API to connect my iPad to a DSLR camera for data collection. On my end, I am using AVCapture Video Data Output to obtain raw data for processing and rendering. However, the pixelbuf returned from the system layer is incomplete, with only a portion cropped in the middle. But using the Mac API is normal. I would like to ask how to obtain the complete pixelbuf of the image on iPad
0
0
325
Dec ’24
Can anyone help?
I recently used Open core legacy patcher to update my old 2012 Macbook pro to run a new pice of dj software. the update went smooth but now the Dj software wont open just gives me a crash report. Im totally stumped. the crash report. Crashed Thread: 0 Dispatch queue: com.apple.main-thread Exception Type: EXC_BAD_INSTRUCTION (SIGILL) Exception Codes: 0x0000000000000001, 0x0000000000000000 Termination Reason: Namespace SIGNAL, Code 4 Illegal instruction: 4 Terminating Process: exc handler [3839] Thread 0 Crashed:: Dispatch queue: com.apple.main-thread 0 Engine DJ 0x10c9e3d81 0x10c28f000 + 7687553 1 dyld 0x7ff807632729 invocation function for block in dyld4::Loader::findAndRunAllInitializers(dyld4::RuntimeState&) const + 241 2 dyld 0x7ff80766b34e invocation function for block in dyld3::MachOAnalyzer::forEachInitializer(Diagnostics&, dyld3::MachOAnalyzer::VMAddrConverter const&, void (unsigned int) block_pointer, void const*) const + 133 3 dyld 0x7ff80765fb73 invocation function for block in dyld3::MachOFile::forEachSection(void (dyld3::MachOFile::SectionInfo const&, bool, bool&) block_pointer) const + 543 4 dyld 0x7ff80761a07b dyld3::MachOFile::forEachLoadCommand(Diagnostics&, void (load_command const*, bool&) block_pointer) const + 249 5 dyld 0x7ff80765ebe8 dyld3::MachOFile::forEachSection(void (dyld3::MachOFile::SectionInfo const&, bool, bool&) block_pointer) const + 176 6 dyld 0x7ff807661266 dyld3::MachOFile::forEachInitializerPointerSection(Diagnostics&, void (unsigned int, unsigned int, bool&) block_pointer) const + 116 7 dyld 0x7ff80766b084 dyld3::MachOAnalyzer::forEachInitializer(Diagnostics&, dyld3::MachOAnalyzer::VMAddrConverter const&, void (unsigned int) block_pointer, void const*) const + 390 8 dyld 0x7ff8076325c2 dyld4::Loader::findAndRunAllInitializers(dyld4::RuntimeState&) const + 150 9 dyld 0x7ff807638af7 dyld4::JustInTimeLoader::runInitializers(dyld4::RuntimeState&) const + 21 10 dyld 0x7ff807632928 dyld4::Loader::runInitializersBottomUp(dyld4::RuntimeState&, dyld3::Array<dyld4::Loader const*>&, dyld3::Array<dyld4::Loader const*>&) const + 276 11 dyld 0x7ff807636141 dyld4::Loader::runInitializersBottomUpPlusUpwardLinks(dyld4::RuntimeState&) const::$_0::operator()() const + 147 12 dyld 0x7ff8076329bc dyld4::Loader::runInitializersBottomUpPlusUpwardLinks(dyld4::RuntimeState&) const + 90 13 dyld 0x7ff80764e1f7 dyld4::APIs::runAllInitializersForMain() + 277 14 dyld 0x7ff80761f52e dyld4::prepare(dyld4::APIs&, dyld3::MachOAnalyzer const*) + 3433 15 dyld 0x7ff80761e792 dyld4::start(dyld4::KernelArgs*, void*, void*)::$_0::operator()() const + 572 16 dyld 0x7ff80761e27f start + 1727 Thread 1: 0 libsystem_pthread.dylib 0x7ff8079a8bcc start_wqthread + 0 Thread 2: 0 libsystem_pthread.dylib 0x7ff8079a8bcc start_wqthread + 0 Thread 0 crashed with X86 Thread State (64-bit): rax: 0x00006000012acc80 rbx: 0x00006000032b3c90 rcx: 0x00006000012acd00 rdx: 0x000000011008e000 rdi: 0x0000000000000000 rsi: 0x00006000012ac000 rbp: 0x00007ff7b3c5a9f0 rsp: 0x00007ff7b3c5a9c0 r8: 0x0000000000000002 r9: 0x000000000000001b r10: 0x00000000001ff800 r11: 0x0000000000000080 r12: 0x000000010eeae278 r13: 0x000000010c28f6e8 r14: 0x00007ff84a461050 r15: 0x00007ff84a4614a0 rip: 0x000000010c9e3d81 rfl: 0x0000000000010207 cr2: 0x0000000000000000 Logical CPU: 2 Error Code: 0x00000000 Trap Number: 6
0
0
181
Dec ’24
SIGTRAP (#0): Application crash: SIGTRAP (Trace/BPT trap)
Hardware Model: iPhone15,3 Process: fieldserviceapp [14394] Path: Version: 1.0.446605 (446605) Code Type: ARM-64 Parent Process: [1] Date/Time: 2024-12-03 22:01:11.0030 +0530 OS Version: iPhone OS 18.1.1 (22B91) Exception Type: SIGTRAP Exception Codes: #0 Triggered by Thread: 31 Thread 0 name: Thread 0: 0 libsystem_kernel.dylib 0x00000001ecc76688 mach_msg2_trap + 8 1 libsystem_kernel.dylib 0x00000001ecc79cb0 mach_msg_overwrite + 424 2 libsystem_kernel.dylib 0x00000001ecc79afc mach_msg + 24 3 CoreFoundation 0x000000019c8b5a84 __CFRunLoopServiceMachPort + 160 4 CoreFoundation 0x000000019c8b5130 __CFRunLoopRun + 1212 5 CoreFoundation 0x000000019c8b4830 CFRunLoopRunSpecific + 588 6 GraphicsServices 0x00000001e88941c4 GSEventRunModal + 164 7 UIKitCore 0x000000019f41aeb0 -[UIApplication _run] + 816 8 UIKitCore 0x000000019f4c95b4 UIApplicationMain + 340 9 fieldserviceapp 0x0000000100e44e60 0x100e34000 + 69216 10 ??? 0x00000001c22a2ec8 0x0 + 7552511688 Thread 1 name: Thread 1: 0 libsystem_kernel.dylib 0x00000001ecc76688 mach_msg2_trap + 8 1 libsystem_kernel.dylib 0x00000001ecc79cb0 mach_msg_overwrite + 424 2 libsystem_kernel.dylib 0x00000001ecc79afc mach_msg + 24 3 CoreFoundation 0x000000019c8b5a84 __CFRunLoopServiceMachPort + 160 4 CoreFoundation 0x000000019c8b5130 __CFRunLoopRun + 1212 5 CoreFoundation 0x000000019c8b4830 CFRunLoopRunSpecific + 588 6 Foundation 0x000000019b55c500 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 212 7 Foundation 0x000000019b55c350 -[NSRunLoop(NSRunLoop) runUntilDate:] + 64 8 UIKitCore 0x000000019f42e358 -[UIEventFetcher threadMain] + 420 9 Foundation 0x000000019b56d6c8 NSThread__start + 724 10 libsystem_pthread.dylib 0x0000000224de937c _pthread_start + 136 11 libsystem_pthread.dylib 0x0000000224de4494 thread_start + 8 Thread 2 name: Thread 2: 0 libsystem_kernel.dylib 0x00000001ecc76688 mach_msg2_trap + 8 1 libsystem_kernel.dylib 0x00000001ecc79cb0 mach_msg_overwrite + 424 2 libsystem_kernel.dylib 0x00000001ecc79afc mach_msg + 24 3 CoreFoundation 0x000000019c8b5a84 __CFRunLoopServiceMachPort + 160 4 CoreFoundation 0x000000019c8b5130 __CFRunLoopRun + 1212 5 CoreFoundation 0x000000019c8b4830 CFRunLoopRunSpecific + 588 6 fieldserviceapp 0x0000000101226620 0x100e34000 + 4138528 7 Foundation 0x000000019b56d6c8 NSThread__start + 724 8 libsystem_pthread.dylib 0x0000000224de937c _pthread_start + 136 9 libsystem_pthread.dylib 0x0000000224de4494 thread_start + 8 Thread 3 name: Thread 3: 0 libsystem_kernel.dylib 0x00000001ecc7bf90 __psynch_cvwait + 8 1 libc++.1.dylib 0x00000001ace87584 std::__1::condition_variable::wait(std::__1::unique_lockstd::__1::mutex&) + 28 2 hermes 0x0000000103788f24 0x1036bc000 + 839460 3 hermes 0x0000000103788e8c 0x1036bc000 + 839308 4 libsystem_pthread.dylib 0x0000000224de937c _pthread_start + 136 5 libsystem_pthread.dylib 0x0000000224de4494 thread_start + 8 Thread 4 name: Thread 4: 0 libsystem_kernel.dylib 0x00000001ecc7bf90 __psynch_cvwait + 8 1 libc++.1.dylib 0x00000001ace87584 std::__1::condition_variable::wait(std::__1::unique_lockstd::__1::mutex&) + 28 2 hermes 0x0000000103788f24 0x1036bc000 + 839460 3 hermes 0x0000000103788e8c 0x1036bc000 + 839308 4 libsystem_pthread.dylib 0x0000000224de937c _pthread_start + 136 5 libsystem_pthread.dylib 0x0000000224de4494 thread_start + 8 Thread 5 name: Thread 5: 0 libsystem_kernel.dylib 0x00000001ecc7bf90 __psynch_cvwait + 8 1 libc++.1.dylib 0x00000001ace87584 std::__1::condition_variable::wait(std::__1::unique_lockstd::__1::mutex&) + 28 2 CardReaderWrapperDynamic 0x000000010432e3e4 0x104298000 + 615396 3 CardReaderWrapperDynamic 0x0000000104330a08 0x104298000 + 625160 4 libsystem_pthread.dylib 0x0000000224de937c _pthread_start + 136 5 libsystem_pthread.dylib 0x0000000224de4494 thread_start + 8 Thread 9 name: Thread 9: 0 libsystem_kernel.dylib 0x00000001ecc7bf90 __psynch_cvwait + 8 1 libc++.1.dylib 0x00000001ace87618 std::__1::condition_variable::__do_timed_wait(std::__1::unique_lockstd::__1::mutex&, std::__1::chrono::time_point<std::__1::chrono::system_clock, std::__1::chrono::duration<long long, std::__1::ratio<(long)1, (long)1000000000> > >) + 100 2 fieldserviceapp 0x0000000101d115fc 0x100e34000 + 15586812 3 fieldserviceapp 0x0000000101e740fc 0x100e34000 + 17039612 4 fieldserviceapp 0x0000000101e6f878 0x100e34000 + 17021048 5 fieldserviceapp 0x0000000101e75e2c 0x100e34000 + 17047084 6 libsystem_pthread.dylib 0x0000000224de937c _pthread_start + 136 7 libsystem_pthread.dylib 0x0000000224de4494 thread_start + 8 Thread 12 name: Thread 12: 0 libsystem_kernel.dylib 0x00000001ecc76688 mach_msg2_trap + 8 1 libsystem_kernel.dylib 0x00000001ecc79cb0 mach_msg_overwrite + 424 2 libsystem_kernel.dylib 0x00000001ecc79afc mach_msg + 24 3 CoreFoundation 0x000000019c8b5a84 __CFRunLoopServiceMachPort + 160 4 CoreFoundation 0x000000019c8b5130 __CFRunLoopRun + 1212 5 CoreFoundation 0x000000019c8b4830 CFRunLoopRunSpecific + 588 6 CFNetwork 0x000000019de30ee0 +[__CFN_CoreSchedulingSetRunnable _run:] + 416 7 Foundation 0x000000019b56d6c8 NSThread__start + 724 8 libsystem_pthread.dylib 0x0000000224de937c _pthread_start + 136 9 libsystem_pthread.dylib 0x0000000224de4494 thread_start + 8
0
0
300
Dec ’24
Issues with Multicast Operations using NWConnectionGroup and NWMulticastGroup
Hello, I've been encountering some challenges while working with NWConnectionGroup and NWMulticastGroup for multicast operations on iOS. I have a few doubts and issues that I would like to address: 1. NWMulticastGroup Initialization It seems that when initializing NWMulticastGroup, only one NWEndpoint can be passed, and attempting to pass multiple endpoints results in failure. Can someone confirm if this behavior is correct? 2. Interface Level Control Upon initializing NWConnectionGroup, it appears that packets are received on all interfaces without the ability to control this at the interface level. Is this correct? If not is there a way to configure NWConnectionGroup to receive packets on all interfaces? 3. Sending Behavior During the send operation, it appears that the data is sent through any one of the available interfaces, and there doesn't seem to be an option to configure it to send through all available endpoints. Is there a way to enable sending data through all available endpoints? Any insights, guidance, or solutions to these issues would be greatly appreciated. Has anyone else encountered similar problems or found workarounds for these limitations? Thank you for your assistance and support. Thanks, Harshal
4
0
797
Jan ’25
ShortCuts: Send email with email address as a parameter
Hello everyone, I would like to dictate a text with Shortcuts and then send it to one of two e-mail addresses (private or business). I would like to be able to select one of two email addresses. Unfortunately, I am not able to pass an email address as a parameter to the Send email function. Is it possible to do this? I'm new to apple and I'm all but not a programmer. So take pity on me :) Best, Niko
0
0
464
Dec ’24
Apple Push Notification service server certificate update
You are probably aware of the upcoming root certificate change for any servers you might have that you use to send push notifications by connection to APNs. If you are not, here is the announcement. We have been getting some questions about this, and understand not everyone is familiar with their server setup. First, we would like to clarify that this is only a change to your server's certificate trust store. You do not need to update anything else, like your APNs push certificates, the build certificates and provisioning profiles for your team/app, and so on. All you need to do is to install the mentioned new root certificate to your push server's trust store. If you are using a 3rd party push provider, it is them who will need to handle their servers. But you may want to double check with them nevertheless. If you are managing your own push servers that connect to APNs directly, then it is your responsibility to download and install the root certificate mentioned in the above link on your server(s). Unfortunately we cannot provide specific instructions on how to install this root certificate on every kind of server out there. Each server operating system/push server software will have different ways these root certificates are installed, which is out of scope of our support abilities. If you are not sure how to do this, I would recommend you seek help for this from your server-side developers or server admins. Or, if you don't have access to such resources, you can ask the support channels for your system the question: How do I install a root certificate? We have setup a test server at 17.188.143.34:443 that you can use to try and send pushes to test whether your new root certificate is correctly installed. An alternative way to test this would be, from a terminal prompt: openssl s_client -connect 17.188.143.34:443 -servername api.sandbox.push.apple.com -verifyCAfile USERTrustRSACertificationAuthority.crt -showcerts Change the parameter to the -verifyCAfile argument to point to your trust store, and it should allow you to validate Sample return results would be: Connecting to 17.188.143.34 CONNECTED(00000003) depth=2 C=US, ST=New Jersey, L=Jersey City, O=The USERTRUST Network, CN=USERTrust RSA Certification Authority verify return:1 depth=1 CN=Apple Public Server RSA CA 11 - G1, O=Apple Inc., ST=California, C=US verify return:1 depth=0 C=US, ST=California, O=Apple Inc., CN=api.sandbox.push.apple.com verify return:1 Argun Tekant /  DTS Engineer / Core Technologies
0
0
2.3k
Jan ’25
Can Apple Pay Transactions Be Integrated into a Third-Party Expense Management App?
Hello, I am developing a mobile application focused on helping users centralize and analyze their expenses. The app's key feature is to track transactions made through Apple Pay, providing users with a consolidated view of their spending across all linked bank cards or accounts. I have a few specific questions regarding the feasibility of this integration: Does Apple provide any official APIs or tools to access Apple Pay transaction data for third-party applications? Are there restrictions or guidelines for apps that aim to use Apple Pay to support expense tracking? What would be the best way to initiate a partnership or obtain further support from Apple for such a project? Your insights or direction on how to proceed would be greatly appreciated. Thank you for your time and guidance! Best regards, Amine
1
0
347
Jan ’25
Critical SKAdNetwork Attribution
Subject/Title: Critical SKAdNetwork Attribution Failures (Bug Type: 237, Failure Type: 1201 in ASDErrorDomain) Issue Summary We are encountering repeated SKAdNetwork attribution failures (failureType: 1201 in ASDErrorDomain) for ad impression events processed through the ad network mj797d8u6f.skadnetwork. These failures are causing significant revenue losses, as ad impressions are not being properly attributed to installs. The issue occurs across multiple campaigns and involves both SKAdNetwork API 3.0 and 4.0, suggesting a systemic problem with attribution validation or network communication. This problem is critical as it disrupts advertisers’ ability to track conversions, optimize campaigns, and allocate budgets effectively. Technical Details Key Logs: Below are anonymized samples of the failed SKAdNetwork events: Log Sample 1 (Failure): { "bug_type": "237", "timestamp": "2025-01-07 22:49:15.00 -0500", "os_version": "iPhone OS 18.2.1 (22C161)", "roots_installed": 0, "incident_id": "78523BD9-1F58-4738-B526-8A8A63203214" } { "advertisementStoryId": "3D2E7EBB-1A57-4DF8-9375-2C465F423038", "apiVersion": "3.0", "eventType": "adImpression", "resultType": "finalized", "anonymous": true, "failureType": 1201, "failureDomain": "ASDErrorDomain", "clientEventId": "0F456623-584F-4913-BBD3-C3FD1219D104", "os": "iOS", "topic": "xp_amp_skad_perf", "adType": "app", "adNetworkId": "mj797d8u6f.skadnetwork", "eventTime": 1736305200000, "osBuildNumber": "22C161", "hardwareFamily": "iPhone", "api": "SKAdNetwork" } Log Sample 2 (Failure): { "bug_type": "237", "timestamp": "2025-01-07 22:49:15.00 -0500", "os_version": "iPhone OS 18.2.1 (22C161)", "roots_installed": 0, "incident_id": "0CBF612D-F0D9-449E-A34E-DE2DB92BEC0D" } { "advertisementStoryId": "946E568C-D2C1-478F-BFF3-4996C48F9B39", "apiVersion": "3.0", "eventType": "adImpression", "resultType": "finalized", "anonymous": true, "failureType": 1201, "failureDomain": "ASDErrorDomain", "clientEventId": "1A3D48FB-4452-4FD8-BB25-1195470A53DC", "os": "iOS", "topic": "xp_amp_skad_perf", "adType": "app", "adNetworkId": "mj797d8u6f.skadnetwork", "eventTime": 1736298000000, "osBuildNumber": "22C161", "hardwareFamily": "iPhone", "api": "SKAdNetwork" } Log Sample 3 (Success Example for Comparison): { "bug_type": "237", "timestamp": "2025-01-07 22:49:15.00 -0500", "os_version": "iPhone OS 18.2.1 (22C161)", "roots_installed": 0, "incident_id": "BFEAC86B-8195-4DB0-96FF-2028107256AD" } { "advertisementStoryId": "946E568C-D2C1-478F-BFF3-4996C48F9B39", "apiVersion": "3.0", "eventType": "adImpression", "resultType": "finalized", "anonymous": true, "clientEventId": "F6265488-E0FB-448A-A406-3F7254BCA9D7", "os": "iOS", "topic": "xp_amp_skad_perf", "adType": "app", "adNetworkId": "mj797d8u6f.skadnetwork", "eventTime": 1736294400000, "osBuildNumber": "22C161", "hardwareFamily": "iPhone", "api": "SKAdNetwork" } Failure Details: Failure Type: 1201 Failure Domain: ASDErrorDomain Ad Network ID: mj797d8u6f.skadnetwork API Versions Affected: 3.0, 4.0 Timeframe of Failures: All logs occur within 2025-01-07 22:00:00 UTC to 23:00:00 UTC. Environment: OS Version: iOS 18.2.1 (Build 22C161). Device Type: iPhone (hardwareFamily: iPhone). App Configuration: Includes the ad network ID in the Info.plist under SKAdNetworkItems. Impact Details Financial Loss: Based on failure rates, we estimate $20–$65/day per advertiser for small campaigns and $75–$375/day per advertiser for larger campaigns. If 100 advertisers are affected, daily losses range from $2,000–$37,500. Over a week, losses could exceed $70,000 to $262,500 or more. Operational Impact: Advertisers cannot track installs or optimize campaigns, leading to inefficient ad spending and potential budget reallocation to other networks. Damaged trust between advertisers and the ad network. Reputation Risk: Continued failures harm the credibility of the SKAdNetwork framework, critical in a post-ATT (App Tracking Transparency) ecosystem. Steps to Reproduce Serve an ad impression through the ad network mj797d8u6f.skadnetwork. Monitor SKAdNetwork attribution for that impression. Observe repeated failures (failureType: 1201) despite the resultType: finalized status. Recommendations for Investigation Attribution Timeout: Verify if these failures stem from delayed responses or missed attribution windows. Ad Network Configuration: Confirm the ad network’s integration complies with SKAdNetwork API 3.0 and 4.0 requirements. Infrastructure Review: Investigate potential bottlenecks or failures in Apple’s attribution servers (ASDErrorDomain) or communication delays. Contact Details Name: [Your Full Name] Role: [Your Role] (e.g., Ad Network Analyst/Developer) Organization: [Your Company Name] Email: [Your Email Address] Phone: [Your Phone Number] Submission Instructions You can submit this report via the following channels: Apple Feedback Assistant: https://feedbackassistant.apple.com/ Bug Reporting Tool: https://developer.apple.com/bug-reporting/ Apple DTS: https://developer.apple.com/support/technical/
0
0
355
Jan ’25
iOS sdcard plug-in/unplug event and read problems
Currently, we use UIDocumentPickerViewController to read the user's connected sdcard. However, this requires the user to select manually, and the event cannot be monitored. But recently I found that ImageCaptureCore's ICDeviceBrowserDelegate can monitor the plug-in and unplug events in the didAddDevice callback, but cannot obtain the path of the storage card. I wonder if there is a way to combine the advantages of both, so that with the user's consent, the card reader events can be monitored and the content can be read directly without the user manually selecting the folder
0
0
291
Jan ’25
NESMVPNSession disconnected
Hi, I have a problem with my OpenVPN connection on my app with iOS 14.4. I perform my VPN configuration from an oven file, with a NETunnelProviderManager protocol, but when I perform the startVPNTunnel, it starts connecting and immediately disconnects. The error I see in the logs is the following: NESMVPNSession[Primary Tunnel:OpenVPN Client: -----(null)]: status changed to disconnected, last stop reason Plugin was disabled This happens to me when running my app on a physical iPad. Regards import NetworkExtension import OpenVPNAdapter class VPNConnection {          var connectionStatus = "Disconnected"              var myProviderManager: NETunnelProviderManager?          func manageConnectionChanges( manager:NETunnelProviderManager ) - String {         NSLog("Waiting for changes");         var status = "Disconnected"                  NotificationCenter.default.addObserver(forName: NSNotification.Name.NEVPNStatusDidChange, object: manager.connection, queue: OperationQueue.main, using: { notification in                          let baseText = "VPN Status is "                          switch manager.connection.status {             case .connected:                 status = "Connected"             case .connecting:                 status = "Connecting"             case .disconnected:                 status = "Disconnected"             case .disconnecting:                 status = "Disconnecting"             case .invalid:                 status = "Invalid"             case .reasserting:                 status = "Reasserting"             default:                 status = "Connected"             }                          self.connectionStatus = status                          NSLog(baseText+status)                      });         return status     }          func createProtocolConfiguration() - NETunnelProviderProtocol {         guard             let configurationFileURL = Bundle.main.url(forResource: "app-vpn", withExtension: "ovpn"),             let configurationFileContent = try? Data(contentsOf: configurationFileURL)         else {             fatalError()         }                  let tunnelProtocol = NETunnelProviderProtocol()         tunnelProtocol.serverAddress = ""         tunnelProtocol.providerBundleIdentifier = "com.app.ios"                  tunnelProtocol.providerConfiguration = ["ovpn": String(data: configurationFileContent, encoding: .utf8)! as Any]         tunnelProtocol.disconnectOnSleep = false                  return tunnelProtocol     }          func startConnection(completion:@escaping () - Void){         self.myProviderManager?.loadFromPreferences(completionHandler: { (error) in             guard error == nil else {                 // Handle an occurred error                 return             }                          do {                 try self.myProviderManager?.connection.startVPNTunnel()                 print("Tunnel started")             } catch {                 fatalError()             }         })     }          func loadProviderManager(completion:@escaping () - Void) {                           NETunnelProviderManager.loadAllFromPreferences { (managers, error) in             guard error == nil else {                 fatalError()                 return             }                          self.myProviderManager = managers?.first ?? NETunnelProviderManager()             self.manageConnectionChanges(manager: self.myProviderManager!)                          self.myProviderManager?.loadFromPreferences(completionHandler: { (error) in                 guard error == nil else {                     fatalError()                     return                 }                                  let tunnelProtocol = self.createProtocolConfiguration()                                  self.myProviderManager?.protocolConfiguration = tunnelProtocol                 self.myProviderManager?.localizedDescription = "OpenVPN Client Ubic"                                  self.myProviderManager?.isEnabled = true                                  self.myProviderManager?.isOnDemandEnabled = false                                  self.myProviderManager?.saveToPreferences(completionHandler: { (error) in                     if error != nil  {                         // Handle an occurred error                         fatalError()                     }                     self.startConnection {                         print("VPN loaded")                     }                 })             })         }     } }
14
0
3.2k
Jan ’25
Handling Data Download Backpressure in URLSession
I am developing an application that processes a video file stored on a server. I use URLSessionDataTask with a delegate handler to download the file. It is not necessary to download the entire file at once. Instead, I can load small chunks of the file as needed. This approach helps minimize memory consumption. I am trying to design a network layer that supports this behavior. Ideally, I would like to have an interface similar to: func readMoreData(length: Int) async throws -> Data Problems I Encountered: It seems that URLSessionDataTask does not allow controlling how many bytes will be downloaded. It always downloads the entire request. If I call suspend on URLSessionDataTask, the network activity does not stop, and the file keeps downloading. If I upgrade the dataTask to a StreamTask, the file still downloads, though reading bytes can be done through the StreamTask API. I would prefer behavior similar to AsyncHTTPClient (a Swift Server library) or Network Framework. These frameworks allow controlling the number of bytes downloaded at a time. Unfortunately, they do not fit the specific requirements of my project. Am I correct in understanding that controlling the download process is not possible with URLSessionDataTask? As a possible solution, I am considering using HTTP Range Requests, though this would increase the number of additional server requests, which I would like to avoid.
0
0
213
Dec ’24
Local Network privacy blocking my app when it shouldn't
I have read the other most relevant posts on this topic here and here. However, the situations described in these posts are different. My app is just a regular Mach-O bundle with a single executable that is launched by the user from the Finder. I've read the Local Network Privacy FAQ and TN3179 carefully and these also doesn't cover the problem described below, which is being reported to me by several of my users. The problem is that some days after giving Local Network permission to my app, without having changed anything, local network connections will spontaneously start failing with EHOSTUNREACH, indicating that it is being blocked by macOS. This typically happens after a Mac reboot. Toggling off/on the Local Network permission for my app will get it working again, until the next time it fails. My users who are reporting this have stated that they are running macOS Sonoma 15.2, with only a single version/copy of my app installed. I've tried, and failed, to reproduce this in a VM with a clean 15.2 system, but maybe this is due to the relatively short duration of my testing (days rather than weeks). I know there isn't much to go on here, and it may be tempting to put this down to misreporting. After all, the vast majority of my users aren't reporting this, and I can't reproduce it. But, I have received enough similar reports at this point that it's starting to feel like a macOS bug. Is anyone else seeing this? If there is anything that anyone can suggest - either modifications in my app, or anything that my users can do on their side - this would be very much appreciated! Many thanks, Ben
1
0
432
Jan ’25
CKShare Fails with quotaExceeded Error on Family iCloud Plan
Hello, When attempting to create a CKShare on a personal device linked to a Family iCloud plan (non-primary account holder), the operation fails with a quotaExceeded error. This occurs with the Family plan having 1.5TB available storage space. This is also causing a data loss for the object(s) that were attempted to be shared. Details Account Type: Family iCloud Plan (2TB total storage) Current Family Usage: 399GB iCloud Account Usage: 70 GB Steps to Reproduce: Have an iCloud account with storage over the 5GB free space limit. Be on a part of a iCloud Family Plan as the non-primary account holder. Have storage space available in the Family Plan Attempt to start a CloudKit Share/Collaboration on the device. Observe that the CKShare creation fails with a quotaExceeded error. Expected Behavior: The CKShare should be successfully created, reflecting the total available storage of the Family plan. Observed Behavior: The CKShare fails to be created with quotaExceeded. Additional Testing On a test device using an iCloud account with no stored data, the CKShare was created successfully and shared without issue. Suspected Cause The CKShare functionality is verifying the personal storage allocation of the iCloud account and failing without checking total available storage provided by the Family plan.
2
0
752
Jan ’25
CallKit Keeps Terminating
Hello, I am currently developing a call service using CallKit and VoIP push. Recently, I have encountered a very challenging issue. During testing, when a VoIP push is received, the incomingCall gets triggered continuously, but then it automatically terminates after about 1-2 seconds. I am checking this issue under the debug scheme, and even when switching to different commits, the same problem persists. I suspect it might be an issue with the device, but I would like to confirm the cause and find a solution. Below are some characteristics I have noticed: On this device, when a VoIP push is received, CallKit automatically terminates, but this does not occur when debugging. The issue always occurs when not debugging. Looking at the device console logs related to callservicesd, there are many logs with 'invalidate' appended. For example: Invalidating process assertion for bundle ID from timeout All calls ended. Clearing system uplink muted cache Invalidate callDurationUpdateTimer InCallService has changed process state to 2 InCallService has been suspended; invalidating its XPC client connections. [0x565544180] invalidated because the current process cancelled the connection by calling xpc_connection_cancel() XPC connection invalidated from client These logs appear although our server did not receive any incoming call request, so we did not terminate it on our end. I also checked if there was a crash, but there were no reports left on the device. Could you please share any insights into the cause or solutions for this situation? Thank you.
0
0
366
Jan ’25
Field recordName is not marked queryable
I'm using NSPersistentCloudKitContainer and in the CloudKit dashboards I have added indexes for all my records modifiedTimestamp queryable, modifiedTimestamp sortable and recordName queryable. But I'm still getting this warning message in the console. <CKError 0x302acf0c0: "Invalid Arguments" (12/2015); server message = "Field 'recordName' is not marked queryable"; op = FF68EFF8D501AED8; uuid = 12C5C84B-EA9B-41A6-AD85-34023827E6FA; container ID = "z.y.x"> error: CoreData+CloudKit: -[NSCloudKitMirroringDelegate _importFinishedWithResult:importer:](1400): <PFCloudKitImporter: 0x30316c1c0>: Import failed with error: <CKError 0x302acf0c0: "Invalid Arguments" (12/2015); server message = "Field 'recordName' is not marked queryable"; op = FF68EFF8D501AED8; uuid = 12C5C84B-EA9B-41A6-AD85-34023827E6FA; container ID = "z.y.x"> error: CoreData+CloudKit: -[NSCloudKitMirroringDelegate recoverFromError:](2312): <NSCloudKitMirroringDelegate: 0x301b1cd20> - Attempting recovery from error: <CKError 0x302acf0c0: "Invalid Arguments" (12/2015); server message = "Field 'recordName' is not marked queryable"; op = FF68EFF8D501AED8; uuid = 12C5C84B-EA9B-41A6-AD85-34023827E6FA; container ID = "z.y.x"> error: CoreData+CloudKit: -[NSCloudKitMirroringDelegate _recoverFromError:withZoneIDs:forStore:inMonitor:](2622): <NSCloudKitMirroringDelegate: 0x301b1cd20> - Failed to recover from error: CKErrorDomain:12 Recovery encountered the following error: (null):0 error: CoreData+CloudKit: -[NSCloudKitMirroringDelegate resetAfterError:andKeepContainer:](612): <NSCloudKitMirroringDelegate: 0x301b1cd20> - resetting internal state after error: <CKError 0x302acf0c0: "Invalid Arguments" (12/2015); server message = "Field 'recordName' is not marked queryable"; op = FF68EFF8D501AED8; uuid = 12C5C84B-EA9B-41A6-AD85-34023827E6FA; container ID = "z.y.x"> error: CoreData+CloudKit: -[NSCloudKitMirroringDelegate _requestAbortedNotInitialized:](2200): <NSCloudKitMirroringDelegate: 0x301b1cd20> - Never successfully initialized and cannot execute request '<NSCloudKitMirroringImportRequest: 0x300738eb0> A3F23AAC-F820-4044-B4B9-28DFAC4DE8D7' due to error: <CKError 0x302acf0c0: "Invalid Arguments" (12/2015); server message = "Field 'recordName' is not marked queryable"; op = FF68EFF8D501AED8; uuid = 12C5C84B-EA9B-41A6-AD85-34023827E6FA; container ID = "z.y.x">
2
0
975
Dec ’24
App built with Xcode 16.2 is greater then 100 mb vs the app built with Xcode 15.4
I have an app written in swift. It has multiple pods dependencies installed. When the app is generated with Xcode 15.4 the size of app is ~148Mb and when the same app is generated with Xcode 16.2 the size is ~246MB When I extracted and analysed the app, it was observed that one of the framework installed via pods Dependencies("DocumentReaderCore") was consuming more size(42.9 MB vs 215 MB) the DocumentReaderCore present in the Payload/.app/Frameworks/DocumentReaderCore.framework/DocumentReaderCore was of type linux executable when generated using Xcode 15.4 vs the other was od document type and size was 215MB.
1
0
527
Dec ’24
The message filtering documentation is offline
Hello the documentation for message filtering has been offline for a few days now, is it possible to get it back, or is there somewhere else it can be viewed in the meanwhile? https://developer.apple.com/documentation/sms_and_call_reporting/sms_and_mms_message_filtering (I just chose topic/tags at random, there aren't any relevant for this)
0
0
315
Dec ’24
The app icon is not appearing under the "From Apps on Your iPhone" section in Apple Wallet.
Hello, We are integrating Apple Wallet functionality using the Thales SDK. While we’ve successfully implemented In-App provisioning, we are encountering an issue with the Wallet Extension. I followed the documentation provided here to implement the Apple Wallet Extension: https://developer.dbp.thalescloud.io/docs/d1-developer-portal/ab10ea4059dx1-apple-wallet-extension I’ve implemented everything as per the guide, but I’m still unable to see my app logo in the Wallet Extension under "From Apps on Your iPhone." Could anyone help identify what might be missing or point me in the right direction to resolve this issue. Thanks!
0
0
482
Dec ’24