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

Re: suid-perl



According to Michael Stone:
> Quoting Chip Salzenberg (chip@perlsupport.com):
> > According to Michael Stone:
> > > Quoting Wichert Akkerman (wakkerma@cs.leidenuniv.nl):
> > > > What perl-suid should do is check the mountoptions for the filesystem on
> > > > which the script resides and abort if that was mounted with nosuid.
> > > > Should be quite simple actually..
> > > 
> > > But that's still not general enough. For example, you just missed the
> > > case of noexec... The solution should be done at a higher level, IMHO...
> > 
> > Every OS has a different set of mount options that may or may not be
> > relevant to setuid security.  I don't see what 'higher level' would be
> > useful.
> 
> Well, maybe I'm not clear on what you/wichert would do instead. How are
> you going to check this? 

The code exists to check the mount options relevant to an open file.
It's just a Small Matter of Programming to integrate that into the
Perl source code, and disable emultation of setuid scripts when the
'nosuid' mount option is set.

And as for 'noexec', well, it's not relevant to Perl anyway.  (All you
have to do is run "perl scriptname" instead of just "./scriptname".)
Or do you suggest that every single language compiler/interpreter must
check mount options?  Should Java .class files be unusable if they're
on a 'noexec' filesystem?  I don't _think_ so.
-- 
Chip Salzenberg      - a.k.a. -      <chip@perlsupport.com>
      "When do you work?"   "Whenever I'm not busy."


Reply to: