[lkml]   [2015]   [Apr]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [GIT PULL] kdbus for 4.1-rc1

On Tue, Apr 21, 2015 at 4:27 PM, Michal Hocko <> wrote:
> On Tue 21-04-15 16:01:01, David Herrmann wrote:
>> On Tue, Apr 21, 2015 at 2:20 PM, Michal Hocko <> wrote:
>> > If for nothing else then the memcg reasons mentioned in
>> > other email ( If an
>> > untrusted user is allowed to hand over a shmem backed buffer which hasn't
>> > been charged yet (read faulted in) and then kdbus forced to fault it in
>> > a different user's context then you basically allow to hide memory
>> > allocations from the memcg. That is a clear show stopper.
>> >
>> > Or have I misunderstood the way how shmem buffers are used here?
>> you mentioned memcg, lets figure that out here. shmem buffers are
>> used as receive-buffers by kdbus peers. They are read-only to
>> user-space. All allocations are done by the kernel on message passing.
> OK, so the shmem buffer is allocated on the kernels behalf and under
> its control and no userspace can hand over one to kdbus. Do I get
> it right? If yes then the memcg escape I was describing above is
> not possible of course. This wasn't clear to me from the previous
> discussion. Thanks for the clarification!

Exactly. Much appreciated!


 \ /
  Last update: 2015-04-21 17:01    [W:0.054 / U:2.924 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site