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: <20081003004340.GF32682@tyan-ft48-01.lab.bos.redhat.com>
Date:	Fri, 3 Oct 2008 02:43:40 +0200
From:	Jakub Jelinek <jakub@...hat.com>
To:	Kees Cook <kees.cook@...onical.com>
Cc:	Roland McGrath <roland@...hat.com>, linux-kernel@...r.kernel.org,
	Ulrich Drepper <drepper@...hat.com>, libc-alpha@...rceware.org
Subject: Re: [PATCH] ELF: implement AT_RANDOM for future glibc use

On Thu, Oct 02, 2008 at 05:16:16PM -0700, Kees Cook wrote:
> @@ -196,6 +198,18 @@ create_elf_tables(struct linux_binprm *bprm, struct elfhdr *exec,
>  			return -EFAULT;
>  	}
>  
> +	rand_size = CONFIG_SECURITY_AUXV_RANDOM_SIZE * sizeof(unsigned long);

I believe you want sizeof (elf_addr_t) here instead.

> +	u_rand_bytes = NULL;
> +	if (rand_size) {
> +		unsigned char k_rand_bytes[CONFIG_SECURITY_AUXV_RANDOM_SIZE *
> +					   sizeof(unsigned long)];

And here too, because having a 64-bit kernel supply twice as much random
data to 32-bit programs as a 32-bit kernel would supply would be certainly
unexpected.

	Jakub
--
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