mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Valdis.Kletnieks@vt.edu
To: dean gaudet <dean@arctic.org>
Cc: David Newall <david@davidnewall.com>, Mark Lord <lkml@rtr.ca>,
	Al Viro <viro@ftp.linux.org.uk>,
	Alexander Viro <viro@zeniv.linux.org.uk>,
	Andrew Morton <akpm@linux-foundation.org>,
	Linux Kernel <linux-kernel@vger.kernel.org>
Subject: Re: RFC: permit link(2) to work across --bind mounts ?
Date: Sat, 29 Dec 2007 22:43:52 -0500	[thread overview]
Message-ID: <25388.1198986232@turing-police.cc.vt.edu> (raw)
In-Reply-To: Your message of "Sat, 29 Dec 2007 12:40:47 PST." <alpine.DEB.0.999999.0712291239360.5207@twinlark.arctic.org>

[-- Attachment #1: Type: text/plain, Size: 1481 bytes --]

On Sat, 29 Dec 2007 12:40:47 PST, dean gaudet said:

> > See, this is where you show that you don't understand the system.  I'll
> > explain it, just once.  /var/home contains  home directories.  /var/log and
> > /var/home are on the same filesystem.  So /var/log/* can be linked to
> > /var/home/malicious, and that's just one of your basic misunderstandings.
> 
> yes you are on crack.
> 
> i told you i understand this exactly.  it's right there in the message 
> sent.

So... You understand that if /var/home and /var/log are on one file system,
you can hard-link, and you set your system up knowing that, and then you're
*surprised* that:

> the main worry i have is some user maliciously hardlinks everything
> under /var/log somewhere else and slowly fills up the file system with
> old rotated logs.

"Doctor, it hurts when I do this.." "Well, don't do that then".

I think the first time I saw the recommendation "Put /home on its own
filesystem and don't give users directly writable directories on /var (except
via set-uid helpers) so they can't play hardlink games" back in 1983 or so.
I know that when SunOS 3.1 came out, that was already well-understood basic
sysadmining.  Sometimes, there's actual good reasons behind 20-year-old
voodoo.. ;)

You sure you don't want to redesign your filesystem layout so you don't
have to worry about your malicious users hardlinking stuff? Might be a lot
easier than trying to get the kernel to do what you want in this case....


[-- Attachment #2: Type: application/pgp-signature, Size: 226 bytes --]

  reply	other threads:[~2007-12-30  3:44 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-18 22:46 Mark Lord
2007-12-18 22:57 ` Mark Lord
2007-12-18 23:00 ` Al Viro
2007-12-18 23:14   ` Al Viro
2007-12-19  3:54     ` Mark Lord
2007-12-19  3:59       ` David Newall
2007-12-19 16:47         ` Mark Lord
2007-12-19 18:38           ` David Newall
2007-12-29  2:53         ` dean gaudet
2007-12-29  3:31           ` Jan Engelhardt
2007-12-29  6:02             ` dean gaudet
2007-12-29  6:48               ` Jan Engelhardt
2007-12-29  8:29           ` David Newall
2007-12-29 16:18             ` dean gaudet
2007-12-29 20:35               ` David Newall
2007-12-29 20:40                 ` dean gaudet
2007-12-30  3:43                   ` Valdis.Kletnieks [this message]
2007-12-30  3:55                     ` dean gaudet
2007-12-27  3:43 ` Rogelio M. Serrano Jr.
     [not found] <9BTqk-2ck-31@gated-at.bofh.it>
     [not found] ` <9BTJN-2Sv-21@gated-at.bofh.it>
     [not found]   ` <9BTTr-35L-13@gated-at.bofh.it>
2007-12-19 13:43     ` Bodo Eggert
2007-12-19 14:23       ` Al Viro
2007-12-19 15:42         ` Johannes Weiner
2007-12-19 16:44         ` Mark Lord
2007-12-20 20:55         ` Bodo Eggert
2007-12-20  1:33 linux
2007-12-20  2:06 ` Mark Lord

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=25388.1198986232@turing-police.cc.vt.edu \
    --to=valdis.kletnieks@vt.edu \
    --cc=akpm@linux-foundation.org \
    --cc=david@davidnewall.com \
    --cc=dean@arctic.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lkml@rtr.ca \
    --cc=viro@ftp.linux.org.uk \
    --cc=viro@zeniv.linux.org.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®