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: <20160802095040.GC19251@leverpostej>
Date:	Tue, 2 Aug 2016 10:50:41 +0100
From:	Mark Rutland <mark.rutland@....com>
To:	Kees Cook <keescook@...omium.org>
Cc:	Linus Torvalds <torvalds@...ux-foundation.org>,
	Arnd Bergmann <arnd@...db.de>,
	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] lkdtm: Fix targets for objcopy usage

On Mon, Aug 01, 2016 at 02:25:48PM -0700, Kees Cook wrote:
> On Fri, Jul 29, 2016 at 2:37 AM, Mark Rutland <mark.rutland@....com> wrote:
> > Hi,
> >
> > On Thu, Jul 28, 2016 at 07:30:39PM -0700, Kees Cook wrote:
> >> The targets for lkdtm's objcopy were missing which caused them to always
> >> be rebuilt. This corrects the problem.
> >>
> >> Additionally, commit f8fa70f392fa ("arm64: localise Image objcopy flags")
> >> has landed now, so this removes the work-around for the global OBJCOPY
> >> flag setting.
> >>
> >> Reported-by: Linus Torvalds <torvalds@...ux-foundation.org>
> >> Signed-off-by: Kees Cook <keescook@...omium.org>
> >
> > With this applied, LKDTM builds fine for me on arm64, the redundant
> > rebuilds are gone, and the result appears to work. So FWIW:
> >
> > Tested-by: Mark Rutland <mark.rutland@....com>
> 
> Argh, it looks like ARM suffers the same global OBJCOPY problem, so
> I'm going to leave that change out. :(

:(

FWIW, I dropped a patch for ARM [1] in Russell's patch system [2]. Hopefully
that will be picked up during the v4.9 merge window.

Looking again, it appears a number of other arches might be affected:

[mark@...erpostej:~/src/linux]% git grep 'OBJCOPYFLAGS\s\+:=' -- arch/*/Makefile
arch/arm/Makefile:OBJCOPYFLAGS  :=-O binary -R .comment -S
arch/blackfin/Makefile:OBJCOPYFLAGS     := -O binary -R .note -R .comment -S
arch/cris/Makefile:OBJCOPYFLAGS := -O binary -R .note -R .comment -S
arch/ia64/Makefile:OBJCOPYFLAGS := --strip-all
arch/m32r/Makefile:OBJCOPYFLAGS := -O binary -R .note -R .comment -S
arch/metag/Makefile:OBJCOPYFLAGS                                := -O binary -R .note -R .comment -S
arch/mn10300/Makefile:OBJCOPYFLAGS      := -O binary -R .note -R .comment -R .GCC-command-line -R .note.gnu.build-id -S
arch/openrisc/Makefile:OBJCOPYFLAGS    := -O binary -R .note -R .comment -S
arch/s390/Makefile:OBJCOPYFLAGS := -O binary
arch/sh/Makefile:OBJCOPYFLAGS   := -O binary -R .note -R .note.gnu.build-id -R .comment \
arch/unicore32/Makefile:OBJCOPYFLAGS            := -O binary -R .note -R .note.gnu.build-id -R .comment -S

... so we probably need to fix up these first, regardless.

In the mean time, can we add the targets dependency, but leave the flags
work-around intact? 

Thanks,
Mark.

[1] http://lists.infradead.org/pipermail/linux-arm-kernel/2016-July/442974.html
[2] http://www.armlinux.org.uk/developer/patches/viewpatch.php?id=8588/1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ