Idiomatic way to encrypt file in macOS?

1

When I am running Linux and want to encrypt a file that contains sensitive information, I run gpg -c filename and enter a password when prompted.

What is the common way to do this on macOS?

user1283776

Posted 2017-12-15T21:17:53.847

Reputation: 449

2

Is there some reason you cannot use gpg on osx?

– DavidPostill – 2017-12-15T21:23:04.337

Answers

4

On macOS, you can install gpg via Homebrew and other methods.

brew install gpg


As far as encryption tools that come with the OS, you can create encrypted disk images through Disk Utility (and the related command line tools):

Disk Utility Encryption

You could open such a disk image on a Mac without installing additional software.

Alexander O'Mara

Posted 2017-12-15T21:17:53.847

Reputation: 548

What kind of encryption format does Mac's Disk Utility use, simlar to LUKS? – Xen2050 – 2017-12-17T23:02:46.010

@Xen2050 It's like a regular DMG, but the majority of the file is encrypted using AES with a key derived from the password. I'm not sure if a proper file format specification is publicly available. – Alexander O'Mara – 2017-12-17T23:09:50.213