summaryrefslogtreecommitdiff
path: root/static/freebsd/man4/inet.4 3.html
diff options
context:
space:
mode:
Diffstat (limited to 'static/freebsd/man4/inet.4 3.html')
-rw-r--r--static/freebsd/man4/inet.4 3.html271
1 files changed, 0 insertions, 271 deletions
diff --git a/static/freebsd/man4/inet.4 3.html b/static/freebsd/man4/inet.4 3.html
deleted file mode 100644
index e1c7551a..00000000
--- a/static/freebsd/man4/inet.4 3.html
+++ /dev/null
@@ -1,271 +0,0 @@
-<table class="head">
- <tr>
- <td class="head-ltitle">INET(4)</td>
- <td class="head-vol">Device Drivers Manual</td>
- <td class="head-rtitle">INET(4)</td>
- </tr>
-</table>
-<div class="manual-text">
-<section class="Sh">
-<h1 class="Sh" id="NAME"><a class="permalink" href="#NAME">NAME</a></h1>
-<p class="Pp"><code class="Nm">inet</code> &#x2014; <span class="Nd">Internet
- protocol family</span></p>
-</section>
-<section class="Sh">
-<h1 class="Sh" id="SYNOPSIS"><a class="permalink" href="#SYNOPSIS">SYNOPSIS</a></h1>
-<p class="Pp"><code class="In">#include
- &lt;<a class="In">sys/types.h</a>&gt;</code>
- <br/>
- <code class="In">#include &lt;<a class="In">netinet/in.h</a>&gt;</code></p>
-</section>
-<section class="Sh">
-<h1 class="Sh" id="DESCRIPTION"><a class="permalink" href="#DESCRIPTION">DESCRIPTION</a></h1>
-<p class="Pp">The Internet protocol family is a collection of protocols layered
- atop the
- <a class="permalink" href="#Internet"><i class="Em" id="Internet">Internet
- Protocol</i></a> (IP) transport layer, and utilizing the Internet address
- format. The Internet family provides protocol support for the
- <code class="Dv">SOCK_STREAM</code>, <code class="Dv">SOCK_DGRAM</code>, and
- <code class="Dv">SOCK_RAW</code> socket types; the
- <code class="Dv">SOCK_RAW</code> interface provides access to the IP
- protocol.</p>
-</section>
-<section class="Sh">
-<h1 class="Sh" id="ADDRESSING"><a class="permalink" href="#ADDRESSING">ADDRESSING</a></h1>
-<p class="Pp">Internet addresses are four byte quantities, stored in network
- standard format (on little endian machines, such as the alpha, amd64 and
- i386 these are word and byte reversed). The include file
- <code class="In">&lt;<a class="In">netinet/in.h</a>&gt;</code> defines this
- address as a discriminated union.</p>
-<p class="Pp">Sockets bound to the Internet protocol family utilize the
- following addressing structure,</p>
-<div class="Bd Pp Bd-indent Li">
-<pre>struct sockaddr_in {
- uint8_t sin_len;
- sa_family_t sin_family;
- in_port_t sin_port;
- struct in_addr sin_addr;
- char sin_zero[8];
-};</pre>
-</div>
-<p class="Pp">Sockets may be created with the local address
- <code class="Dv">INADDR_ANY</code> to affect &#x201C;wildcard&#x201D;
- matching on incoming messages. The address in a <a class="Xr">connect(2)</a>
- or <a class="Xr">sendto(2)</a> call may be given as
- <code class="Dv">INADDR_ANY</code> to mean &#x201C;this host&#x201D;. The
- distinguished address <code class="Dv">INADDR_BROADCAST</code> is allowed as
- a shorthand for the broadcast address on the primary network if the first
- network configured supports broadcast.</p>
-</section>
-<section class="Sh">
-<h1 class="Sh" id="PROTOCOLS"><a class="permalink" href="#PROTOCOLS">PROTOCOLS</a></h1>
-<p class="Pp">The Internet protocol family is comprised of the IP network
- protocol, Internet Control Message Protocol (ICMP), Internet Group
- Management Protocol (IGMP), Transmission Control Protocol (TCP), and User
- Datagram Protocol (UDP). TCP is used to support the
- <code class="Dv">SOCK_STREAM</code> abstraction while UDP is used to support
- the <code class="Dv">SOCK_DGRAM</code> abstraction. A raw interface to IP is
- available by creating an Internet socket of type
- <code class="Dv">SOCK_RAW</code>. The ICMP message protocol is accessible
- from a raw socket.</p>
-<p class="Pp">The <code class="Nm">inet</code> address on an interface consist
- of the address itself, the netmask, either broadcast address in case of a
- broadcast interface or peers address in case of point-to-point interface.
- The following <a class="Xr">ioctl(2)</a> commands are provided for a
- datagram socket in the Internet domain:</p>
-<p class="Pp"></p>
-<div class="Bd-indent">
-<dl class="Bl-tag Bl-compact">
- <dt id="SIOCAIFADDR"><a class="permalink" href="#SIOCAIFADDR"><code class="Dv">SIOCAIFADDR</code></a></dt>
- <dd>Add address to an interface. The command requires <var class="Ft">struct
- in_aliasreq</var> as argument.</dd>
- <dt id="SIOCDIFADDR"><a class="permalink" href="#SIOCDIFADDR"><code class="Dv">SIOCDIFADDR</code></a></dt>
- <dd>Delete address from an interface. The command requires
- <var class="Ft">struct ifreq</var> as argument.</dd>
- <dt id="SIOCGIFADDR"><a class="permalink" href="#SIOCGIFADDR"><code class="Dv">SIOCGIFADDR</code></a></dt>
- <dd style="width: auto;">&#x00A0;</dd>
- <dt id="SIOCGIFBRDADDR"><a class="permalink" href="#SIOCGIFBRDADDR"><code class="Dv">SIOCGIFBRDADDR</code></a></dt>
- <dd style="width: auto;">&#x00A0;</dd>
- <dt id="SIOCGIFDSTADDR"><a class="permalink" href="#SIOCGIFDSTADDR"><code class="Dv">SIOCGIFDSTADDR</code></a></dt>
- <dd style="width: auto;">&#x00A0;</dd>
- <dt id="SIOCGIFNETMASK"><a class="permalink" href="#SIOCGIFNETMASK"><code class="Dv">SIOCGIFNETMASK</code></a></dt>
- <dd>Return address information from interface. The returned value is in
- <var class="Ft">struct ifreq</var>. This way of address information
- retrieval is obsoleted, a preferred way is to use
- <a class="Xr">getifaddrs(3)</a> API.</dd>
-</dl>
-</div>
-<section class="Ss">
-<h2 class="Ss" id="MIB_(sysctl)_Variables"><a class="permalink" href="#MIB_(sysctl)_Variables">MIB
- (sysctl) Variables</a></h2>
-<p class="Pp">In addition to the variables supported by the transport protocols
- in <var class="Va">net.inet</var> (for which the respective manual pages may
- be consulted), there are a number of general variables implemented in the
- <var class="Va">net.inet.ip</var> branch of the <a class="Xr">sysctl(3)</a>
- MIB, which can be also read or modified with <a class="Xr">sysctl(8)</a>.
- The following general variables are defined:</p>
-<dl class="Bl-tag">
- <dt id="accept_sourceroute"><var class="Va">accept_sourceroute</var></dt>
- <dd>Boolean: enable/disable accepting of source-routed IP packets (default
- false).</dd>
- <dt id="allow_net0"><var class="Va">allow_net0</var></dt>
- <dd>Boolean: allow forwarding of, and ICMP responses to, packets with
- addresses in 0.0.0.0/8.</dd>
- <dt id="allow_net240"><var class="Va">allow_net240</var></dt>
- <dd>Boolean: allow forwarding of, and ICMP responses to, packets with
- addresses in 240.0.0.0/4.</dd>
- <dt id="curfrags"><var class="Va">curfrags</var></dt>
- <dd>Integer: Current number of IPv4 fragments across all reassembly queues in
- all VNETs (read-only).</dd>
- <dt id="forwarding"><var class="Va">forwarding</var></dt>
- <dd>Boolean: enable/disable forwarding of IP packets. Defaults to off.</dd>
- <dt id="fragpackets"><var class="Va">fragpackets</var></dt>
- <dd>Integer: Current number of IPv4 fragment reassembly queue entries for the
- VNET (read-only).</dd>
- <dt id="fragttl"><var class="Va">fragttl</var></dt>
- <dd>Integer: time to live for IPv4 packet fragments in the per-VNET reassemby
- queue.</dd>
- <dt id="loopback_prefixlen"><var class="Va">loopback_prefixlen</var></dt>
- <dd>Integer: prefix length of the address space reserved for loopback
- purposes. The default is 8, meaning that 127.0.0.0/8 is reserved for
- loopback, and cannot be sent, received, or forwarded on a non-loopback
- interface. Use of other values is experimental.</dd>
- <dt id="maxfragbucketsize"><var class="Va">maxfragbucketsize</var></dt>
- <dd>Integer: maximum number of reassembly queues per bucket. Fragmented
- packets are hashed to buckets. Each bucket has a list of reassembly
- queues. The system must compare the incoming packets to the existing
- reassembly queues in the bucket to find a matching reassembly queue. To
- preserve system resources, the system limits the number of reassembly
- queues allowed in each bucket. This limit is recalculated when the number
- of mbuf clusters is changed or when the value of
- <var class="Va">maxfragpackets</var> changes. This is a per-VNET
- limit.</dd>
- <dt id="maxfragpackets"><var class="Va">maxfragpackets</var></dt>
- <dd>Integer: maximum number of fragmented packets the host will accept and
- simultaneously hold in the reassembly queue for a particular VNET. 0 means
- that the host will not accept any fragmented packets for that VNET. -1
- means that the host will not apply this limit for that VNET. This limit is
- recalculated when the number of mbuf clusters is changed. This is a
- per-VNET limit.</dd>
- <dt id="maxfrags"><var class="Va">maxfrags</var></dt>
- <dd>Integer: maximum number of fragments the host will accept and
- simultaneously hold across all reassembly queues in all VNETs. If set to
- 0, reassembly is disabled. If set to -1, this limit is not applied. This
- limit is recalculated when the number of mbuf clusters is changed. This is
- a global limit.</dd>
- <dt id="maxfragsperpacket"><var class="Va">maxfragsperpacket</var></dt>
- <dd>Integer: maximum number of fragments the host will accept and hold in the
- reassembly queue for a packet. 0 means that the host will not accept any
- fragmented packets for the VNET. This is a per-VNET limit.</dd>
- <dt id="mcast"><var class="Va">mcast</var></dt>
- <dd>Variables under the <var class="Va">net.inet.ip.mcast</var> node are
- documented in <a class="Xr">ip(4)</a>.</dd>
- <dt id="no_same_prefix"><var class="Va">no_same_prefix</var></dt>
- <dd>Boolean: Refuse to create same prefixes on different interfaces. This is a
- per-VNET value.</dd>
- <dt id="portrange"><var class="Va">portrange</var></dt>
- <dd>Variables under the <var class="Va">net.inet.ip.portrange</var> node
- control port ranges used by transport protocols; see
- <a class="Xr">ip(4)</a> for details.</dd>
- <dt id="process_options"><var class="Va">process_options</var></dt>
- <dd>Integer: control IP options processing. By setting this variable to 0, all
- IP options in the incoming packets will be ignored, and the packets will
- be passed unmodified. By setting to 1, IP options in the incoming packets
- will be processed accordingly. By setting to 2, an ICMP &#x201C;prohibited
- by filter&#x201D; message will be sent back in response to incoming
- packets with IP options. Default is 1. This <a class="Xr">sysctl(8)</a>
- variable affects packets destined for a local host as well as packets
- forwarded to some other host.</dd>
- <dt id="random_id"><var class="Va">random_id</var></dt>
- <dd>Boolean: control IP IDs generation behavior. Setting this
- <a class="Xr">sysctl(8)</a> to 1 causes the ID field in
- <a class="permalink" href="#non-atomic"><i class="Em" id="non-atomic">non-atomic</i></a>
- IP datagrams (or all IP datagrams, if <var class="Va">rfc6864</var> is
- disabled) to be randomized instead of incremented by 1 with each packet
- generated. This closes a minor information leak which allows remote
- observers to determine the rate of packet generation on the machine by
- watching the counter. At the same time, on high-speed links, it can
- decrease the ID reuse cycle greatly. Default is 0 (sequential IP IDs).
- IPv6 flow IDs and fragment IDs are always random.</dd>
- <dt id="random_id_collisions"><var class="Va">random_id_collisions</var></dt>
- <dd>Integer: count of IP ID collisions (read-only, per-VNET).</dd>
- <dt id="random_id_period"><var class="Va">random_id_period</var></dt>
- <dd>Integer: size of the IP ID array, which is the number of previous packets
- for which the IDs are recorded. The number must be between 512 and 32768
- inclusive. This is a per-VNET value.</dd>
- <dt id="random_id_total"><var class="Va">random_id_total</var></dt>
- <dd>Integer: count of IP IDs created (read-only, per-VNET).</dd>
- <dt id="reass_hashsize"><var class="Va">reass_hashsize</var></dt>
- <dd>Number of hash slots in the IPv4 reassembly queue (loader tunable).</dd>
- <dt id="redirect"><var class="Va">redirect</var></dt>
- <dd>Boolean: enable/disable sending of ICMP redirects in response to IP
- packets for which a better, and for the sender directly reachable, route
- and next hop is known. Defaults to on.</dd>
- <dt id="rfc1122_strong_es"><var class="Va">rfc1122_strong_es</var></dt>
- <dd>Boolean: in non-forwarding mode (forwarding is disabled) partially
- implement the Strong End System model per RFC1122. If a packet with
- destination address that is local arrives on a different interface than
- the interface the address belongs to, the packet would be silently
- dropped. Enabling this option may break certain setups, e.g. having an
- alias address(es) on loopback that are expected to be reachable by outside
- traffic. Enabling some other network features, e.g.
- <a class="Xr">carp(4)</a> or destination address rewriting
- <a class="Xr">pfil(4)</a> filters may override and bypass this check.
- Disabled by default.</dd>
- <dt id="rfc6864"><var class="Va">rfc6864</var></dt>
- <dd>Boolean: control IP IDs generation behaviour. True value enables RFC6864
- support, which specifies that IP ID field of
- <a class="permalink" href="#atomic"><i class="Em" id="atomic">atomic</i></a>
- datagrams can be set to any value. The <span class="Ux">FreeBSD
- implementation</span> sets it to zero. Enabled by default.</dd>
- <dt id="source_address_validation"><var class="Va">source_address_validation</var></dt>
- <dd>Boolean: perform source address validation for packets destined for the
- local host. Consider this as following Section 3.2 of RFC3704/BCP84, where
- we treat local host as our own infrastructure. Forwarded packets are
- unaffected by this and it should not be considered an anti-spoof feature
- for a router. Enabled by default.</dd>
- <dt id="sourceroute"><var class="Va">sourceroute</var></dt>
- <dd>Boolean: enable/disable forwarding of source-routed IP packets (default
- false).</dd>
- <dt id="ttl"><var class="Va">ttl</var></dt>
- <dd>Integer: default time-to-live (&#x201C;TTL&#x201D;) to use for outgoing IP
- packets.</dd>
-</dl>
-</section>
-</section>
-<section class="Sh">
-<h1 class="Sh" id="SEE_ALSO"><a class="permalink" href="#SEE_ALSO">SEE
- ALSO</a></h1>
-<p class="Pp"><a class="Xr">ioctl(2)</a>, <a class="Xr">socket(2)</a>,
- <a class="Xr">getifaddrs(3)</a>, <a class="Xr">sysctl(3)</a>,
- <a class="Xr">icmp(4)</a>, <a class="Xr">intro(4)</a>,
- <a class="Xr">ip(4)</a>, <a class="Xr">ipfirewall(4)</a>,
- <a class="Xr">route(4)</a>, <a class="Xr">tcp(4)</a>,
- <a class="Xr">udp(4)</a>, <a class="Xr">sysctl(8)</a>,
- <a class="Xr">pfil(9)</a></p>
-<p class="Pp"><cite class="Rs"><span class="RsT">An Introductory 4.3 BSD
- Interprocess Communication Tutorial</span>, <i class="RsB">PS1</i>,
- <span class="RsN">7</span>.</cite></p>
-<p class="Pp"><cite class="Rs"><span class="RsT">An Advanced 4.3 BSD
- Interprocess Communication Tutorial</span>, <i class="RsB">PS1</i>,
- <span class="RsN">8</span>.</cite></p>
-</section>
-<section class="Sh">
-<h1 class="Sh" id="HISTORY"><a class="permalink" href="#HISTORY">HISTORY</a></h1>
-<p class="Pp">The <code class="Nm">inet</code> protocol interface appeared in
- <span class="Ux">4.2BSD</span>. The &#x201C;protocol cloning&#x201D; code
- appeared in <span class="Ux">FreeBSD 2.1</span>.</p>
-</section>
-<section class="Sh">
-<h1 class="Sh" id="CAVEATS"><a class="permalink" href="#CAVEATS">CAVEATS</a></h1>
-<p class="Pp">The Internet protocol support is subject to change as the Internet
- protocols develop. Users should not depend on details of the current
- implementation, but rather the services exported.</p>
-</section>
-</div>
-<table class="foot">
- <tr>
- <td class="foot-date">December 31, 2024</td>
- <td class="foot-os">FreeBSD 15.0</td>
- </tr>
-</table>