iOS is the operating system for iPhone.

Posts under iOS tag

200 Posts

Post

Replies

Boosts

Views

Activity

Ajuda com identificação de usuário Apple nome email e Firebase
E aí pessoal, tudo certo? Estou desenvolvendo um app com React Native no front-end e Node.js no back-end, usando o Firebase como banco de dados (e possivelmente para autenticação também, dependendo da solução). Preciso implementar o "Sign in with Apple" e estou com algumas dúvidas em como integrar tudo isso. A ideia é: o usuário clica no botão "Entrar com a Apple" no app (React Native), o backend (Node.js) processa a autenticação com a Apple e, em seguida, armazena as informações necessárias (nome, email, etc.) no Firebase. Se alguém já trabalhou com essa combinação (React Native, Node.js, Firebase e Sign in with Apple) e puder compartilhar alguma experiência, dicas, exemplos de código ou até mesmo um boilerplate, seria de grande ajuda!
0
0
373
Jan ’25
How to implement server-side authentication for text filtering requests??
If an app has a text filtering extension and associated server that the iPhone OS communicates with, then how can that communication be authenticated? In other words, how can the server verify that the request is valid and coming from the iPhone and not from some spoofer? If somebody reverse engineers the associated domain urls our of the app's info.plist or entitlement files and calls the server url directly, then how can the server detect this has occurred and the request is not coming from the iPhone OS of a handset on which the app is installed?
16
1
710
Jan ’25
App being launched while device is locked
DESCRIPTION OF PROBLEM Logs and data from our application indicate various errors that strongly suggest that our application is being launched in a state in which the device is likely locked. We are looking for guidance on how to identify, debug, reproduce, and fix these cases. Our application does not use any of the common mechanisms for background activity, such as Background App Refresh, Navigation, Audio, etc. Errors we get in our logs such as "authorization denied (code: 23)" when trying to access a file in our app's container on disk (a simple disk cache for data our application uses) strongly suggest that the device is operating in a state, such as being locked, where our application lacks the requisite permissions it would normally have during operation. Furthermore, attempts to access authentication information stored in the keychain also fails. We use kSecAttrAccessibleWhenUnlocked when accessing items we store in the keychain. We have investigated "Prewarming", as well as our notification extension that helps process incoming push notifications, but cannot find any way to recreate this behavior. Are there any steps Apple engineers can recommend to triage and debug this? Some additional questions that would help us: What are all of the symptoms that we can look for if prewarming escapes the intended execution context? What are all of the circumstances in which we would be unauthorized to access the app’s documents/file directories even if it works correctly in normal operation? STEPS TO REPRODUCE Unfortunately, we are unable to forcibly reproduce this behavior in our application, so we're looking for guidance on how we might simulate this behavior in Xcode / Instruments. Are there tools that Apple provides that would allow us to simulate certain behaviors like prewarming to verify our application's functionality? Are there other reasons our application might be launched while the device is locked? Are there other reasons we would receive security errors when accessing the keychain or disk that are unrelated to the device being locked?
1
1
516
Jan ’25
iOS devices in CI get lost
Hello. We have a few iOS devices connected to CI macs. We test our 3D engine, so we really need hardware devices for that. The issue is that Xcode loses connection to the devices once in a while, mostly after mac reboot, which requires a human to enter test room and unplug and plug cable again. Even if device is visible and accessible in Finder, Xcode may still don't see it, and devicectl shows it as disconnected. Are there any hacks to make connection stable? The best what we could achieve so far was to remove iOS device screen lock - otherwise mac reboot would in 100% cases require human interaction to reconnect the device. Both iOS and mac are logged into the same Apple ID. Mac is logged in automatically after reboot iOS devices have no screen lock Thank you.
0
0
165
Jan ’25
Unknown CHHapticError.Code (561015905 == '!pla')
Hello, I'm sporadically getting the unknown CoreHaptics error described in the title, when trying to create a CHHapticPatternPlayer from an .ahap file — this does not occur in a repeatable manner, unfortunately... This occurs in a SpriteKit game, running on both iOS 17 and 18. Anyone know what the error means, since it's apparently undocumented? Note that the haptics engine is started right before creating the pattern, and the start request doesn't appear to fail... Thanks, D.
2
0
472
Jan ’25
Message Filter Extension and multiple servers
In the documentation for a Message Filter Extension it states: If you have servers that can help your app extension determine how to handle a message, you must add the Associated Domains capability to your Xcode project and specify those domains. (https://developer.apple.com/documentation/sms_and_call_reporting/sms_and_mms_message_filtering/creating_a_message_filter_app_extension) The words servers and domains are in the plural. If it's possible to specify multiple servers/domains for a Message Filter Extension then how is that done? There's no documentation nor reference for that. If multiple domains can be added to the info.plist then what is the iOS behavior in that case? Can the extension supply/change which domain is used at run time?
0
0
425
Jan ’25
Adopt UIFindInteraction across multiple views
We are currently trying to adopt the newly introduced find bar in our app. The app: The app is a text editor with a main text view. However it includes nested views (for text like footnotes) that are presented as modal sheets. So you tap on the footnote within the main text, a form sheet is presented with the contents of the footnote ready to be edited. We have an existing search implementation, but are eager to move to the system-provided UI. Connecting the find bar through a custom UIFindSession with our existing implementation is working without any issues. The Problem: Searching for text does not only work in the main text view, but also nested text (like footnotes). Let's say I have a text containing the word "iPhone" both in the main text and the footnote. In our existing implementation, stepping from the search match to the next one would open the modal and highlight the match in the nested text. The keyboard would stay open. With the new UIFindInteraction this is not working however. As soon as a modal form sheet is presented, the find interaction closes. By looking at the stack trace I can see a private class called UIInputWindowController that cleans up input accessory views after the modal gets presented. I believe it is causing the find panel to give up its first responder state. I noticed that opening popovers appears to be working fine. Is there a way to alter the presentation of the nested text so that the view is either not modal or able to preserve the current find session? Or is this unsupported behavior and we should try and look for a different way? The thing that really confuses me is that this appears to work without issue in Notes.app. There the find bar is implemented as well. There are multiple views that can be presented while the find bar is open. Move Note is one of them. The view appears as a modal sheet. It keeps the find bar open and active, though its tint color matches the deactivated one of the main Notes view. The find bar is still functional with the text field being active and the overlay updating in the background. This behavior appears to be a bug in the Notes app, but is exactly what we want for our use case. I attached some images: Two are from the Notes app, two from a test project demonstrating the problem. Opening a modal view closes the find bar there.
2
0
1.3k
Jan ’25
Beta update 18.3 on IOS
Beta Update Feedback: iOS 18.3 The iOS 18.3 beta update has been a deeply frustrating experience due to numerous critical issues that severely impact the device's functionality. Below is a detailed report of the problems encountered: All major social applications, including WhatsApp, Instagram, and Photos, consistently crash. When launching these apps, the screen often turns dark before reverting to the home screen. This issue persists across other third-party and native apps, making the device unusable for basic tasks. The system frequently hangs, failing to process basic operations effectively. Restarting the device is often the only temporary solution; however, even after multiple restarts, the issues remain unresolved. Significant charging drops are observed, and the device intermittently fails to recognize the charger. Charging efficiency has drastically decreased, creating inconvenience for daily usage. The Photos app is riddled with bugs, making it nearly impossible to use. Basic functions such as viewing, editing, or sharing photos do not work properly. Every aspect of the update feels unstable, with issues cropping up in every corner of the system. The phone’s functionality has deteriorated, so it no longer performs as expected. Device Affected: iPhone 13 Impact Level: Severe This update has caused immense frustration and has made the iPhone 13 difficult.
2
1
2.2k
Jan ’25
How to handle a non-consumable in app purchase when SKPaymentQueue is deprecated
I use the code below for a non-consumable in-app purchase in my apps. Has anybody worked out how to handle this without using any of the deprecated items? SKPaymentQueue - deprecated, SKPayment - deprecated, SKProduct - deprecated, transactionState - deprecated, SKPaymentTransaction - deprecated, finishTransaction - deprecated func paymentQueue(_ queue: SKPaymentQueue, shouldAddStorePayment payment: SKPayment, for product: SKProduct) -> Bool { true } func paymentQueue(_ queue: SKPaymentQueue, updatedTransactions transactions: [SKPaymentTransaction]) { for transaction in transactions { switch transaction.transactionState { case .purchasing: break case .purchased: SKPaymentQueue.default().finishTransaction(transaction) // Hide the restore button navigationItem.setRightBarButton(nil, animated: true) // Set the ProVerion in the Db to true IAPHandler.setProVersionToPurchased() // Also hide the Purchase button UIView.animate(withDuration: 1.0, animations: { [weak self] in self?.purchaseBtn_Outlet.alpha = 0 }) { [weak self] (success) in if self!.theDevice.isOneOf(K.Device_Groups.SE_3_iPhone8) { self?.segControlTop_Constraint.constant = 10 } else if self!.theDevice.isPhone { self?.segControlTop_Constraint.constant = 30 } } case .failed: if let error = transaction.error { let errorDescription = error.localizedDescription print("Transaction failed due to error: \(errorDescription)") } case .restored: SKPaymentQueue.default().finishTransaction(transaction) // Hide the restore button navigationItem.setRightBarButton(nil, animated: true) // Set the ProVerion in the Db to true IAPHandler.setProVersionToPurchased() // Also hide the Purchase button UIView.animate(withDuration: 1.0, animations: { [weak self] in self?.purchaseBtn_Outlet.alpha = 0 }) { [weak self] (success) in if self!.theDevice.isOneOf(K.Device_Groups.SE_3_iPhone8) { self?.segControlTop_Constraint.constant = 10 } else if self!.theDevice.isPhone { self?.segControlTop_Constraint.constant = 30 } } case .deferred: break @unknown default: if let error = transaction.error { let errorDescription = error.localizedDescription print("Transaction failed due to error: \(errorDescription)") } break } } } // Sets the purchase to true in the Db class IAPHandler: NSObject { //Get the ProVersion Status static func isProVersionPurchased() -> Bool { let VC_String = "IAPHandler" var theStatus = false do { let settings = try Database.shared.databaseConnection!.read { db in try My_Settings.fetchOne(db) } let theStatusText = settings?.ProVersion ?? "false" theStatus = theStatusText == "true" ? true : false } catch { print("Getting the ProVersion Status failed! \(VC_String) \(error)") } return theStatus } // Set ProVersion to true. static func setProVersionToPurchased() { let VC_String = "IAPHandler" do { try Database.shared.databaseConnection!.write { db in try db.execute(sql: "UPDATE My_Settings SET ProVersion = :proVersion WHERE Settings_ID = :id", arguments: ["proVersion": "true", "id": 1]) } } catch { print("Update set pro version, failed! \(VC_String)s \(error)") } } }// End of class
1
0
335
Jan ’25
iOS 18.1 crash UIHostingView.layoutSubviews() / swift_unknownObjectWeakAssign / objc_storeWeak
We're seeing sporadic crashes on devices running iOS 18.1 - both beta and release builds (22B83). The stack trace is always identical, a snippet of it below. As you can tell from the trace, it's happening in places we embed SwiftUI into UIKit via UIHostingController. Anyone else seeing this? 4 libobjc.A.dylib 0xbe2c _objc_fatalv(unsigned long long, unsigned long long, char const*, char*) + 30 5 libobjc.A.dylib 0xb040 weak_register_no_lock + 396 6 libobjc.A.dylib 0xac50 objc_storeWeak + 472 7 libswiftCore.dylib 0x43ac34 swift_unknownObjectWeakAssign + 24 8 SwiftUI 0xeb74c8 _UIHostingView.base.getter + 160 9 SwiftUI 0x92124 _UIHostingView.layoutSubviews() + 112 10 SwiftUI 0x47860 @objc _UIHostingView.layoutSubviews() + 36
8
1
1.1k
Jan ’25
Create C++ static library with Swift interoperability for iOS. How?
Hello all! My application written with C++ for iOS. Want to make some functionality in static library for the purpose of reuse it in different C++ projects. Want to make universal library for using StoreKit2. Global idea is to wrap StoreKit2 Swift out with CPP interoperability. Now trying to make clear for my self how to create C++ static library with Swift interoperability for iOS in XCode. There are only Objective-C option when you creating static library in XCode for iOS. Is it correct: Create Static Library with Objective-C in XCode Remove all default Objective-C files Add C++ files Add C++/Swift interoperability in build settings Add swift classes Beside all of it some questions: When C++ static library contain Swift code with interoperability will it require some special settings for project (Swift standard lib or some other settings)? Or it could be used like any other C++ libraries? What is the optimal build settings in this case to reduce dependencies when using it different projects? Is there any examples of the same approach for iOS development?
0
0
362
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
257
Jan ’25
Camera's settings at calibration time
Hi everyone, I am wondering under which settings the camera(s) were set by the time they were calibrated. For instance, one aspect that is easy to find is the reference resolution of the images taken when calibrating the intrinsics, this is by retrieving intrinsicMatrixReferenceDimensions. Making sure that the principal point is referenced to the by the time resolution used when the calibration was ongoing. However, recently I saw that there are focusing modes that potentially displace the lens' physical position. Settings like: AutoFocusRangeRestriction: none, near, far setFocusModeLocked: Locks the lens position at the specified value, and sets the focus mode to a locked state. My concern lies the impact this focusing lens displacements have on the intrinsic matrix parameters, if the lens is displaced, these parameters no longer describe the camera since the lens position has changed w.r.t. the lensPosition set when they were calibrated [0-1]. If my understanding is correct the AutoFocusRangeRestriction is just a range freedom the system is allowed to auto-focus and not a specific lens position. Conversely, the setFocusModeLocked does indeed fix the lensPosition to a certain value [0 - 1]. In simple words, what is the focus lensPosition the cameras were set when calibrating them for intrnisics?
0
0
427
Jan ’25
Does your app provide end-to-end encryption?
One of the questions Apple ask regarding iOS apps is "Does your app provide end-to-end encryption?" But without defining exactly what they mean by end-to-end encryption specifically. Isn't HTTPS basically etee? Therefore any app that contacts a server using https provides end-to-end encryption? Or does the question mean something additional above and beyond https?
9
0
539
Jan ’25
"Contact Us to Continue"
Hey, Everyone. I am new to Apple Developer and want to enroll in the program to publish my app in the AppStore. I logged into my personal Apple account on the developer app and tried to enroll but I got the error message: "There may be an issue with your account that needs to be resolved before you can continue. Please contact support." I click on the contact support button and I explain the situation. The developer support team gets back to me telling me that I need to turn on "twofactor authentication" I've had this on the entire time, but I check settings and remove it and turn it back on. After this I tried enrolling again but got the same error message. I've contacted support again explaining the situation but I've not gotten a response yet. My question is, Has anyone else encountered this problem? and if so, How did you solve it? Thanks in advance, Lars A
2
0
623
Jan ’25
WhatsApp not showing in Apple Carplay in iOS 18.X
I bought a new iPhone 16 recently and connected with my car (Hyundai Venue) I couldn't able to see WhatsApp. I researched and found some forum, but the suggested steps are not workable or not suitable for latest iOS version. I have updated iOS and WhatsApp, nothing helped to resolve. Note: Earlier I was used Pixel phone I can able to see Whatsapp and I can make a call
2
0
482
Jan ’25
Live Caller ID Lookup Extension - No option in phone settings
iOS 18 (22A3354) will not offer a option in settings (> Apps > Phone) after calling openSettings to enable live caller id lookup extension. iPhone and MacBook are in the same network. The PIRService runs on MacBook and is reachable via iPhone Safari (via http://MacBookPro:8080/). Hummingbird print log: hb_method=GET hb_uri=/ [Hummingbird] Request. After deploying the application via Xcode to the iPhone no requests are printed in the terminal. The extension was added like documented and bundle id is also checked multiple times. issuerRequestUri in service-config.json is http://MacBookPro:8080/issue. As far as I can tell, everything has been set up in accordance with the Testing Live Caller ID instructions. Is there something missing?
9
0
1.3k
Jan ’25
Crash:Exceeded system-wide per-process Port Limit
Hi everyone, I’m encountering a crash in my app and need help understanding what’s causing it and how to resolve it. As stated in the crash report, the issue is caused by exceeding the system-wide per-process port limit. Can you tell me how to locate and identify why this is happening? Below are the full report of the crash log: crash.log Summary of Crash: ------------------------------------- Translated Report (Full Report Below) ------------------------------------- Incident Identifier: B509FF2B-C8D8-4E9F-B664-E24464CFD5F8 CrashReporter Key: b390cfe931a83efde49bd8b523023a275b55ef64 Hardware Model: iPhone14,2 Process: MyApp [22515] Path: /private/var/containers/Bundle/Application/F73212A7-4CB9-485A-A8B7-8114F4E9A9AB/MyApp.app/MyApp Identifier: com.beeasy.app.id.enterprise Version: 3.41.38-ID-MySDKMemory-12261114 (3.41.38-ID-MySDKMemory-12261114) Code Type: ARM-64 (Native) Role: Foreground Parent Process: launchd [1] Coalition: com.beeasy.app.id.enterprise [515] Date/Time: 2024-12-29 01:29:48.3023 +0800 Launch Time: 2024-12-26 16:38:36.7895 +0800 OS Version: iPhone OS 16.6.1 (20G81) Release Type: User Baseband Version: 2.80.01 Report Version: 104 Exception Type: EXC_RESOURCE (SIGKILL) Exception Codes: 0x000000000001c1d6, 0x0000000000000000 Termination Reason: PORT_SPACE 14123288431433990614 (Limit 115158 ports) Exceeded system-wide per-process Port Limit Triggered by Thread: 64 Thread 64 name: AURemoteIO::IOThread Thread 64 Crashed: 0 libsystem_kernel.dylib 0x20ce5eca4 mach_msg2_trap + 8 1 libsystem_kernel.dylib 0x20ce71b74 mach_msg2_internal + 80 2 libsystem_kernel.dylib 0x20ce71e4c mach_msg_overwrite + 540 3 libsystem_kernel.dylib 0x20ce5f1e8 mach_msg + 24 4 libEmbeddedSystemAUs.dylib 0x238bb2148 void* caulk::thread_proxy<std::__1::tuple<caulk::thread::attributes, AURemoteIO::IOThread::IOThread(AURemoteIO&, caulk::thread::attributes const&, caulk::mach::os_workgroup_managed const&)::'lambda'(), std::__1::tuple<>>>(void*) + 556 5 libsystem_pthread.dylib 0x22dcda6b8 _pthread_start + 148 6 libsystem_pthread.dylib 0x22dcd9b88 thread_start + 8
3
0
605
Jan ’25