CAP_NETWORK_IOCTL(3N)CAP_NETWORK_IOCTL(3N)NAMEcap_network_ioctl - execute an I/O control operation with privilege
SYNOPSIS
#include <cap_net.h>
int cap_network_ioctl(int fd, int request, ...);
DESCRIPTIONcap_network_ioctl asserts appropriate privilege when executing an I/O
control operation.
If _POSIX_CAP is in effect, a process calling this function should have
the approriate capabilities, i.e. CAP_NETWORK_MGT and/or CAP_DEVICE_MGT
in its permitted capability set.
SUPPORTED REQUESTS
The following generic interface ioctls require CAP_NETWORK_MGT. Please
refer to netintro(7) for details on the usage.
SIOCSARP
SIOCDARP
SIOCSARPX
SIOCDARPX
SIOCIFISPSCTL
SIOCSIFMTU
SIOCSIFFLAGS
SIOCSIFSEND
SIOCSIFRECV
SIOCSIFMETRIC
SIOCADDMULTI
SIOCDELMULTI
SIOCSIFSTATS
SIOCSIFHEAD
SIOCSIFREACHABLE
SIOCSIFHLIM
SIOCSIFNDMTU
SIOCSIFADXMIT
SIOCSIFSEND
SIOCVIF
SIOCVIFMAP
SIOCVIFSTAT
DRIVER SPECIFIC IOCTLS
E-Plex 8-port Ethernet Interface
The following ioctls require CAP_NETWORK_MGT.
SIOC_EP_STO
SIOC_EP_POKE
SIOC_EP_EXEC
SIOC_EP_FET
Page 1
CAP_NETWORK_IOCTL(3N)CAP_NETWORK_IOCTL(3N)
SIOC_EP_SIGNAL
FDDI controller interface
The following ioctls require CAP_NETWORK_MGT.
SIOC_XPI_STO
SIOC_XPI_EXEC
SIOC_XPI_FET
SIOC_XPI_SIGNAL
Tigon3 gigabit ethernet driver interface
The following ioctls require both CAP_NETWORK_MGT and CAP_DEVICE_MGT. See
tg(7m) for more details on Tigon3 gigabit ethernet.
TGIOC_GET_CONFIGS
TGIOC_GET_TRACEMASK
TGIOC_SET_TRACEMASK
TGIOC_LINK_STATE
TGIOC_CLEAR_STATS
TGIOC_GET_NIC_STATS
TGIOC_DUMP_EEPROM
TGIOC_FORCE_INTERRUPT
TGIOC_GET_DVR_STATS
TGIOC_GET_STATE
TGIOC_IGNORE_LINKCHANGE
TGIOC_READ_PHY_REG
TGIOC_WRITE_PHY_REG
RETURN VALUEScap_network_ioctl returns 0 if successful, -1 otherwise.
ERRORS
EINVAL The requested operation is not supported.
Otherwise, cap_network_ioctl has the same error codes as ioctl(2).
SEE ALSOcapability(4), ioctl(2), sysconf(3c).
Page 2