farp: Require CAP_NET_RAW capability to open AF_PACKET socket
This commit is contained in:
parent
6f15f5e632
commit
405f5ab9e9
|
@ -92,6 +92,12 @@ plugin_t *farp_plugin_create()
|
|||
{
|
||||
private_farp_plugin_t *this;
|
||||
|
||||
if (!lib->caps->keep(lib->caps, CAP_NET_RAW))
|
||||
{ /* required to open ARP socket (AF_PACKET) */
|
||||
DBG1(DBG_NET, "farp plugin requires CAP_NET_RAW capability");
|
||||
return NULL;
|
||||
}
|
||||
|
||||
INIT(this,
|
||||
.public = {
|
||||
.plugin = {
|
||||
|
|
Loading…
Reference in New Issue