NetworkManager/src/tests/client
Beniamino Galvani c86d234516 nmcli: show the CLAT state
It is useful to show that the CLAT is enabled and which addresses and
prefix it is using. Add this information to the overview and to the
device/connection output. Example:

$ nmcli
  veth0: connected to clat
          "veth0"
          ethernet (veth), 4A:37:01:56:9D:AE, sw, mtu 1500
          ip4 default
          inet4 192.0.0.5/32
          route4 default metric 101
          inet6 2002:aaaa::64d4:2932:3585:7c89/64
          inet6 fe80::c060:8caf:f69b:e41a/64
          route6 fe80::/64 metric 1024
          route6 2002:aaaa::/64 metric 101
          route6 default via fe80::871:7ff:fe14:b7b9 metric 101
          clat inet4 192.0.0.5 inet6 2002:aaaa::2c0d:1e71:ef87:fac7 pref64 64:ff9b::/96

$ nmcli connection show clat
   ...
  IP4.ADDRESS[1]:                         192.0.0.5/32
  IP4.GATEWAY:                            0.0.0.0
  IP4.ROUTE[1]:                           dst = 0.0.0.0/0, nh = 0.0.0.0, mt = 101
  IP4.CLAT-ADDRESS:                       192.0.0.5
  IP6.ADDRESS[1]:                         2002:aaaa::64d4:2932:3585:7c89/64
  IP6.ADDRESS[2]:                         fe80::c060:8caf:f69b:e41a/64
  IP6.GATEWAY:                            fe80::871:7ff:fe14:b7b9
  IP6.ROUTE[1]:                           dst = fe80::/64, nh = ::, mt = 1024
  IP6.ROUTE[2]:                           dst = 2002:aaaa::/64, nh = ::, mt = 101
  IP6.ROUTE[3]:                           dst = ::/0, nh = fe80::871:7ff:fe14:b7b9, mt = 101
  IP6.CLAT-ADDRESS:                       2002:aaaa::2c0d:1e71:ef87:fac7
  IP6.CLAT-PREF64:                        64:ff9b::/96

Note how the IPv4 CLAT address is displayed both in IP4.ADDRESS and
IP4.CLAT-ADDRESS. That's because it is also configured in kernel. The
IPv6 CLAT address is not displayed in IP6.ADDRESS because it's not
configured in kernel.
2026-02-06 10:38:04 +01:00
..
terminal-colors.d client/tests: move "clients/tests/test-client.py" to "src/tests/client/" 2021-03-15 17:10:55 +01:00
test-client.check-on-disk nmcli: show the CLAT state 2026-02-06 10:38:04 +01:00
meson.build build: remove autotools leftovers 2025-09-08 10:46:44 +00:00
test-client.py nmcli: print the band of wifi access points 2026-01-15 17:38:41 +01:00
test-client.sh build: remove autotools leftovers 2025-09-08 10:46:44 +00:00