From owner-freebsd-audit Tue Jun 19 11:42:20 2001 Delivered-To: freebsd-audit@freebsd.org Received: from ringworld.nanolink.com (ringworld.nanolink.com [195.24.48.13]) by hub.freebsd.org (Postfix) with SMTP id 3958A37B401 for ; Tue, 19 Jun 2001 11:42:13 -0700 (PDT) (envelope-from roam@orbitel.bg) Received: (qmail 5337 invoked by uid 1000); 19 Jun 2001 18:40:41 -0000 Date: Tue, 19 Jun 2001 21:40:41 +0300 From: Peter Pentchev To: Terry Lambert Cc: John Baldwin , arch@FreeBSD.ORG, audit@FreeBSD.ORG Subject: Re: new kldpath(8): display/modify the module search path Message-ID: <20010619214041.E3535@ringworld.oblivion.bg> Mail-Followup-To: Terry Lambert , John Baldwin , arch@FreeBSD.ORG, audit@FreeBSD.ORG References: <3B2F958E.BC556A1E@mindspring.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <3B2F958E.BC556A1E@mindspring.com>; from tlambert2@mindspring.com on Tue, Jun 19, 2001 at 11:10:22AM -0700 Sender: owner-freebsd-audit@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Tue, Jun 19, 2001 at 11:10:22AM -0700, Terry Lambert wrote: > John Baldwin wrote: > > To me, it seems more sensible to use the same interface that > > ldconfig uses. > > Noooooooooooooooooooooooooooooooooooooooooooooooooooooooooo! > > ldconfig is a serious pain in the ass, ever since the "fix" > that made it not look in the linkage or configured directories > on a lookup miss. > > This is particularly aggregious if you have a "/opt" or some > other place where you prefer to install your ports or locally > developed software. Uh.. Terry.. have you even looked to check what this new kldconfig thing is supposed to do? :) kldconfig(8) does not traverse any directories; it just modifies a list of paths. As other posters in this thread have made me believe, it doesn't even need to check for the existence of the paths. The only kind of path traversing in the KLD case is done at module-load time, by the linker_search_path() function in sys/kern/kern_linker.c, invoked by kldload() syscall defined in the same file. It is there that any kind of checks should be made (currently none, though I plan on addressing this soon, in a very-very-very simple way, if Robert Watson doesn't do his MAC thing first :). kldconfig(8) just reads a sysctl value, parses it into a list of paths, parses some user-specified options, adds or removes paths as appropriate, and sets the sysctl value back. G'luck, Peter -- This sentence is false. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-audit" in the body of the message