Posts under App & System Services topic

Post

Replies

Boosts

Views

Activity

PDFKit leaks a Vision document-analysis pipeline per rendered PDFDocument on iPadOS 26 – and `PDFView` already has the switch to stop it
On iPadOS 26, PDFKit runs VNRecognizeDocumentsRequest over the pages of a PDFDocument when those pages are rendered. The analysis pipelines are never released. Measured on an iPad Pro 12.9-inch 4th gen (iPad8,11), iPadOS 26.6, with a 61-page image-only scanned score: each newly-created-and-rendered PDFDocument costs about 2.7 OS threads and 20 MB, permanently. Repeatedly loading the same file from disk reached 153 threads and 1519 MB in under seven minutes, then died of an allocation failure. Nothing releases it: not replacing PDFView.document, not deallocating the PDFView entirely, not releasing the PDFDocument, and not time. With every code path in the app stopped, the thread count does not fall — it continues to rise. The stack -[PDFView visiblePagesChanged:] → +[PDFPageAnalyzerV2 analyzePage:withBox:requestTypes:] → -[VNImageRequestHandler performRequests:gatheredForensics:error:] → -[VNRecognizeDocumentsRequest internalPerformRevision:inContext:error:] → -[VNDetector processUsingQualityOfServiceClass:options:regionOfInterest:…] → -[VNControlledCapacityTasksQueue dispatchSyncByPreservingQueueCapacity:] Thread census at 1519 MB — 153 threads total, after 66 document loads: 66 PDFKit.PDFDocument.formFillingQueue 64 com.apple.VNRecognizeDocumentsRequestRevision1 10 ANEServicesThread 66 orphaned pipelines for 66 loads, all blocked on Vision's capacity limiter. The console also emits Invalid permutation index when reordering subregions. Index N must be less than number of subregions 1 continuously, with N increasing — and these keep arriving after all application activity has stopped. Isolation Each row is a separate run on the same device and OS, one variable changed. Counts are OS threads; baseline is 13. Configuration Result Page-stepping only on a stable document (~1000 visiblePagesChanged: events) No growth; footprint declines Recreating PDFThumbnailView on every load No growth Creating a PDFDocument and never rendering it No growth Creating + rendering, assigned to a PDFView +2.0 to +2.7 threads / +20 MB per load Creating + rendering, never assigned to any PDFView Same growth Creating + rendering, entire PDFView destroyed and rebuilt per load Same growth Two points worth drawing out: The leak occurs with no PDFView involved at all — plain PDFPage.thumbnail(of:for:) or PDFPage.draw(with:to:) on a freshly created document is sufficient. Destroying the PDFView releases nothing. Whatever retains the analyses outlives every object the application can reach. Also, for anyone who arrives here from the other PDFPageAnalyzerV2 threads: the usePageViewController(true, withViewOptions: nil) workaround does not help this. It reduces visiblePagesChanged: frequency, and page changes on a stable document leak nothing. The variable is newly rendered documents, not new pages. The switch already exists PDFView implements -setDocumentAnalysisEnabled: and -isDocumentAnalysisEnabled, plus -handleAnalysisCompletionOfPage:resultTypes:. None of these appear in any public header. With document analysis disabled, the leak disappears completely — 28 consecutive document loads with zero thread growth, and after stopping, the process released down to 6 threads and 64 MB, below its own idle baseline. It also suppresses the leak for documents never assigned to that PDFView, so whatever the flag gates is not scoped to a single view. For completeness, the per-page -setCandidateForOCR: / -setDidPerformOCR: accessors do not help: the writes land and read back correctly, and the analysis runs anyway. They appear to be state rather than policy. Request Either: Fix the leak — cancel and release analyses when the document or the view goes away; or Make documentAnalysisEnabled public on PDFView (or add an equivalent on PDFDocument). Ideally, please do both. The second costs Apple nothing: the property exists, it works, and it is exactly the control that is needed. Applications that render sheet music, engineering drawings, or any other content where document understanding provides no value are currently paying for it with unbounded memory growth and no supported way to decline. Filed as FB24211659. Happy to share the isolation harness with anyone from the PDFKit team. Related: 825803 (crash in PDFPageAnalyzerV2, FB22409977), 827781 (deadlock in the same class), 838272 / 837282 (PDFTileSurface over-release), 107007 (CGContextDrawPDFPage thread safety, open since 2018).
0
0
170
1w
iOS26.4,appStoreReceiptURL获取票据延迟
iOS 26.4系统上,我们发现三个问题: 1.调用了finishTransaction接口,但是在App重新启动后,[SKPaymentQueue defaultQueue].transactions仍然会有这笔订单。 2.支付完成后,[[NSBundle mainBundle] appStoreReceiptURL]],拿到的票据解析出来里面的商品是空的,需要延迟2秒钟左右在调用[[NSBundle mainBundle] appStoreReceiptURL]]才能获取有效票据。 3.支付完成后,如果用户没有点击最后弹出的确认弹框,等待5秒钟,系统会自己回调 - (void)paymentQueue:(SKPaymentQueue *)queue updatedTransactions:(NSArray<SKPaymentTransaction *> *)transactions; 代理方法。正常应该是用户点击了最后弹出的确认弹框,在回调- (void)paymentQueue:(SKPaymentQueue *)queue updatedTransactions:(NSArray<SKPaymentTransaction *> *)transactions;方法。 我们在苹果开发者论坛上面找到其他开发者反馈的类似问题,链接如下: https://developer.apple.com/forums/thread/817700 https://developer.apple.com/forums/thread/792437?answerId=849557022#849557022 https://developer.apple.com/forums/thread/817834 https://developer.apple.com/forums/thread/817706 https://developer.apple.com/forums/thread/818586 我们有大量用户升级到了26.4系统,这对于我们造成了巨大的困扰,我们需要你们的帮助,感谢!
8
1
1.5k
1w
Prevent multiple DNS Proxy Filter when switching users
Hello Team, We have a System Extension with Provider Type "DNS Proxy". We have embedded the System Extension in GUI target which registered as LaunchAgent. We found NEDNSProxyManager saves the proxy configuration in the caller's preferences. Due to that we see a prompt for Network Extension when switching users. On allowing that we see multiple DNS filter in the System Settings->Network->Filters even though one DNS Filter can enabled which is annoying. Question 1: Is this expected for non MDM users? Are the users expected to authorise Network extension when switching users. Question 2: Is there a way to prevent the multiple DNS filter for both MDM and non MDM users? To prevent multiple filters, we identified a solution to embed the System Extension in our LaunchDaemon target. So the proxy configuration will be save in the root preference. But with this approach we ended up with an error [OSSystemExtensionErrorDomain error 13] during OSSystemExtensionRequest.deactivationRequest. Question 3: Is there a way to avoid OSSystemExtensionErrorDomain 13 when deactivating System extension from our LaunchDaemon process? Question 4: What is the best practice in terms of embedding and deploying DNS Proxy System Extension for managed and non managed environment. Also if user expected to see multiple DNS filter. I suggest to show the filter that saved for that user's preference. Thank you.
1
0
518
1w
URL Filters not activating on iOS 27 beta
(Also submitted as FB23072541) iOS 27 beta 1 brings a brand new error which ends up resulting in a state of .serverSetupIncomplete: <NEPIRChecker: 0x7de6c79b60>: -[NEPIRChecker start:responseQueue:completionHandler:]_block_invoke - PIR status returned error <Error Domain=com.apple.CipherML Code=1100 "Unable to query status due to errors: Error details were logged and redacted." UserInfo={NSLocalizedDescription=Unable to query status due to errors: Error details were logged and redacted., NSUnderlyingError=0x7de712f4e0 {Error Domain=com.apple.CipherML Code=1800 "Error details were logged and redacted." UserInfo={NSLocalizedDescription=Error details were logged and redacted.}}}> <NEAgentURLFilterExtension: 0x7de6d24e60>: -[NEAgentURLFilterExtension startURLFilter]_block_invoke - Failed to startFilter <Error Domain=NEMembershipCheckerErrorDomain Code=3 "(null)"> What’s a NEMembershipChecker? Member of what? Digging deeper I found these: Failed to prefetch tokens for group 'site.kaylees.Wipr2': Error Domain=NSURLErrorDomain Code=-1009 "The Internet connection appears to be offline." UserInfo={_NSURLErrorNWPathKey=satisfied (Path is satisfied), interface: en0[802.11], ipv4, dns, uses wifi, LQM: good, NSErrorFailingURLKey=https://pirissuer.kaylees.site/token-key-for-user-token, NSUnderlyingError=0x7517125a40 {Error Domain=NSPOSIXErrorDomain Code=50 "Network is down" UserInfo={NSDescription=Network is down}}, _NSURLErrorPrivacyProxyFailureKey=true, NSLocalizedDescription=The Internet connection appears to be offline.} queryStatus(for:options:) threw an error: Error Domain=NSURLErrorDomain Code=-1009 "The Internet connection appears to be offline." UserInfo={_NSURLErrorNWPathKey=satisfied (Path is satisfied), interface: en0[802.11], ipv4, dns, uses wifi, LQM: good, NSErrorFailingURLKey=https://pirissuer.kaylees.site/token-key-for-user-token, NSUnderlyingError=0x7517125b00 {Error Domain=NSPOSIXErrorDomain Code=50 "Network is down" UserInfo={NSDescription=Network is down}}, _NSURLErrorPrivacyProxyFailureKey=true, NSLocalizedDescription=The Internet connection appears to be offline.} The connection and the URL mentioned are fine of course, but "Network is down” now? This new problem only affects the App Store version of my app – not present if I install from Xcode. Users report that oddly, having an active VPN on the device works around this bug.
10
3
987
1w
Monterey:Network System Extension OSSystemExtensionRequest.deactivationRequest fails with authorizationRequired = 13
Hello, On Mac OS monterey, OSSystemExtensionRequest.deactivationRequest is failing with deactivation request for com.xxxxxx.networkextensionapp.netextension failed authorization check, error: Error Domain=OSSystemExtensionErrorDomain Code=13 "(null)" Even after providing the correct credentials for authorisation when prompted for.
4
0
1.9k
1w
Kernel Sandbox/System Policy intermittently denies ALL file access (not just mount syscall) on NFS mounts
I'm seeing a recurring issue on macOS 26.5.2 (build 25F84) where the kernel's Sandbox/System Policy layer intermittently denies file access on NFS mount points from local network servers. Posting here in case anyone recognizes this pattern or has a workaround, and flagging it since I've also filed a Feedback Assistant report (with a live-captured sysdiagnose) for the same issue. WHAT HAPPENS Two independent NFS mounts to two separate, unrelated servers on my LAN start failing simultaneously with "Operation not permitted." The kernel log shows: kernel: (Sandbox) System Policy: mount_nfs(PID) deny(1) file-mount /path/to/mount Critically, it's not limited to the mount syscall - within the same few-second window, System Policy also denies ls, perl, diskutil, and even umount -f on the exact same path, for otherwise unrelated processes. So it looks like a transient, path-scoped kernel decision rather than something specific to NFS or the mount syscall. It self-heals anywhere from seconds to ~30 minutes later, then recurs - documented 30-80+ occurrences/day via a background watchdog script. WHAT I'VE RULED OUT Server-side cause: two independent servers on different hardware fail identically at the same instant. Network issue: checked network logs in the same window, no correlated connectivity event. Third-party kext conflict: kextstat shows zero third-party kexts loaded. syspolicyd database corruption: no "ASP: Validation category" signature present. TCC/Full Disk Access: already granted; the denying layer is kernel Sandbox "System Policy," not TCC. QUESTION Has anyone else run into System Policy denying file-mount/file-read-data/file-unmount on network volume paths intermittently like this? Is there any userland way to inspect or reset whatever internal state drives this decision (I haven't found one - no spctl/tccutil/sysctl lever that touches it)? Happy to share more log excerpts if useful.
18
0
1.2k
1w
didRegisterForRemoteNotificationsWithDeviceToken never fires after Individual→Organization account conversion — no token, no error, app‑wide
Summary: After converting our Apple Developer account from Individual → Organization, our app stopped receiving APNs device tokens. application(:didRegisterForRemoteNotificationsWithDeviceToken:) is never called, and application(:didFailToRegisterForRemoteNotificationsWithError:) is also never called — no token, no error. This affects all new device‑token registrations app‑wide; device tokens issued before the conversion still work and continue to deliver pushes. Environment Membership status: Active Device: iPhone 15 Pro, iOS [26.6] Reproduced on both development (sandbox) builds installed via Xcode/CLI and TestFlight builds. What works Existing device tokens (created before ~Aug 1) still deliver pushes normally (server reports delivered 1/1 via our .p8 token‑based auth). So the send path and APNs auth key are fine. UNUserNotificationCenter authorization succeeds — authorizationStatus == .authorized. UIApplication.shared.isRegisteredForRemoteNotifications == true. What doesn't work We call UIApplication.shared.registerForRemoteNotifications() on the main thread after authorization is granted, but neither delegate callback ever fires — no token, no error — on any new install/launch. Timeline / trigger Everything worked before the Individual→Organization conversion. Since the conversion, no new APNs device token has been issued for the app at all. Server‑side we can confirm the most recent device token was created 2026‑08‑01, and none since, despite many fresh installs/launches across multiple users. Pre‑conversion tokens still function. What we've already tried / ruled out App ID has Push Notifications capability enabled; regenerated provisioning profiles. Generated a new APNs Auth Key (.p8) (sends already work, so this was expected not to matter). Fixed the Xcode signing team (it briefly showed "Unknown Name (TEAMID)" right after conversion; resolved by signing into the correct org account — Team now resolves correctly). Device reboot, network settings reset, app delete/reinstall, latest iOS. Confirmed delegate is wired (@UIApplicationDelegateAdaptor) — the same code issued tokens fine before the conversion. Thanks in advance!
0
0
171
1w
TabBar icons not displayed
Working on a CarPlay app (Driving App) and despite setting tab bar icons, they don’t display in either the simulator or two physical devices (one no older than 2024 and with a very large screen), I only see the textual description/name of the tab. Am I missing something ?
1
0
132
1w
ShareLink with Collaboration in SwiftUI with a Document based app
Hello to anyone reading this. I am a bit lost as to what is the correct approach for enabling Collaboration for a Document based SwiftUI app. If I understand correctly, after setting up all the relevant entitlements and capabilities for enabling sharing, you only need to use ShareLink to begin a collaboration/send a copy by passing in the URL of the document. The collaboration is then handled with SWCollaborationView, which there have been NSViewRepresentable wrapper implementations posted around the web. My main question is; how do I know whether the document has been shared to create a collaboration? Do I have to have 2 sharing ToolbarItems? Basically, is there any documentation for implementing collaborations from a document based app, other than simply saying that starting a share is done by passing the url into a ShareLink? This seems to massively missing, or have I massively missed something?
0
0
162
1w
Does the Channel Sounding have regional restrictions by country?
I'm trying to get the new Bluetooth Channel Sounding distance measurement working between an iPhone 17 running iOS 27 Beta4 and a Nordic nRF54L15DK board. I enabled bonding in the latest ipt_reflector sample from Nordic. Someone get the sample working with iOS 27 beta1. I paired the board with AccessorySetupKit. I suspect that the Channel Sounding feature is subject to regional restrictions by country (China). Here's the code to check if CS is available on my iPhone func centralManagerDidUpdateState(_ central: CBCentralManager) { switch central.state { case .poweredOn: print("central update") if CBCentralManager.supports(.channelSounding) { print("Supports channel sounding - YES") } else { print("Supports channel sounding - NO") } if let id = pendingPeripheralIdentifier, let name = pendingPeripheralName { pendingPeripheralIdentifier = nil pendingPeripheralName = nil retrieveAndConnect(identifier: id, name: name) } case .poweredOff: connectionState = .bluetoothOff case .unauthorized: connectionState = .error("Bluetooth not authorized — check Settings") case .unsupported: connectionState = .error("BLE not supported on this device") default: break } } The console log shows [ASK] Session activated — accessories: 1 central update Supports channel sounding - NO [CS] startChannelSounding skipped — channelSounding not supported Please also check the topic. it's very similar.
1
0
549
1w
Can a Mac App Store app use an Apple Events temporary exception for Notes?
Hi all, I’m building a sandboxed macOS app that, among other things, lets the user create and associate an Apple Note with a calendar meeting. The user explicitly initiates the action. The app uses AppleScript to create the note, obtain its identifier, and open it in Notes. Notes only declares the com.apple.Notes.openlocation scripting access group. Note creation is not covered, so com.apple.security.scripting-targets does not appear sufficient. The working implementation requires: com.apple.security.automation.apple-events com.apple.security.temporary-exception.apple-events for com.apple.Notes NSAppleEventsUsageDescription Has anyone successfully shipped a Mac App Store app using this temporary exception to control the built-in Notes app? Is this potentially acceptable with a clear entitlement explanation and Feedback Assistant report, or should I assume that note creation through AppleScript cannot be included in a Mac App Store build? Is there another supported API that can create an Apple Note and return an identifier or openable URL for it?
3
0
312
1w
Push notifications not received despite HTTP 200 from APNs — seeking help to identify the cause
We're experiencing an issue where push notifications are not being received on certain iOS devices, and we'd like help identifying the possible causes. What we've confirmed so far: Push notifications are sent from our own provider server to APNs. APNs returns a normal response (HTTP/2 200) The device tokens are valid and up to date. Affected users have confirmed that notifications are enabled for our app in Settings. Users report no network connectivity issues. We are sending with apns-priority: 10 and apns-push-type: alert. Scope: This is occurring for multiple users, not isolated to a single device. It happens intermittently — some notifications from the same campaign reach the device, while others don't. Critically, some affected users report that they only fail to receive notifications from our app during certain specific time windows, while notifications from other apps arrive normally during the same period. This suggests the issue is app-specific and time-correlated, rather than a device-wide or network-level problem. Questions we'd like help with: Given that APNs returns 200, are there known scenarios where the notification still doesn't reach the device? (e.g., Focus / Do Not Disturb, low power mode, high-frequency throttling, stored-then-discarded due to apns-expiration) Is there a recommended way to obtain per-notification delivery status in the production environment? Are there known limits on how many notifications can be sent to the same device within a short window before APNs starts throttling or coalescing them? Our server logs currently do not retain the apns-id returned by APNs. If we provide the affected device tokens along with the approximate send timestamps, would it be possible for Apple to help investigate the delivery status of those notifications on the APNs side? Any guidance or pointers to relevant documentation would be greatly appreciated. Thank you!
5
0
500
1w
Apple Silicon prevents execution of wine for Windows ARM64 binaries due to JIT/W^X restrictions and x18 register reservation
I am porting Wine to macOS to run Windows on ARM (WOA) binaries. Windows PE files place .text and .data in the same page, which macOS’s JIT/W^X model cannot handle. pthread_jit_write_protect_np() cannot be used for foreign ARM64 code. Apple Silicon reserves x18, breaking the Windows ARM64 ABI. Wine also must reserve 0x7FFE0000 for the Windows TEB, but macOS cannot guarantee this address. These issues make it impossible for Wine to load or execute WOA binaries. I am requesting mechanisms to safely execute foreign ARM64 code, support mixed W/X pages, emulate x18, and reserve the Windows TEB region. Branch is here: https://github.com/trcrsired/wine/tree/apple-silicon-mac-woa
1
0
186
1w
Local Network permission randomly breaks connectivity, only fixable via Recovery Mode
I am currently using macOS 27 beta 4, but this issue also existed on macOS 26.5 before I updated to macOS 27. I am not sure whether earlier system versions had the same problem, as I had never encountered a similar issue before. I am developing through the local network, including using VSCode Remote SSH to connect to a local server, and using a Swift app to establish a WebSocket connection with the local server. Recently, I have encountered multiple cases where the local server connection suddenly failed. Checking the logs showed messages such as Permission denied or similar errors. AI assistants explained that this usually means the target app does not have Local Network permission enabled in Privacy & Security settings. However, I checked the settings page and confirmed that the target apps already have Local Network permission enabled. Previously, when VSCode Remote SSH failed, I observed the following behavior: after updating VSCode, if the local server was not running, VSCode Remote SSH immediately reported that the target server could not be found. After starting the local server, it immediately reported that there was no route to the host (I do not remember the exact English error message, but it was a common network error). Checking the logs showed Permission denied. I even noticed two VSCode entries in the Local Network permission list that could be enabled or disabled independently. Just now, my Swift app failed in a similar way. I verified that the server was running and listening because websocat could successfully connect to the local server. The app uses Starscream, and client.connect() was executed but the connection could not be established. Checking log stream --predicate 'process == "name"' --level debug showed: 2026-08-08 14:48:38.620396 ... nw_endpoint_handler_path_change [C1 ... waiting parent-flow (unsatisfied (Local network prohibited), interface: bridge100, ipv4)] However, after successfully applying the workaround described below, I saw the backend server print related output, proving that the server received the app's ping frame. At the same time, the Local Network permission page did not show this app as an entry, and no permission prompt appeared asking me to authorize Local Network access. Therefore, I am no longer certain that this issue is strictly related to Local Network permission. All of the above cases involve third-party components: VSCode Remote SSH, UTM providing a server at 192.168.64.3, and Starscream instead of the WebSocket implementation provided by Foundation. I am not an expert in networking, so I cannot completely rule out issues caused by third-party software. However, I found that running the following commands in macOS Recovery Mode: #!/bin/bash cd "/Volumes/Data/Library/Preferences/" rm -f com.apple.networkextension.plist rm -f com.apple.networkextension.uuidcache.plist rm -f com.apple.networkextension.control.plist rm -f com.apple.networkextension.necp.plist and then rebooting can resolve the situation where one specific app suddenly cannot access the local network while other apps continue to work normally. Running tccutil reset All com.bundle.id did not solve the problem. This command was suggested by Claude Sonnet 5. I am not even sure whether Local Network permission is managed by TCC, but I am including this information because the five commands above appear to modify NetworkExtension-related files rather than the TCC database. This issue cannot currently be reproduced reliably. I do not know when it will happen. After it occurs, I have not found a normal-system-environment solution. The only workaround I have found is booting into Recovery Mode and clearing the local network authorization-related files.
1
0
647
1w
Possible change in sysctlbyname() / oldlenp behavior on iOS and iPadOS 27
I am investigating an issue involving sysctlbyname("hw.machine", ...) that became observable after moving to iOS/iPadOS 27. The affected legacy code is essentially the following: void getPlatform(unsigned char machine[]) { size_t size; sysctlbyname("hw.machine", machine, &size, NULL, 0); for (int i = 0; i < size; i++) { if (machine[i] == ',') { machine[i] = '.'; } } } The caller provides a zero-initialized fixed-size buffer: unsigned char machine[20] = {0}; getPlatform(machine); I understand that this implementation is incorrect because size is not initialized. When oldp is non-NULL, oldlenp must provide the available size of the buffer. A correct implementation would therefore initialize it, for example: void getPlatform(unsigned char *machine, size_t capacity) { size_t size = capacity; if (sysctlbyname("hw.machine", machine, &size, NULL, 0) != 0) return; for (size_t i = 0; i < size; i++) { if (machine[i] == ',') machine[i] = '.'; } } with: unsigned char machine[20] = {0}; getPlatform(machine, sizeof(machine)); The question is not whether the original implementation is valid. It clearly relies on an uninitialized value and should be corrected. What I am trying to understand is why the issue became observable specifically on iOS/iPadOS 27, and whether there has been any related implementation or documentation change. Using LLDB, I inspected the arguments at the entry to: sysctlbyname("hw.machine", machine, &size, NULL, 0); Because size is uninitialized, the value referenced by oldlenp varies depending on the contents of the stack location. For example, I observed a call where: *oldlenp = 0 The call then returned: return = -1 errno = 12 (ENOMEM) and the output buffer remained empty. In another execution, the same uninitialized stack location happened to contain a very large value. In that case sysctlbyname() succeeded and returned the expected hardware identifier: iPhone18,2 Adding unrelated code such as printf() can also change whether the original implementation succeeds, which is consistent with the uninitialized value being affected by changes in stack/register layout. There is also a second issue I would like clarification on regarding the documented behavior of oldlenp. The current documentation states that when the amount of data is greater than the value supplied through oldlenp, the function updates it to the required size and returns ENOMEM. It also states: The function doesn’t modify the value if it’s larger than or equal to the amount of available data. However, this does not match what I observed at runtime. For example, in one successful call I observed: Before sysctlbyname(): *oldlenp = 4301365248 The value was clearly much larger than required. After the call returned successfully: return = 0 machine = "iPhone18,2" *oldlenp = actual returned data length In other words, oldlenp was modified on a successful call even though the input value was already much larger than the amount of data being returned. I would appreciate clarification on the following: Was there any implementation change to sysctlbyname(), sysctl(), or the handling of oldlenp in iOS/iPadOS 27? Have there been changes in compiler/runtime behavior on iOS/iPadOS 27 that could make this type of existing uninitialized-variable bug surface more consistently? Is the documented statement that oldlenp is not modified when the supplied value is sufficiently large still accurate for sysctlbyname() on current iOS versions? Has the documentation or intended contract for oldlenp changed recently? Have other developers observed ENOMEM from existing sysctlbyname() code after updating to iOS/iPadOS 27? Again, I understand that the original code is incorrect and should initialize oldlenp before calling sysctlbyname(). The part I am trying to clarify is whether iOS/iPadOS 27 introduced any behavioral change that exposed this latent bug, and whether the currently documented successful-call behavior of oldlenp matches the actual implementation.
2
0
249
1w
iOS 27 Beta 3: iBeacon region monitoring sometimes never exits or enters
After upgrading to iOS 27 Beta 3, iBeacon region monitoring no longer behaves as it did on previous iOS versions. Issue 1 – Never exits region After connecting to an iBeacon, I power off the beacon and move several kilometers away. The app never receives an Outside (didExitRegion) event. Even after force quitting the app, powering off the beacon, locking the screen, and turning the screen back on, iOS may relaunch the app as if it were still inside the beacon region. Is this an intentional change in iOS 27 or a bug? Issue 2 – Sometimes never enters region Occasionally, the app is not awakened when entering the iBeacon region. No Inside event is delivered. The only way to recover is to manually scan and reconnect to the beacon. Otherwise, the app is never awakened by the iBeacon again. This worked reliably on iOS versions before iOS 27.
5
1
1.2k
1w
Return journey from containing app back to original host
Question 1 (Return journey from containing app back to original host): Is there an alternative, supported method for a custom keyboard extension to launch its containing app such that when that containing app is later suspended/resigned, the system returns the user to the original host app (e.g., Notes) instead of the Home screen? Does iOS 26 provide any handoff/return APIs for the keyboard voice‑input scenario? Question 2 (Full‑access‑off persistence and settings navigation): (a) Is the shared app group container expected to be effectively read‑only (with EPERM) when Full Access is off? If so, is there any supported way to persist keyboard settings (that require writing to shared files) without Full Access? (b) What is the supported method for a keyboard extension to direct the user to Settings to enable Full Access on iOS 26, given that openURL via responder chain and extensionContext.open both fail? We are seeking a reliable, non‑private API approach.
1
0
221
1w
PDFKit leaks a Vision document-analysis pipeline per rendered PDFDocument on iPadOS 26 – and `PDFView` already has the switch to stop it
On iPadOS 26, PDFKit runs VNRecognizeDocumentsRequest over the pages of a PDFDocument when those pages are rendered. The analysis pipelines are never released. Measured on an iPad Pro 12.9-inch 4th gen (iPad8,11), iPadOS 26.6, with a 61-page image-only scanned score: each newly-created-and-rendered PDFDocument costs about 2.7 OS threads and 20 MB, permanently. Repeatedly loading the same file from disk reached 153 threads and 1519 MB in under seven minutes, then died of an allocation failure. Nothing releases it: not replacing PDFView.document, not deallocating the PDFView entirely, not releasing the PDFDocument, and not time. With every code path in the app stopped, the thread count does not fall — it continues to rise. The stack -[PDFView visiblePagesChanged:] → +[PDFPageAnalyzerV2 analyzePage:withBox:requestTypes:] → -[VNImageRequestHandler performRequests:gatheredForensics:error:] → -[VNRecognizeDocumentsRequest internalPerformRevision:inContext:error:] → -[VNDetector processUsingQualityOfServiceClass:options:regionOfInterest:…] → -[VNControlledCapacityTasksQueue dispatchSyncByPreservingQueueCapacity:] Thread census at 1519 MB — 153 threads total, after 66 document loads: 66 PDFKit.PDFDocument.formFillingQueue 64 com.apple.VNRecognizeDocumentsRequestRevision1 10 ANEServicesThread 66 orphaned pipelines for 66 loads, all blocked on Vision's capacity limiter. The console also emits Invalid permutation index when reordering subregions. Index N must be less than number of subregions 1 continuously, with N increasing — and these keep arriving after all application activity has stopped. Isolation Each row is a separate run on the same device and OS, one variable changed. Counts are OS threads; baseline is 13. Configuration Result Page-stepping only on a stable document (~1000 visiblePagesChanged: events) No growth; footprint declines Recreating PDFThumbnailView on every load No growth Creating a PDFDocument and never rendering it No growth Creating + rendering, assigned to a PDFView +2.0 to +2.7 threads / +20 MB per load Creating + rendering, never assigned to any PDFView Same growth Creating + rendering, entire PDFView destroyed and rebuilt per load Same growth Two points worth drawing out: The leak occurs with no PDFView involved at all — plain PDFPage.thumbnail(of:for:) or PDFPage.draw(with:to:) on a freshly created document is sufficient. Destroying the PDFView releases nothing. Whatever retains the analyses outlives every object the application can reach. Also, for anyone who arrives here from the other PDFPageAnalyzerV2 threads: the usePageViewController(true, withViewOptions: nil) workaround does not help this. It reduces visiblePagesChanged: frequency, and page changes on a stable document leak nothing. The variable is newly rendered documents, not new pages. The switch already exists PDFView implements -setDocumentAnalysisEnabled: and -isDocumentAnalysisEnabled, plus -handleAnalysisCompletionOfPage:resultTypes:. None of these appear in any public header. With document analysis disabled, the leak disappears completely — 28 consecutive document loads with zero thread growth, and after stopping, the process released down to 6 threads and 64 MB, below its own idle baseline. It also suppresses the leak for documents never assigned to that PDFView, so whatever the flag gates is not scoped to a single view. For completeness, the per-page -setCandidateForOCR: / -setDidPerformOCR: accessors do not help: the writes land and read back correctly, and the analysis runs anyway. They appear to be state rather than policy. Request Either: Fix the leak — cancel and release analyses when the document or the view goes away; or Make documentAnalysisEnabled public on PDFView (or add an equivalent on PDFDocument). Ideally, please do both. The second costs Apple nothing: the property exists, it works, and it is exactly the control that is needed. Applications that render sheet music, engineering drawings, or any other content where document understanding provides no value are currently paying for it with unbounded memory growth and no supported way to decline. Filed as FB24211659. Happy to share the isolation harness with anyone from the PDFKit team. Related: 825803 (crash in PDFPageAnalyzerV2, FB22409977), 827781 (deadlock in the same class), 838272 / 837282 (PDFTileSurface over-release), 107007 (CGContextDrawPDFPage thread safety, open since 2018).
Replies
0
Boosts
0
Views
170
Activity
1w
iOS26.4,appStoreReceiptURL获取票据延迟
iOS 26.4系统上,我们发现三个问题: 1.调用了finishTransaction接口,但是在App重新启动后,[SKPaymentQueue defaultQueue].transactions仍然会有这笔订单。 2.支付完成后,[[NSBundle mainBundle] appStoreReceiptURL]],拿到的票据解析出来里面的商品是空的,需要延迟2秒钟左右在调用[[NSBundle mainBundle] appStoreReceiptURL]]才能获取有效票据。 3.支付完成后,如果用户没有点击最后弹出的确认弹框,等待5秒钟,系统会自己回调 - (void)paymentQueue:(SKPaymentQueue *)queue updatedTransactions:(NSArray<SKPaymentTransaction *> *)transactions; 代理方法。正常应该是用户点击了最后弹出的确认弹框,在回调- (void)paymentQueue:(SKPaymentQueue *)queue updatedTransactions:(NSArray<SKPaymentTransaction *> *)transactions;方法。 我们在苹果开发者论坛上面找到其他开发者反馈的类似问题,链接如下: https://developer.apple.com/forums/thread/817700 https://developer.apple.com/forums/thread/792437?answerId=849557022#849557022 https://developer.apple.com/forums/thread/817834 https://developer.apple.com/forums/thread/817706 https://developer.apple.com/forums/thread/818586 我们有大量用户升级到了26.4系统,这对于我们造成了巨大的困扰,我们需要你们的帮助,感谢!
Replies
8
Boosts
1
Views
1.5k
Activity
1w
Does setting "activityType" make sense?
I'm wondering if setting the correct activityType after initializing CLLocationManager will make the location results more accurate. locationManager = CLLocationManager() locationManager.distanceFilter = 20 locationManager.activityType = .fitness
Replies
2
Boosts
0
Views
538
Activity
1w
CarPlay CPListItem.accessoryImage display incorrectly on IOS 27 beta 4
I'm testing iOS 27 and face this issue that the accessoryImage on the CPListItem is no longer shown properly. It works fine up until iOS 26.5 but on 27 it is way to small. Check attached screen shot for details. Also filed FB23903072, hope this gets fixed before iOS 27 final arrives. 🤞
Replies
3
Boosts
0
Views
503
Activity
1w
Prevent multiple DNS Proxy Filter when switching users
Hello Team, We have a System Extension with Provider Type "DNS Proxy". We have embedded the System Extension in GUI target which registered as LaunchAgent. We found NEDNSProxyManager saves the proxy configuration in the caller's preferences. Due to that we see a prompt for Network Extension when switching users. On allowing that we see multiple DNS filter in the System Settings->Network->Filters even though one DNS Filter can enabled which is annoying. Question 1: Is this expected for non MDM users? Are the users expected to authorise Network extension when switching users. Question 2: Is there a way to prevent the multiple DNS filter for both MDM and non MDM users? To prevent multiple filters, we identified a solution to embed the System Extension in our LaunchDaemon target. So the proxy configuration will be save in the root preference. But with this approach we ended up with an error [OSSystemExtensionErrorDomain error 13] during OSSystemExtensionRequest.deactivationRequest. Question 3: Is there a way to avoid OSSystemExtensionErrorDomain 13 when deactivating System extension from our LaunchDaemon process? Question 4: What is the best practice in terms of embedding and deploying DNS Proxy System Extension for managed and non managed environment. Also if user expected to see multiple DNS filter. I suggest to show the filter that saved for that user's preference. Thank you.
Replies
1
Boosts
0
Views
518
Activity
1w
URL Filters not activating on iOS 27 beta
(Also submitted as FB23072541) iOS 27 beta 1 brings a brand new error which ends up resulting in a state of .serverSetupIncomplete: <NEPIRChecker: 0x7de6c79b60>: -[NEPIRChecker start:responseQueue:completionHandler:]_block_invoke - PIR status returned error <Error Domain=com.apple.CipherML Code=1100 "Unable to query status due to errors: Error details were logged and redacted." UserInfo={NSLocalizedDescription=Unable to query status due to errors: Error details were logged and redacted., NSUnderlyingError=0x7de712f4e0 {Error Domain=com.apple.CipherML Code=1800 "Error details were logged and redacted." UserInfo={NSLocalizedDescription=Error details were logged and redacted.}}}> <NEAgentURLFilterExtension: 0x7de6d24e60>: -[NEAgentURLFilterExtension startURLFilter]_block_invoke - Failed to startFilter <Error Domain=NEMembershipCheckerErrorDomain Code=3 "(null)"> What’s a NEMembershipChecker? Member of what? Digging deeper I found these: Failed to prefetch tokens for group 'site.kaylees.Wipr2': Error Domain=NSURLErrorDomain Code=-1009 "The Internet connection appears to be offline." UserInfo={_NSURLErrorNWPathKey=satisfied (Path is satisfied), interface: en0[802.11], ipv4, dns, uses wifi, LQM: good, NSErrorFailingURLKey=https://pirissuer.kaylees.site/token-key-for-user-token, NSUnderlyingError=0x7517125a40 {Error Domain=NSPOSIXErrorDomain Code=50 "Network is down" UserInfo={NSDescription=Network is down}}, _NSURLErrorPrivacyProxyFailureKey=true, NSLocalizedDescription=The Internet connection appears to be offline.} queryStatus(for:options:) threw an error: Error Domain=NSURLErrorDomain Code=-1009 "The Internet connection appears to be offline." UserInfo={_NSURLErrorNWPathKey=satisfied (Path is satisfied), interface: en0[802.11], ipv4, dns, uses wifi, LQM: good, NSErrorFailingURLKey=https://pirissuer.kaylees.site/token-key-for-user-token, NSUnderlyingError=0x7517125b00 {Error Domain=NSPOSIXErrorDomain Code=50 "Network is down" UserInfo={NSDescription=Network is down}}, _NSURLErrorPrivacyProxyFailureKey=true, NSLocalizedDescription=The Internet connection appears to be offline.} The connection and the URL mentioned are fine of course, but "Network is down” now? This new problem only affects the App Store version of my app – not present if I install from Xcode. Users report that oddly, having an active VPN on the device works around this bug.
Replies
10
Boosts
3
Views
987
Activity
1w
Monterey:Network System Extension OSSystemExtensionRequest.deactivationRequest fails with authorizationRequired = 13
Hello, On Mac OS monterey, OSSystemExtensionRequest.deactivationRequest is failing with deactivation request for com.xxxxxx.networkextensionapp.netextension failed authorization check, error: Error Domain=OSSystemExtensionErrorDomain Code=13 "(null)" Even after providing the correct credentials for authorisation when prompted for.
Replies
4
Boosts
0
Views
1.9k
Activity
1w
Kernel Sandbox/System Policy intermittently denies ALL file access (not just mount syscall) on NFS mounts
I'm seeing a recurring issue on macOS 26.5.2 (build 25F84) where the kernel's Sandbox/System Policy layer intermittently denies file access on NFS mount points from local network servers. Posting here in case anyone recognizes this pattern or has a workaround, and flagging it since I've also filed a Feedback Assistant report (with a live-captured sysdiagnose) for the same issue. WHAT HAPPENS Two independent NFS mounts to two separate, unrelated servers on my LAN start failing simultaneously with "Operation not permitted." The kernel log shows: kernel: (Sandbox) System Policy: mount_nfs(PID) deny(1) file-mount /path/to/mount Critically, it's not limited to the mount syscall - within the same few-second window, System Policy also denies ls, perl, diskutil, and even umount -f on the exact same path, for otherwise unrelated processes. So it looks like a transient, path-scoped kernel decision rather than something specific to NFS or the mount syscall. It self-heals anywhere from seconds to ~30 minutes later, then recurs - documented 30-80+ occurrences/day via a background watchdog script. WHAT I'VE RULED OUT Server-side cause: two independent servers on different hardware fail identically at the same instant. Network issue: checked network logs in the same window, no correlated connectivity event. Third-party kext conflict: kextstat shows zero third-party kexts loaded. syspolicyd database corruption: no "ASP: Validation category" signature present. TCC/Full Disk Access: already granted; the denying layer is kernel Sandbox "System Policy," not TCC. QUESTION Has anyone else run into System Policy denying file-mount/file-read-data/file-unmount on network volume paths intermittently like this? Is there any userland way to inspect or reset whatever internal state drives this decision (I haven't found one - no spctl/tccutil/sysctl lever that touches it)? Happy to share more log excerpts if useful.
Replies
18
Boosts
0
Views
1.2k
Activity
1w
didRegisterForRemoteNotificationsWithDeviceToken never fires after Individual→Organization account conversion — no token, no error, app‑wide
Summary: After converting our Apple Developer account from Individual → Organization, our app stopped receiving APNs device tokens. application(:didRegisterForRemoteNotificationsWithDeviceToken:) is never called, and application(:didFailToRegisterForRemoteNotificationsWithError:) is also never called — no token, no error. This affects all new device‑token registrations app‑wide; device tokens issued before the conversion still work and continue to deliver pushes. Environment Membership status: Active Device: iPhone 15 Pro, iOS [26.6] Reproduced on both development (sandbox) builds installed via Xcode/CLI and TestFlight builds. What works Existing device tokens (created before ~Aug 1) still deliver pushes normally (server reports delivered 1/1 via our .p8 token‑based auth). So the send path and APNs auth key are fine. UNUserNotificationCenter authorization succeeds — authorizationStatus == .authorized. UIApplication.shared.isRegisteredForRemoteNotifications == true. What doesn't work We call UIApplication.shared.registerForRemoteNotifications() on the main thread after authorization is granted, but neither delegate callback ever fires — no token, no error — on any new install/launch. Timeline / trigger Everything worked before the Individual→Organization conversion. Since the conversion, no new APNs device token has been issued for the app at all. Server‑side we can confirm the most recent device token was created 2026‑08‑01, and none since, despite many fresh installs/launches across multiple users. Pre‑conversion tokens still function. What we've already tried / ruled out App ID has Push Notifications capability enabled; regenerated provisioning profiles. Generated a new APNs Auth Key (.p8) (sends already work, so this was expected not to matter). Fixed the Xcode signing team (it briefly showed "Unknown Name (TEAMID)" right after conversion; resolved by signing into the correct org account — Team now resolves correctly). Device reboot, network settings reset, app delete/reinstall, latest iOS. Confirmed delegate is wired (@UIApplicationDelegateAdaptor) — the same code issued tokens fine before the conversion. Thanks in advance!
Replies
0
Boosts
0
Views
171
Activity
1w
TabBar icons not displayed
Working on a CarPlay app (Driving App) and despite setting tab bar icons, they don’t display in either the simulator or two physical devices (one no older than 2024 and with a very large screen), I only see the textual description/name of the tab. Am I missing something ?
Replies
1
Boosts
0
Views
132
Activity
1w
ShareLink with Collaboration in SwiftUI with a Document based app
Hello to anyone reading this. I am a bit lost as to what is the correct approach for enabling Collaboration for a Document based SwiftUI app. If I understand correctly, after setting up all the relevant entitlements and capabilities for enabling sharing, you only need to use ShareLink to begin a collaboration/send a copy by passing in the URL of the document. The collaboration is then handled with SWCollaborationView, which there have been NSViewRepresentable wrapper implementations posted around the web. My main question is; how do I know whether the document has been shared to create a collaboration? Do I have to have 2 sharing ToolbarItems? Basically, is there any documentation for implementing collaborations from a document based app, other than simply saying that starting a share is done by passing the url into a ShareLink? This seems to massively missing, or have I massively missed something?
Replies
0
Boosts
0
Views
162
Activity
1w
Does the Channel Sounding have regional restrictions by country?
I'm trying to get the new Bluetooth Channel Sounding distance measurement working between an iPhone 17 running iOS 27 Beta4 and a Nordic nRF54L15DK board. I enabled bonding in the latest ipt_reflector sample from Nordic. Someone get the sample working with iOS 27 beta1. I paired the board with AccessorySetupKit. I suspect that the Channel Sounding feature is subject to regional restrictions by country (China). Here's the code to check if CS is available on my iPhone func centralManagerDidUpdateState(_ central: CBCentralManager) { switch central.state { case .poweredOn: print("central update") if CBCentralManager.supports(.channelSounding) { print("Supports channel sounding - YES") } else { print("Supports channel sounding - NO") } if let id = pendingPeripheralIdentifier, let name = pendingPeripheralName { pendingPeripheralIdentifier = nil pendingPeripheralName = nil retrieveAndConnect(identifier: id, name: name) } case .poweredOff: connectionState = .bluetoothOff case .unauthorized: connectionState = .error("Bluetooth not authorized — check Settings") case .unsupported: connectionState = .error("BLE not supported on this device") default: break } } The console log shows [ASK] Session activated — accessories: 1 central update Supports channel sounding - NO [CS] startChannelSounding skipped — channelSounding not supported Please also check the topic. it's very similar.
Replies
1
Boosts
0
Views
549
Activity
1w
Can a Mac App Store app use an Apple Events temporary exception for Notes?
Hi all, I’m building a sandboxed macOS app that, among other things, lets the user create and associate an Apple Note with a calendar meeting. The user explicitly initiates the action. The app uses AppleScript to create the note, obtain its identifier, and open it in Notes. Notes only declares the com.apple.Notes.openlocation scripting access group. Note creation is not covered, so com.apple.security.scripting-targets does not appear sufficient. The working implementation requires: com.apple.security.automation.apple-events com.apple.security.temporary-exception.apple-events for com.apple.Notes NSAppleEventsUsageDescription Has anyone successfully shipped a Mac App Store app using this temporary exception to control the built-in Notes app? Is this potentially acceptable with a clear entitlement explanation and Feedback Assistant report, or should I assume that note creation through AppleScript cannot be included in a Mac App Store build? Is there another supported API that can create an Apple Note and return an identifier or openable URL for it?
Replies
3
Boosts
0
Views
312
Activity
1w
Push notifications not received despite HTTP 200 from APNs — seeking help to identify the cause
We're experiencing an issue where push notifications are not being received on certain iOS devices, and we'd like help identifying the possible causes. What we've confirmed so far: Push notifications are sent from our own provider server to APNs. APNs returns a normal response (HTTP/2 200) The device tokens are valid and up to date. Affected users have confirmed that notifications are enabled for our app in Settings. Users report no network connectivity issues. We are sending with apns-priority: 10 and apns-push-type: alert. Scope: This is occurring for multiple users, not isolated to a single device. It happens intermittently — some notifications from the same campaign reach the device, while others don't. Critically, some affected users report that they only fail to receive notifications from our app during certain specific time windows, while notifications from other apps arrive normally during the same period. This suggests the issue is app-specific and time-correlated, rather than a device-wide or network-level problem. Questions we'd like help with: Given that APNs returns 200, are there known scenarios where the notification still doesn't reach the device? (e.g., Focus / Do Not Disturb, low power mode, high-frequency throttling, stored-then-discarded due to apns-expiration) Is there a recommended way to obtain per-notification delivery status in the production environment? Are there known limits on how many notifications can be sent to the same device within a short window before APNs starts throttling or coalescing them? Our server logs currently do not retain the apns-id returned by APNs. If we provide the affected device tokens along with the approximate send timestamps, would it be possible for Apple to help investigate the delivery status of those notifications on the APNs side? Any guidance or pointers to relevant documentation would be greatly appreciated. Thank you!
Replies
5
Boosts
0
Views
500
Activity
1w
Apple Silicon prevents execution of wine for Windows ARM64 binaries due to JIT/W^X restrictions and x18 register reservation
I am porting Wine to macOS to run Windows on ARM (WOA) binaries. Windows PE files place .text and .data in the same page, which macOS’s JIT/W^X model cannot handle. pthread_jit_write_protect_np() cannot be used for foreign ARM64 code. Apple Silicon reserves x18, breaking the Windows ARM64 ABI. Wine also must reserve 0x7FFE0000 for the Windows TEB, but macOS cannot guarantee this address. These issues make it impossible for Wine to load or execute WOA binaries. I am requesting mechanisms to safely execute foreign ARM64 code, support mixed W/X pages, emulate x18, and reserve the Windows TEB region. Branch is here: https://github.com/trcrsired/wine/tree/apple-silicon-mac-woa
Replies
1
Boosts
0
Views
186
Activity
1w
Local Network permission randomly breaks connectivity, only fixable via Recovery Mode
I am currently using macOS 27 beta 4, but this issue also existed on macOS 26.5 before I updated to macOS 27. I am not sure whether earlier system versions had the same problem, as I had never encountered a similar issue before. I am developing through the local network, including using VSCode Remote SSH to connect to a local server, and using a Swift app to establish a WebSocket connection with the local server. Recently, I have encountered multiple cases where the local server connection suddenly failed. Checking the logs showed messages such as Permission denied or similar errors. AI assistants explained that this usually means the target app does not have Local Network permission enabled in Privacy & Security settings. However, I checked the settings page and confirmed that the target apps already have Local Network permission enabled. Previously, when VSCode Remote SSH failed, I observed the following behavior: after updating VSCode, if the local server was not running, VSCode Remote SSH immediately reported that the target server could not be found. After starting the local server, it immediately reported that there was no route to the host (I do not remember the exact English error message, but it was a common network error). Checking the logs showed Permission denied. I even noticed two VSCode entries in the Local Network permission list that could be enabled or disabled independently. Just now, my Swift app failed in a similar way. I verified that the server was running and listening because websocat could successfully connect to the local server. The app uses Starscream, and client.connect() was executed but the connection could not be established. Checking log stream --predicate 'process == "name"' --level debug showed: 2026-08-08 14:48:38.620396 ... nw_endpoint_handler_path_change [C1 ... waiting parent-flow (unsatisfied (Local network prohibited), interface: bridge100, ipv4)] However, after successfully applying the workaround described below, I saw the backend server print related output, proving that the server received the app's ping frame. At the same time, the Local Network permission page did not show this app as an entry, and no permission prompt appeared asking me to authorize Local Network access. Therefore, I am no longer certain that this issue is strictly related to Local Network permission. All of the above cases involve third-party components: VSCode Remote SSH, UTM providing a server at 192.168.64.3, and Starscream instead of the WebSocket implementation provided by Foundation. I am not an expert in networking, so I cannot completely rule out issues caused by third-party software. However, I found that running the following commands in macOS Recovery Mode: #!/bin/bash cd "/Volumes/Data/Library/Preferences/" rm -f com.apple.networkextension.plist rm -f com.apple.networkextension.uuidcache.plist rm -f com.apple.networkextension.control.plist rm -f com.apple.networkextension.necp.plist and then rebooting can resolve the situation where one specific app suddenly cannot access the local network while other apps continue to work normally. Running tccutil reset All com.bundle.id did not solve the problem. This command was suggested by Claude Sonnet 5. I am not even sure whether Local Network permission is managed by TCC, but I am including this information because the five commands above appear to modify NetworkExtension-related files rather than the TCC database. This issue cannot currently be reproduced reliably. I do not know when it will happen. After it occurs, I have not found a normal-system-environment solution. The only workaround I have found is booting into Recovery Mode and clearing the local network authorization-related files.
Replies
1
Boosts
0
Views
647
Activity
1w
Possible change in sysctlbyname() / oldlenp behavior on iOS and iPadOS 27
I am investigating an issue involving sysctlbyname("hw.machine", ...) that became observable after moving to iOS/iPadOS 27. The affected legacy code is essentially the following: void getPlatform(unsigned char machine[]) { size_t size; sysctlbyname("hw.machine", machine, &size, NULL, 0); for (int i = 0; i < size; i++) { if (machine[i] == ',') { machine[i] = '.'; } } } The caller provides a zero-initialized fixed-size buffer: unsigned char machine[20] = {0}; getPlatform(machine); I understand that this implementation is incorrect because size is not initialized. When oldp is non-NULL, oldlenp must provide the available size of the buffer. A correct implementation would therefore initialize it, for example: void getPlatform(unsigned char *machine, size_t capacity) { size_t size = capacity; if (sysctlbyname("hw.machine", machine, &size, NULL, 0) != 0) return; for (size_t i = 0; i < size; i++) { if (machine[i] == ',') machine[i] = '.'; } } with: unsigned char machine[20] = {0}; getPlatform(machine, sizeof(machine)); The question is not whether the original implementation is valid. It clearly relies on an uninitialized value and should be corrected. What I am trying to understand is why the issue became observable specifically on iOS/iPadOS 27, and whether there has been any related implementation or documentation change. Using LLDB, I inspected the arguments at the entry to: sysctlbyname("hw.machine", machine, &size, NULL, 0); Because size is uninitialized, the value referenced by oldlenp varies depending on the contents of the stack location. For example, I observed a call where: *oldlenp = 0 The call then returned: return = -1 errno = 12 (ENOMEM) and the output buffer remained empty. In another execution, the same uninitialized stack location happened to contain a very large value. In that case sysctlbyname() succeeded and returned the expected hardware identifier: iPhone18,2 Adding unrelated code such as printf() can also change whether the original implementation succeeds, which is consistent with the uninitialized value being affected by changes in stack/register layout. There is also a second issue I would like clarification on regarding the documented behavior of oldlenp. The current documentation states that when the amount of data is greater than the value supplied through oldlenp, the function updates it to the required size and returns ENOMEM. It also states: The function doesn’t modify the value if it’s larger than or equal to the amount of available data. However, this does not match what I observed at runtime. For example, in one successful call I observed: Before sysctlbyname(): *oldlenp = 4301365248 The value was clearly much larger than required. After the call returned successfully: return = 0 machine = "iPhone18,2" *oldlenp = actual returned data length In other words, oldlenp was modified on a successful call even though the input value was already much larger than the amount of data being returned. I would appreciate clarification on the following: Was there any implementation change to sysctlbyname(), sysctl(), or the handling of oldlenp in iOS/iPadOS 27? Have there been changes in compiler/runtime behavior on iOS/iPadOS 27 that could make this type of existing uninitialized-variable bug surface more consistently? Is the documented statement that oldlenp is not modified when the supplied value is sufficiently large still accurate for sysctlbyname() on current iOS versions? Has the documentation or intended contract for oldlenp changed recently? Have other developers observed ENOMEM from existing sysctlbyname() code after updating to iOS/iPadOS 27? Again, I understand that the original code is incorrect and should initialize oldlenp before calling sysctlbyname(). The part I am trying to clarify is whether iOS/iPadOS 27 introduced any behavioral change that exposed this latent bug, and whether the currently documented successful-call behavior of oldlenp matches the actual implementation.
Replies
2
Boosts
0
Views
249
Activity
1w
iOS 27 Beta 3: iBeacon region monitoring sometimes never exits or enters
After upgrading to iOS 27 Beta 3, iBeacon region monitoring no longer behaves as it did on previous iOS versions. Issue 1 – Never exits region After connecting to an iBeacon, I power off the beacon and move several kilometers away. The app never receives an Outside (didExitRegion) event. Even after force quitting the app, powering off the beacon, locking the screen, and turning the screen back on, iOS may relaunch the app as if it were still inside the beacon region. Is this an intentional change in iOS 27 or a bug? Issue 2 – Sometimes never enters region Occasionally, the app is not awakened when entering the iBeacon region. No Inside event is delivered. The only way to recover is to manually scan and reconnect to the beacon. Otherwise, the app is never awakened by the iBeacon again. This worked reliably on iOS versions before iOS 27.
Replies
5
Boosts
1
Views
1.2k
Activity
1w
Return journey from containing app back to original host
Question 1 (Return journey from containing app back to original host): Is there an alternative, supported method for a custom keyboard extension to launch its containing app such that when that containing app is later suspended/resigned, the system returns the user to the original host app (e.g., Notes) instead of the Home screen? Does iOS 26 provide any handoff/return APIs for the keyboard voice‑input scenario? Question 2 (Full‑access‑off persistence and settings navigation): (a) Is the shared app group container expected to be effectively read‑only (with EPERM) when Full Access is off? If so, is there any supported way to persist keyboard settings (that require writing to shared files) without Full Access? (b) What is the supported method for a keyboard extension to direct the user to Settings to enable Full Access on iOS 26, given that openURL via responder chain and extensionContext.open both fail? We are seeking a reliable, non‑private API approach.
Replies
1
Boosts
0
Views
221
Activity
1w
I didn't receive any push notifications from apns on my iPhone
What I found during the development: The Apple phone has registered the device token and it is within the validity period, but it cannot receive the apns message. However, only after I re-registered the device token with this token could this iPhone receive apns push notifications normally... What's going on here? How can it be optimized?
Replies
1
Boosts
0
Views
332
Activity
1w