Thread (43 messages) flat view 43 messages, 5 authors, 2017-09-22

Re: [kernel-hardening] Re: [PATCH v3 03/31] usercopy: Mark kmalloc caches as usercopy caches

From: Christopher Lameter <hidden>
Date: 2017-09-21 16:04:35
Also in: linux-fsdevel, linux-mm, linux-xfs, lkml

On Thu, 21 Sep 2017, Kees Cook wrote:
quoted
So what is the point of this patch?
The DMA kmalloc caches are not whitelisted:
The DMA kmalloc caches are pretty obsolete and mostly there for obscure
drivers.

??
quoted
quoted
                        kmalloc_dma_caches[i] = create_kmalloc_cache(n,
-                               size, SLAB_CACHE_DMA | flags);
+                               size, SLAB_CACHE_DMA | flags, 0, 0);
So this is creating the distinction between the kmallocs that go to
userspace and those that don't. The expectation is that future work
can start to distinguish between "for userspace" and "only kernel"
kmalloc allocations, as is already done here for DMA.
The creation of the kmalloc caches in earlier patches already setup the
"whitelisting". Why do it twice?
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help