lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Mon, 12 Jul 2010 22:56:40 +0530
From:	Srikar Dronamraju <srikar@...ux.vnet.ibm.com>
To:	Arnaldo Carvalho de Melo <acme@...radead.org>
Cc:	Peter Zijlstra <peterz@...radead.org>, Ingo Molnar <mingo@...e.hu>,
	Steven Rostedt <rostedt@...dmis.org>,
	Randy Dunlap <rdunlap@...otime.net>,
	Linus Torvalds <torvalds@...ux-foundation.org>,
	Christoph Hellwig <hch@...radead.org>,
	Masami Hiramatsu <masami.hiramatsu.pt@...achi.com>,
	Oleg Nesterov <oleg@...hat.com>,
	Mark Wielaard <mjw@...hat.com>,
	Mathieu Desnoyers <mathieu.desnoyers@...icios.com>,
	LKML <linux-kernel@...r.kernel.org>,
	Naren A Devaiah <naren.devaiah@...ibm.com>,
	Jim Keniston <jkenisto@...ux.vnet.ibm.com>,
	Frederic Weisbecker <fweisbec@...il.com>,
	"Frank Ch. Eigler" <fche@...hat.com>,
	Ananth N Mavinakayanahalli <ananth@...ibm.com>,
	Andrew Morton <akpm@...ux-foundation.org>,
	"Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>
Subject: Re: [PATCHv9 2.6.35-rc4-tip 10/13]  perf: Re-Add make_absolute_path

> 
> > Actually we dont need to convert malloc@...c-2.5.so to a
> > malloc@...b/libc.so.6. Because we can match the shortname of the dso. 
> 
> Humm, I see, it is path based, so the first libc-2.5.so that appears in
> the LD_LIBRARY_PATH equivalent used in this code will be user, is that
> right?

No,  As you might have got it by reading patch 11. I am trying to
reuse the thread/session elements and walk thro the maps in the
map_groups. So I dont need to bother on LD_LIBRARY_PATH.
> 
> I.e. if I'm testing some new libc-2.5.so that provides, say, private
> futexes while the one in my distro still doesn't have this feature, I'll
> have to specify the absolute name or make sure it is before the system's
> libc-2.5.so in the LD_LIBRARY_PATH, right?

We get to the right one, as we walk the list of dsos in the
threadlist. But we have an option of either giving a correct full path
or the shortname for the dso without any path. However right now the
shortname has to be unique i.e I cant use malloc@...c instead of
malloc@...c-2.5.so. I would think specifying full path will be the most
probable usage case. However if a person refers /proc/<pid>/maps,
specifying shortnames should also be easy.

> 
> > Problem will occur when users specifies a full path of the file.
> > Since the file can refer to a symbolic link and the dso will have just
> > the short name or the target file name. Here I am using
> > make_absolute_path to resolve to the target file.
> > Now we can then either check on dso full names or short names.
> > I have chosen to use the short name.
> 
> Humm, so what you want is one of:
> 
> realpath - return the canonicalized absolute pathname
> canonicalize_file_name -  return the canonicalized filename
> 
> Can you please check the man pages for both before we decide
> re-introducing make_absolute_path?

right, realpath is right choice, I will use it instead of this patch. 


--
Thanks and Regards
Srikar

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ