# Codesigning some (not all) apps fails

**URL:** <https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743>\
**Category:** macOS\
**Created:** [February 21, 2026, 11:22am UTC](https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743 "2026-02-21T11:22:26Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![Aaron\_Hunt](https://forum.xojo.com/user_avatar/forum.xojo.com/aaron_hunt/32/23752_2.png) [@Aaron\_Hunt](https://forum.xojo.com/u/Aaron_Hunt)\
**Post date:** [February 21, 2026, 11:22am UTC](https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743/1 "2026-02-21T11:22:26Z")

</div>

Xojo2025r3.1

I’m getting the following error when codesigning the apps (desktop):

codesign -d -vvvv \<app\_path\>  
unsealed contents present in the bundle root

To confirm this problem:

spctl -a -vv \<app\_path\>  
a sealed resource is missing or invalid

Codesigning works fine for all the app’s libs / frameworks, it only fails on the app itself. I know my Apple certificates are all fine, because many other apps get signed with no problems. There is something about these particular apps that stop the codesigning from working, the error message is however pretty useless as it does not tell me exactly what the problem is.

I tried the following:

- remove all resorce forks from all files
- remove quarantine if it exists on any file

This changed nothing.

I can’t issue updates for these particular apps until this problem is solved. I never had this problem before, Apple changed something, who knows what.

Any help?

Thank you.

---

<div class="post-metadata">

**Author:** ![Christian\_Schmitz](https://forum.xojo.com/user_avatar/forum.xojo.com/christian_schmitz/32/158_2.png) [@Christian\_Schmitz](https://forum.xojo.com/u/Christian_Schmitz)\
**Post date:** [February 21, 2026, 12:27pm UTC](https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743/2 "2026-02-21T12:27:14Z")

</div>

Did you code sign any included helper app, frameworks and dylibs before signing the app?  
You have to sign from inside to outside.

And maybe beforehand run `xattr -cr path` on the folder to remove stuff.  
Also good to find and delete .DS\_Store files.

And this can’t be in a folder inside iCloud, Dropbox or similar.

---

<div class="post-metadata">

**Author:** ![Aaron\_Hunt](https://forum.xojo.com/user_avatar/forum.xojo.com/aaron_hunt/32/23752_2.png) [@Aaron\_Hunt](https://forum.xojo.com/u/Aaron_Hunt)\
**Post date:** [February 21, 2026, 12:54pm UTC](https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743/3 "2026-02-21T12:54:34Z")

</div>

> [@Christian\_Schmitz](#):
>
> Did you code sign any included helper app, frameworks and dylibs before signing the app?

I did look there first. All the plugins and the Xojo framework are signed first. One of the apps has a couple of additional dylibs which get copied over in the Build script, which are also signed before the app. But I have one app which has no additional libraries and it still fails.

> [@Christian\_Schmitz](#):
>
> And maybe beforehand run `xattr -cr path` on the folder to remove stuff.  
> Also good to find and delete .DS\_Store files.

Okay, I added that.

> [@Christian\_Schmitz](#):
>
> And this can’t be in a folder inside iCloud, Dropbox or similar.

Thanks, I don’t use any of those kinds of services. I always work with data on the internal SSD.

Unfortunately, the result is the same. It doesn’t work.

I forgot to mention that my machine is a Mac Studio M1. I’ve read reports of the file system having issues with Unicode, so I checked for any unusual characters in filenames. There are none as far as I can tell.

---

<div class="post-metadata">

**Author:** ![Greg\_O](https://forum.xojo.com/user_avatar/forum.xojo.com/greg_o/32/22785_2.png) [@Greg\_O](https://forum.xojo.com/u/Greg_O)\
**Post date:** [February 21, 2026, 3:56pm UTC](https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743/4 "2026-02-21T15:56:10Z")

</div>

> [@Aaron\_Hunt](#):
>
> unsealed contents present in the bundle root

Is there something in the bundle next to the Contents directory?

Also, check for symlinks that point to something outside the bundle.

---

<div class="post-metadata">

**Author:** ![Aaron\_Hunt](https://forum.xojo.com/user_avatar/forum.xojo.com/aaron_hunt/32/23752_2.png) [@Aaron\_Hunt](https://forum.xojo.com/u/Aaron_Hunt)\
**Post date:** [February 21, 2026, 4:11pm UTC](https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743/5 "2026-02-21T16:11:06Z")

</div>

> [@Greg\_O](#):
>
> Is there something in the bundle next to the Contents directory?

No, the directory structure is completeley normal as far as I can see.

> [@Greg\_O](#):
>
> Also, check for symlinks that point to something outside the bundle.

Thanks, I’ll do that for the one app that is using added dylibs. If they are using @rpath they should be fine, right?

What I really don’t get is that these same apps signed and uploaded with no problem to the Mac App Store. It’s only trying to sign them for use outside the app store that the signing fails. That would suggest that the certificate is at fault, but why then would many other apps sign with no problem? [EDIT: here I mean signing with correct certificates for distribution outside MAS] It doesn’t make any sense.

It may be that there are multiple causes, but symlinks can’t be the cause for the app that has no added dylibs but also fails. I found some text files with no extension which appeared in Finder as Unix Executable files (even though terminal told me they were identified as HTML files). I added extensions to those so they appear in Finder correctly, but that changed nothing, the signing still failed the same way.

---

<div class="post-metadata">

**Author:** ![Mike\_D](https://forum.xojo.com/user_avatar/forum.xojo.com/mike_d/32/266_2.png) [@Mike\_D](https://forum.xojo.com/u/Mike_D)\
**Post date:** [February 21, 2026, 4:21pm UTC](https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743/6 "2026-02-21T16:21:19Z")

</div>

> [@Aaron\_Hunt](#):
>
> App Store. It’s only trying to sign them for use outside the app store that the signing fails

You know that you have to use a different certificate in this case, right?

---

<div class="post-metadata">

**Author:** ![Aaron\_Hunt](https://forum.xojo.com/user_avatar/forum.xojo.com/aaron_hunt/32/23752_2.png) [@Aaron\_Hunt](https://forum.xojo.com/u/Aaron_Hunt)\
**Post date:** [February 21, 2026, 4:31pm UTC](https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743/7 "2026-02-21T16:31:13Z")

</div>

> [@Mike\_D](#):
>
> You know that you have to use a different certificate in this case, right?

Yes. I’m using the correct certificates. They work for other apps that I also prepare for distribution outside MAS. I updated the above to try to make that more clear, thanks.

---

<div class="post-metadata">

**Author:** ![Aaron\_Hunt](https://forum.xojo.com/user_avatar/forum.xojo.com/aaron_hunt/32/23752_2.png) [@Aaron\_Hunt](https://forum.xojo.com/u/Aaron_Hunt)\
**Post date:** [February 23, 2026, 10:34am UTC](https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743/8 "2026-02-23T10:34:24Z")

</div>

Still no luck. The offending file(s) aren’t listed in the error report and I don’t see anything wrong.

---

<div class="post-metadata">

**Author:** ![Mike\_D](https://forum.xojo.com/user_avatar/forum.xojo.com/mike_d/32/266_2.png) [@Mike\_D](https://forum.xojo.com/u/Mike_D)\
**Post date:** [February 23, 2026, 2:59pm UTC](https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743/9 "2026-02-23T14:59:10Z")

</div>

1. Look through your app bundle (right click app, choose `Show Package Contents` ) In the Mac Finder window, type Command-Shift-Period which will turn on showing of invisible files.  
Does anything look weird? The App bundle typically should have only a `Contents` folder at the top level.

2. are you transferring these files to another Mac? Many file sharing services will mangle mac executables, so you need to transfer the Zip file and un-zip on the destination mac, or create a DMG…

---

<div class="post-metadata">

**Author:** ![Aaron\_Hunt](https://forum.xojo.com/user_avatar/forum.xojo.com/aaron_hunt/32/23752_2.png) [@Aaron\_Hunt](https://forum.xojo.com/u/Aaron_Hunt)\
**Post date:** [February 23, 2026, 3:14pm UTC](https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743/10 "2026-02-23T15:14:41Z")

</div>

Thanks, I’ve done all that. Nothing out of the ordinary.

I’ve read online reports of this problem, where certain image or icon files seem to be the cause. Of course, there’s nothing about why that would be, or what the problem actually is, just random reports from users that after they replace a certain file, then it works. I’ve had no such luck.

---

<div class="post-metadata">

**Author:** ![Javier\_Menendez](https://forum.xojo.com/user_avatar/forum.xojo.com/javier_menendez/32/15692_2.png) [@Javier\_Menendez](https://forum.xojo.com/u/Javier_Menendez)\
**Post date:** [February 23, 2026, 4:35pm UTC](https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743/11 "2026-02-23T16:35:14Z")

</div>

Just a blind shot… maybe some of the files have the quarentined attribute set?

---

<div class="post-metadata">

**Author:** ![Aaron\_Hunt](https://forum.xojo.com/user_avatar/forum.xojo.com/aaron_hunt/32/23752_2.png) [@Aaron\_Hunt](https://forum.xojo.com/u/Aaron_Hunt)\
**Post date:** [February 23, 2026, 4:38pm UTC](https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743/12 "2026-02-23T16:38:38Z")

</div>

Thanks, it’s the right idea but as I mentioned above, I checked for that already and removed all quarantines. In one case there were in fact quarantined files, but after removing quarantine from those files, nothing changed.

---

<div class="post-metadata">

**Author:** ![Greg\_O](https://forum.xojo.com/user_avatar/forum.xojo.com/greg_o/32/22785_2.png) [@Greg\_O](https://forum.xojo.com/u/Greg_O)\
**Post date:** [February 24, 2026, 2:07am UTC](https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743/13 "2026-02-24T02:07:23Z")

</div>

Just a thought…Apple has been threatening to remove the -d or —deep option for years. Have you tried manually signing the package from the inside out without the -d option?

---

<div class="post-metadata">

**Author:** ![Greg\_O](https://forum.xojo.com/user_avatar/forum.xojo.com/greg_o/32/22785_2.png) [@Greg\_O](https://forum.xojo.com/u/Greg_O)\
**Post date:** [February 24, 2026, 2:10am UTC](https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743/14 "2026-02-24T02:10:36Z")

</div>

Oh you know what? Open the bundle in Finder and press CMD-SHIFT-.

Maybe there’s some invisible files in there?

---

<div class="post-metadata">

**Author:** ![Tim\_Parnell](https://forum.xojo.com/user_avatar/forum.xojo.com/tim_parnell/32/161_2.png) [@Tim\_Parnell](https://forum.xojo.com/u/Tim_Parnell)\
**Post date:** [February 24, 2026, 2:35pm UTC](https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743/15 "2026-02-24T14:35:44Z")

</div>

I would suggest trying the “control group” test of seeing if App Wrapper can handle it.

Even if App Wrapper isn’t going to be part of the automation in the end, we’ll get the data point of “does _anyone_ know how to get this signed”.

---

<div class="post-metadata">

**Author:** ![Aaron\_Hunt](https://forum.xojo.com/user_avatar/forum.xojo.com/aaron_hunt/32/23752_2.png) [@Aaron\_Hunt](https://forum.xojo.com/u/Aaron_Hunt)\
**Post date:** [February 24, 2026, 3:54pm UTC](https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743/16 "2026-02-24T15:54:21Z")

</div>

> [@Tim\_Parnell](#):
>
> seeing if App Wrapper can handle it.

Thanks for the suggestion. I’ve never used it but found the free trial. Very good of Sam to allow 14 days of free use. It was easy to figure out how to use. Nicely done.

And the result is: it works. At least for the first app I tried which has consistently failed until now. App Wrapper had no trouble signing and notarizing.

Which is great, although I’m still left looking for a reason for the failure …

---

<div class="post-metadata">

**Author:** ![Tim\_Parnell](https://forum.xojo.com/user_avatar/forum.xojo.com/tim_parnell/32/161_2.png) [@Tim\_Parnell](https://forum.xojo.com/u/Tim_Parnell)\
**Post date:** [February 24, 2026, 4:00pm UTC](https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743/17 "2026-02-24T16:00:23Z")

</div>

Sam’s engine signs everything from the inside out, so the `-deep` option could be the culprit. It is also _significantly_ better at cleaning up (or skipping? idk) the files Apple complains about as “detritus” files. Those are those files that you read about where someone replacing the file suddenly works. (which can sometimes be the invisible `Icon?` file inside folders with custom icons)

---

<div class="post-metadata">

**Author:** ![Aaron\_Hunt](https://forum.xojo.com/user_avatar/forum.xojo.com/aaron_hunt/32/23752_2.png) [@Aaron\_Hunt](https://forum.xojo.com/u/Aaron_Hunt)\
**Post date:** [February 24, 2026, 6:01pm UTC](https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743/18 "2026-02-24T18:01:01Z")

</div>

> [@Tim\_Parnell](#):
>
> the `-deep` option could be the culprit.

> [@Greg\_O](#):
>
> Apple has been threatening to remove the -d or —deep option for years. Have you tried manually signing the package from the inside out without the -d option?

Thanks for the suggestion, sorry I forgot to reply to this. Removing the –deep option didn’t change anything.

This appears to be one of those cases where the error message is probably just incorrect, meaning: there is a problem somewhere, but it has nothing to do with “unsealed contents present in the bundle root”, it’s something else that trips up some sequence of operations, who knows what, and the only thing that gets spit out is a failure message which is worse than useless since it has nothing to do with the real cause. That’s my guess anyway.

---

<div class="post-metadata">

**Author:** ![Aaron\_Hunt](https://forum.xojo.com/user_avatar/forum.xojo.com/aaron_hunt/32/23752_2.png) [@Aaron\_Hunt](https://forum.xojo.com/u/Aaron_Hunt)\
**Post date:** [February 24, 2026, 6:14pm UTC](https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743/19 "2026-02-24T18:14:56Z")

</div>

Here’s something weird App Wrapper shows me which I suppose could be a clue:

App Wrapper lists an expired “Apple Worldwide Developer Relations Certification Authority” certificate on my system, one that expired 3 years ago. The thing is, when I look for this certificate in the Keychain, it’s nowhere to be found. Nowhere. I have the current same-named certificate installed, which expires in 2030. I have no expired certificates anywhere on my system…

Except this one, apparently, somewhere … the question is: where is it? App Wrapper says it’s in “System”, but it isn’t there.

---

<div class="post-metadata">

**Author:** ![Thomas\_Roemert](https://forum.xojo.com/user_avatar/forum.xojo.com/thomas_roemert/32/827_2.png) [@Thomas\_Roemert](https://forum.xojo.com/u/Thomas_Roemert)\
**Post date:** [February 24, 2026, 6:28pm UTC](https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743/20 "2026-02-24T18:28:04Z")

</div>

> [@Aaron\_Hunt](#):
>
> Except this one, apparently, somewhere … the question is: where is it?

Have a look in your project folder, this certificate was - if I remember correctly - used in the MAS functions to verify receipts and therefor included in the project…

[Next page](https://forum.xojo.com/t/codesigning-some-not-all-apps-fails/87743.md?page=2)
