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] [day] [month] [year] [list]
Date:	Tue, 5 May 2015 14:43:28 +0200
From:	Anisse Astier <anisse@...ier.eu>
To:	PaX Team <pageexec@...email.hu>
Cc:	Andrew Morton <akpm@...ux-foundation.org>,
	Mel Gorman <mgorman@...e.de>,
	"Kirill A. Shutemov" <kirill.shutemov@...ux.intel.com>,
	David Rientjes <rientjes@...gle.com>,
	Alan Cox <gnomes@...rguk.ukuu.org.uk>,
	Linus Torvalds <torvalds@...ux-foundation.org>,
	Peter Zijlstra <peterz@...radead.org>,
	Brad Spengler <spender@...ecurity.net>,
	Kees Cook <keescook@...omium.org>,
	Andi Kleen <andi@...stfloor.org>, linux-mm@...ck.org,
	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v2 4/4] mm: Add debug code for SANITIZE_FREED_PAGES

On Mon, May 4, 2015 at 11:50 PM, PaX Team <pageexec@...email.hu> wrote:
> On 4 May 2015 at 23:16, Anisse Astier wrote:
>
>> diff --git a/mm/page_alloc.c b/mm/page_alloc.c
>> index c29e3a0..ba8aa25 100644
>> --- a/mm/page_alloc.c
>> +++ b/mm/page_alloc.c
>> @@ -975,6 +975,31 @@ static int prep_new_page(struct page *page, unsigned int order, gfp_t gfp_flags,
>>               for (i = 0; i < (1 << order); i++)
>>                       clear_highpage(page + i);
>>  #endif
>> +#ifdef CONFIG_SANITIZE_FREED_PAGES_DEBUG
>> +     for (i = 0; i < (1 << order); i++) {
>> +             struct page *p = page + i;
>> +             int j;
>> +             bool err = false;
>> +             void *kaddr = kmap_atomic(p);
>> +
>> +             for (j = 0; j < PAGE_SIZE; j++) {
>
> did you mean to use memchr_inv(kaddr, 0, PAGE_SIZE) instead? ;)

Will be fixed in v3, although as I said I'm not sure if this debug
code should go in or not.

Thanks for you time.

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