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]
Message-ID: <56C77A53.6060708@zytor.com>
Date:	Fri, 19 Feb 2016 12:25:55 -0800
From:	"H. Peter Anvin" <hpa@...or.com>
To:	"Luis R. Rodriguez" <mcgrof@...nel.org>, tglx@...utronix.de,
	mingo@...hat.com, bp@...en8.de
Cc:	x86@...nel.org, linux-kernel@...r.kernel.org, luto@...capital.net,
	boris.ostrovsky@...cle.com, rusty@...tcorp.com.au,
	david.vrabel@...rix.com, konrad.wilk@...cle.com, mcb30@...e.org,
	jgross@...e.com, ming.lei@...onical.com,
	gregkh@...uxfoundation.org, arnd@...db.de,
	linux-arch@...r.kernel.org, linux@....linux.org.uk,
	benh@...nel.crashing.org, jbaron@...mai.com, ananth@...ibm.com,
	anil.s.keshavamurthy@...el.com, davem@...emloft.net,
	masami.hiramatsu.pt@...achi.com, andriy.shevchenko@...ux.intel.com,
	dwmw2@...radead.org, xen-devel@...ts.xensource.com
Subject: Re: [RFC v2 2/7] tables.h: add linker table support

On 02/19/2016 05:45 AM, Luis R. Rodriguez wrote:
> +
> +/**
> + * DOC: Regular linker linker table constructors
> + *
> + * Regular constructors are expected to be used for valid linker table entries.
> + * Valid uses of weak entries other than the beginning and is currently
> + * untested but should in theory work.
> + */
> +
> +/**
> + * LINKTABLE_TEXT - Declares a linker table entry for execution
> + *
> + * @name: linker table name
> + * @level: order level
> + *
> + * Declares a linker table to be used for execution.
> + */
> +#define LINKTABLE_TEXT(name, level)					\
> +	      __typeof__(name[0])					\
> +	      __attribute__((used,					\
> +			     __aligned__(LINKTABLE_ALIGNMENT(name)),	\
> +			     section(SECTION_TBL(SECTION_TEXT, name, level))))

I'm really confused by this.  Text should obviously be readonly, but I'm
not at all clear how this works here.

The issue with linktables for text is kind of confusing if nothing else;
Russel is right about that.  It doesn't prevent us from doing something
similar, but perhaps it ought to have a different name.

For one thing, priority level is meaningless for text, since it is not a
table that can be indexed into.

	-hpa

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ