Ubuntu: Restore your encrypted home directory

From Tomelec
Revision as of 19:03, 27 January 2013 by Tom (talk | contribs)

Jump to: navigation, search

What you need

  • A running Ubuntu
  • Access to the disk from which you want to restore
  • Your user password of the system you want to restore from OR the passphrase you might have recorded earlier

How it works

Mount the disk or partition with the encrypted home on it

It can be done with Nautilus or on the text console. Change to the directory with the encrypted home which might look like that:

user@ubuntu:/media/my_disk/home/.ecryptfs/username$

Optional: Get the passphrase

The passphrase is not the user password. It is a random key, stored in the file wrapped-passphrase and encrypted with the user´s password. It´s unlikely that you´ve got that passphrase writen down somewhere but if you do so, skip that step. Else unwrap it:

user@ubuntu:/media/my_disk/home/.ecryptfs/username$ ecryptfs-unwrap-passphrase .ecryptfs/wrapped-passphrase
Passphrase: <enter user´s password here>
2dac479b16e0efd2ac7b8e9e7690f8f7

This got us the passphrase, for exmple 2dac479b16e0efd2ac7b8e9e7690f8f7.