Back on the rack

FCBikeLibrary Keep your Mac useful

Fixing "app is damaged"

You download a zip, the Mac clears its throat, and a box says the app is damaged and should go in the bin. Most Saturdays that box is wrong. The file is fine. The Mac is sulking about where it came from. This is the card we leave on the bench so nobody "fixes" it by switching every safety check off.

What the message means

macOS keeps a note on files that arrived from the internet. That note is called the quarantine flag. Gatekeeper reads it and, if the app is not one it already trusts, it may refuse to open and describe the file as damaged. The wording is clumsy. Damaged, in that box, often means "I have not seen this before", not "the bytes are rotten".

It happens with perfectly ordinary tools: a compressor, a sample player, a little menu-bar clock. It is not a verdict on the program, and it is not a reason to fetch the same zip six times. A second copy of the same file gets the same note.

The ordinary way through

Try this before any command line. It is enough for almost every program on the shelf.

  1. Move the app into Applications. Do not run it from inside the zip, and do not leave it sitting in Downloads if you can help it.
  2. In Finder, right-click the app (or control-click) and choose Open.
  3. Read the second box. If it offers Open again, choose it. That is you saying you meant this file.
  4. If the Mac asks for an admin password, that is the machine's password, not a licence key for the app.
  5. After that first open, a normal double-click should do. You do not repeat the ritual every morning.

If there is no Open button and the only choice is to bin the file, stop. Do not disable Gatekeeper for the whole Mac to win an argument. Come back to the next section, or ask whoever is holding the repair book.

The quarantine flag

When the right-click path is not offered, the flag can be cleared for that one file. Terminal is in Applications, Utilities. Drag the app onto the Terminal window after you have typed the command and a space, so you do not have to type the path by hand.

xattr -d com.apple.quarantine

Then drop the app icon so the line becomes the command plus the real path, and press Return. You are deleting one attribute, not the app. Check your work with:

xattr -l

Again, drop the same app on the end of the line. If com.apple.quarantine is gone from the list, try the right-click Open once more.

Do this for the app you intend to open. Do not pipe it across your entire user folder because a forum said it was quicker. Other people's downloads can stay flagged. That flag is doing a job.

When it really is damaged

Sometimes the zip is actually incomplete. The cafe Wi-Fi drops, Safari shows a file, and the file is a stump. Clues:

A program that needs helper tools, Compresto among them, may also stop during its own setup because the network never really connected. That is a different message. It is covered on the Compresto card. Fix the login page on the cafe Wi-Fi before you decide the app is rotten.

Updating a program from this shelf

We do not auto-update the Macs. A donor machine should not be phoning home for a surprise build on a Sunday night.

  1. Read the card. Check the yellow tag against About This Mac before you download anything newer.
  2. Download the new zip. Leave the old app where it is until the new one has opened once.
  3. If the new version is a drag-and-drop app, drop it on Applications and choose Replace when Finder asks. Your settings usually live in your user library, not inside the app, but do not find out the hard way on the only copy of someone's thesis.
  4. Open it with the same right-click the first time, if the Mac asks.
  5. Only then move the old zip to the bin.

If the new build will not run and the old one did, put the old one back. Previous versions on the program card exist for that exact walk of shame. Write a line in the job book so the next volunteer does not repeat it.

Still stuck? Write to the shelf and say which Mac, which system version, and the exact wording of the box. "It doesn't work" is a flat tyre with the wheel still on. We can help faster if we can see the puncture.

Back up