Verify a Disk Image with hdiutil verify
Checksum a .dmg against its embedded checksum before mounting or burning — no Disk Utility needed.
Run `hdiutil verify ~/Downloads/Installer.dmg` to confirm the image's internal checksum passes.
01Command
Command
$ hdiutil verify ~/Downloads/Installer.dmg02What it does
hdiutil verify walks the image's data and compares it to the checksum stored inside the image, reporting success or the first bad block. It works without attaching the image, so a corrupt download never gets mounted at all. Related read-only helpers include `hdiutil imageinfo` for format details and `hdiutil attach -readonly` for safe inspection.
03Risk
!Warning: A passing checksum only proves the image matches itself at creation time — it is not malware analysis.
04Undo
✓No undo needed — this command does not change persistent state.
05Sources
- HDIUtil Command: Manipulate disk images in macOSEvidence: Documents hdiutil verify for checksumming disk images, plus attach, burn, and imageinfo subcommands.
Last verified: 2026-09-17 · Category: System & Settings