Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

My assumption (which seems to be incorrect) was that ecryptfs (FUSE filesystems in general) used the following stacking mechanism:

  • User code issues read()
  • Kernel attempts to satisfy request from existing (unencrypted) buffer
  • Buffer doesn't exist, kernel asks ecryptfs to load block
  • ecryptfs asks kernel to load physical (encrypted) block, kernel does this and stores it in buffer cache
  • ecryptfs decrypts physical block
  • kernel stores decrypted block in buffer cache
  • subsequent reads are fulfilled from decrypted block in cache

However, comparing the "sys" times for identical operations on encrypted and non-encrypted filesystems, it appears that the only buffer in the cache is the encrypted one, and ecryptfs decrypts on every read(). The diagram on the FUSE homepage doesn't mention buffer cache, but seems to indicate that operations take place at the syscall level, not the block level.

Could someone who is familiar with either the internals of ecryptfs (Dustin?) or FUSE in general answer this?

share|improve this question

migrated from askubuntu.com Jun 5 at 17:34

This question came from our site for Ubuntu users and developers.

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.