Skip to content

Commit

Permalink
pohmelfs/connector: Disallow unpliviged users to configure pohmelfs
Browse files Browse the repository at this point in the history
Signed-off-by: Philipp Reisner <philipp.reisner@linbit.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Philipp Reisner authored and David S. Miller committed Oct 2, 2009
1 parent 5788c56 commit 98a5783
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions drivers/staging/pohmelfs/config.c
Original file line number Diff line number Diff line change
Expand Up @@ -531,6 +531,9 @@ static void pohmelfs_cn_callback(struct cn_msg *msg, struct netlink_skb_parms *n
{
int err;

if (!cap_raised(nsp->eff_cap, CAP_SYS_ADMIN))
return;

switch (msg->flags) {
case POHMELFS_FLAGS_ADD:
case POHMELFS_FLAGS_DEL:
Expand Down

0 comments on commit 98a5783

Please sign in to comment.