On Apr 04, 2005 20:08 -0400, Vineet Joglekar wrote: > I have created another file system - copied everything from ext2, > renaming it as some different file system and doing some experiments on that. > > Let me be more clear about what I am trying to do. In my masters > project, I am encrypting inodes along with the data part of the file. Keys > of different users are different. In the same directory, if there are > 2 files stored by different users, their inodes will be encrypted with > different keys. If user1 is doing "ls" on that directory, the inode > of the other file - which is encrypted by user2, will be decrypted by > using user1's key, resulting into garbage. To avoid this, I am trying > to store the uid in the directry entry, so that I can match it with > current->fsuid and skip decrypting the inode if the file doesn't belong > to the current user. (assuming user1 doesnt want to share that file and > different users can store different files under same directory.) This is broken by design. What happens if you chown a file? The UID will change in the inode, but nothing will be updated in the directory. This key must be stored in the inode along with the ownership info (it can be an EA, and possibly a fast EA or fixed inode field in a large inode). Cheers, Andreas -- Andreas Dilger Principal Software Engineer Cluster File Systems, Inc.
Attachment:
pgpbjuz9fAFR3.pgp
Description: PGP signature
- Follow-Ups:
- Re: Adding a field to ext2_dir_entry_2
- From: "Theodore Ts'o" <[email protected]>
- Re: Adding a field to ext2_dir_entry_2
- References:
- Re: Adding a field to ext2_dir_entry_2
- From: "Vineet Joglekar" <[email protected]>
- Re: Adding a field to ext2_dir_entry_2
- Prev by Date: Re: [RFC 5/6]clean cpu state after hotremove CPU
- Next by Date: Re: i8042 controller on Toshiba Satellite P10 notebook - patch
- Previous by thread: Re: Adding a field to ext2_dir_entry_2
- Next by thread: Re: Adding a field to ext2_dir_entry_2
- Index(es):