4

Does FreeBSD, NetBSD, or OpenBSD have an encryption feature like Linux's dm-crypt? And will it work for a system partition?

2

3 Answers 3

4

Indeed, this is documented in the handbook:

https://www.freebsd.org/doc/handbook/disks-encrypting.html

And although gbde is mentioned first, geli is generally more recommended. The installer actually will even help you set this up, there's a prompt for it.

0
2

OpenBSD has softraid(4), which allows you to use an encrypting discipline on a block device. Setting up disk encryption is not supported by the installer (as of September 2020), but can be configured by hand during an operating system installation. OpenBSD FAQ has a section dedicated to Full Disk Encryption which can be used as a reference for setting up disk or partition encryption.

2

NetBSD can indeed be run with an encrypted root filesystem, via a kernel module called cdgroot (though it still needs an unencrypted partition to boot from).

See the following for some comments on the concept and configuration:

NetBSD Root Filesystem Encryption

You must log in to answer this question.