tech-toolchain archive

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

Re: Fixing $ORGIN RPATHs - at least some of them



On Tue, Nov 07, 2017 at 12:23:13AM +0100, Kamil Rytarowski wrote:
 > Can we kill vnode_to_path() from sys/uvm/uvm_map.c? This one is
 > problematic in existing software. There is need to alter programs using
 > sanitizer to not break (shorten filenames). 

I don't understand what you mean, or why programs using sanitizers in
userland care whether this exists in the kernel.

 > This perhaps would mean to attach a path name to a vnode entry.

That's a big change. Remember, it's not just one path but potentially
many, or in some cases none, and in order to be reliable/useful they
have to be updated correctly when rename(2) happens.

Linux has this because they have a first-class namecache; this is a
direction I think we should go in the long term, but getting there is
not a small project.

It also does not solve the problem this thread is concerned with,
because given a vnode you can't tell which path you think you want
from it.

 > How to deal with resolution of the exec name under chroot (program
 > called chroot(2) during execution)? I think that returning the original
 > path might be wrong.

I think that's the program's own problem to deal with.

 > 1. Return failure (ENOTSUP?).

ENOTSUP is something POSIX made up recently. The correct error would
ENOENT.

-- 
David A. Holland
dholland%netbsd.org@localhost


Home | Main Index | Thread Index | Old Index