Monday, December 14, 2020

“Damaged” Apps That Can’t Be Opened

Craig Hockenberry (tweet):

This story began with customer reports of xScope being a “damaged app” on Big Sur. This was surprising because I had been downloading and testing the app on Big Sur for several months without issue.


It turns out all these folks complaining about a “damaged app” were either using Chrome or had Safari’s “safe” file handling turned off. The damaged archive wasn’t getting repaired automatically by Safari.

The root of the problem is localization in the Sparkle framework. There are two symlinks with extended attributes (the “._” is where macOS stores things like Finder information). The intent of the symlink was to say that French Canadian is the same as French, and Portuguese is the same as Brazilian Portuguese.

There’s also arguably a bug in Safari because, even though it my be desirable in this case, why is it changing the contents of the ZIP archive?

Thomas Tempelmann appears to be seeing the opposite beahvior with ZIP archives:

I’ve now had it several times that customers cannot launch my downloaded apps in Big Sur because “… is damaged and can’t be opened.” - and that’s because they’re using broken 3rd party unzip tools like “Decompressor”. I can recommend The Unarchiver, though.


I downloaded with Safari (“Open safe files …” is unchecked), then used the “Decompressor” app to unzip the app -> damaged. Unzip same file with Apple’s tool -> fine. Happens with my iClip app but not with my FindAnyFile app.

And I think there’s more to this issue because, over the last few weeks, I’ve received customer support requests about the “‘App’ is damaged and can’t be opened. You should move it to the Trash” error for the first time—even though my apps are shipped in .dmg files rather than .zip files. Sometimes, removing the quarantine xattr helps, but I don’t understand what the underlying issue is. If the disk image’s checksum verifies, is the app somehow being damaged as Finder copies it to the Applications folder?

See also: AskDifferent, OSXDaily, Apple’s forum.

1 Comment RSS · Twitter

Update: I figured out what did wrong: My zipped app has a non-ASCII file name, which it managed to garble ("•" becomes "•"). If I fix this after decompression but before launching the unzipped app, it'll run. So it's not related to the issue Craig Hockenberry reported but rather a result of a bug in Decompressor and recent macOS's stricter checking of all files inside the app package.


Leave a Comment