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:	Thu, 28 Apr 2016 11:02:14 +0200
From:	Ingo Molnar <mingo@...nel.org>
To:	Kees Cook <keescook@...omium.org>
Cc:	Yinghai Lu <yinghai@...nel.org>, Baoquan He <bhe@...hat.com>,
	Borislav Petkov <bp@...e.de>, Ingo Molnar <mingo@...hat.com>,
	"x86@...nel.org" <x86@...nel.org>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Andrey Ryabinin <aryabinin@...tuozzo.com>,
	Dmitry Vyukov <dvyukov@...gle.com>,
	"H.J. Lu" <hjl.tools@...il.com>,
	Josh Poimboeuf <jpoimboe@...hat.com>,
	Andy Lutomirski <luto@...nel.org>,
	LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v2] x86/boot: Rename overlapping memcpy() to memmove()


* Kees Cook <keescook@...omium.org> wrote:

> Instead of having non-standard memcpy() behavior, explicitly call the new
> function memmove(), make it available to the decompressors, and switch
> the two overlap cases (screen scrolling and ELF parsing) to use memmove().
> Additionally documents the purpose of compressed/string.c.
> 
> Suggested-by: Lasse Collin <lasse.collin@...aani.org>
> Signed-off-by: Kees Cook <keescook@...omium.org>
> ---
> Applies on top of tip:x86/boot
> ---
>  arch/x86/boot/compressed/misc.c   |  6 ++++--
>  arch/x86/boot/compressed/string.c | 19 +++++++++++--------
>  2 files changed, 15 insertions(+), 10 deletions(-)
> 
> diff --git a/arch/x86/boot/compressed/misc.c b/arch/x86/boot/compressed/misc.c
> index c57d785ff955..6dde6ccdf00e 100644
> --- a/arch/x86/boot/compressed/misc.c
> +++ b/arch/x86/boot/compressed/misc.c
> @@ -32,9 +32,11 @@
>  #undef memcpy
>  #undef memset
>  #define memzero(s, n)	memset((s), 0, (n))
> +#define memmove		memmove

Btw., what's the purpose of this define? If it's already defined then we should 
get a build warning. If it's not, we won't.

Anyway, applied it, just curious.

Thanks,

	Ingo

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ