From owner-freebsd-current Sat Feb 3 11:33:29 2001 Delivered-To: freebsd-current@freebsd.org Received: from harmony.village.org (rover.village.org [204.144.255.66]) by hub.freebsd.org (Postfix) with ESMTP id 1373037B4EC for ; Sat, 3 Feb 2001 11:33:06 -0800 (PST) Received: from harmony.village.org (localhost.village.org [127.0.0.1]) by harmony.village.org (8.11.1/8.11.1) with ESMTP id f13JWo961621; Sat, 3 Feb 2001 12:32:52 -0700 (MST) (envelope-from imp@harmony.village.org) Message-Id: <200102031932.f13JWo961621@harmony.village.org> To: Peter Wemm Subject: Re: DEVFS newbie... Cc: freebsd-current@FreeBSD.ORG In-reply-to: Your message of "Sat, 03 Feb 2001 09:48:56 PST." <200102031748.f13HmuW44694@mobile.wemm.org> References: <200102031748.f13HmuW44694@mobile.wemm.org> Date: Sat, 03 Feb 2001 12:32:50 -0700 From: Warner Losh Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG In message <200102031748.f13HmuW44694@mobile.wemm.org> Peter Wemm writes: : As bizzare as it sounds, I like Julian's hack for populating this stuff... : ie: use a hard link to propagate nodes to the jailed /dev. : : eg: mount -t devfs -o empty /home/jail/dev : ln /dev/null /home/jail/dev/null : ln /dev/zero /home/jail/dev/zero : ... : mount -u -o ro /home/jail/dev But you can't do hard links accross file systems. Or is that a hack of devfs to allow it, and if so does that create any other security problems. Recall the security implications of having procfs's 'file' file. He made a hard link to the file in question, and exposed many different classes of problem: unwanted disclosure, failure to take into account directory permissions, the ability to hard link to the file and execute it later (bad for setuid programs), etc. Warner To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message