0

I've managed to mount "old" ecryptfs home folder with sudo mount -t ecryptfs [SRC DIR] [DST DIR]. It was failing for ecryptfs-recover-private with mount: No such file or directory and with setreuid: Operation not permitted for strace --follow-forks -o file.log ecryptfs-recover-private. BTW, why different error for --follow-forks? Maybe worth separate question about strace.

Anyway it mounted but ls [DST DIR] lists files and folders that look as correct home folder, but with ? and "cannot access ... no such file or directory". What could be the problem?

With web search I've managed to find QAs for mount issue. https://askubuntu.com/questions/1074753/ecryptfs-mount-private-failure-in-ubuntu-18-04-mount-no-such-file-or-directory; https://askubuntu.com/questions/1126981/ecryptfs-mount-no-such-file-or-directory; mount: No such file or directory with encrypted recovery "ecryptfs-mount-private" returns "fopen: No such file or directory"

Closest to mine is ecryptfs mounting failure from kernel 4.7 onwards with also ? for ls, but it is from 2016 and answer is for kernel change for plaintext+encrypted names change, my encrypted home folder is from 2021.

BTW I've tried mount both plaintext passthrough y and n.

0

1 Answer 1

1

FDEK (filenames decryption key) offered by mount as default was not correct one and I have not noted that before.

TL;DR

I was able to mount and read my encrypted folder via ecryptfs-recover-private.

ecryptfs-recover-private is shell script that near the end has mount -i -t ecryptfs -o "$mount_opts" "$d" "$tmpdir". I've compared my way to the script and the only IMO difference is -i flag in the script (other options looks like same as I've chosen interactively when I ran mount -t ecryptfs: ecryptfs_sig=$mount_sig,ecryptfs_fnek_sig=$fnek_sig,ecryptfs_cipher=aes,ecryptfs_key_bytes=16).

Knowing that, and thinking about the issue I've somehow realized to check FDEK and indeed in my terminal I saw FDEK (filenames decryption key) offered by mount as default was not correct one. After I entered second line from Private.sig as FDEK to mount -t it worked too.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .