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-next>] [day] [month] [year] [list]
Date:	Sun, 15 Sep 2013 20:04:33 -0700
From:	Davidlohr Bueso <davidlohr@...com>
To:	Manfred Spraul <manfred@...orfullife.com>,
	Linus Torvalds <torvalds@...ux-foundation.org>,
	Andrew Morton <akpm@...ux-foundation.org>
Cc:	Rik van Riel <riel@...hat.com>, Mike Galbraith <efault@....de>,
	sedat.dilek@...il.com,
	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
	Davidlohr Bueso <davidlohr@...com>
Subject: [PATCH 0/4] ipc: shm and msg fixes

This patchset deals with the selinux and rmid races Manfred found on
the ipc scaling work that has been going on. It specifically addresses
shared mem and msg queues. While semaphores still need updated, I want
to make sure these are correct first. Also, Manfred had already sent out
a patchset that deals with a race in sem complex operations. So any changes
should be on top of his.

Patches 1 and 2 deal with shared memory.
Patches 3 and 4 deal with msg queues.
Specific details about each race and its fix are in the corresponding
patches.

Note that Linus suggested a good alternative to patches 1 and 3: use
kfree_rcu() and delay the freeing of the security structure. I would
much prefer that approach to doing security checks with the lock held,
but I want to leave the patches out and ready in case we go with the
later solution.

I have tested these patches with IPC testcases from LTP on both my
quad-core laptop and on a 64 core NUMA server. In both cases, voluntary
and forced preemption have passed the tests -- note that I was not able
to reproduce any of these bugs in the first case, so these tests were
mostly to make sure I didn't further introduce any other issues.

Manfred, could you please give me your feedback on these, as I'd like
to make sure I'm not doing anything stupid.

Davidlohr Bueso (4):
  ipc,shm: fix race with selinux
  ipc,shm: prevent race with rmid in shmat(2)
  ipc,msg: fix race with selinux
  ipc,msg: prevent race with rmid in msgsnd,msgrcv

 ipc/msg.c | 27 +++++++++++++++++++++------
 ipc/shm.c | 31 ++++++++++++++++++++++---------
 2 files changed, 43 insertions(+), 15 deletions(-)

-- 
1.7.11.7

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