lkml.org 
[lkml]   [1997]   [Jul]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: fmount system call
> during the smbfs-rewrite I remembered the security problem in smbmount
> and ncpmount. Both programs are designed to let the user mount remote
> file systems of his own. This is necessary because the remote file
> systems are per-user password protected. To do this, they check
> whether the user has write permissions on the mount point and then
> mount the file. Playing with links between the check and the real
> mount creates quite well-known races.

Hmmm. AFAIK, this comes from smbmount and ncpmount being setuid-root,
which in turn comes from mount(2) requiring root privileges. Maybe
this restriction could be relaxed with some additional VFS protocol,
like adding a per-fs function verify_credentials. So the actual mount
would proceed, if
- the current uid is 0 or
- the fs driver in question supports the verify_credentials operation
and calling it returns true and the current user has write permissions
for the mount point.
If this is implemented, smbmount could loose its s-bit, or at least
drop the checks that lead to races.

Regards,
Martin

\
 
 \ /
  Last update: 2005-03-22 13:39    [W:0.192 / U:23.956 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site