. "$BST_LIB"
# netbase ships no binary: it installs the IANA name/number databases
# /etc/services (service<->port) and /etc/protocols (protocol<->number),
# read by getservbyname/getprotobyname and by curl, tcpdump, mtr, iperf3.
# It is allarch and arrives transitively via packagegroup-core-boot; coverage
# is the two database files plus a representative entry in each.

check     netbase/services  test -f /etc/services
check     netbase/protocols test -f /etc/protocols

# /etc/services maps ssh -> 22/tcp
check_out netbase/ssh-port  "22/tcp" sh -c "grep '^ssh' /etc/services"

# /etc/protocols lists tcp and udp
check_out netbase/proto-tcp "tcp" sh -c "grep -E '^tcp[[:space:]]' /etc/protocols"
check_out netbase/proto-udp "udp" sh -c "grep -E '^udp[[:space:]]' /etc/protocols"
