<br />

Added: 7

## **STRUCTS**

### Ipv4Address

*Defined in [fuchsia.net/net.fidl](https://cs.opensource.google/fuchsia/fuchsia/+/main:sdk/fidl/fuchsia.net/net.fidl;l=32)*

Ipv4Address is expressed in network byte order, so the most significant byte
("127" in the address "127.0.0.1") will be at index 0.

<br />

| Field | Type | Description | Default |
|---|---|---|---|
| `addr` | `array<uint8, 4>` |   | No default |

### Ipv4AddressWithPrefix

*Defined in [fuchsia.net/net.fidl](https://cs.opensource.google/fuchsia/fuchsia/+/main:sdk/fidl/fuchsia.net/net.fidl;l=69)*

An IPv4 address with its subnet prefix length.

<br />

| Field | Type | Description | Default |
|---|---|---|---|
| `addr` | `https://fuchsia.dev/reference/fidl/fuchsia.net#Ipv4Address` | The IPv4 address. | No default |
| `prefix_len` | `uint8` | The prefix length. Must be in the range \[0, 32\]. | No default |

### Ipv4SocketAddress

*Defined in [fuchsia.net/socket.fidl](https://cs.opensource.google/fuchsia/fuchsia/+/main:sdk/fidl/fuchsia.net/socket.fidl;l=11)*

An IPv4 socket address, composed of an IPv4 address and a port.

Inspired by the address definition in the [POSIX specification](https://pubs.opengroup.org/onlinepubs/9699919799/).

<br />

| Field | Type | Description | Default |
|---|---|---|---|
| `address` | `https://fuchsia.dev/reference/fidl/fuchsia.net#Ipv4Address` | IPv4 Address. | No default |
| `port` | `uint16` | Transport-layer port. | No default |

### Ipv6Address

*Defined in [fuchsia.net/net.fidl](https://cs.opensource.google/fuchsia/fuchsia/+/main:sdk/fidl/fuchsia.net/net.fidl;l=40)*

Ipv6Address is expressed in network byte order, so the most significant byte
("ff" in the address "ff02::1") will be at index 0.

<br />

| Field | Type | Description | Default |
|---|---|---|---|
| `addr` | `array<uint8, 16>` |   | No default |

### Ipv6AddressWithPrefix

*Defined in [fuchsia.net/net.fidl](https://cs.opensource.google/fuchsia/fuchsia/+/main:sdk/fidl/fuchsia.net/net.fidl;l=78)*

An IPv6 address with its subnet prefix length.

<br />

| Field | Type | Description | Default |
|---|---|---|---|
| `addr` | `https://fuchsia.dev/reference/fidl/fuchsia.net#Ipv6Address` | The IPv6 address. | No default |
| `prefix_len` | `uint8` | The prefix length. Must be in the range \[0, 128\]. | No default |

### Ipv6SocketAddress

*Defined in [fuchsia.net/socket.fidl](https://cs.opensource.google/fuchsia/fuchsia/+/main:sdk/fidl/fuchsia.net/socket.fidl;l=23)*

An IPV6 socket address, composed of an IPv6 address, a port, and a scope identifier.

Inspired by the address definition in the [POSIX specification](https://pubs.opengroup.org/onlinepubs/9699919799/).

<br />

| Field | Type | Description | Default |
|---|---|---|---|
| `address` | `https://fuchsia.dev/reference/fidl/fuchsia.net#Ipv6Address` | IPv6 Address. | No default |
| `port` | `uint16` | Transport-layer port. | No default |
| `zone_index` | `https://fuchsia.dev/reference/fidl/fuchsia.net#InterfaceId` | Provides a means to identify to which zone a non-global address belongs. A node may have interfaces attached to different zones of the same scope, for example different link-local zones are disambiguated by the use of a `zone_index` providing the interface identifier. `zone_index` 0 is the default zone. See [RFC 4007](https://tools.ietf.org/html/rfc4007) for terminology and examples. | No default |

### MacAddress

*Defined in [fuchsia.net/net.fidl](https://cs.opensource.google/fuchsia/fuchsia/+/main:sdk/fidl/fuchsia.net/net.fidl;l=87)*

A MAC address used to identify a network interface on the data link layer within the network.

<br />

| Field | Type | Description | Default |
|---|---|---|---|
| `octets` | `array<uint8, 6>` |   | No default |

### Subnet

*Defined in [fuchsia.net/net.fidl](https://cs.opensource.google/fuchsia/fuchsia/+/main:sdk/fidl/fuchsia.net/net.fidl;l=56)*

An IP address with its subnet prefix length.

<br />

| Field | Type | Description | Default |
|---|---|---|---|
| `addr` | `https://fuchsia.dev/reference/fidl/fuchsia.net#IpAddress` | The IPv4 or IPv6 address. | No default |
| `prefix_len` | `uint8` | The number of bits set to 1 in the subnet mask. When [addr](https://fuchsia.dev/reference/fidl/fuchsia.net#addr) is [IpAddress.ipv4](https://fuchsia.dev/reference/fidl/fuchsia.net#IpAddress.ipv4), must be in the range `[0, 32]`. When [addr](https://fuchsia.dev/reference/fidl/fuchsia.net#addr) is [IpAddress.ipv6](https://fuchsia.dev/reference/fidl/fuchsia.net#IpAddress.ipv6), must be in the range `[0, 128]`. | No default |

## **ENUMS**

### IpVersion [strict](https://fuchsia.dev/fuchsia-src/reference/fidl/language/language#strict-vs-flexible)

Type: `uint32`

*Defined in [fuchsia.net/net.fidl](https://cs.opensource.google/fuchsia/fuchsia/+/main:sdk/fidl/fuchsia.net/net.fidl;l=25)*

IpVersion is an IP version.

<br />

| Name | Value | Description |
|---|---|---|
| ### V4 | `1` |   |
| ### V6 | `2` |   |

### MarkDomain [strict](https://fuchsia.dev/fuchsia-src/reference/fidl/language/language#strict-vs-flexible)

Type: `uint8`

*Defined in [fuchsia.net/net.fidl](https://cs.opensource.google/fuchsia/fuchsia/+/main:sdk/fidl/fuchsia.net/net.fidl;l=99)*

Domains for a mark. This allows multiple marks to be set and retrieved
independently.
Added: HEAD

<br />

| Name | Value | Description |
|---|---|---|
| ### MARK_1 | `1` |   |
| ### MARK_2 | `2` |   |

## **TABLES**

### Marks

*Defined in [fuchsia.net/net.fidl](https://cs.opensource.google/fuchsia/fuchsia/+/main:sdk/fidl/fuchsia.net/net.fidl;l=119)*

Includes all the marks the platform supports.
Added: HEAD

<br />

| Ordinal | Field | Type | Description |
|---|---|---|---|
| ### 1 | `mark_1` | `https://fuchsia.dev/reference/fidl/fuchsia.net#Mark` | The mark in the `MARK_1` domain. |
| ### 2 | `mark_2` | `https://fuchsia.dev/reference/fidl/fuchsia.net#Mark` | The mark in the `MARK_2` domain. |

## **UNIONS**

### IpAddress [strict](https://fuchsia.dev/fuchsia-src/reference/fidl/language/language#strict-vs-flexible)

*Defined in [fuchsia.net/net.fidl](https://cs.opensource.google/fuchsia/fuchsia/+/main:sdk/fidl/fuchsia.net/net.fidl;l=48)*

Represents an IP address that may be either v4 or v6.

| Ordinal | Variant | Type | Description |
|---|---|---|---|
| ### 1 | `ipv4` | `https://fuchsia.dev/reference/fidl/fuchsia.net#Ipv4Address` |   |
| ### 2 | `ipv6` | `https://fuchsia.dev/reference/fidl/fuchsia.net#Ipv6Address` |   |

<br />

### SocketAddress [strict](https://fuchsia.dev/fuchsia-src/reference/fidl/language/language#strict-vs-flexible)

*Defined in [fuchsia.net/socket.fidl](https://cs.opensource.google/fuchsia/fuchsia/+/main:sdk/fidl/fuchsia.net/socket.fidl;l=44)*

Represents an IP socket address that may be either v4 or v6.

| Ordinal | Variant | Type | Description |
|---|---|---|---|
| ### 1 | `ipv4` | `https://fuchsia.dev/reference/fidl/fuchsia.net#Ipv4SocketAddress` |   |
| ### 2 | `ipv6` | `https://fuchsia.dev/reference/fidl/fuchsia.net#Ipv6SocketAddress` |   |

<br />

## **CONSTANTS**

| Name | Value | Type | Description |
|---|---|---|---|
| [MARK_DOMAIN_SOCKET_UID](https://cs.opensource.google/fuchsia/fuchsia/+/main:sdk/fidl/fuchsia.net/net.fidl;l=114) | Fuchsia does not have UIDs, we use the `MARK_2` domain mark to store the UID of the process that created the sockets when the socket was created by a process running in Starnix. This mark should be left unset otherwise. Added: HEAD |
| [MARK_DOMAIN_SO_MARK](https://cs.opensource.google/fuchsia/fuchsia/+/main:sdk/fidl/fuchsia.net/net.fidl;l=108) | `MARK_1` domain is used to store the `SO_MARK` value set by Starnix processes. If a mark in this domain is absent, it will be reported to applications as a `0` since that is the default mark value on Linux. Added: HEAD |
| [MAX_HOSTNAME_SIZE](https://cs.opensource.google/fuchsia/fuchsia/+/main:sdk/fidl/fuchsia.net/net.fidl;l=9) | `255` | `uint64` | The maximum length of a hostname, as per [RFC 1035 section 2.3.4](https://tools.ietf.org/html/rfc1035#section-2.3.4). |

## **ALIASES**

| Name | Value | Description |
|---|---|---|
| [Hostname](https://cs.opensource.google/fuchsia/fuchsia/+/main:sdk/fidl/fuchsia.net/net.fidl;l=18) | `string`\[`https://fuchsia.dev/reference/fidl/fuchsia.net#MAX_HOSTNAME_SIZE`\] | A hostname. Although the maximum length of a domain or hostname is 255 characters, each label within a name must not be longer than 63 characters as per [RFC 1035 section 2.3.4](https://tools.ietf.org/html/rfc1035#section-2.3.4). A label in a host name is the alphanumeric characters or hyphens, seperated by a period (e.g. abc.com has two labels, 'abc' and 'com'). |
| [InterfaceId](https://cs.opensource.google/fuchsia/fuchsia/+/main:sdk/fidl/fuchsia.net/net.fidl;l=21) | `uint64` | A unique non-zero interface identifier. |
| [Mark](https://cs.opensource.google/fuchsia/fuchsia/+/main:sdk/fidl/fuchsia.net/net.fidl;l=94) | `uint32` | A mark that is used to make route decisions and can be attached to packets. Added: HEAD |
| [RouteMetric](https://cs.opensource.google/fuchsia/fuchsia/+/main:sdk/fidl/fuchsia.net/net.fidl;l=127) | `uint32` | The metric of a route. Lower metrics indicate higher priority. |