[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: cryptoloop confusion [repost]



On Fri, Aug 30, 2002 at 02:20:36PM -0700, Jeff wrote:
> 
> Does anyone know how I can create an encrypted filesystem on a file in
> my home directory, non-root?  I'm using the loop-aes system and I can
> create everything but I have to chown the file and mount point to
> change the owner and group to my user.  But, when I mount the
> filesystem the mount point directory is changed back to owner=root and
> group=root and I can't create directories and files in the mounted
> filesystem since I don't have permission.

 Are you aware that when you mount a filesystem on a directory, the
mountpoint is hidden, so not only are files in it not accessable by name,
the ownership and permissions are hidden as well?  The new filesystem's root
directory ownership and permissions are what you see when you ls -ld /mnt/foo
(after mounting something on /mnt/foo).

 mke2fs creates the root directory with ownership=0:0, so you need to change
it.  If you mount the filesystem and chmod it to what you want it to be, it
will stay that way across mounts and unmounts, just like /usr stays owned by
root.

 If you already knew that, and the problem is something else, then I don't
know how to help.


-- 
#define X(x,y) x##y
Peter Cordes ;  e-mail: X(peter@llama.nslug. , ns.ca)

"The gods confound the man who first found out how to distinguish the hours!
 Confound him, too, who in this place set up a sundial, to cut and hack
 my day so wretchedly into small pieces!" -- Plautus, 200 BCE



Reply to: