Search results for

“codesign”

3,222 results found

Post

Replies

Boosts

Views

Activity

Reply to 自签名证书到期对SDK的影响
The impact of self-signed certificate expiration on the SDK. We have developed an SDK and signed it with a self-signed certificate. Our certificate will expire on January 30, 2025. After it expires, will there be any impact on apps that are already published on the App Store? If a user opens the app on January 31, 2025, will the app crash due to the expired self-signed certificate? Many apps have integrated our SDK, and this issue is very urgent and important for us. We kindly ask for your prompt reply. Thank you! Here are the steps we followed for signing: Self-signing steps: self-signed certificate xcframework Keychain creation: Certificate Assistant - Create Certificate - Self-signed Root Certificate + Code Signing Modify trust settings for the self-signed root certificate Sign the already packaged xcframework (Official command example) codesign --timestamp -v --sign Certificate Name ~/Desktop/MySDK.xcframework
Jan ’25
Reply to Emergency Reset
Detailed Analysis of the Logs These logs provide a snapshot of system activity and processes, including detailed information about framework usage, threading, and potential performance issues. Below is a breakdown of the logs and an analysis of possible tampering or anomalies. General Observations Key Frameworks and Libraries 1. Foundation & CoreFoundation: • Used for fundamental data manipulation and interaction between processes. Commonly seen in most application logs. 2. QuartzCore: • Graphics and animation rendering. Frequent recursive calls suggest heavy graphical processing. 3. libdispatch: • Task and thread queue management. Repeated invocations at specific offsets (+ 16296, + 49444) indicate high inter-thread activity. 4. AccountsDaemon: • Manages user accounts and synchronization. Persistent queries indicate high activity related to account management. 5. CoreData: • Backend database system; multiple recursive calls (+ 523316, + 182512) suggest inefficiencies in database interactions. Recurrent P
Jan ’25
Reply to Cannot load iTunesLibrary on macOS Sequoia 15.1
I found a solution to this problem after losing a full day. Thanks again to Apple for releasing an update that serves no purpose other than making life even harder for us developers. Every time an update is released, I dread installing it because I know very well that many apps will stop working after the update. I had coded two applications that use iTunesLibrary. They worked perfectly before, but now they don't work anymore, throwing the same error: Code=4097 connection to service named com.apple.amp.library.framework. Based on the documentation, I suspected an issue with sandboxing, entitlements, or binary signing ... but no, that wasn’t the root of the problem. After trying to mimic some behaviors of the Music app, like com.apple.amp.artwork.client, com.apple.amp.devices.client, com.apple.amp.library.client, com.apple.security.files.user-selected.read-only ... and experimenting with various options (some documented, some not), I stumbled upon something incredible that gave me the solution: I had moved my
Topic: Media Technologies SubTopic: General Tags:
Jan ’25
自签名证书到期对SDK的影响
我们开发了一款SDK,并用自签名证书对SDK进行了签名,我们的证书会在2025年1月30日到期,到期后对已发布至appstore的app会有影响吗? 用户在2025年1月31日打开app时,会因为自签名证书到期而闪退吗?有不少app集成了我们的SDK,这个问题对我们来说非常紧急和重要,麻烦尽快回复,谢谢! 以下是我们的签名步骤: 自签名步骤:self-signed certificate xcframework 1、钥匙串创建:证书助理-创建证书-自签名根证书+代码签名 2、自行签名根证书修改信任设置 3、对已经打包好的xcframework进行签名 (官方命令示例)codesign --timestamp -v --sign 证书名字 ~/Desktop/MySDK.xcframework
2
0
497
Jan ’25
Reply to The notarized custom PAM module cannot function properly after unlock from screensaver
Sorry it’s taken me a few days to wade in here; I’m only now just catching up with the backlog that built up over the winter break. [quote='772227021, FCG, /thread/772227, /profile/FCG'] Could this issue also be related to a code signing configuration that needs adjustment? [/quote] On your part? No. First, some background. When you call the PAM API, PAM loads plug-ins into your process. This is subject to library validation, as explained here. IMPORTANT The following discusses implementation details that will help you understand what’s going on, but are not considered API. Don’t ship products that rely on this stuff. The exact rules for library validation are different for code that’s built-in to the OS [1]. For third-party code you have to opt in to library validation, either directly, via the library option when signing your code, or indirectly, via the hardened runtime. In contrast, built-in code is always subject to library validation, with an option to opt out. You can see this in action with the author
Jan ’25
Operation not permitted on xpc_listener_create
Hi, I'm trying to create a launch daemon that uses XPC to receive requests from an unprivileged app. Ultimately both components will be written in Go. For now I'm trying to write a PoC in Objective-C to make sure I get everything right, so I'm compiling / signing from the CLI, and writing plist files by hand -- I'm not using XCode. My current daemon code is pretty much the same as the boilerplate code that XCode generates when creating a new 'XPC Service': #import #include int main(int argc, char *argv[]) { xpc_rich_error_t error; dispatch_queue_t queue = dispatch_queue_create(com.foobar.daemon, DISPATCH_QUEUE_SERIAL); xpc_listener_t listener = xpc_listener_create( com.foobar.daemon, queue, XPC_LISTENER_CREATE_NONE, ^(xpc_session_t _Nonnull peer) { xpc_session_set_incoming_message_handler(peer, ^(xpc_object_t _Nonnull message) { int64_t firstNumber = xpc_dictionary_get_int64(message, firstNumber); int64_t secondNumber = xpc_dictionary_get_int64(message, secondNumber); // Create a reply and send it back to t
1
0
622
Jan ’25
Reply to Mass deployment of certificates and marking it as trusted
Hi @szigetics_nt szigetics_nt, Thank you for you commands and i was able to trust the certificate by creating a package with composer and user these commands in this way through post install script. sudo /usr/bin/security authorizationdb write com.apple.trust-settings.admin allow sudo security add-trusted-cert -p codeSign -p pkgSign -d -r trustAsRoot -k /Library/Keychains/System.keychain /private/tmp/Nexthink/SCTASK8557870_Nexthink.cer sudo /usr/bin/security authorizationdb write com.apple.trust-settings.admin admin you can edit the script as per your certificate and requirement. Also, if you can with the command to temporarily disable and re-enable the confirmation dialog for macOS sequoia then it will greatley helpful
Jan ’25
Reply to SwiftData and CloudKit Development vs. Production Database
Everything you described above makes sense, except that a Release build with this same entitlements file doesn't work. I don't know a lot about Direct Distribution. My understanding is that it is the same as Developer ID distribution mentioned in Supported capabilities (macOS). If that's the case, CloudKit should be supported. My guess is that your app probably has something wrong about entitlements, which prevents it from using CloudKit. To confirm that, you can: Try to capture a sysdiagnose and find relevant error messages from there. This topic is covered in Capture and analyze a sysdiagnose. Use the following command line tool to dump the entitlements claimed by your app, and check if there is no difference between the the Release and Debug builds. $ codesign --display --entitlements - Also, if you can detail the steps about how you produced the Release build, I'd see if I can find something relevant. Best, —— Ziqiao Chen  Worldwide Developer Relations.
Jan ’25
UnityCloudBuild: Codesigned with Sandbox enabled, but still get ITMS-90296: App sandbox not enabled
I've made an MacOS app with Unity Cloud Build and I want to sign and distribute it using App Store Connect. I download the compiled .app file and use codesign to sign all the appropriate files. I also use an entitlements file when I sign the runtime binary. I used the command codesign -d --entitlements on the resulting .app file to confirm that com.apple.security.app-sandbox is set to true, which it is. But when I use productbuild to create the .pkg file and upload it using Transporter, I get an e-mail from App Store Connect saying that ITMS-90296: App sandbox not enabled I don't know how to further debug this... Does anyone have any pointers on how to fix this? Note: it has to be doable either via the Unity Editor, Unity Build Cloud or the MacOS CLI... Codesign showing that app-sandbox is enabled: The error from App Store Connect:
0
0
269
Jan ’25
Disappearing External link account entitlement
I've got a Flutter app that is a “reader” app. The External Link Account Entitlement has already been requested and granted. It is already added as an Additional Capability to the App ID. The com.apple.developer.storekit.external-link.account entitlement is already present in the .entitlements file. Also SKExternalLinkAccount key is added to the Info.plist file with the correct URL. ExternalLinkAccount.open() is invoked via a MethodChannel call handler and things work perfectly in debug mode. The modal appears as expected and opens the link in the external browser. Xcode archive is also sucessful and the entitlement seems to be in place when inspecting the app with: codesign -d --entitlements :- ./path/to/app But when trying to distribute the app via Xcode the entitlement disappears. Other entitlements are not affected by this issue, eg.: com.apple.developer.associated-domains for universal links. This happens with automatically managed singing and a manually selected provisioning profile as well. Wh
3
0
839
Jan ’25
Reply to VPN causes developer cert in keychain to become untrusted
I just started running into this a few days ago and I'm not sure why. Same behavior as described above. Everything is working fine, then I need to connect to a VPN for work and when I disconnect from the VPN and try to build the app again and deploy it to the phone, it fails with: Warning: unable to build chain to self-signed root for signer Apple Development: {redacted} (redacted) Command CodeSign failed with a nonzero exit code There is also mention of errSecInternalComponent. If I open keychain on my Mac, I see that my development certificate now says that it's not trusted. And indeed, as julian99 stated, if I change the trust settings to Always Trust, close that window, re-open the certificate again, change the trust settings back to Use System Defaults and then close the window again, it fixes the problem. For added fun, I have to connect and disconnect from the VPN a lot during the work day because the VPN configuration blocks all IPv6 traffic (including link-local traffic) so when I'm connecte
Dec ’24
Command Line Tool doesn't trigger permission prompt for audio recording
Hello, I'm developing a Command Line Tool in XCode, in order to capture system audio and save it to a file, which will then be used by a separate process. Everything works perfectly when running it from either XCode or the native terminal application (see image below), but as soon as I try to run it from any 3rd party application, it doesn't ask for permissions to record sound, and the resultant file ends up soundless. When archiving it and then running it from other 3rd party applications, e.g Warp (terminal) or spawning it as a child process from a bundled Electron application, it doesn't ask for permissions. Things of note: I've codesigned the application with Developer ID Application I've added NSAudioCaptureUsageDescriptionto Info.plist I've included Info.plist in the binary (see image below) I've added the com.apple.security.device.audio-input entitlement I've used the following resources as inspiration: https://github.com/insidegui/AudioCap https://developer.apple.com/documentation/coreaudio/c
2
0
743
Dec ’24
MetalTools.framework Missing/Corrupted
Like I said in the title, it looks like MetalTools.framework is missing or corrupted. I think I saw that the symbolic link was broken. They look like aliases in the finder, but I can't find the original. This was a problem with Ventura (using the last compatible Xcode version) and Sequoia 15.2 (Xcode 16.2). I didn't use Xcode before that. Note that none of my apps need Metal API (I don't think). I only noticed it when Xcode gave an error regarding Metal. Sorry this is so long; I hope the Terminal info will help. I don't want to reinstall Sequoia and this has been a problem since at least Ventura. Recommendations? ls -l /System/Library/PrivateFrameworks/MetalTools.framework/ total 0 lrwxr-xr-x 1 root wheel 27 Dec 7 01:11 MetalTools -> Versions/Current/MetalTools lrwxr-xr-x 1 root wheel 26 Dec 7 01:11 Resources -> Versions/Current/Resources drwxr-xr-x 4 root wheel 128 Dec 7 01:11 Versions ls -la /System/Library/PrivateFrameworks/MetalTools.framework/ total 0 drwxr-xr-x 5 root wheel 160 Dec 7 01:11 . drwxr
3
0
629
Dec ’24
Reply to How to count the number of signed files
Yes I'm referring to the files inside the .app. We need this info for statistics and create if possible also the reports. We execute the codesign inside a CI pipeline. Thanks
Topic: Code Signing SubTopic: General
Replies
Boosts
Views
Activity
Jan ’25
Reply to 自签名证书到期对SDK的影响
The impact of self-signed certificate expiration on the SDK. We have developed an SDK and signed it with a self-signed certificate. Our certificate will expire on January 30, 2025. After it expires, will there be any impact on apps that are already published on the App Store? If a user opens the app on January 31, 2025, will the app crash due to the expired self-signed certificate? Many apps have integrated our SDK, and this issue is very urgent and important for us. We kindly ask for your prompt reply. Thank you! Here are the steps we followed for signing: Self-signing steps: self-signed certificate xcframework Keychain creation: Certificate Assistant - Create Certificate - Self-signed Root Certificate + Code Signing Modify trust settings for the self-signed root certificate Sign the already packaged xcframework (Official command example) codesign --timestamp -v --sign Certificate Name ~/Desktop/MySDK.xcframework
Replies
Boosts
Views
Activity
Jan ’25
Reply to Emergency Reset
Detailed Analysis of the Logs These logs provide a snapshot of system activity and processes, including detailed information about framework usage, threading, and potential performance issues. Below is a breakdown of the logs and an analysis of possible tampering or anomalies. General Observations Key Frameworks and Libraries 1. Foundation & CoreFoundation: • Used for fundamental data manipulation and interaction between processes. Commonly seen in most application logs. 2. QuartzCore: • Graphics and animation rendering. Frequent recursive calls suggest heavy graphical processing. 3. libdispatch: • Task and thread queue management. Repeated invocations at specific offsets (+ 16296, + 49444) indicate high inter-thread activity. 4. AccountsDaemon: • Manages user accounts and synchronization. Persistent queries indicate high activity related to account management. 5. CoreData: • Backend database system; multiple recursive calls (+ 523316, + 182512) suggest inefficiencies in database interactions. Recurrent P
Replies
Boosts
Views
Activity
Jan ’25
How to count the number of signed files
Hi at all, is there a way to count how many files have been marked with the codesign? Thanks in advance
Topic: Code Signing SubTopic: General
Replies
3
Boosts
0
Views
501
Activity
Jan ’25
Reply to Cannot load iTunesLibrary on macOS Sequoia 15.1
I found a solution to this problem after losing a full day. Thanks again to Apple for releasing an update that serves no purpose other than making life even harder for us developers. Every time an update is released, I dread installing it because I know very well that many apps will stop working after the update. I had coded two applications that use iTunesLibrary. They worked perfectly before, but now they don't work anymore, throwing the same error: Code=4097 connection to service named com.apple.amp.library.framework. Based on the documentation, I suspected an issue with sandboxing, entitlements, or binary signing ... but no, that wasn’t the root of the problem. After trying to mimic some behaviors of the Music app, like com.apple.amp.artwork.client, com.apple.amp.devices.client, com.apple.amp.library.client, com.apple.security.files.user-selected.read-only ... and experimenting with various options (some documented, some not), I stumbled upon something incredible that gave me the solution: I had moved my
Topic: Media Technologies SubTopic: General Tags:
Replies
Boosts
Views
Activity
Jan ’25
自签名证书到期对SDK的影响
我们开发了一款SDK,并用自签名证书对SDK进行了签名,我们的证书会在2025年1月30日到期,到期后对已发布至appstore的app会有影响吗? 用户在2025年1月31日打开app时,会因为自签名证书到期而闪退吗?有不少app集成了我们的SDK,这个问题对我们来说非常紧急和重要,麻烦尽快回复,谢谢! 以下是我们的签名步骤: 自签名步骤:self-signed certificate xcframework 1、钥匙串创建:证书助理-创建证书-自签名根证书+代码签名 2、自行签名根证书修改信任设置 3、对已经打包好的xcframework进行签名 (官方命令示例)codesign --timestamp -v --sign 证书名字 ~/Desktop/MySDK.xcframework
Replies
2
Boosts
0
Views
497
Activity
Jan ’25
Reply to The notarized custom PAM module cannot function properly after unlock from screensaver
Sorry it’s taken me a few days to wade in here; I’m only now just catching up with the backlog that built up over the winter break. [quote='772227021, FCG, /thread/772227, /profile/FCG'] Could this issue also be related to a code signing configuration that needs adjustment? [/quote] On your part? No. First, some background. When you call the PAM API, PAM loads plug-ins into your process. This is subject to library validation, as explained here. IMPORTANT The following discusses implementation details that will help you understand what’s going on, but are not considered API. Don’t ship products that rely on this stuff. The exact rules for library validation are different for code that’s built-in to the OS [1]. For third-party code you have to opt in to library validation, either directly, via the library option when signing your code, or indirectly, via the hardened runtime. In contrast, built-in code is always subject to library validation, with an option to opt out. You can see this in action with the author
Replies
Boosts
Views
Activity
Jan ’25
Operation not permitted on xpc_listener_create
Hi, I'm trying to create a launch daemon that uses XPC to receive requests from an unprivileged app. Ultimately both components will be written in Go. For now I'm trying to write a PoC in Objective-C to make sure I get everything right, so I'm compiling / signing from the CLI, and writing plist files by hand -- I'm not using XCode. My current daemon code is pretty much the same as the boilerplate code that XCode generates when creating a new 'XPC Service': #import #include int main(int argc, char *argv[]) { xpc_rich_error_t error; dispatch_queue_t queue = dispatch_queue_create(com.foobar.daemon, DISPATCH_QUEUE_SERIAL); xpc_listener_t listener = xpc_listener_create( com.foobar.daemon, queue, XPC_LISTENER_CREATE_NONE, ^(xpc_session_t _Nonnull peer) { xpc_session_set_incoming_message_handler(peer, ^(xpc_object_t _Nonnull message) { int64_t firstNumber = xpc_dictionary_get_int64(message, firstNumber); int64_t secondNumber = xpc_dictionary_get_int64(message, secondNumber); // Create a reply and send it back to t
Replies
1
Boosts
0
Views
622
Activity
Jan ’25
Reply to Mass deployment of certificates and marking it as trusted
Hi @szigetics_nt szigetics_nt, Thank you for you commands and i was able to trust the certificate by creating a package with composer and user these commands in this way through post install script. sudo /usr/bin/security authorizationdb write com.apple.trust-settings.admin allow sudo security add-trusted-cert -p codeSign -p pkgSign -d -r trustAsRoot -k /Library/Keychains/System.keychain /private/tmp/Nexthink/SCTASK8557870_Nexthink.cer sudo /usr/bin/security authorizationdb write com.apple.trust-settings.admin admin you can edit the script as per your certificate and requirement. Also, if you can with the command to temporarily disable and re-enable the confirmation dialog for macOS sequoia then it will greatley helpful
Replies
Boosts
Views
Activity
Jan ’25
Reply to SwiftData and CloudKit Development vs. Production Database
Everything you described above makes sense, except that a Release build with this same entitlements file doesn't work. I don't know a lot about Direct Distribution. My understanding is that it is the same as Developer ID distribution mentioned in Supported capabilities (macOS). If that's the case, CloudKit should be supported. My guess is that your app probably has something wrong about entitlements, which prevents it from using CloudKit. To confirm that, you can: Try to capture a sysdiagnose and find relevant error messages from there. This topic is covered in Capture and analyze a sysdiagnose. Use the following command line tool to dump the entitlements claimed by your app, and check if there is no difference between the the Release and Debug builds. $ codesign --display --entitlements - Also, if you can detail the steps about how you produced the Release build, I'd see if I can find something relevant. Best, —— Ziqiao Chen  Worldwide Developer Relations.
Replies
Boosts
Views
Activity
Jan ’25
UnityCloudBuild: Codesigned with Sandbox enabled, but still get ITMS-90296: App sandbox not enabled
I've made an MacOS app with Unity Cloud Build and I want to sign and distribute it using App Store Connect. I download the compiled .app file and use codesign to sign all the appropriate files. I also use an entitlements file when I sign the runtime binary. I used the command codesign -d --entitlements on the resulting .app file to confirm that com.apple.security.app-sandbox is set to true, which it is. But when I use productbuild to create the .pkg file and upload it using Transporter, I get an e-mail from App Store Connect saying that ITMS-90296: App sandbox not enabled I don't know how to further debug this... Does anyone have any pointers on how to fix this? Note: it has to be doable either via the Unity Editor, Unity Build Cloud or the MacOS CLI... Codesign showing that app-sandbox is enabled: The error from App Store Connect:
Replies
0
Boosts
0
Views
269
Activity
Jan ’25
Disappearing External link account entitlement
I've got a Flutter app that is a “reader” app. The External Link Account Entitlement has already been requested and granted. It is already added as an Additional Capability to the App ID. The com.apple.developer.storekit.external-link.account entitlement is already present in the .entitlements file. Also SKExternalLinkAccount key is added to the Info.plist file with the correct URL. ExternalLinkAccount.open() is invoked via a MethodChannel call handler and things work perfectly in debug mode. The modal appears as expected and opens the link in the external browser. Xcode archive is also sucessful and the entitlement seems to be in place when inspecting the app with: codesign -d --entitlements :- ./path/to/app But when trying to distribute the app via Xcode the entitlement disappears. Other entitlements are not affected by this issue, eg.: com.apple.developer.associated-domains for universal links. This happens with automatically managed singing and a manually selected provisioning profile as well. Wh
Replies
3
Boosts
0
Views
839
Activity
Jan ’25
Reply to VPN causes developer cert in keychain to become untrusted
I just started running into this a few days ago and I'm not sure why. Same behavior as described above. Everything is working fine, then I need to connect to a VPN for work and when I disconnect from the VPN and try to build the app again and deploy it to the phone, it fails with: Warning: unable to build chain to self-signed root for signer Apple Development: {redacted} (redacted) Command CodeSign failed with a nonzero exit code There is also mention of errSecInternalComponent. If I open keychain on my Mac, I see that my development certificate now says that it's not trusted. And indeed, as julian99 stated, if I change the trust settings to Always Trust, close that window, re-open the certificate again, change the trust settings back to Use System Defaults and then close the window again, it fixes the problem. For added fun, I have to connect and disconnect from the VPN a lot during the work day because the VPN configuration blocks all IPv6 traffic (including link-local traffic) so when I'm connecte
Replies
Boosts
Views
Activity
Dec ’24
Command Line Tool doesn't trigger permission prompt for audio recording
Hello, I'm developing a Command Line Tool in XCode, in order to capture system audio and save it to a file, which will then be used by a separate process. Everything works perfectly when running it from either XCode or the native terminal application (see image below), but as soon as I try to run it from any 3rd party application, it doesn't ask for permissions to record sound, and the resultant file ends up soundless. When archiving it and then running it from other 3rd party applications, e.g Warp (terminal) or spawning it as a child process from a bundled Electron application, it doesn't ask for permissions. Things of note: I've codesigned the application with Developer ID Application I've added NSAudioCaptureUsageDescriptionto Info.plist I've included Info.plist in the binary (see image below) I've added the com.apple.security.device.audio-input entitlement I've used the following resources as inspiration: https://github.com/insidegui/AudioCap https://developer.apple.com/documentation/coreaudio/c
Replies
2
Boosts
0
Views
743
Activity
Dec ’24
MetalTools.framework Missing/Corrupted
Like I said in the title, it looks like MetalTools.framework is missing or corrupted. I think I saw that the symbolic link was broken. They look like aliases in the finder, but I can't find the original. This was a problem with Ventura (using the last compatible Xcode version) and Sequoia 15.2 (Xcode 16.2). I didn't use Xcode before that. Note that none of my apps need Metal API (I don't think). I only noticed it when Xcode gave an error regarding Metal. Sorry this is so long; I hope the Terminal info will help. I don't want to reinstall Sequoia and this has been a problem since at least Ventura. Recommendations? ls -l /System/Library/PrivateFrameworks/MetalTools.framework/ total 0 lrwxr-xr-x 1 root wheel 27 Dec 7 01:11 MetalTools -> Versions/Current/MetalTools lrwxr-xr-x 1 root wheel 26 Dec 7 01:11 Resources -> Versions/Current/Resources drwxr-xr-x 4 root wheel 128 Dec 7 01:11 Versions ls -la /System/Library/PrivateFrameworks/MetalTools.framework/ total 0 drwxr-xr-x 5 root wheel 160 Dec 7 01:11 . drwxr
Replies
3
Boosts
0
Views
629
Activity
Dec ’24