Frameworks

RSS for tag

Ask questions about APIs that can drive features in your apps.

Posts under Frameworks tag

200 Posts
Sort by:

Post

Replies

Boosts

Views

Activity

Privacy manifest in a non-embedded xcframework?
Hello all, My team makes a third-party SDK in the form of an xcframework, and we're working on creating our privacy manifest. However, I've noticed that the privacy manifest we include in the xcframework does not seem to get aggregated in with the base app's manifest when generating the privacy report. Is that even the expected behavior? That when generating a privacy report, it will aggregate the manifests from the app and all frameworks? We've always recommended to our clients to select "Do not embed" when adding our SDK, as embedding it seems to introduce problems when submitting to the app store. Are the problems in the aggregation due to the fact that it's not embedded? If it turns out that our manifest won't get aggregated with the client's app's manifest, what should we do? Should we recommend that they manually include any items from our manifest into theirs? I'd appreciate any information, I haven't been able to find any solid details on any of this.
1
3
1.3k
Dec ’23
Security Framework Evaluate ED25519 certificates
Hello, is it possible to evaluate a certificate chain using one of the Bernstein curves ED25519/ED448 with the Security framework? Using X.509 version 3 and own private CA for testing. Signature Algorithm: ED448; Public Key Algorithm: ED25519 The following setting/API is used: SecPolicyCreateBasicX509, SecTrustSetAnchorCertificatesOnly, SecTrustEvaluateWithError There are some requirements only for RSA keys regarding the key size since iOS 13: https://support.apple.com/en-us/103769 "RSA key sizes smaller than 2048 bits are no longer trusted for TLS" And here are some information about TLS: https://support.apple.com/en-gb/guide/security/sec100a75d12/web "minimum 2048-bit RSA key or 256-bit elliptic curve key" Findings: The OpenSSL (v3.1.4) certificate verification was successful. The evaluation is working fine in the iOS Simulator (iOS 15) and Playground. But on real devices (e.g. iPhone/iOS 17) it is failing with the following error: Error Domain=NSOSStatusErrorDomain Code=-67735 "“...” certificate is using a broken key size" UserInfo={NSLocalizedDescription=“...” certificate is using a broken key size, NSUnderlyingError=0x281115920 {Error Domain=NSOSStatusErrorDomain Code=-67735 "Certificate 0 “...” has errors: Certificate is using a broken key size, Unable to build chain to root (possible missing intermediate);" UserInfo={NSLocalizedDescription=Certificate 0 “...”} Also SecCertificateCopyKey is returning NULL. According to the documentation it may not support the algorithm: https://developer.apple.com/documentation/security/2963103-seccertificatecopykey Could you please elaborate the error, point to some documentation and explain why it behaves differently on a real device? Thank you in advance!
0
0
445
Nov ’23
Unknown type name 'sec_protocol_options_t'
I have 7 applications with the same structure, however in one of them I suddenly got this error that I cannot solve why. The error appears to be related to Network Framework. The other 6 applications do not present this problem. /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS17.0.sdk/System/Library/Frameworks/Network.framework/Headers/quic_options.h:97:21 Unknown type name 'sec_protocol_options_t'; did you mean 'nw_protocol_options_t'? /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS17.0.sdk/System/Library/Frameworks/Network.framework/Headers/tls_options.h:72:21 Unknown type name 'sec_protocol_options_t'; did you mean 'nw_protocol_options_t'?
1
0
403
Nov ’23
Library Framework WebPrivacy missing MacOS Ventura
Not developer related but I can't find any help with google and trying to send a crash report to apple just causes spinning beachball. So hoping i can find some much needed help in this forum. Safari runs very slow and every time it launches i get an error producing the log below. Any fix suggestions please. Seeing a WebPrivacy library missing leaves me with no confidence using my mac. I had hoped a software update to Ventura 13.6.3 would resolve but no. Path: /Volumes/VOLUME/*/WebPrivacy.framework/Versions/A/XPCServices/com.apple.WebPrivacy.Service.xpc/Contents/MacOS/com.apple.WebPrivacy.Service Identifier: com.apple.WebPrivacy.Service Version: 34 (34.1.1) Build Info: WebPrivacy-34000000000000~249 (617C13) Code Type: X86-64 (Native) Parent Process: launchd [1] Responsible: Safari [5749] User ID: 501 Date/Time: 2023-11-15 09:15:24.5072 +0000 OS Version: macOS 13.6.3 (22G423) Report Version: 12 Anonymous UUID: EC45AED0-4F92-87DE-6EE8-AE74E4A4BD5E Sleep/Wake UUID: 65B3C137-4BC0-476B-9975-503694B76241 Time Awake Since Boot: 150000 seconds Time Since Wake: 88111 seconds System Integrity Protection: enabled Crashed Thread: 0 Exception Type: EXC_CRASH (SIGABRT) Exception Codes: 0x0000000000000000, 0x0000000000000000 Termination Reason: Namespace DYLD, Code 1 Library missing Library not loaded: /System/Library/PrivateFrameworks/WebPrivacy.framework/Versions/A/WebPrivacy Referenced from: <BF03A141-E3B8-3EC8-B0D3-79F9E987841B> /Volumes/VOLUME/*/WebPrivacy.framework/Versions/A/XPCServices/com.apple.WebPrivacy.Service.xpc/Contents/MacOS/com.apple.WebPrivacy.Service Reason: tried: '/System/Library/PrivateFrameworks/WebPrivacy.framework/Versions/A/WebPrivacy' (no such file), '/System/Volumes/Preboot/Cryptexes/Incoming/OS/System/Library/PrivateFrameworks/WebPrivacy.framework/Versions/A/WebPrivacy' (no such file), '/System/Library/PrivateFrameworks/WebPrivacy.framework/Versions/A/WebPrivacy' (no such file, not in dyld cache), '/System/Library/Frameworks/WebPrivacy.framework/Versions/A/WebPrivacy' (no such file, not in dyld cache) (terminated at launch; ignore backtrace) Thread 0 Crashed: 0 dyld 0x7ff812633c52 __abort_with_payload + 10 1 dyld 0x7ff81264dfd7 abort_with_payload_wrapper_internal + 82 2 dyld 0x7ff81264e009 abort_with_payload + 9 3 dyld 0x7ff8125d28f0 dyld4::halt(char const*) + 375 4 dyld 0x7ff8125cfb71 dyld4::prepare(dyld4::APIs&, dyld3::MachOAnalyzer const*) + 4526 5 dyld 0x7ff8125ce3bd start + 1805 Thread 0 crashed with X86 Thread State (64-bit): rax: 0x0000000002000209 rbx: 0x0000000000000000 rcx: 0x00007ff7b8f8a3c8 rdx: 0x00007ff7b8f8a830 rdi: 0x0000000000000006 rsi: 0x0000000000000001 rbp: 0x00007ff7b8f8a410 rsp: 0x00007ff7b8f8a3c8 r8: 0x00007ff7b8f8a430 r9: 0x0000000000000000 r10: 0x0000000000000127 r11: 0x0000000000000246 r12: 0x0000000000000127 r13: 0x00007ff7b8f8a830 r14: 0x0000000000000001 r15: 0x0000000000000006 rip: 0x00007ff812633c52 rfl: 0x0000000000000246 cr2: 0x0000000000000000 Logical CPU: 0 Error Code: 0x02000209 Trap Number: 133 Binary Images: 0x106f74000 - 0x106f8bfff com.apple.WebPrivacy.Service (34) <bf03a141-e3b8-3ec8-b0d3-79f9e987841b> /Volumes/VOLUME/*/WebPrivacy.framework/Versions/A/XPCServices/com.apple.WebPrivacy.Service.xpc/Contents/MacOS/com.apple.WebPrivacy.Service 0x7ff8125c8000 - 0x7ff8126605ef dyld (*) <d963b325-2b69-3e5a-ab79-8ce1662ec8cc> /usr/lib/dyld External Modification Summary: Calls made by other processes targeting this process: task_for_pid: 0 thread_create: 0 thread_set_state: 0 Calls made by this process: task_for_pid: 0 thread_create: 0 thread_set_state: 0 Calls made by all processes on this machine: task_for_pid: 153 thread_create: 0 thread_set_state: 5851 VM Region Summary: ReadOnly portion of Libraries: Total=171.8M resident=0K(0%) swapped_out_or_unallocated=171.8M(100%) Writable regions: Total=8452K written=0K(0%) resident=0K(0%) swapped_out=0K(0%) unallocated=8452K(100%)
0
0
677
Nov ’23
Clarify on APIs of Calculating Total Revenue and Accurate via APIs
Hi Apple team, We'd like to clarify some questions below for our Data team in ELSA Corp. Source of Currency Exchange Rates: We noticed that Apple has been utilizing a rolling average for the past month to calculate currency exchange rates. Could you please inform us about the specific source used for obtaining these exchange rates? Calculating Total Revenue via APIs: In the documentation, it is mentioned that "proceeds" represent the amount derived after deducting taxes and fees from the customer price. In theory, the sum of proceeds should equate to the total revenue for the month as per the definitions provided. However, when we examined this, even in the case of the US (where there are no currency exchange rate issues), we observed disparities between the figures displayed in the dashboard and those obtained through the APIs. Availability of Accurate APIs: Are there any APIs within Apple's platform that can provide data matching the numbers found in the AppStore Dashboard and reports, specifically concerning downloads and revenues? Thanks, Vinh
1
0
261
Nov ’23
ASAuthorizationController passkeys not working when applinks contain wildcard domains
Hey, I'm looking for some help with ASAuthorizationController and passkeys. It seems that wildcards in applinks used for subdomains break passkeys for the main domain. The app has the following entries in entitlements (where mydomain.com is a placeholder for the actual domain): webcredentials: mydomain.com applinks: mydomain.com applinks: *.mydomain.com The AASA file is hosted only at mydomain.com and contains a correctly formatted webcredentials entry: { "webcredentials": { "apps": [ "app-id-corretly-formatted" ] }, "applinks": { "apps": [], "details": [ // ... ] } } When I use ASAuthorizationController with the domain mydomain.com, it reports the following error: Error Domain=com.apple.AuthenticationServices.AuthorizationError Code=1004 "Application with identifier X is not associated with domain mydomain.com" UserInfo={NSLocalizedFailureReason=Application with identifier X is not associated with domain mydomain.com If I remove the following line from the entitlements applinks: *.mydomain.com, it works as expected: webcredentials: mydomain.com applinks: mydomain.com It appears that the problem is with the wildcard in the subdomains. Has someone experienced this issue?
1
0
510
Nov ’23
ASAuthorizationController fails with error 1004 when wildcard for applinks is used
Hey, I'm looking for some help with ASAuthorizationController and passkeys. It seems that wildcards in applinks for subdomains break passkeys for the main domain. The app has the following entries in entitlements: webcredentials: mydomain.com applinks: mydomain.com applinks: *.mydomain.com mydomain.com is a placeholder for the actual domain The AASA file is hosted only at mydomain.com and contains a correctly formatted "webcredentials" entry. { "webcredentials": { "apps": [ "app-id-corretly-formatted" ] }, "applinks": { "apps": [], "details": [ // ... ] } } When I use ASAuthorizationController with the domain mydomain.com, it reports the following error: Error Domain=com.apple.AuthenticationServices.AuthorizationError Code=1004 "Application with identifier X is not associated with domain mydomain.com" UserInfo={NSLocalizedFailureReason=Application with identifier X is not associated with domain mydomain.com If I remove the following line from the entitlements "applinks: *.mydomain.com", it works as expected: webcredentials: mydomain.com applinks: mydomain.com It appears that the problem is with the wildcard in the subdomains. Has someone experienced this issue?
3
1
1.2k
Nov ’23
GameCenter crash starting iOS 16.4.1
Hello, Our game has been released since 2020, and we recently started seeing a crash starting with iOS 16.4.1. We're having trouble reproducing it, it only seems to happen on brand new devices with GameCenter accounts that have not run our game before, it seems to me the first time the game tries to make a save. We just got our hands on a pair of new devices and still cannot reproduce the crash. My knowledge of Obj-C is exactly zero, so it's difficult for me to know what's really going on here. I've attached the crash log and a screenshot of what I believe is the file and line pointed to in the crash. From what little I can tell, it might just be that the function on line 58 is missing an extra argument as with the one on line 63, is it possible it's that easy? Is it possible that's something that's changed starting with 16.4.1? Any help is appreciated! 2023-10-31_10-13-06.1263_+0100-c51744f526ed25211ba33f86d78d738167b94ce2.crash
0
0
643
Oct ’23
Using POCO library for C++
Somebody uses POCO library(https://pocoproject.org/) under MACOS? Ive try to build my app in CLion using CMAKE but there is an error: ====================[ Clean | Debug ]=========================================== /Applications/CLion.app/Contents/bin/cmake/mac/bin/cmake --build /Users/michaelikus/CLionProjects/training/poco01 --target clean -- -j 8 Clean finished ====================[ Build | all | Debug ]===================================== /Applications/CLion.app/Contents/bin/cmake/mac/bin/cmake --build /Users/michaelikus/CLionProjects/training/poco01 --target all -- -j 8 [ 50%] Building CXX object CMakeFiles/poco01.dir/poco01.cpp.o [100%] Linking CXX executable poco01 ld: Undefined symbols: Poco::Data::SQLite::Connector::registerConnector(), referenced from: _main in poco01.cpp.o clang: error: linker command failed with exit code 1 (use -v to see invocation) make[2]: *** [poco01] Error 1 make[1]: *** [CMakeFiles/poco01.dir/all] Error 2 make: *** [all] Error 2
1
0
711
Oct ’23
Crashes in requestSendPTPCommand(_:outData:completion:) of ImageCaptureCore framework
Hi there :) We're in our way to make an app to can communicate with DSLR camera by using ImageCaptureCore framework for PTP communication with the camera. In our app, we're sending some PTP commands to the camera by using requestSendPTPCommand(_:outData:completion:). This is our snipped-code to execute a PTP command. public extension ICCameraDevice { func sendCommand(command: Command) async { do { print("sendCommand ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++") print("sendCommand \(command.tag()) : sendCommand Started") let result = try await self.requestSendPTPCommand(command.encodeCommand().commandBuffer, outData: nil) let (data, response) = result print("sendCommand \(command.tag()) : sendCommand Finished") print("sendCommand data: \(data.bytes.count)") print("sendCommand response: \(response.bytes.count)") if !response.bytes.isEmpty { command.decodeResponse(responseData: response) } print("sendCommand \(command.tag()) : sendCommand Finished with response code \(command.responseCode)") print("sendCommand ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++") if command.responseCode != .ok { isRunning = false errorResponseCode = command.responseCode.rawValue print("response error with code = \(command.responseCode)") return } let copiedData = data.deepCopy() command.decodeData(data: copiedData) } catch { isRunning = false print("Error Send Command with error: \(error.localizedDescription)") } } } The function sendCommand(command: Command) async is called in a while-loop in async-await way. So that it needs to wait a sent command to finish before executing another command. The looping keeps running since the device connected to the camera. The result is, the process is running by no problem at all for several minutes, It can get camera's setting, device info, even its images. But then the problems occurred. The amount of time is random, some time it takes only 15 minutes, some time it takes 1 hour. There are 2 problems recorded in our case: 1. The requestSendPTPCommand(_:outData:completion:) result returning empty data without throwing any error, because the error never be caught in catch block. This is my printed result: sendCommand +++++++++++++++++++++++++++++++++++++ sendCommand GetObjectHandlesCommand : sendCommand Started sendCommand GetObjectHandlesCommand : sendCommand Finished sendCommand data: 0 sendCommand response: 0 sendCommand GetObjectHandlesCommand : sendCommand Finished with response code undefined sendCommand +++++++++++++++++++++++++++++++++++++ 2. It crashes with the last message in my logger: sendCommand +++++++++++++++++++++++++++++++++++++ sendCommand GetObjectHandlesCommand : sendCommand Started 2023-10-27 10:44:37.186768+0700 PTPHelper_Example[76486:11538353] [PTPHelper_Example] remoteCamera ! Canon EOS 200D - Error Domain=NSCocoaErrorDomain Code=4097 “connection to service with pid 76493 created from an endpoint” UserInfo={NSDebugDescription=connection to service with pid 76493 created from an endpoint} 2023-10-27 10:44:37.187146+0700 PTPHelper_Example[76486:11538353] [PTPHelper_Example] failureBlock ! Canon EOS 200D - Failure block was called due to a connection failure. For crashed issue, I've tried to attach in this post. But it always failed with messaged An error occured while uploading this log. Please try again later.. So that, I uploaded it in my google drive with url: https://drive.google.com/file/d/1IvJohGwp1zSkncTWHc3430weGntciB3K/view?usp=sharing Reproduced on iOS 16.3.1. I've checked the stack traces of the other threads but nothing suspicious got my attention. But it might relate to this issue https://developer.apple.com/forums/thread/104576. But I can't ensure. Any good idea of how to address these crashes shown above? Thank you!
3
0
527
Oct ’23
How to make framework and spm work together on Xcode15?
My project uses frameworkes and spm(swift package manager), and it works well on Xcode14. But on Xcode15, build for iPhone Simulator, framework is not supported. If I want to use the framework, I must add arm64 to Exclude Architecture, but this setting will cause spm to not supported. Even the new project has same problem which uses framework and spm on Xcod15? How to make framework and spm work together on Xcode15?
0
0
411
Oct ’23
How Xcode15 build a project with framework?
I create a new project, and drag the Google WebRTC.framework in it, "Embed and Sign". But there is a error occurring when the project build. Building for iOS Simulator, but linking in dylib built for iOS, file '/Users/***/Desktop/WrtcDemo/WrtcDemo/WebRTC.framework/WebRTC' for architecture arm64 And I add the Run Script on the Build Phases # Type a script or drag a script file from your workspace to insert its path. APP_PATH="${TARGET_BUILD_DIR}/${WRAPPER_NAME}" echo "$APP_PATH" find "$APP_PATH" -name 'WebRTC.framework' -type d | while read -r FRAMEWORK do FRAMEWORK_EXECUTABLE_NAME=$(defaults read "$FRAMEWORK/Info.plist" CFBundleExecutable) FRAMEWORK_EXECUTABLE_PATH="$FRAMEWORK/$FRAMEWORK_EXECUTABLE_NAME" echo "Executable is $FRAMEWORK_EXECUTABLE_PATH" EXTRACTED_ARCHS=() for ARCH in $ARCHS do echo "Extracting $ARCH from $FRAMEWORK_EXECUTABLE_NAME" lipo -extract "$ARCH" "$FRAMEWORK_EXECUTABLE_PATH" -o "$FRAMEWORK_EXECUTABLE_PATH-$ARCH" EXTRACTED_ARCHS+=("$FRAMEWORK_EXECUTABLE_PATH-$ARCH") done echo "Merging extracted architectures: ${ARCHS}" lipo -o "$FRAMEWORK_EXECUTABLE_PATH-merged" -create "${EXTRACTED_ARCHS[@]}" rm "${EXTRACTED_ARCHS[@]}" echo "Replacing original executable with thinned version" rm "$FRAMEWORK_EXECUTABLE_PATH" mv "$FRAMEWORK_EXECUTABLE_PATH-merged" "$FRAMEWORK_EXECUTABLE_PATH" done The script is worked, but the error is still alive. How I solved it? The same project can be run on Xcode14, but no be build on Xcode15.
0
0
433
Oct ’23
The signature of "My Library" cannot be found
I'm creating macos frameworks and ios xcframeworks using xcode 13.1 In my python script I do the following: codesign --sign "My Company" "full path to my framework" codesign -dv --verbose=4 "full path to my framework" This results in something like the following: Executable=/Info.plist Identifier= Format=bundle CodeDirectory v=20100 size=194 flags=0x0(none) hashes=1+3 location=embedded Hash type=sha256 size=32 CandidateCDHash sha1=e8178a1c065d50b0c056ac1d28a00b32f5233cfa CandidateCDHashFull sha1=e8178a1c065d50b0c056ac1d28a00b32f5233cfa CandidateCDHash sha256=a09d875a205267dbae768f5432c2eb6971d79a33 CandidateCDHashFull sha256=a09d875a205267dbae768f5432c2eb6971d79a33744005c715fe2388c9e91a5c Hash choices=sha1,sha256 CMSDigest=3aa96ec9a8a5d6b761fa80050907acd77cfd23019c338d6e7e6bbb89de08daf5 CMSDigestType=2 Page size=none CDHash=a09d875a205267dbae768f5432c2eb6971d79a33 Signature size=6940 Authority= Authority=Sectigo Public Code Signing CA R36 Authority=Sectigo Public Code Signing Root R46 Authority=AAA Certificate Services Signed Time=Oct 19, 2023 at 9:40:08 PM Info.plist entries=3 TeamIdentifier=not set Sealed Resources version=2 rules=10 files=5 Internal requirements count=1 size=96 Success: codesign verification succeeded. However, when trying to use this framework in Xcode 15, we are getting the error: "The signature of "My Library" cannot be found"
0
0
313
Oct ’23
How to obtain Swift interface files of all the iOS system Frameworks?
I hope to get all the swift interface files of all the iOS system Frameworks like what I get in Xcode @available(iOS 4.0, *) open class AVAsset : NSObject, NSCopying, AVAsynchronousKeyValueLoading { /** @method assetWithURL: @abstract Returns an instance of AVAsset for inspection of a media resource. @param URL An instance of NSURL that references a media resource. @result An instance of AVAsset. @discussion Returns a newly allocated instance of a subclass of AVAsset initialized with the specified URL. */ public convenience init(url URL: URL) /* Indicates the duration of the asset. If @"providesPreciseDurationAndTiming" is NO, a best-available estimate of the duration is returned. The degree of precision preferred for timing-related properties can be set at initialization time for assets initialized with URLs. See AVURLAssetPreferPreciseDurationAndTimingKey for AVURLAsset below. */ @available(iOS, introduced: 4.0, deprecated: 16.0, message: "Use load(.duration) instead") open var duration: CMTime { get } /* indicates the natural rate at which the asset is to be played; often but not always 1.0 */ @available(iOS, introduced: 4.0, deprecated: 16.0, message: "Use load(.preferredRate) instead") open var preferredRate: Float { get } /* indicates the preferred volume at which the audible media of an asset is to be played; often but not always 1.0 */ @available(iOS, introduced: 4.0, deprecated: 16.0, message: "Use load(.preferredVolume) instead") open var preferredVolume: Float { get } /* indicates the preferred transform to apply to the visual content of the asset for presentation or processing; the value is often but not always the identity transform */ @available(iOS, introduced: 4.0, deprecated: 16.0, message: "Use load(.preferredTransform) instead") open var preferredTransform: CGAffineTransform { get } /** @property minimumTimeOffsetFromLive @abstract Indicates how close to the latest content in a live stream playback can be sustained. @discussion For non-live assets this value is kCMTimeInvalid. */ @available(iOS, introduced: 13.0, deprecated: 16.0, message: "Use load(.minimumTimeOffsetFromLive) instead") open var minimumTimeOffsetFromLive: CMTime { get } }
0
0
240
Oct ’23