I've set up a fresh installation of Ubuntu 16.04 and enabled full disk encryption using LUKS during installation.
Since the correct key map for my locale was not available yet, I entered a really weak password that was easy to type, with the intent of changing it after successful installation.
Now I'm starting to wonder whether this is a good idea at all. My question is about the strength of the encryption key and the effect of changing my password retroactively. Which of the following two scenarios is true?
The strength of the encryption key is completely unrelated to the strength of the password that the user chose. The encryption key is always of similar strength and is generated randomly, with the user's password simply acting as some kind of "salt". What attackers will try to crack is not the encryption key but the user's password. So changing the user's password from a weak one to a strong one retroactively does significantly improve security.
The strength of the encryption key is directly dependent on the strength of the original password that the user chose. The encryption key significantly varys in strength and is derived from the user's password (in a deterministic way). What attackers will try to crack is either the user's password or the encryption key itself. Changing the user's password from a weak one to a strong one retroactively does not really improve security because attackers will not try to crack the (now strong) password but the (still weak) encryption key whose strength didn't change through the password change and which is weak because the initial password was weak.
#1 is correct
The encryption key is always generated randomly and will have the same length no matter the password. An attacker would always attack the password, as it is far weaker than the encryption key.
The encryption key will be encrypted separately using the password, so changing the password to a stronger one will improve security.
I believe 1 is correct.
I'm not an expert on LUKS, but I do know that for Android's full device encryption (which uses
dm-crypt
), the actual encryption key is randomly generated, and that key is then in turn encrypted with the password the user chose. That way, the user can change the password without requiring a complete re-encryption of the disk. Therefore, the strength of the user's password directly affects the strength of the key.