I had an encrypted home dir in my Ubuntu partition (system and home together). I left the live usb plugged in and someone reinstalled Ubuntu over that partition.
I read all I could on the net about people with similar issues. First of all, I stopped using the affected hard drive (writing this from a Lubuntu live cd). Then I ran Photorec on the affected disk, without any filter (i.e. recover everything). The results are now sitting in an external disk.
Among all the files, I think it's the .eCryptfs ones I need. However, I only know my login password. I never wrote down the mount passphrase. I know I can recover it with just my login password if I find the
However, Photorec didn't recover the original name of any file (I believe it names them according to the disk sector from which they were recovered). Moreover, all files are distributed among different directories (recup_dir.1 and so on).
Is my only choice to wade through the millions of txt files until I find
wrapped-passphrase? I don't think I could recognize it, since most surely it's a byte stream and there might be millions of files like that...
EDIT: Just in case anyone was wondering, the version was 12.04 (which means the filenames were encrypted, IIRC)
EDIT2: I created an Ubuntu 12.04 virtual machine with the same user and password as my old system and enabled home dir encryption. Here's the resulting