mirror of
https://github.com/siderolabs/talos.git
synced 2025-10-25 22:41:10 +02:00
Many changes to the nftables backend which will be used in the follow-up PR with #4421. 1. Add support for chain policy: drop/accept. 2. Properly handle match on all IPs in the set (`0.0.0.0/0` like). 3. Implement conntrack state matching. 4. Implement multiple ifname matching in a single rule. 5. Implement anonymous counters. Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
21 lines
554 B
Go
21 lines
554 B
Go
// This Source Code Form is subject to the terms of the Mozilla Public
|
|
// License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
|
|
|
package nethelpers
|
|
|
|
//go:generate enumer -type=Protocol -linecomment -text
|
|
|
|
// Protocol is a inet protocol.
|
|
type Protocol uint8
|
|
|
|
// Protocol constants.
|
|
//
|
|
//structprotogen:gen_enum
|
|
const (
|
|
ProtocolICMP Protocol = 0x1 // icmp
|
|
ProtocolTCP Protocol = 0x6 // tcp
|
|
ProtocolUDP Protocol = 0x11 // udp
|
|
ProtocolICMPv6 Protocol = 0x3a // icmpv6
|
|
)
|