NetBSD-Bugs archive

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

Re: kern/42420: $ORIGIN undefined on NetBSD

The following reply was made to PR kern/42420; it has been noted by GNATS.

From: David Laight <>
Subject: Re: kern/42420: $ORIGIN undefined on NetBSD
Date: Wed, 11 Jul 2012 07:53:37 +0100

 On Tue, Jul 10, 2012 at 06:36:25PM -0400, Christos Zoulas wrote:
 > On Jul 10,  9:25pm, (Austin English) wrote:
 > -- Subject: Re: kern/42420: $ORIGIN undefined on NetBSD
 > Look for #ifdef notyet in kern_exec.c and get rid of them
 > christos
 Maybe the kernel should be keeping a vnode reference of the directory
 a program was loaded on.
 Then something like open("//$ORIGIN/<path>"...) could be used.
 Or maybe openat() could have some magic fd numbers.
 Of course, you need to DTRT when a program chroots.
 If $ORIGIN is inside the chroot, $ORIGIN relative paths should still work
 (and if outside, must not).
 David Laight:

Home | Main Index | Thread Index | Old Index