Out of curiosity, I have a couple of questions regarding APFS passphrases. Using
diskutil I found out that each APFS encrypted volume includes several cryptographic users, which at least in my system are divided into two types:
Disk User and
Local Open Directory User. The latter obviously being the different accounts on the system.
Disk User seems to be the one to be used when mounting non bootable volumes.
I changed the passphrase of the
Disk User, which returned immediately (and successfully). So I believe this passphrase should be unrelated to the actual encryption key... Otherwise the change would require a reencryption of the volume.
- What is the actual key used by the APFS AES encryption algorithm? Are those cryptographic users just a wrapper to gain access to the actual key? In such a case, I assume that key is generated when creating a new volume and never exposed.
- Moreover, what happens in case of data corruption? In particular, what happens if the encryption key data gets corrupted? Does it means it is impossible to recover any of the data in the disk? We have the passphrase, but not the actual key...