| Main index | Section 4 | Options |
#include <netgraph/ng_iface.h>
An iface node has a single hook corresponding to each supported protocol. Packets transmitted via the interface flow out the corresponding protocol-specific hook. Similarly, packets received on a hook appear on the interface as packets received into the corresponding protocol stack. The currently supported protocols are IP and IPv6.
An iface node can be configured as a point-to-point interface or a broadcast interface. The configuration can only be changed when the interface is down. The default mode is point-to-point.
Iface nodes support the Berkeley Packet Filter (BPF).
| inet | |
| Transmission and reception of IP packets. | |
| inet6 | |
| Transmission and reception of IPv6 packets. | |
| NGM_IFACE_GET_IFNAME ( getifname) | |
| Returns the name of the associated interface as a NUL-terminated ASCII string. Normally this is the same as the name of the node. | |
| NGM_IFACE_GET_IFINDEX ( getifindex) | |
| Returns the global index of the associated interface as a 32 bit integer. | |
| NGM_IFACE_POINT2POINT ( point2point) | |
| Set the interface to point-to-point mode. The interface must not currently be up. | |
| NGM_IFACE_BROADCAST ( broadcast) | |
| Set the interface to broadcast mode. The interface must not currently be up. | |
Unlike most other node types, an iface node does not go away when all hooks have been disconnected; rather, and explicit NGM_SHUTDOWN control message is required.
| NG_IFACE (4) | July 31, 2020 |
| Main index | Section 4 | Options |
Please direct any comments about this manual page service to Ben Bullock. Privacy policy.
