Ecryptfs encrypts filenames and sometimes I need to find particular file, so I would like a tool to map the encrypted filenames back to their plaintext file name.
You would want to use the utility ecryptfs-find
As of ecryptfs-utils version 96, ecryptfs-find is the best way to go from an encrypted path to a non-encrypted path. It meets the needs of most users that need to map between filenames, but there are some things to note about the tool:
- It doesn't decrypt filenames. It maps the filenames based on the inode number corresponding to a file.
- You must have a live eCryptfs mount. "Offline" mapping of filenames is not possible with ecryptfs-find.
- ecryptfs-find may return multiple results and only one of them will be the actual decrypted version of the path you're looking for. If an inode has multiple hard links, paths to each hard link will be printed.