I don't believe this is a regression caused by the fix in bug #390833.
The only change that fix made was to the st_blocks field of the stat
struct.

The problem that Loïc is seeing is that return value of readlink() and
st_size don't match.  As far as I can tell, that has always been the
case since the inception of the encrypted filename feature in eCryptfs.
The reason is that when we create a symbolic link, we have to store the
encrypted version of the target path in the sym link file.  However,
when readlink() is called we decrypt that path and return the
unencrypted path, resulting in a difference in readlink()'s return value
and the reported st_size of the sym link file.

Loïc, have you been able to successfully use dpkg inside your eCryptfs
partition (with encrypted filenames enabled) before?  My guess is that
either no one has tried this before or the 'assert(r == stab.st_size);'
is relatively new.

-- 
ecryptfs breaks lstat/readlink size assumption
https://bugs.launchpad.net/bugs/524919
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to