lkml.org 
[lkml]   [1996]   [Dec]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: Proposal: restrict link(2)

    amethyst@valjean.sfhs.floyd.k12.ky.us (Neil Moore) wrote on 13.12.96 in <199612131959.OAA00216@valjean.sfhs.floyd.k12.ky.us>:

    > it. Changing the kernel to get around userland bugs is a Bad
    > Thing. Not only does it bloat the kernel, but it causes Linux
    > programmers to assume that the files they are accessing will not
    > be hard links to things they shouldn't be messing with -- which
    > is okay, until the program runs under an earlier kernel, or gets
    > ported to another Unix. When this happens, these assumptions
    > blow up, and we end up with a program as buggy (on another oper-
    > ating system) as the ones we are concerned about right now. All
    > the broken userland programs need to be changed, *not* the kernel.

    Here's another idea. It's probably not good enough as-is, but maybe
    someone can improve it - or show why it is a dumb idea to begin with.

    As I see it, the main problem is that everybody uses /tmp for temporary
    files, including priviledged programs. That is, priviledged programs are
    using a directory where every user can mess around.

    Now, a priviledged program is a program running with root as one of its
    various uids - or maybe (for an even stricter definition) also a program
    running with two or more different uids.

    Now, the idea - have a mount option that restricts priviledged programs
    from using files in directories (like /tmp) that have the t bit set. (I
    hope I'm not confusing those bits here ...)

    This will force those programs to be rewritten to use safer areas for
    their temp files.

    Of course, as-is, this will break a lot of stuff, and not all of it stuff
    that should break, for example:

    * how would we clean out /tmp?
    * root may have trouble reading mail, or using any odd program that does
    temp files in /tmp - then again, those programs _are_ unsafe.


    MfG Kai

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