Getting files back
'You do not have permission' and 'cannot be opened' are different problems with different fixes.
Read the exact message:
→ Gatekeeper quarantine
corruption
Each has its own fix; treating them the same is why people flail.
ls -l@ file # see owner and mode
sudo chown "$(whoami)" file # take ownership
chmod u+rw file # grant yourself read/write
Common after migrating from another Mac, where the old numeric user ID no longer matches.
For an app or file you trust:
xattr -d com.apple.quarantine fileOnly for files whose source you trust — this gate exists for a reason.
Check what it really is:
file suspicious.pdf
A mismatch (a "PDF" that is HTML, a truncated image) explains the failure. The corrupted- file article covers salvage; the short version is try a more forgiving app, then fall back to Versions, Time Machine or a cloud version.
Get Info → uncheck Locked, or:
chflags nouchg file
A locked file opens read-only or refuses edits — distinct from permissions, same felt symptom.
Ownership likely came from another user or Mac. sudo chown $(whoami) file and chmod u+rw file restore access.
Right-click → Open and confirm, or System Settings → Privacy & Security → Open Anyway, for sources you trust.
Everywhere keeps track of every file on your Mac — including the folders Spotlight hides and drives you have unplugged. Free for a day, then $19 once.
Download for Mac