Difference between revisions of "Ubuntu: Restore your encrypted home directory"

From Tomelec
Jump to: navigation, search
(Created page with "=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 hav...")
 
Line 8: Line 8:
 
It can be done with Nautilus or on the text console. Change to the directory with the encrypted home which might look like that:
 
It can be done with Nautilus or on the text console. Change to the directory with the encrypted home which might look like that:
 
  <nowiki>user@ubuntu:/media/my_disk/home/.ecryptfs/username$</nowiki>
 
  <nowiki>user@ubuntu:/media/my_disk/home/.ecryptfs/username$</nowiki>
 +
 
==Optional: Get the passphrase==
 
==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. Unwrap it:
+
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:
 
  <nowiki>user@ubuntu:/media/my_disk/home/.ecryptfs/username$ ecryptfs-unwrap-passphrase .ecryptfs/wrapped-passphrase
 
  <nowiki>user@ubuntu:/media/my_disk/home/.ecryptfs/username$ ecryptfs-unwrap-passphrase .ecryptfs/wrapped-passphrase
Passphrase:
+
Passphrase: <enter user´s password here>
 
2dac479b16e0efd2ac7b8e9e7690f8f7</nowiki>
 
2dac479b16e0efd2ac7b8e9e7690f8f7</nowiki>
 +
This got us the passphrase, for exmple ''2dac479b16e0efd2ac7b8e9e7690f8f7''.

Revision as of 20:03, 27 January 2013

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.