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, 26 Oct 2006 21:37:41 -0700
From:	Andrew Morton <akpm@...l.org>
To:	Heiko Carstens <heiko.carstens@...ibm.com>
Cc:	linux-kernel@...r.kernel.org
Subject: Re: [patch 1/5] binfmt: fix uaccess handling

On Thu, 26 Oct 2006 15:01:46 +0200
Heiko Carstens <heiko.carstens@...ibm.com> wrote:

> @@ -254,7 +255,8 @@
>  	p = current->mm->arg_end = current->mm->arg_start;
>  	while (argc-- > 0) {
>  		size_t len;
> -		__put_user((elf_addr_t)p, argv++);
> +		if (__put_user((elf_addr_t)p, argv++))
> +			return -EFAULT;
>  		len = strnlen_user((void __user *)p, PAGE_SIZE*MAX_ARG_PAGES);
>  		if (!len || len > PAGE_SIZE*MAX_ARG_PAGES)
>  			return 0;

We return EFAULT, but if strnlen_user() gets a fault, we return zero.  But
then, the return value of create_elf_tables() gets cheerfully ignored
anyway.  So I assume we start up some new program with a
partially-constructed environment and it then mysteriously malfunctions.

Nice, eh?
-
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