From: Jean Tourrilhes <jt@bougret.hpl.hp.com>
To: Alexey Kuznetsov <kuznet@ms2.inr.ac.ru>, Andi Kleen <ak@muc.de>,
Alan Cox <alan@lxorguk.ukuu.org.uk>,
Jeff Garzik <jgarzik@mandrakesoft.com>,
Linux kernel mailing list <linux-kernel@vger.kernel.org>
Subject: Multicast netlink for non-root process
Date: Tue, 11 Jun 2002 13:44:18 -0700 [thread overview]
Message-ID: <20020611134418.A22893@bougret.hpl.hp.com> (raw)
Hi,
I'm developping an application that need to monitor every
network interface of the system. Network interfaces are
virtual/dynamic and go up and down all the time, so to keep track of
my interface list, I'm listening for RTM_NEWLINK events on the
RTnetLink socket (RTMGRP_LINK multicast group).
Problem : this works only as ROOT.
And my mother told me that having my application running as
root is bad for my health.
The cause is here :
----------- net/netlink/af_netlink.c - l322 ------------------
static int netlink_bind(struct socket *sock, struct sockaddr *addr, int addr_len)
{
[...]
/* Only superuser is allowed to listen multicasts */
if (nladdr->nl_groups && !capable(CAP_NET_ADMIN))
return -EPERM;
--------------------------------------------------------------
Why ?
Why ?
Why ?
Have a good day...
Jean
next reply other threads:[~2002-06-11 20:44 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-06-11 20:44 Jean Tourrilhes [this message]
[not found] <20020611134418.A22893@bougret.hpl.hp.com.suse.lists.linux.kernel>
2002-06-11 21:02 ` Andi Kleen
2002-06-11 21:13 ` Jean Tourrilhes
2002-06-11 21:23 ` Andi Kleen
2002-06-11 21:40 ` kuznet
2002-06-11 23:31 ` Andi Kleen
2002-06-11 23:55 ` Jean Tourrilhes
2002-06-12 4:25 ` James Morris
2002-06-12 17:25 ` kuznet
2002-06-12 17:45 ` James Morris
2002-06-12 17:54 ` kuznet
2002-06-12 22:53 ` David S. Miller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20020611134418.A22893@bougret.hpl.hp.com \
--to=jt@bougret.hpl.hp.com \
--cc=ak@muc.de \
--cc=alan@lxorguk.ukuu.org.uk \
--cc=jgarzik@mandrakesoft.com \
--cc=jt@hpl.hp.com \
--cc=kuznet@ms2.inr.ac.ru \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®