summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Haller <thaller@redhat.com>2022-02-09 19:04:05 +0100
committerThomas Haller <thaller@redhat.com>2022-02-09 22:33:23 +0100
commit7b1e9a5c3d146c7ddd83f552c290fc841388cfda (patch)
tree4a491b12a3e367b17a0c0b04cd190fe25a47e172
parent35599b4349c18b771d86ea6a7f577909cfcb7a2f (diff)
downloadNetworkManager-7b1e9a5c3d146c7ddd83f552c290fc841388cfda.tar.gz
libnm/doc: list route attributes in `man nm-settings-nmcli`
IPv4: routes A list of IPv4 destination addresses, prefix length, optional IPv4 next hop addresses, optional route metric, optional attribute. The valid syntax is: "ip[/prefix] [next-hop] [metric] [attribute=val]...[,ip[/prefix]...]". For example "192.0.2.0/24 10.1.1.1 77, 198.51.100.0/24". Various attributes are supported: • "cwnd" - an unsigned 32 bit integer. • "initcwnd" - an unsigned 32 bit integer. • "initrwnd" - an unsigned 32 bit integer. • "lock-cwnd" - a boolean value. • "lock-initcwnd" - a boolean value. • "lock-initrwnd" - a boolean value. • "lock-mtu" - a boolean value. • "lock-window" - a boolean value. • "mtu" - an unsigned 32 bit integer. • "onlink" - a boolean value. • "scope" - an unsigned 8 bit integer. IPv4 only. • "src" - an IPv4 address. • "table" - an unsigned 32 bit integer. The default depends on ipv4.route-table. • "tos" - an unsigned 8 bit integer. IPv4 only. • "type" - one of unicast, local, blackhole, unavailable, prohibit. The default is unicast. • "window" - an unsigned 32 bit integer. For details see also `man ip-route`. Format: a comma separated list of routes IPv6: routes A list of IPv6 destination addresses, prefix length, optional IPv6 next hop addresses, optional route metric, optional attribute. The valid syntax is: "ip[/prefix] [next-hop] [metric] [attribute=val]...[,ip[/prefix]...]". Various attributes are supported: • "cwnd" - an unsigned 32 bit integer. • "from" - an IPv6 address with optional prefix. IPv6 only. • "initcwnd" - an unsigned 32 bit integer. • "initrwnd" - an unsigned 32 bit integer. • "lock-cwnd" - a boolean value. • "lock-initcwnd" - a boolean value. • "lock-initrwnd" - a boolean value. • "lock-mtu" - a boolean value. • "lock-window" - a boolean value. • "mtu" - an unsigned 32 bit integer. • "onlink" - a boolean value. • "src" - an IPv6 address. • "table" - an unsigned 32 bit integer. The default depends on ipv6.route-table. • "type" - one of unicast, local, blackhole, unavailable, prohibit. The default is unicast. • "window" - an unsigned 32 bit integer. For details see also `man ip-route`. Format: a comma separated list of routes
-rw-r--r--src/libnm-core-impl/nm-setting-ip4-config.c70
-rw-r--r--src/libnm-core-impl/nm-setting-ip6-config.c65
2 files changed, 132 insertions, 3 deletions
diff --git a/src/libnm-core-impl/nm-setting-ip4-config.c b/src/libnm-core-impl/nm-setting-ip4-config.c
index 6c2ba10d6c..76043cd50a 100644
--- a/src/libnm-core-impl/nm-setting-ip4-config.c
+++ b/src/libnm-core-impl/nm-setting-ip4-config.c
@@ -949,9 +949,73 @@ nm_setting_ip4_config_class_init(NMSettingIP4ConfigClass *klass)
* property: routes
* format: a comma separated list of routes
* description: A list of IPv4 destination addresses, prefix length, optional IPv4
- * next hop addresses, optional route metric, optional attribute. The valid syntax is:
- * "ip[/prefix] [next-hop] [metric] [attribute=val]...[,ip[/prefix]...]". For example
- * "192.0.2.0/24 10.1.1.1 77, 198.51.100.0/24".
+ * next hop addresses, optional route metric, optional attribute. The valid syntax is:
+ * "ip[/prefix] [next-hop] [metric] [attribute=val]...[,ip[/prefix]...]". For example
+ * "192.0.2.0/24 10.1.1.1 77, 198.51.100.0/24".
+ * description-docbook:
+ * <para>
+ * A list of IPv4 destination addresses, prefix length, optional IPv4
+ * next hop addresses, optional route metric, optional attribute. The valid syntax is:
+ * "ip[/prefix] [next-hop] [metric] [attribute=val]...[,ip[/prefix]...]".
+ * For example "192.0.2.0/24 10.1.1.1 77, 198.51.100.0/24".
+ * </para>
+ * <para>
+ * Various attributes are supported:
+ * <itemizedlist>
+ * <listitem>
+ * <para><literal>"cwnd"</literal> - an unsigned 32 bit integer.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"initcwnd"</literal> - an unsigned 32 bit integer.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"initrwnd"</literal> - an unsigned 32 bit integer.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"lock-cwnd"</literal> - a boolean value.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"lock-initcwnd"</literal> - a boolean value.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"lock-initrwnd"</literal> - a boolean value.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"lock-mtu"</literal> - a boolean value.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"lock-window"</literal> - a boolean value.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"mtu"</literal> - an unsigned 32 bit integer.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"onlink"</literal> - a boolean value.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"scope"</literal> - an unsigned 8 bit integer. IPv4 only.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"src"</literal> - an IPv4 address.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"table"</literal> - an unsigned 32 bit integer. The default depends on ipv4.route-table.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"tos"</literal> - an unsigned 8 bit integer. IPv4 only.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"type"</literal> - one of <literal>unicast</literal>, <literal>local</literal>, <literal>blackhole</literal>,
+ * <literal>unavailable</literal>, <literal>prohibit</literal>. The default is <literal>unicast</literal>.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"window"</literal> - an unsigned 32 bit integer.</para>
+ * </listitem>
+ * </itemizedlist>
+ * </para>
+ * <para>
+ * For details see also `man ip-route`.
+ * </para>
* ---end---
*/
_nm_properties_override_gobj(
diff --git a/src/libnm-core-impl/nm-setting-ip6-config.c b/src/libnm-core-impl/nm-setting-ip6-config.c
index 99032e97f2..54f3f96b87 100644
--- a/src/libnm-core-impl/nm-setting-ip6-config.c
+++ b/src/libnm-core-impl/nm-setting-ip6-config.c
@@ -989,6 +989,71 @@ nm_setting_ip6_config_class_init(NMSettingIP6ConfigClass *klass)
* default metric for the device.
* ---end---
*/
+ /* ---nmcli---
+ * property: routes
+ * format: a comma separated list of routes
+ * description-docbook:
+ * <para>
+ * A list of IPv6 destination addresses, prefix length, optional IPv6
+ * next hop addresses, optional route metric, optional attribute. The valid syntax is:
+ * "ip[/prefix] [next-hop] [metric] [attribute=val]...[,ip[/prefix]...]".
+ * </para>
+ * <para>
+ * Various attributes are supported:
+ * <itemizedlist>
+ * <listitem>
+ * <para><literal>"cwnd"</literal> - an unsigned 32 bit integer.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"from"</literal> - an IPv6 address with optional prefix. IPv6 only.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"initcwnd"</literal> - an unsigned 32 bit integer.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"initrwnd"</literal> - an unsigned 32 bit integer.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"lock-cwnd"</literal> - a boolean value.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"lock-initcwnd"</literal> - a boolean value.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"lock-initrwnd"</literal> - a boolean value.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"lock-mtu"</literal> - a boolean value.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"lock-window"</literal> - a boolean value.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"mtu"</literal> - an unsigned 32 bit integer.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"onlink"</literal> - a boolean value.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"src"</literal> - an IPv6 address.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"table"</literal> - an unsigned 32 bit integer. The default depends on ipv6.route-table.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"type"</literal> - one of <literal>unicast</literal>, <literal>local</literal>, <literal>blackhole</literal>,
+ * <literal>unavailable</literal>, <literal>prohibit</literal>. The default is <literal>unicast</literal>.</para>
+ * </listitem>
+ * <listitem>
+ * <para><literal>"window"</literal> - an unsigned 32 bit integer.</para>
+ * </listitem>
+ * </itemizedlist>
+ * </para>
+ * <para>
+ * For details see also `man ip-route`.
+ * </para>
+ * ---end---
+ */
_nm_properties_override_gobj(
properties_override,
g_object_class_find_property(G_OBJECT_CLASS(setting_class), NM_SETTING_IP_CONFIG_ROUTES),