linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/2] implement uid mount option for ext2 and ext3
@ 2009-07-23 11:36 Ludwig Nussel
  2009-07-23 11:36 ` [PATCH 1/2] implement uid mount option for ext2 Ludwig Nussel
                   ` (4 more replies)
  0 siblings, 5 replies; 22+ messages in thread
From: Ludwig Nussel @ 2009-07-23 11:36 UTC (permalink / raw)
  To: linux-fsdevel; +Cc: linux-kernel

Hi,

When using 'real' file systems on removable storage devices such as
hard disks or usb sticks people quickly face the problem that their
Linux users have different uids on different machines. Therefore one
cannot modify or even read files created on a different machine
without running chown as root or storing everything with mode 777.
Simple file systems such as vfat don't have that problem as they
don't store file ownership information and one can pass the uid
files should belong to as mount option.

The following two patches (for 2.6.31-rc4) therefore implement the
uid mount option for ext2 and ext3 to make them actually useful on
removable media. My implementation just writes uid 0 to disk for
files that are owned by the specified user. In read direction files
with uid 0 appear as being owned by the specified user.

In an ideal world this would probably be implemented as vfs feature
rather than having it in every single file system.

Anyways, AFAICT the method works just fine for ext2. I'm not sure
about the ext3 patch though as ext3 has that ext3_setattr() function
for journaling. I don't know if the uid should better be mangled
there instead.

cu
Ludwig

-- 
 (o_   Ludwig Nussel
 //\   
 V_/_  http://www.suse.de/
SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nuernberg)

^ permalink raw reply	[flat|nested] 22+ messages in thread
* [RFC] [PATCH 0/2] implement uid mount option for ext2 and ext3
@ 2009-04-08 13:21 Ludwig Nussel
  2009-04-08 13:21 ` [PATCH 1/2] implement uid mount option for ext2 Ludwig Nussel
  0 siblings, 1 reply; 22+ messages in thread
From: Ludwig Nussel @ 2009-04-08 13:21 UTC (permalink / raw)
  To: linux-fsdevel

Hi,

When using 'real' file systems on removable storage devices such as
hard disks or usb sticks people quickly face the problem that their
Linux users have different uids on different machines. Therefore one
cannot modify or even read files created on a different machine
without running chown as root or storing everything with mode 777.
Simple file systems such as vfat don't have that problem as they
don't store file ownership information and one can pass the uid
files should belong to as mount option.

The following two patches (for 2.6.29) therefore implement the uid
mount option for ext2 and ext3 to make them actually useful on
removable media. My implementation just writes uid 0 to disk for
files that are owned by the specified user. In read direction files
with uid 0 appear as being owned by the specified user.

In an ideal world this would probably be implemented as vfs feature
rather than having it in every single file system.

Anyways, AFAICT the method works just fine for ext2. I'm not sure
about the ext3 patch though as ext3 has that ext3_setattr() function
for journaling. I don't know if the uid should better be mangled
there instead.

cu
Ludwig

-- 
 (o_   Ludwig Nussel
 //\   
 V_/_  http://www.suse.de/
SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nuernberg)

^ permalink raw reply	[flat|nested] 22+ messages in thread

end of thread, other threads:[~2009-08-02 12:50 UTC | newest]

Thread overview: 22+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-07-23 11:36 [PATCH 0/2] implement uid mount option for ext2 and ext3 Ludwig Nussel
2009-07-23 11:36 ` [PATCH 1/2] implement uid mount option for ext2 Ludwig Nussel
2009-07-23 11:36   ` [PATCH 2/2] implement uid mount option for ext3 Ludwig Nussel
2009-07-23 14:37 ` [PATCH 0/2] implement uid mount option for ext2 and ext3 Randy Dunlap
2009-07-23 21:23 ` Valdis.Kletnieks
2009-07-24 10:23   ` Ludwig Nussel
2009-07-30  9:07     ` Pavel Machek
2009-07-24 10:30 ` [PATCH 0/2] implement uid mount option for ext2 and ext3, try 2 Ludwig Nussel
2009-07-24 10:30   ` [PATCH 1/2] implement uid mount option for ext2 Ludwig Nussel
2009-07-24 10:30     ` [PATCH 2/2] implement uid mount option for ext3 Ludwig Nussel
2009-07-24 16:52     ` [PATCH 1/2] implement uid mount option for ext2 Andreas Dilger
2009-07-24 18:58       ` John Stoffel
2009-07-24 23:16         ` Jamie Lokier
2009-07-27 14:56           ` John Stoffel
2009-07-25 15:44       ` Ludwig Nussel
2009-07-27 19:14         ` Andreas Dilger
2009-07-28  7:50           ` Ludwig Nussel
2009-07-28 11:01 ` [PATCH 0/2] implement uid mount option for ext2 and ext3, try 3 Ludwig Nussel
2009-07-28 11:01   ` [PATCH 1/2] implement uid and gid mount options for ext2 Ludwig Nussel
2009-07-28 11:01     ` [PATCH 2/2] implement uid and gid mount options for ext3 Ludwig Nussel
2009-07-28 18:11   ` [PATCH 0/2] implement uid mount option for ext2 and ext3, try 3 Andreas Dilger
  -- strict thread matches above, loose matches on Subject: below --
2009-04-08 13:21 [RFC] [PATCH 0/2] implement uid mount option for ext2 and ext3 Ludwig Nussel
2009-04-08 13:21 ` [PATCH 1/2] implement uid mount option for ext2 Ludwig Nussel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).