lkml.org 
[lkml]   [2015]   [Mar]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRcceiving a generic netlink multicast - should be restricted to the root user?
From
I wrote a kernel module that sends generic Netlink multicasts, and
wrote a userland client using libmnl that receives them.

That all works fine, but my client works even when it's not the root user.

man 7 netlink says:

Only processes with an effective UID of 0 or the CAP_NET_ADMIN capability
may send or listen to a netlink multicast group.

The listen part of this is seemingly not true. I've tried this on
kernels 3.13 (Ubuntu 14.04), 2.6.32 (CentOS 6) and 2.6.18 (CentOS 5).

Is this a bug?

If not: I know that restricting receiving generic netlink commands
incoming to the kernel to being only from root is possible with
GENL_ADMIN_PERM flag, but is it possible to send multicasts from the
kernel that can only be received by root?

Thank you


\
 
 \ /
  Last update: 2015-03-07 03:21    [W:0.061 / U:0.188 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site