This YANG module provides a Netgate-defined data-model for Network Address Translation data.
Copyright 2017-2020 Rubicon Communications, LLC.
Network Address Translation (NAT) data needed to support VPP.
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:nat-config": {
- "netgate-nat:global-options": {
- "netgate-nat:timeouts": {
- "netgate-nat:udp": 0,
- "netgate-nat:tcp_established": 0,
- "netgate-nat:icmp": 0,
- "netgate-nat:tcp_transitory": 0
}, - "netgate-nat:nat44": {
- "netgate-nat:out2in-dpo": true,
- "netgate-nat:max-translations-per-thread": 128000,
- "netgate-nat:max-users-per-thread": 0,
- "netgate-nat:static-mapping-only": true,
- "netgate-nat:endpoint-dependent": true,
- "netgate-nat:max-translations-per-user": 0,
- "netgate-nat:forwarding-enabled": true,
- "netgate-nat:enabled": false
}
}, - "netgate-nat:ipfix": {
- "netgate-nat:logging": {
- "netgate-nat:enable": true,
- "netgate-nat:src-port": 4739,
- "netgate-nat:domain": 1
}
}, - "netgate-nat:dynamic": {
- "netgate-nat:pool-if-table": {
- "netgate-nat:if-entry": [
- {
- "netgate-nat:if-name": "string",
- "netgate-nat:twice-nat": true
}
]
}, - "netgate-nat:pool-table": {
- "netgate-nat:pool-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:first-address": "string",
- "netgate-nat:last-address": "string",
- "netgate-nat:twice-nat": true
}
]
}
}, - "netgate-nat:static": {
- "netgate-nat:mapping-table": {
- "netgate-nat:mapping-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:external-if-name": "string",
- "netgate-nat:external-port": "string",
- "netgate-nat:local-port": "string",
- "netgate-nat:external-address": "string",
- "netgate-nat:transport-protocol": "icmp",
- "netgate-nat:out-to-in-only": true,
- "netgate-nat:twice-nat": true,
- "netgate-nat:local-address": "string"
}
]
}
}, - "netgate-nat:nat64": {
- "netgate-map:map": {
- "netgate-nat:parameters": {
- "netgate-nat:tcp": {
- "netgate-nat:mss": 0
}, - "netgate-nat:security-check": {
- "netgate-nat:enable": true,
- "netgate-nat:fragments": true
}, - "netgate-nat:fragment": {
- "netgate-nat:inner": true,
- "netgate-nat:ignore-df": true
}, - "netgate-nat:traffic-class": {
- "netgate-nat:copy": true,
- "netgate-nat:tc": 0
}, - "netgate-nat:icmp": {
- "netgate-nat:source-address": "string"
}, - "netgate-nat:pre-resolve": {
- "netgate-nat:ipv4": {
- "netgate-nat:next-hop": "string"
}, - "netgate-nat:ipv6": {
- "netgate-nat:next-hop": "string"
}
}, - "netgate-nat:icmp6": {
- "netgate-nat:unreachables": true
}
}, - "netgate-nat:map-domains": {
- "netgate-nat:domain": [
- {
- "netgate-nat:psid-offset": 0,
- "netgate-nat:ea-bits-length": 0,
- "netgate-nat:ip6-src-prefix": "string",
- "netgate-nat:ip4-prefix": "string",
- "netgate-nat:name": "string",
- "netgate-nat:description": "string",
- "netgate-nat:rules": {
- "netgate-nat:rule": [
- {
- "netgate-nat:ip6-destination": null,
- "netgate-nat:psid": null
}
]
}, - "netgate-nat:psid-length": 0,
- "netgate-nat:ip6-prefix": "string",
- "netgate-nat:mtu": 0
}
]
}
}
}
}
}
Network Address Translation (NAT) data needed to support VPP.
netgate.nat.NatConfig to be added to list
object (netgate.nat.natconfig.GlobalOptions) NAT global options | |
object (netgate.nat.natconfig.Ipfix) IPFIX information. | |
object (netgate.nat.natconfig.Dynamic) Dynamic mapping information. | |
object (netgate.nat.natconfig.Static) Static mapping information. | |
object (netgate.nat.natconfig.Nat64) NAT for IPv6/IPv4. |
{- "netgate-nat:global-options": {
- "netgate-nat:timeouts": {
- "netgate-nat:udp": 0,
- "netgate-nat:tcp_established": 0,
- "netgate-nat:icmp": 0,
- "netgate-nat:tcp_transitory": 0
}, - "netgate-nat:nat44": {
- "netgate-nat:out2in-dpo": true,
- "netgate-nat:max-translations-per-thread": 128000,
- "netgate-nat:max-users-per-thread": 0,
- "netgate-nat:static-mapping-only": true,
- "netgate-nat:endpoint-dependent": true,
- "netgate-nat:max-translations-per-user": 0,
- "netgate-nat:forwarding-enabled": true,
- "netgate-nat:enabled": false
}
}, - "netgate-nat:ipfix": {
- "netgate-nat:logging": {
- "netgate-nat:enable": true,
- "netgate-nat:src-port": 4739,
- "netgate-nat:domain": 1
}
}, - "netgate-nat:dynamic": {
- "netgate-nat:pool-if-table": {
- "netgate-nat:if-entry": [
- {
- "netgate-nat:if-name": "string",
- "netgate-nat:twice-nat": true
}
]
}, - "netgate-nat:pool-table": {
- "netgate-nat:pool-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:first-address": "string",
- "netgate-nat:last-address": "string",
- "netgate-nat:twice-nat": true
}
]
}
}, - "netgate-nat:static": {
- "netgate-nat:mapping-table": {
- "netgate-nat:mapping-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:external-if-name": "string",
- "netgate-nat:external-port": "string",
- "netgate-nat:local-port": "string",
- "netgate-nat:external-address": "string",
- "netgate-nat:transport-protocol": "icmp",
- "netgate-nat:out-to-in-only": true,
- "netgate-nat:twice-nat": true,
- "netgate-nat:local-address": "string"
}
]
}
}, - "netgate-nat:nat64": {
- "netgate-map:map": {
- "netgate-nat:parameters": {
- "netgate-nat:tcp": {
- "netgate-nat:mss": 0
}, - "netgate-nat:security-check": {
- "netgate-nat:enable": true,
- "netgate-nat:fragments": true
}, - "netgate-nat:fragment": {
- "netgate-nat:inner": true,
- "netgate-nat:ignore-df": true
}, - "netgate-nat:traffic-class": {
- "netgate-nat:copy": true,
- "netgate-nat:tc": 0
}, - "netgate-nat:icmp": {
- "netgate-nat:source-address": "string"
}, - "netgate-nat:pre-resolve": {
- "netgate-nat:ipv4": {
- "netgate-nat:next-hop": "string"
}, - "netgate-nat:ipv6": {
- "netgate-nat:next-hop": "string"
}
}, - "netgate-nat:icmp6": {
- "netgate-nat:unreachables": true
}
}, - "netgate-nat:map-domains": {
- "netgate-nat:domain": [
- {
- "netgate-nat:psid-offset": 0,
- "netgate-nat:ea-bits-length": 0,
- "netgate-nat:ip6-src-prefix": "string",
- "netgate-nat:ip4-prefix": "string",
- "netgate-nat:name": "string",
- "netgate-nat:description": "string",
- "netgate-nat:rules": {
- "netgate-nat:rule": [
- {
- "netgate-nat:ip6-destination": "string",
- "netgate-nat:psid": 0
}
]
}, - "netgate-nat:psid-length": 0,
- "netgate-nat:ip6-prefix": "string",
- "netgate-nat:mtu": 0
}
]
}
}
}
}
Network Address Translation (NAT) data needed to support VPP.
netgate.nat.NatConfig to be added or updated
object (netgate.nat.NatConfig) Network Address Translation (NAT) data needed to support VPP. |
{- "netgate-nat:nat-config": {
- "netgate-nat:global-options": {
- "netgate-nat:timeouts": {
- "netgate-nat:udp": 0,
- "netgate-nat:tcp_established": 0,
- "netgate-nat:icmp": 0,
- "netgate-nat:tcp_transitory": 0
}, - "netgate-nat:nat44": {
- "netgate-nat:out2in-dpo": true,
- "netgate-nat:max-translations-per-thread": 128000,
- "netgate-nat:max-users-per-thread": 0,
- "netgate-nat:static-mapping-only": true,
- "netgate-nat:endpoint-dependent": true,
- "netgate-nat:max-translations-per-user": 0,
- "netgate-nat:forwarding-enabled": true,
- "netgate-nat:enabled": false
}
}, - "netgate-nat:ipfix": {
- "netgate-nat:logging": {
- "netgate-nat:enable": true,
- "netgate-nat:src-port": 4739,
- "netgate-nat:domain": 1
}
}, - "netgate-nat:dynamic": {
- "netgate-nat:pool-if-table": {
- "netgate-nat:if-entry": [
- {
- "netgate-nat:if-name": "string",
- "netgate-nat:twice-nat": true
}
]
}, - "netgate-nat:pool-table": {
- "netgate-nat:pool-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:first-address": "string",
- "netgate-nat:last-address": "string",
- "netgate-nat:twice-nat": true
}
]
}
}, - "netgate-nat:static": {
- "netgate-nat:mapping-table": {
- "netgate-nat:mapping-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:external-if-name": "string",
- "netgate-nat:external-port": "string",
- "netgate-nat:local-port": "string",
- "netgate-nat:external-address": "string",
- "netgate-nat:transport-protocol": "icmp",
- "netgate-nat:out-to-in-only": true,
- "netgate-nat:twice-nat": true,
- "netgate-nat:local-address": "string"
}
]
}
}, - "netgate-nat:nat64": {
- "netgate-map:map": {
- "netgate-nat:parameters": {
- "netgate-nat:tcp": {
- "netgate-nat:mss": 0
}, - "netgate-nat:security-check": {
- "netgate-nat:enable": true,
- "netgate-nat:fragments": true
}, - "netgate-nat:fragment": {
- "netgate-nat:inner": true,
- "netgate-nat:ignore-df": true
}, - "netgate-nat:traffic-class": {
- "netgate-nat:copy": true,
- "netgate-nat:tc": 0
}, - "netgate-nat:icmp": {
- "netgate-nat:source-address": "string"
}, - "netgate-nat:pre-resolve": {
- "netgate-nat:ipv4": {
- "netgate-nat:next-hop": "string"
}, - "netgate-nat:ipv6": {
- "netgate-nat:next-hop": "string"
}
}, - "netgate-nat:icmp6": {
- "netgate-nat:unreachables": true
}
}, - "netgate-nat:map-domains": {
- "netgate-nat:domain": [
- {
- "netgate-nat:psid-offset": 0,
- "netgate-nat:ea-bits-length": 0,
- "netgate-nat:ip6-src-prefix": "string",
- "netgate-nat:ip4-prefix": "string",
- "netgate-nat:name": "string",
- "netgate-nat:description": "string",
- "netgate-nat:rules": {
- "netgate-nat:rule": [
- {
- "netgate-nat:ip6-destination": null,
- "netgate-nat:psid": null
}
]
}, - "netgate-nat:psid-length": 0,
- "netgate-nat:ip6-prefix": "string",
- "netgate-nat:mtu": 0
}
]
}
}
}
}
}
Network Address Translation (NAT) data needed to support VPP.
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/dynamic" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:dynamic": {
- "netgate-nat:pool-if-table": {
- "netgate-nat:if-entry": [
- {
- "netgate-nat:if-name": "string",
- "netgate-nat:twice-nat": true
}
]
}, - "netgate-nat:pool-table": {
- "netgate-nat:pool-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:first-address": "string",
- "netgate-nat:last-address": "string",
- "netgate-nat:twice-nat": true
}
]
}
}
}
Dynamic mapping information.
netgate.nat.natconfig.Dynamic to be added to list
object (netgate.nat.natconfig.dynamic.PoolIfTable) NAT interface pool table. | |
object (netgate.nat.natconfig.dynamic.PoolTable) NAT address pool table. |
{- "netgate-nat:pool-if-table": {
- "netgate-nat:if-entry": [
- {
- "netgate-nat:if-name": "string",
- "netgate-nat:twice-nat": true
}
]
}, - "netgate-nat:pool-table": {
- "netgate-nat:pool-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:first-address": "string",
- "netgate-nat:last-address": "string",
- "netgate-nat:twice-nat": true
}
]
}
}
Dynamic mapping information.
netgate.nat.natconfig.Dynamic to be added or updated
object (netgate.nat.natconfig.Dynamic) Dynamic mapping information. |
{- "netgate-nat:dynamic": {
- "netgate-nat:pool-if-table": {
- "netgate-nat:if-entry": [
- {
- "netgate-nat:if-name": "string",
- "netgate-nat:twice-nat": true
}
]
}, - "netgate-nat:pool-table": {
- "netgate-nat:pool-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:first-address": "string",
- "netgate-nat:last-address": "string",
- "netgate-nat:twice-nat": true
}
]
}
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/dynamic" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/dynamic/pool-if-table" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:pool-if-table": {
- "netgate-nat:if-entry": [
- {
- "netgate-nat:if-name": "string",
- "netgate-nat:twice-nat": true
}
]
}
}
NAT interface pool table.
netgate.nat.natconfig.dynamic.PoolIfTable to be added to list
Array of objects (netgate.nat.natconfig.dynamic.pooliftable.IfEntry) Dynamic pool interface entries. |
{- "netgate-nat:if-entry": [
- {
- "netgate-nat:if-name": "string",
- "netgate-nat:twice-nat": true
}
]
}
NAT interface pool table.
netgate.nat.natconfig.dynamic.PoolIfTable to be added or updated
object (netgate.nat.natconfig.dynamic.PoolIfTable) NAT interface pool table. |
{- "netgate-nat:pool-if-table": {
- "netgate-nat:if-entry": [
- {
- "netgate-nat:if-name": "string",
- "netgate-nat:twice-nat": true
}
]
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/dynamic/pool-if-table" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
Dynamic pool interface entries.
netgate.nat.natconfig.dynamic.pooliftable.IfEntry to be added to list
netgate-nat:if-name | string The name of an interface whose IPv4 addresses are added to the pool of addresses used in NAT mappings. |
netgate-nat:twice-nat | boolean Twice-nat address range for external hosts. |
{- "netgate-nat:if-name": "string",
- "netgate-nat:twice-nat": true
}
Dynamic pool interface entries.
if-name required | string Id of if-entry |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/dynamic/pool-if-table/if-entry=%7Bif-name%7D" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:if-entry": {
- "netgate-nat:if-name": "string",
- "netgate-nat:twice-nat": true
}
}
Dynamic pool interface entries.
if-name required | string Id of if-entry |
netgate.nat.natconfig.dynamic.pooliftable.IfEntry to be added or updated
object (netgate.nat.natconfig.dynamic.pooliftable.IfEntry) Dynamic pool interface entries. |
{- "netgate-nat:if-entry": {
- "netgate-nat:if-name": "string",
- "netgate-nat:twice-nat": true
}
}
Dynamic pool interface entries.
if-name required | string Id of if-entry |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/dynamic/pool-if-table/if-entry=%7Bif-name%7D" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/dynamic/pool-table" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:pool-table": {
- "netgate-nat:pool-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:first-address": "string",
- "netgate-nat:last-address": "string",
- "netgate-nat:twice-nat": true
}
]
}
}
NAT address pool table.
netgate.nat.natconfig.dynamic.PoolTable to be added to list
Array of objects (netgate.nat.natconfig.dynamic.pooltable.PoolEntry) NAT address range entry. |
{- "netgate-nat:pool-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:first-address": "string",
- "netgate-nat:last-address": "string",
- "netgate-nat:twice-nat": true
}
]
}
NAT address pool table.
netgate.nat.natconfig.dynamic.PoolTable to be added or updated
object (netgate.nat.natconfig.dynamic.PoolTable) NAT address pool table. |
{- "netgate-nat:pool-table": {
- "netgate-nat:pool-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:first-address": "string",
- "netgate-nat:last-address": "string",
- "netgate-nat:twice-nat": true
}
]
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/dynamic/pool-table" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
NAT address range entry.
netgate.nat.natconfig.dynamic.pooltable.PoolEntry to be added to list
netgate-nat:route-table-name | string The route table name. |
netgate-nat:first-address | string The first IPv4 address in the range. |
netgate-nat:last-address | string The last IPv4 address in the range. |
netgate-nat:twice-nat | boolean Twice-nat address range for external hosts. |
{- "netgate-nat:route-table-name": "string",
- "netgate-nat:first-address": "string",
- "netgate-nat:last-address": "string",
- "netgate-nat:twice-nat": true
}
NAT address range entry.
first-address required | string Id of pool-entry |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/dynamic/pool-table/pool-entry=%7Bfirst-address%7D" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:pool-entry": {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:first-address": "string",
- "netgate-nat:last-address": "string",
- "netgate-nat:twice-nat": true
}
}
NAT address range entry.
first-address required | string Id of pool-entry |
netgate.nat.natconfig.dynamic.pooltable.PoolEntry to be added or updated
object (netgate.nat.natconfig.dynamic.pooltable.PoolEntry) NAT address range entry. |
{- "netgate-nat:pool-entry": {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:first-address": "string",
- "netgate-nat:last-address": "string",
- "netgate-nat:twice-nat": true
}
}
NAT address range entry.
first-address required | string Id of pool-entry |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/dynamic/pool-table/pool-entry=%7Bfirst-address%7D" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/global-options" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:global-options": {
- "netgate-nat:timeouts": {
- "netgate-nat:udp": 0,
- "netgate-nat:tcp_established": 0,
- "netgate-nat:icmp": 0,
- "netgate-nat:tcp_transitory": 0
}, - "netgate-nat:nat44": {
- "netgate-nat:out2in-dpo": true,
- "netgate-nat:max-translations-per-thread": 128000,
- "netgate-nat:max-users-per-thread": 0,
- "netgate-nat:static-mapping-only": true,
- "netgate-nat:endpoint-dependent": true,
- "netgate-nat:max-translations-per-user": 0,
- "netgate-nat:forwarding-enabled": true,
- "netgate-nat:enabled": false
}
}
}
NAT global options
netgate.nat.natconfig.GlobalOptions to be added to list
object (netgate.nat.natconfig.globaloptions.Timeouts) NAT global timeouts | |
object (netgate.nat.natconfig.globaloptions.Nat44) NAT44 options |
{- "netgate-nat:timeouts": {
- "netgate-nat:udp": 0,
- "netgate-nat:tcp_established": 0,
- "netgate-nat:icmp": 0,
- "netgate-nat:tcp_transitory": 0
}, - "netgate-nat:nat44": {
- "netgate-nat:out2in-dpo": true,
- "netgate-nat:max-translations-per-thread": 128000,
- "netgate-nat:max-users-per-thread": 0,
- "netgate-nat:static-mapping-only": true,
- "netgate-nat:endpoint-dependent": true,
- "netgate-nat:max-translations-per-user": 0,
- "netgate-nat:forwarding-enabled": true,
- "netgate-nat:enabled": false
}
}
NAT global options
netgate.nat.natconfig.GlobalOptions to be added or updated
object (netgate.nat.natconfig.GlobalOptions) NAT global options |
{- "netgate-nat:global-options": {
- "netgate-nat:timeouts": {
- "netgate-nat:udp": 0,
- "netgate-nat:tcp_established": 0,
- "netgate-nat:icmp": 0,
- "netgate-nat:tcp_transitory": 0
}, - "netgate-nat:nat44": {
- "netgate-nat:out2in-dpo": true,
- "netgate-nat:max-translations-per-thread": 128000,
- "netgate-nat:max-users-per-thread": 0,
- "netgate-nat:static-mapping-only": true,
- "netgate-nat:endpoint-dependent": true,
- "netgate-nat:max-translations-per-user": 0,
- "netgate-nat:forwarding-enabled": true,
- "netgate-nat:enabled": false
}
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/global-options" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/global-options/nat44" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:nat44": {
- "netgate-nat:out2in-dpo": true,
- "netgate-nat:max-translations-per-thread": 128000,
- "netgate-nat:max-users-per-thread": 0,
- "netgate-nat:static-mapping-only": true,
- "netgate-nat:endpoint-dependent": true,
- "netgate-nat:max-translations-per-user": 0,
- "netgate-nat:forwarding-enabled": true,
- "netgate-nat:enabled": false
}
}
NAT44 options
netgate.nat.natconfig.globaloptions.Nat44 to be added to list
netgate-nat:out2in-dpo | boolean If 'true', out2in DPO is enabled. |
netgate-nat:max-translations-per-thread | integer <int64> Default: 128000 Maximum number of sessions per thread. |
netgate-nat:max-users-per-thread | integer <int64> Maximum number of users per thread. |
netgate-nat:static-mapping-only | boolean If 'true', static mapping only is enabled. |
netgate-nat:endpoint-dependent | boolean If 'true', endpoint-dependent mode is enabled. |
netgate-nat:max-translations-per-user | integer <int64> Maximum number of sessions per user. |
netgate-nat:forwarding-enabled | boolean NAT44 forwarding option. Used 'true' or 'false'. |
netgate-nat:enabled | boolean Default: false If 'true', NAT44 is enabled. |
{- "netgate-nat:out2in-dpo": true,
- "netgate-nat:max-translations-per-thread": 128000,
- "netgate-nat:max-users-per-thread": 0,
- "netgate-nat:static-mapping-only": true,
- "netgate-nat:endpoint-dependent": true,
- "netgate-nat:max-translations-per-user": 0,
- "netgate-nat:forwarding-enabled": true,
- "netgate-nat:enabled": false
}
NAT44 options
netgate.nat.natconfig.globaloptions.Nat44 to be added or updated
object (netgate.nat.natconfig.globaloptions.Nat44) NAT44 options |
{- "netgate-nat:nat44": {
- "netgate-nat:out2in-dpo": true,
- "netgate-nat:max-translations-per-thread": 128000,
- "netgate-nat:max-users-per-thread": 0,
- "netgate-nat:static-mapping-only": true,
- "netgate-nat:endpoint-dependent": true,
- "netgate-nat:max-translations-per-user": 0,
- "netgate-nat:forwarding-enabled": true,
- "netgate-nat:enabled": false
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/global-options/nat44" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/global-options/timeouts" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:timeouts": {
- "netgate-nat:udp": 0,
- "netgate-nat:tcp_established": 0,
- "netgate-nat:icmp": 0,
- "netgate-nat:tcp_transitory": 0
}
}
NAT global timeouts
netgate.nat.natconfig.globaloptions.Timeouts to be added to list
netgate-nat:udp | integer <int64> NAT UDP idle-timeout |
netgate-nat:tcp_established | integer <int64> NAT TCP established connection idle-timeout |
netgate-nat:icmp | integer <int64> NAT ICMP idle-timeout |
netgate-nat:tcp_transitory | integer <int64> NAT TCP transitory connection idle-timeout |
{- "netgate-nat:udp": 0,
- "netgate-nat:tcp_established": 0,
- "netgate-nat:icmp": 0,
- "netgate-nat:tcp_transitory": 0
}
NAT global timeouts
netgate.nat.natconfig.globaloptions.Timeouts to be added or updated
object (netgate.nat.natconfig.globaloptions.Timeouts) NAT global timeouts |
{- "netgate-nat:timeouts": {
- "netgate-nat:udp": 0,
- "netgate-nat:tcp_established": 0,
- "netgate-nat:icmp": 0,
- "netgate-nat:tcp_transitory": 0
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/global-options/timeouts" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/ipfix" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:ipfix": {
- "netgate-nat:logging": {
- "netgate-nat:enable": true,
- "netgate-nat:src-port": 4739,
- "netgate-nat:domain": 1
}
}
}
IPFIX information.
netgate.nat.natconfig.Ipfix to be added to list
object (netgate.nat.natconfig.ipfix.Logging) IPFIX logging information. |
{- "netgate-nat:logging": {
- "netgate-nat:enable": true,
- "netgate-nat:src-port": 4739,
- "netgate-nat:domain": 1
}
}
IPFIX information.
netgate.nat.natconfig.Ipfix to be added or updated
object (netgate.nat.natconfig.Ipfix) IPFIX information. |
{- "netgate-nat:ipfix": {
- "netgate-nat:logging": {
- "netgate-nat:enable": true,
- "netgate-nat:src-port": 4739,
- "netgate-nat:domain": 1
}
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/ipfix" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/ipfix/logging" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:logging": {
- "netgate-nat:enable": true,
- "netgate-nat:src-port": 4739,
- "netgate-nat:domain": 1
}
}
IPFIX logging information.
netgate.nat.natconfig.ipfix.Logging to be added to list
netgate-nat:enable | boolean If logging is enabled for this domain and port, this value will be true. |
netgate-nat:src-port | integer <int32> Default: 4739 The logging source port id. |
netgate-nat:domain | integer <int64> Default: 1 The logging domain id. |
{- "netgate-nat:enable": true,
- "netgate-nat:src-port": 4739,
- "netgate-nat:domain": 1
}
IPFIX logging information.
netgate.nat.natconfig.ipfix.Logging to be added or updated
object (netgate.nat.natconfig.ipfix.Logging) IPFIX logging information. |
{- "netgate-nat:logging": {
- "netgate-nat:enable": true,
- "netgate-nat:src-port": 4739,
- "netgate-nat:domain": 1
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/ipfix/logging" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/nat64" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:nat64": {
- "netgate-map:map": {
- "netgate-nat:parameters": {
- "netgate-nat:tcp": {
- "netgate-nat:mss": 0
}, - "netgate-nat:security-check": {
- "netgate-nat:enable": true,
- "netgate-nat:fragments": true
}, - "netgate-nat:fragment": {
- "netgate-nat:inner": true,
- "netgate-nat:ignore-df": true
}, - "netgate-nat:traffic-class": {
- "netgate-nat:copy": true,
- "netgate-nat:tc": 0
}, - "netgate-nat:icmp": {
- "netgate-nat:source-address": "string"
}, - "netgate-nat:pre-resolve": {
- "netgate-nat:ipv4": {
- "netgate-nat:next-hop": "string"
}, - "netgate-nat:ipv6": {
- "netgate-nat:next-hop": "string"
}
}, - "netgate-nat:icmp6": {
- "netgate-nat:unreachables": true
}
}, - "netgate-nat:map-domains": {
- "netgate-nat:domain": [
- {
- "netgate-nat:psid-offset": 0,
- "netgate-nat:ea-bits-length": 0,
- "netgate-nat:ip6-src-prefix": "string",
- "netgate-nat:ip4-prefix": "string",
- "netgate-nat:name": "string",
- "netgate-nat:description": "string",
- "netgate-nat:rules": {
- "netgate-nat:rule": [
- {
- "netgate-nat:ip6-destination": "string",
- "netgate-nat:psid": 0
}
]
}, - "netgate-nat:psid-length": 0,
- "netgate-nat:ip6-prefix": "string",
- "netgate-nat:mtu": 0
}
]
}
}
}
}
NAT for IPv6/IPv4.
netgate.nat.natconfig.Nat64 to be added to list
object (netgate.map.natstate.nat64.Map) State for MAP-E and MAP-t translations. |
{- "netgate-map:map": {
- "netgate-nat:parameters": {
- "netgate-nat:tcp": {
- "netgate-nat:mss": 0
}, - "netgate-nat:security-check": {
- "netgate-nat:enable": true,
- "netgate-nat:fragments": true
}, - "netgate-nat:fragment": {
- "netgate-nat:inner": true,
- "netgate-nat:ignore-df": true
}, - "netgate-nat:traffic-class": {
- "netgate-nat:copy": true,
- "netgate-nat:tc": 0
}, - "netgate-nat:icmp": {
- "netgate-nat:source-address": "string"
}, - "netgate-nat:pre-resolve": {
- "netgate-nat:ipv4": {
- "netgate-nat:next-hop": "string"
}, - "netgate-nat:ipv6": {
- "netgate-nat:next-hop": "string"
}
}, - "netgate-nat:icmp6": {
- "netgate-nat:unreachables": true
}
}, - "netgate-nat:map-domains": {
- "netgate-nat:domain": [
- {
- "netgate-nat:psid-offset": 0,
- "netgate-nat:ea-bits-length": 0,
- "netgate-nat:ip6-src-prefix": "string",
- "netgate-nat:ip4-prefix": "string",
- "netgate-nat:name": "string",
- "netgate-nat:description": "string",
- "netgate-nat:rules": {
- "netgate-nat:rule": [
- {
- "netgate-nat:ip6-destination": "string",
- "netgate-nat:psid": 0
}
]
}, - "netgate-nat:psid-length": 0,
- "netgate-nat:ip6-prefix": "string",
- "netgate-nat:mtu": 0
}
]
}
}
}
NAT for IPv6/IPv4.
netgate.nat.natconfig.Nat64 to be added or updated
object (netgate.nat.natconfig.Nat64) NAT for IPv6/IPv4. |
{- "netgate-nat:nat64": {
- "netgate-map:map": {
- "netgate-nat:parameters": {
- "netgate-nat:tcp": {
- "netgate-nat:mss": 0
}, - "netgate-nat:security-check": {
- "netgate-nat:enable": true,
- "netgate-nat:fragments": true
}, - "netgate-nat:fragment": {
- "netgate-nat:inner": true,
- "netgate-nat:ignore-df": true
}, - "netgate-nat:traffic-class": {
- "netgate-nat:copy": true,
- "netgate-nat:tc": 0
}, - "netgate-nat:icmp": {
- "netgate-nat:source-address": "string"
}, - "netgate-nat:pre-resolve": {
- "netgate-nat:ipv4": {
- "netgate-nat:next-hop": "string"
}, - "netgate-nat:ipv6": {
- "netgate-nat:next-hop": "string"
}
}, - "netgate-nat:icmp6": {
- "netgate-nat:unreachables": true
}
}, - "netgate-nat:map-domains": {
- "netgate-nat:domain": [
- {
- "netgate-nat:psid-offset": 0,
- "netgate-nat:ea-bits-length": 0,
- "netgate-nat:ip6-src-prefix": "string",
- "netgate-nat:ip4-prefix": "string",
- "netgate-nat:name": "string",
- "netgate-nat:description": "string",
- "netgate-nat:rules": {
- "netgate-nat:rule": [
- {
- "netgate-nat:ip6-destination": "string",
- "netgate-nat:psid": 0
}
]
}, - "netgate-nat:psid-length": 0,
- "netgate-nat:ip6-prefix": "string",
- "netgate-nat:mtu": 0
}
]
}
}
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/nat64" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/static" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:static": {
- "netgate-nat:mapping-table": {
- "netgate-nat:mapping-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:external-if-name": "string",
- "netgate-nat:external-port": "string",
- "netgate-nat:local-port": "string",
- "netgate-nat:external-address": "string",
- "netgate-nat:transport-protocol": "icmp",
- "netgate-nat:out-to-in-only": true,
- "netgate-nat:twice-nat": true,
- "netgate-nat:local-address": "string"
}
]
}
}
}
Static mapping information.
netgate.nat.natconfig.Static to be added to list
object (netgate.nat.natconfig.static.MappingTable) NAT mapping table. |
{- "netgate-nat:mapping-table": {
- "netgate-nat:mapping-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:external-if-name": "string",
- "netgate-nat:external-port": "string",
- "netgate-nat:local-port": "string",
- "netgate-nat:external-address": "string",
- "netgate-nat:transport-protocol": "icmp",
- "netgate-nat:out-to-in-only": true,
- "netgate-nat:twice-nat": true,
- "netgate-nat:local-address": "string"
}
]
}
}
Static mapping information.
netgate.nat.natconfig.Static to be added or updated
object (netgate.nat.natconfig.Static) Static mapping information. |
{- "netgate-nat:static": {
- "netgate-nat:mapping-table": {
- "netgate-nat:mapping-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:external-if-name": "string",
- "netgate-nat:external-port": "string",
- "netgate-nat:local-port": "string",
- "netgate-nat:external-address": "string",
- "netgate-nat:transport-protocol": "icmp",
- "netgate-nat:out-to-in-only": true,
- "netgate-nat:twice-nat": true,
- "netgate-nat:local-address": "string"
}
]
}
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/static" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/static/mapping-table" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:mapping-table": {
- "netgate-nat:mapping-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:external-if-name": "string",
- "netgate-nat:external-port": "string",
- "netgate-nat:local-port": "string",
- "netgate-nat:external-address": "string",
- "netgate-nat:transport-protocol": "icmp",
- "netgate-nat:out-to-in-only": true,
- "netgate-nat:twice-nat": true,
- "netgate-nat:local-address": "string"
}
]
}
}
NAT mapping table.
netgate.nat.natconfig.static.MappingTable to be added to list
Array of objects (netgate.nat.natconfig.static.mappingtable.MappingEntry) NAT Mapping Entry. |
{- "netgate-nat:mapping-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:external-if-name": "string",
- "netgate-nat:external-port": "string",
- "netgate-nat:local-port": "string",
- "netgate-nat:external-address": "string",
- "netgate-nat:transport-protocol": "icmp",
- "netgate-nat:out-to-in-only": true,
- "netgate-nat:twice-nat": true,
- "netgate-nat:local-address": "string"
}
]
}
NAT mapping table.
netgate.nat.natconfig.static.MappingTable to be added or updated
object (netgate.nat.natconfig.static.MappingTable) NAT mapping table. |
{- "netgate-nat:mapping-table": {
- "netgate-nat:mapping-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:external-if-name": "string",
- "netgate-nat:external-port": "string",
- "netgate-nat:local-port": "string",
- "netgate-nat:external-address": "string",
- "netgate-nat:transport-protocol": "icmp",
- "netgate-nat:out-to-in-only": true,
- "netgate-nat:twice-nat": true,
- "netgate-nat:local-address": "string"
}
]
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/static/mapping-table" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
NAT Mapping Entry.
netgate.nat.natconfig.static.mappingtable.MappingEntry to be added to list
netgate-nat:route-table-name | string The name of a Route Table. |
netgate-nat:external-if-name | string The external interface of the IPv4 packet. |
netgate-nat:external-port | string The external port mapped, or wildcard 'any'. |
netgate-nat:local-port | string The local port mapped, or wildcard 'any'. |
netgate-nat:external-address | string The external IPv4 address of the IPv4 packet. |
netgate-nat:transport-protocol | string (netgate.nat.NatIpv4ProtocolAny) Enum: "icmp" "udp" "tcp" "any" |
netgate-nat:out-to-in-only | boolean Match only out-to-in direction. |
netgate-nat:twice-nat | boolean NAT translate external address and port for 1:1 NAPT. |
netgate-nat:local-address | string The local IPv4 address of the IPv4 packet. |
{- "netgate-nat:route-table-name": "string",
- "netgate-nat:external-if-name": "string",
- "netgate-nat:external-port": "string",
- "netgate-nat:local-port": "string",
- "netgate-nat:external-address": "string",
- "netgate-nat:transport-protocol": "icmp",
- "netgate-nat:out-to-in-only": true,
- "netgate-nat:twice-nat": true,
- "netgate-nat:local-address": "string"
}
NAT Mapping Entry.
transport-protocol required | string Id of mapping-entry |
local-address required | string Id of mapping-entry |
local-port required | string Id of mapping-entry |
external-address required | string Id of mapping-entry |
external-port required | string Id of mapping-entry |
route-table-name required | string Id of mapping-entry |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/static/mapping-table/mapping-entry=%7Btransport-protocol%7D,%7Blocal-address%7D,%7Blocal-port%7D,%7Bexternal-address%7D,%7Bexternal-port%7D,%7Broute-table-name%7D" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:mapping-entry": {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:external-if-name": "string",
- "netgate-nat:external-port": "string",
- "netgate-nat:local-port": "string",
- "netgate-nat:external-address": "string",
- "netgate-nat:transport-protocol": "icmp",
- "netgate-nat:out-to-in-only": true,
- "netgate-nat:twice-nat": true,
- "netgate-nat:local-address": "string"
}
}
NAT Mapping Entry.
transport-protocol required | string Id of mapping-entry |
local-address required | string Id of mapping-entry |
local-port required | string Id of mapping-entry |
external-address required | string Id of mapping-entry |
external-port required | string Id of mapping-entry |
route-table-name required | string Id of mapping-entry |
netgate.nat.natconfig.static.mappingtable.MappingEntry to be added or updated
object (netgate.nat.natconfig.static.mappingtable.MappingEntry) NAT Mapping Entry. |
{- "netgate-nat:mapping-entry": {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:external-if-name": "string",
- "netgate-nat:external-port": "string",
- "netgate-nat:local-port": "string",
- "netgate-nat:external-address": "string",
- "netgate-nat:transport-protocol": "icmp",
- "netgate-nat:out-to-in-only": true,
- "netgate-nat:twice-nat": true,
- "netgate-nat:local-address": "string"
}
}
NAT Mapping Entry.
transport-protocol required | string Id of mapping-entry |
local-address required | string Id of mapping-entry |
local-port required | string Id of mapping-entry |
external-address required | string Id of mapping-entry |
external-port required | string Id of mapping-entry |
route-table-name required | string Id of mapping-entry |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-config/static/mapping-table/mapping-entry=%7Btransport-protocol%7D,%7Blocal-address%7D,%7Blocal-port%7D,%7Bexternal-address%7D,%7Bexternal-port%7D,%7Broute-table-name%7D" req, _ := http.NewRequest("DELETE", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-state" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:nat-state": {
- "netgate-nat:interface-sides": {
- "netgate-nat:interface-side": [
- {
- "netgate-nat:if-name": "string",
- "netgate-nat:side": "none"
}
]
}, - "netgate-nat:dynamic": {
- "netgate-nat:pool-if-table": {
- "netgate-nat:if-entry": [
- {
- "netgate-nat:if-name": "string",
- "netgate-nat:twice-nat": true
}
]
}, - "netgate-nat:pool-table": {
- "netgate-nat:pool-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:twice-nat": true,
- "netgate-nat:address": "string"
}
]
}
}, - "netgate-nat:static": {
- "netgate-nat:mapping-table": {
- "netgate-nat:mapping-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:external-if-name": "string",
- "netgate-nat:external-port": "string",
- "netgate-nat:local-port": "string",
- "netgate-nat:external-address": "string",
- "netgate-nat:transport-protocol": "icmp",
- "netgate-nat:out-to-in-only": true,
- "netgate-nat:twice-nat": true,
- "netgate-nat:local-address": "string"
}
]
}
}, - "netgate-nat:nat64": {
- "netgate-map:map": {
- "netgate-nat:parameters": {
- "netgate-nat:tcp": {
- "netgate-nat:mss": 0
}, - "netgate-nat:security-check": {
- "netgate-nat:enable": true,
- "netgate-nat:fragments": true
}, - "netgate-nat:fragment": {
- "netgate-nat:inner": true,
- "netgate-nat:ignore-df": true
}, - "netgate-nat:traffic-class": {
- "netgate-nat:copy": true,
- "netgate-nat:tc": 0
}, - "netgate-nat:icmp": {
- "netgate-nat:source-address": "string"
}, - "netgate-nat:pre-resolve": {
- "netgate-nat:ipv4": {
- "netgate-nat:next-hop": "string"
}, - "netgate-nat:ipv6": {
- "netgate-nat:next-hop": "string"
}
}, - "netgate-nat:icmp6": {
- "netgate-nat:unreachables": true
}
}, - "netgate-nat:map-domains": {
- "netgate-nat:domain": [
- {
- "netgate-nat:psid-offset": 0,
- "netgate-nat:ea-bits-length": 0,
- "netgate-nat:ip6-src-prefix": "string",
- "netgate-nat:ip4-prefix": "string",
- "netgate-nat:name": "string",
- "netgate-nat:description": "string",
- "netgate-nat:rules": {
- "netgate-nat:rule": [
- {
- "netgate-nat:ip6-destination": null,
- "netgate-nat:psid": null
}
]
}, - "netgate-nat:psid-length": 0,
- "netgate-nat:ip6-prefix": "string",
- "netgate-nat:mtu": 0
}
]
}
}
}, - "netgate-nat:parameters": {
- "netgate-nat:translation-memory-size": 0,
- "netgate-nat:translation-buckets": 0,
- "netgate-nat:timeout-icmp": 0,
- "netgate-nat:max-users-per-thread": 0,
- "netgate-nat:user-buckets": 0,
- "netgate-nat:endpoint-dependent": true,
- "netgate-nat:timeout-tcp_transitory": 0,
- "netgate-nat:timeout-tcp_established": 0,
- "netgate-nat:out2in-dpo": true,
- "netgate-nat:max-translations-per-thread": 0,
- "netgate-nat:inside-route-table-name": "string",
- "netgate-nat:user-memory-size": 0,
- "netgate-nat:static-mapping-only": true,
- "netgate-nat:timeout-udp": 0,
- "netgate-nat:outside-route-table-name": "string",
- "netgate-nat:max-translations-per-user": 0,
- "netgate-nat:static-mapping-connection-tracking": true,
- "netgate-nat:forwarding-enabled": true
}, - "netgate-nat:users": {
- "netgate-nat:user": [
- {
- "netgate-nat:static-number": 0,
- "netgate-nat:ip-address": "string",
- "netgate-nat:route-table": "string",
- "netgate-nat:session": [
- {
- "netgate-nat:static": true,
- "netgate-nat:ext-host-port": 0,
- "netgate-nat:last-heard": 0,
- "netgate-nat:inside-ip-address": "string",
- "netgate-nat:index": 0,
- "netgate-nat:twice-nat": true,
- "netgate-nat:outside-port": 0,
- "netgate-nat:outside-ip-address": "string",
- "netgate-nat:total-packets": 0,
- "netgate-nat:protocol": "icmp",
- "netgate-nat:ext-host-valid": true,
- "netgate-nat:ext-host-address": "string",
- "netgate-nat:total-bytes": 0,
- "netgate-nat:ext-host-nat-address": "string",
- "netgate-nat:ext-host-nat-port": 0,
- "netgate-nat:inside-port": 0
}
], - "netgate-nat:dynamic-number": 0
}
]
}
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-state/dynamic" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:dynamic": {
- "netgate-nat:pool-if-table": {
- "netgate-nat:if-entry": [
- {
- "netgate-nat:if-name": "string",
- "netgate-nat:twice-nat": true
}
]
}, - "netgate-nat:pool-table": {
- "netgate-nat:pool-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:twice-nat": true,
- "netgate-nat:address": "string"
}
]
}
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-state/dynamic/pool-if-table" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:pool-if-table": {
- "netgate-nat:if-entry": [
- {
- "netgate-nat:if-name": "string",
- "netgate-nat:twice-nat": true
}
]
}
}
Dynamic pool interface entries.
if-name required | string Id of if-entry |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-state/dynamic/pool-if-table/if-entry=%7Bif-name%7D" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:if-entry": {
- "netgate-nat:if-name": "string",
- "netgate-nat:twice-nat": true
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-state/dynamic/pool-table" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:pool-table": {
- "netgate-nat:pool-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:twice-nat": true,
- "netgate-nat:address": "string"
}
]
}
}
NAT pool address.
address required | string Id of pool-entry |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-state/dynamic/pool-table/pool-entry=%7Baddress%7D" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:pool-entry": {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:twice-nat": true,
- "netgate-nat:address": "string"
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-state/interface-sides" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:interface-sides": {
- "netgate-nat:interface-side": [
- {
- "netgate-nat:if-name": "string",
- "netgate-nat:side": "none"
}
]
}
}
Side information about interfaces.
if-name required | string Id of interface-side |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-state/interface-sides/interface-side=%7Bif-name%7D" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:interface-side": {
- "netgate-nat:if-name": "string",
- "netgate-nat:side": "none"
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-state/nat64" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:nat64": {
- "netgate-map:map": {
- "netgate-nat:parameters": {
- "netgate-nat:tcp": {
- "netgate-nat:mss": 0
}, - "netgate-nat:security-check": {
- "netgate-nat:enable": true,
- "netgate-nat:fragments": true
}, - "netgate-nat:fragment": {
- "netgate-nat:inner": true,
- "netgate-nat:ignore-df": true
}, - "netgate-nat:traffic-class": {
- "netgate-nat:copy": true,
- "netgate-nat:tc": 0
}, - "netgate-nat:icmp": {
- "netgate-nat:source-address": "string"
}, - "netgate-nat:pre-resolve": {
- "netgate-nat:ipv4": {
- "netgate-nat:next-hop": "string"
}, - "netgate-nat:ipv6": {
- "netgate-nat:next-hop": "string"
}
}, - "netgate-nat:icmp6": {
- "netgate-nat:unreachables": true
}
}, - "netgate-nat:map-domains": {
- "netgate-nat:domain": [
- {
- "netgate-nat:psid-offset": 0,
- "netgate-nat:ea-bits-length": 0,
- "netgate-nat:ip6-src-prefix": "string",
- "netgate-nat:ip4-prefix": "string",
- "netgate-nat:name": "string",
- "netgate-nat:description": "string",
- "netgate-nat:rules": {
- "netgate-nat:rule": [
- {
- "netgate-nat:ip6-destination": "string",
- "netgate-nat:psid": 0
}
]
}, - "netgate-nat:psid-length": 0,
- "netgate-nat:ip6-prefix": "string",
- "netgate-nat:mtu": 0
}
]
}
}
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-state/parameters" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:parameters": {
- "netgate-nat:translation-memory-size": 0,
- "netgate-nat:translation-buckets": 0,
- "netgate-nat:timeout-icmp": 0,
- "netgate-nat:max-users-per-thread": 0,
- "netgate-nat:user-buckets": 0,
- "netgate-nat:endpoint-dependent": true,
- "netgate-nat:timeout-tcp_transitory": 0,
- "netgate-nat:timeout-tcp_established": 0,
- "netgate-nat:out2in-dpo": true,
- "netgate-nat:max-translations-per-thread": 0,
- "netgate-nat:inside-route-table-name": "string",
- "netgate-nat:user-memory-size": 0,
- "netgate-nat:static-mapping-only": true,
- "netgate-nat:timeout-udp": 0,
- "netgate-nat:outside-route-table-name": "string",
- "netgate-nat:max-translations-per-user": 0,
- "netgate-nat:static-mapping-connection-tracking": true,
- "netgate-nat:forwarding-enabled": true
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-state/static" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:static": {
- "netgate-nat:mapping-table": {
- "netgate-nat:mapping-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:external-if-name": "string",
- "netgate-nat:external-port": "string",
- "netgate-nat:local-port": "string",
- "netgate-nat:external-address": "string",
- "netgate-nat:transport-protocol": "icmp",
- "netgate-nat:out-to-in-only": true,
- "netgate-nat:twice-nat": true,
- "netgate-nat:local-address": "string"
}
]
}
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-state/static/mapping-table" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:mapping-table": {
- "netgate-nat:mapping-entry": [
- {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:external-if-name": "string",
- "netgate-nat:external-port": "string",
- "netgate-nat:local-port": "string",
- "netgate-nat:external-address": "string",
- "netgate-nat:transport-protocol": "icmp",
- "netgate-nat:out-to-in-only": true,
- "netgate-nat:twice-nat": true,
- "netgate-nat:local-address": "string"
}
]
}
}
NAT Mapping Entry.
transport-protocol required | string Id of mapping-entry |
local-address required | string Id of mapping-entry |
local-port required | string Id of mapping-entry |
external-address required | string Id of mapping-entry |
external-port required | string Id of mapping-entry |
route-table-name required | string Id of mapping-entry |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-state/static/mapping-table/mapping-entry=%7Btransport-protocol%7D,%7Blocal-address%7D,%7Blocal-port%7D,%7Bexternal-address%7D,%7Bexternal-port%7D,%7Broute-table-name%7D" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:mapping-entry": {
- "netgate-nat:route-table-name": "string",
- "netgate-nat:external-if-name": "string",
- "netgate-nat:external-port": "string",
- "netgate-nat:local-port": "string",
- "netgate-nat:external-address": "string",
- "netgate-nat:transport-protocol": "icmp",
- "netgate-nat:out-to-in-only": true,
- "netgate-nat:twice-nat": true,
- "netgate-nat:local-address": "string"
}
}
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-state/users" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:users": {
- "netgate-nat:user": [
- {
- "netgate-nat:static-number": 0,
- "netgate-nat:ip-address": "string",
- "netgate-nat:route-table": "string",
- "netgate-nat:session": [
- {
- "netgate-nat:static": true,
- "netgate-nat:ext-host-port": 0,
- "netgate-nat:last-heard": 0,
- "netgate-nat:inside-ip-address": "string",
- "netgate-nat:index": 0,
- "netgate-nat:twice-nat": true,
- "netgate-nat:outside-port": 0,
- "netgate-nat:outside-ip-address": "string",
- "netgate-nat:total-packets": 0,
- "netgate-nat:protocol": "icmp",
- "netgate-nat:ext-host-valid": true,
- "netgate-nat:ext-host-address": "string",
- "netgate-nat:total-bytes": 0,
- "netgate-nat:ext-host-nat-address": "string",
- "netgate-nat:ext-host-nat-port": 0,
- "netgate-nat:inside-port": 0
}
], - "netgate-nat:dynamic-number": 0
}
]
}
}
NAT user.
route-table required | string Id of user |
ip-address required | string Id of user |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-state/users/user=%7Broute-table%7D,%7Bip-address%7D" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:user": {
- "netgate-nat:static-number": 0,
- "netgate-nat:ip-address": "string",
- "netgate-nat:route-table": "string",
- "netgate-nat:session": [
- {
- "netgate-nat:static": true,
- "netgate-nat:ext-host-port": 0,
- "netgate-nat:last-heard": 0,
- "netgate-nat:inside-ip-address": "string",
- "netgate-nat:index": 0,
- "netgate-nat:twice-nat": true,
- "netgate-nat:outside-port": 0,
- "netgate-nat:outside-ip-address": "string",
- "netgate-nat:total-packets": 0,
- "netgate-nat:protocol": "icmp",
- "netgate-nat:ext-host-valid": true,
- "netgate-nat:ext-host-address": "string",
- "netgate-nat:total-bytes": 0,
- "netgate-nat:ext-host-nat-address": "string",
- "netgate-nat:ext-host-nat-port": 0,
- "netgate-nat:inside-port": 0
}
], - "netgate-nat:dynamic-number": 0
}
}
NAT user session.
route-table required | string Id of user |
ip-address required | string Id of user |
index required | integer <int64> Id of session |
package main import ( "fmt" "net/http" "io/ioutil" ) func main() { url := "http://hostname/restconf/data/netgate-nat:nat-state/users/user=%7Broute-table%7D,%7Bip-address%7D/session=%7Bindex%7D" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) }
{- "netgate-nat:session": {
- "netgate-nat:static": true,
- "netgate-nat:ext-host-port": 0,
- "netgate-nat:last-heard": 0,
- "netgate-nat:inside-ip-address": "string",
- "netgate-nat:index": 0,
- "netgate-nat:twice-nat": true,
- "netgate-nat:outside-port": 0,
- "netgate-nat:outside-ip-address": "string",
- "netgate-nat:total-packets": 0,
- "netgate-nat:protocol": "icmp",
- "netgate-nat:ext-host-valid": true,
- "netgate-nat:ext-host-address": "string",
- "netgate-nat:total-bytes": 0,
- "netgate-nat:ext-host-nat-address": "string",
- "netgate-nat:ext-host-nat-port": 0,
- "netgate-nat:inside-port": 0
}
}