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, 11 Oct 2007 01:18:00 -0700
From:	Andrew Morton <akpm@...ux-foundation.org>
To:	Jiri Kosina <jkosina@...e.cz>
Cc:	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] [RESEND] i386 and x86_64: randomize brk()

On Tue, 11 Sep 2007 14:17:24 +0200 (CEST) Jiri Kosina <jkosina@...e.cz> wrote:

> i386 and x86_64: randomize brk()

I seem to have a different copy of this patch from the one which you
originally sent.  It's the one which implements arch_randomize_brk() in
each arch's header file.  Mayeb it wasn't cc'ed to a mailing list of maybe
I just lost the email, dunno.

Anyway, it breaks on ia64:

  CC      arch/ia64/ia32/binfmt_elf32.o
In file included from arch/ia64/ia32/binfmt_elf32.c:49:
arch/ia64/ia32/../../../fs/binfmt_elf.c: In function `load_elf_binary':
arch/ia64/ia32/../../../fs/binfmt_elf.c:1085: error: implicit declaration of function `arch_randomize_brk'
make[1]: *** [arch/ia64/ia32/binfmt_elf32.o] Error 1
make: *** [arch/ia64/ia32/binfmt_elf32.o] Error 2

This is because ia64 takes the exceptional stupidity which is our
elf-handling build system and adds an extra layer of stupidity on top of
it.  Look:

akpm2:/usr/src/25> head include/asm-ia64/elf.h
#ifndef _ASM_IA64_ELF_H
#define _ASM_IA64_ELF_H

/*
 * ELF-specific definitions.
 *
 * Copyright (C) 1998-1999, 2002-2004 Hewlett-Packard Co
 *      David Mosberger-Tang <davidm@....hp.com>
 */

akpm2:/usr/src/25> grep -r _ASM_IA64_ELF_H arch/ia64
arch/ia64/ia32/ia32priv.h:#define _ASM_IA64_ELF_H               /* Don't include elf.h */

can you believe this stuff?

Anyway, I'm presently running with this loveliness:


--- a/include/asm-ia64/elf.h~i386-and-x86_64-randomize-brk-2-fix
+++ a/include/asm-ia64/elf.h
@@ -249,8 +249,10 @@ do {									\
 
 #endif /* __KERNEL__ */
 
+#endif /* _ASM_IA64_ELF_H */
+
+#ifndef IA64_IS_WEIRD
 static inline void arch_randomize_brk(void)
 {
 }
-
-#endif /* _ASM_IA64_ELF_H */
+#endif
_

Wanna see if there's something saner we can do please?
-
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