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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Fri, 8 Apr 2016 08:56:27 +0200
From:	John Einar Reitan <john.reitan@...s.arm.com>
To:	Laura Abbott <labbott@...hat.com>
Cc:	gregkh@...uxfoundation.org, arve@...roid.com,
	devel@...verdev.osuosl.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] ion: scatterlist offset not used for buffer map

On Thu, Apr 07, 2016 at 12:37:50PM -0700, Laura Abbott wrote:
> On 04/07/2016 04:29 AM, John Einar Reitan wrote:
> > ion's default user/kernel page mapping code don't honor the offset
> > option for scatterlists. It uses sg_page and expect the whole page to be
> > mapped, while the offset could dictate an offset within a large page.
> >
> > sg_phys correctly accounts for the offset, so should be used instead.
> >
> 
> Can you be more specific about which heap and which allocation pattern
> is exposing this bug?

The heap that exposed the bug is one I'm developing and will be posting
as a RFC soon. It uses compound pages and an sub-divides it into surface
buffers. The ion buffers are configured to hold sgl's with the compound
page and the correct offset of the buffer, via 
sg_set_page(.., compound_page, .., offset_of_logical_buffer);

sg_phys/sg_virt  includes this offset, but if you poke the sg and extract
the page with sg_page yourself you must include this offset in your
calculations too.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ