Can an application signed with "com.apple.security.cs.disable-library-validation" be published as trusted?

I am working on releasing my macOS arm64 app. My problem is that after the user downloads the dmg, double-clicking my.app in the dmg, a Gatekeeper pop-up box will appear with a warning that the developer cannot be verified.

Question: Can an application signed with "com.apple.security.cs.disable-library-validation" be published as trusted?

  1. If yes, what steps have I missed?
  2. If not, can I get an official response from Apple?

(Because I referred to this post, it seems to mention that it is possible to publish trusted software.I have looked up similar questions on the forum and tried many things, but nothing works. )

Here are my steps:

  1. Use the codesign to sign my.app. Because my app needs to access third-party dynamic libraries, entitlements.plist contains a "com.apple.security.cs.disable-library-validation". After the "codesign -dvvv" check, the signature was successful.✅

  2. Use the "xcrun notarytool" command to notarize my app, and the status is displayed as accepted.✅

  3. Use "xcrun stapler staple" to attach the notarization to my app, and it returns success.✅

  4. Use the "spctl -a -v " command to verify whether my app has passed Gatekeeper, and it returns that it has passed.✅

  5. Then I packaged my.app into a dmg, and then attached the notarization mark to the dmg, which was successful.✅

  6. I completed the above steps and distributed the dmg. When I downloaded the dmg as a user test and double-clicked my.app in it, the Gatekeeper pop-up box still appeared, and the developer cannot be verified.❌

Answered by DTS Engineer in 816808022
Can an application signed with com.apple.security.cs.disable-library-validation be published as trusted?

Yes.

There are two caveats:

Based on your description of the issue, I suspect you’ve encountered that second caveat.

Use the spctl -a -v command to verify whether my app has passed Gatekeeper

I generally avoid spctl. Instead, follow the instructions in Testing a Notarised Product.

Then I packaged my.app into a dmg, and then attached the notarization mark to the dmg,

It sounds like you’re notarising twice, once for the app and again for the disk image. That’s not actively harmful, but it’s kinda redundant. In most cases you can get away with notarising just the outermost container, which in this case is the disk image. Packaging Mac software for distribution explains this in more detail.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

I removed "com.apple.security.cs.disable-library-validation" and followed all the steps. The test result was passed, but my application failed to call the third-party library. Is there any good solution for this?

Can an application signed with com.apple.security.cs.disable-library-validation be published as trusted?

Yes.

There are two caveats:

Based on your description of the issue, I suspect you’ve encountered that second caveat.

Use the spctl -a -v command to verify whether my app has passed Gatekeeper

I generally avoid spctl. Instead, follow the instructions in Testing a Notarised Product.

Then I packaged my.app into a dmg, and then attached the notarization mark to the dmg,

It sounds like you’re notarising twice, once for the app and again for the disk image. That’s not actively harmful, but it’s kinda redundant. In most cases you can get away with notarising just the outermost container, which in this case is the disk image. Packaging Mac software for distribution explains this in more detail.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Hi Engineer!

Thank you very much for your reply. I paid attention to the second caveat and tried to solve it. But I couldn't follow this post, each step was unexpected.

This post pointed out that it needs to contact a third party or bundle. I need to use the content developed by a third-party developer, but I don't want to bundle it.

As mentioned here, disabling library validation makes it harder to pass Gatekeeper. Resolving Gatekeeper Problems Caused by Dangling Load Command Paths has the details.

Now it is clear that I can't pass Gatekeeper because I signed it with "com.apple.security.cs.disable-library-validation".

Question: Can I have other communication channels besides the forum? Or online help tools? I can send my software for review. Because I didn't create Xcode, I was blocked by the code-level ticket.

Can an application signed with "com.apple.security.cs.disable-library-validation" be published as trusted?
 
 
Q