NG_GIF(4)
β¨ NAME β¨
okay bestie, meet ng_gif β the generic tunnel interface netgraph node type π
and yup, this is the NG_GIF(4) page from the Kernel Interfaces Manual. itβs giving βtunnel interface but make it netgraph,β and honestly? iconic β¨
π οΈ SYNOPSIS π οΈ
#include <netgraph/ng_gif.h>
π¦ DESCRIPTION π¦
The ng_gif netgraph node type allows gif(4) interfaces to interact with the netgraph(4) networking subsystem π«Ά. literally the social glue.
Once the ng_gif module is loaded in the kernel, a node is automatically created for each gif(4) interface in the system β no manual spawning needed, it just happens π«. Each node will attempt to name itself with the same name as the associated interface. All ng_gif nodes are persistent for as long as the interface itself exists. main character energy: they stay as long as the interface does π.
Two hooks are supported: lower and orphans. The hook name divert may be used as an alias for lower, and is provided for compatibility with ng_ether(4). In reality the two names represent the same hook β same vibe, different label, iykyk π·οΈ.
The lower hook is a connection to the raw gif(4) device. When connected, all incoming packets are diverted out this hook. Writing to this hook results in a raw encapsulated packet being transmitted by the device. Normal outgoing packets are not affected by lower being connected. slay, outgoing traffic keeps doing its thing π
.
The orphans hook is equivalent to lower, except that only unrecognized packets (that would otherwise be discarded) are written to the hook, and normal incoming traffic is unaffected. At most one of orphans and lower may be connected at any time. pick one, bestie β they cannot both be connected π«.
In all cases, frames are raw packets with the address family of the packet attached to the front.
When no hooks are connected, packets flow normally upwards and downwards. no hooks? no drama, normal flow π.
πͺ HOOKS πͺ
This node type supports the following hooks:
lowerβ connection to the lower device link layer.orphansβ likelower, but only receives unrecognized packets.
π¬ CONTROL MESSAGES π¬
This node type supports only the generic control messages. thatβs it, thatβs the message π.
π§ͺ EXAMPLES π§ͺ
This command dumps all unrecognized packets received by the gif0 interface to standard output decoded in hex and ASCII:
nghook -a gif0: orphans
π SEE ALSO π
gif(4), netgraph(4), netintro(4), ifconfig(8), ngctl(8), nghook(8)
π AUTHORS π
Brooks Davis <brooks@FreeBSD.org>
xoxo, your fave manual bestie π this page is from Debian, dated September 18, 2001, and itβs the NG_GIF(4) manual β periodt π
π¦ where this page comes from
- freebsd 14.5: base 14.5
- freebsd 15.1: base 15.1
- nixpkgs unstable: source
- Copyright 2000 The Aerospace Corporation. All rights reserved
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms