libnm,nmcli: introduce new ipv4.dhcp-ipv6-only-preferred property
Add a new "ipv4.dhcp-ipv6-only-preferred" property to control the "IPv6-Only Preferred" DHCPv4 option (RFC 8925). The option indicates that a host supports an IPv6-only mode and is willing to forgo obtaining an IPv4 address if the network provides IPv6 connectivity.
This commit is contained in:
@@ -3588,13 +3588,24 @@ do_write_construct(NMConnection *connection,
|
|||||||
} else
|
} else
|
||||||
route_ignore = FALSE;
|
route_ignore = FALSE;
|
||||||
|
|
||||||
if ((s_ip4 = nm_connection_get_setting_ip4_config(connection))
|
if ((s_ip4 = nm_connection_get_setting_ip4_config(connection))) {
|
||||||
&& nm_setting_ip_config_get_dhcp_dscp(s_ip4)) {
|
if (nm_setting_ip_config_get_dhcp_dscp(s_ip4)) {
|
||||||
set_error_unsupported(error,
|
set_error_unsupported(error,
|
||||||
connection,
|
connection,
|
||||||
NM_SETTING_IP4_CONFIG_SETTING_NAME "." NM_SETTING_IP_CONFIG_DHCP_DSCP,
|
NM_SETTING_IP4_CONFIG_SETTING_NAME
|
||||||
FALSE);
|
"." NM_SETTING_IP_CONFIG_DHCP_DSCP,
|
||||||
return FALSE;
|
FALSE);
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
if (nm_setting_ip4_config_get_dhcp_ipv6_only_preferred(NM_SETTING_IP4_CONFIG(s_ip4))
|
||||||
|
!= NM_SETTING_IP4_DHCP_IPV6_ONLY_PREFERRED_DEFAULT) {
|
||||||
|
set_error_unsupported(error,
|
||||||
|
connection,
|
||||||
|
NM_SETTING_IP4_CONFIG_SETTING_NAME
|
||||||
|
"." NM_SETTING_IP4_CONFIG_DHCP_IPV6_ONLY_PREFERRED,
|
||||||
|
FALSE);
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
write_ip4_setting(connection,
|
write_ip4_setting(connection,
|
||||||
|
@@ -2016,6 +2016,8 @@ global:
|
|||||||
nm_device_ipvlan_get_private;
|
nm_device_ipvlan_get_private;
|
||||||
nm_device_ipvlan_get_type;
|
nm_device_ipvlan_get_type;
|
||||||
nm_device_ipvlan_get_vepa;
|
nm_device_ipvlan_get_vepa;
|
||||||
|
nm_setting_ip4_config_get_dhcp_ipv6_only_preferred;
|
||||||
|
nm_setting_ip4_dhcp_ipv6_only_preferred_get_type;
|
||||||
nm_setting_ipvlan_get_mode;
|
nm_setting_ipvlan_get_mode;
|
||||||
nm_setting_ipvlan_get_parent;
|
nm_setting_ipvlan_get_parent;
|
||||||
nm_setting_ipvlan_get_private;
|
nm_setting_ipvlan_get_private;
|
||||||
|
@@ -1648,6 +1648,10 @@
|
|||||||
dbus-type="s"
|
dbus-type="s"
|
||||||
gprop-type="gchararray"
|
gprop-type="gchararray"
|
||||||
/>
|
/>
|
||||||
|
<property name="dhcp-ipv6-only-preferred"
|
||||||
|
dbus-type="i"
|
||||||
|
gprop-type="gint"
|
||||||
|
/>
|
||||||
<property name="dhcp-reject-servers"
|
<property name="dhcp-reject-servers"
|
||||||
dbus-type="as"
|
dbus-type="as"
|
||||||
gprop-type="GStrv"
|
gprop-type="GStrv"
|
||||||
|
@@ -39,7 +39,8 @@
|
|||||||
NM_GOBJECT_PROPERTIES_DEFINE_BASE(PROP_DHCP_CLIENT_ID,
|
NM_GOBJECT_PROPERTIES_DEFINE_BASE(PROP_DHCP_CLIENT_ID,
|
||||||
PROP_DHCP_FQDN,
|
PROP_DHCP_FQDN,
|
||||||
PROP_DHCP_VENDOR_CLASS_IDENTIFIER,
|
PROP_DHCP_VENDOR_CLASS_IDENTIFIER,
|
||||||
PROP_LINK_LOCAL, );
|
PROP_LINK_LOCAL,
|
||||||
|
PROP_DHCP_IPV6_ONLY_PREFERRED, );
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
NMSettingIPConfigPrivate parent;
|
NMSettingIPConfigPrivate parent;
|
||||||
@@ -48,6 +49,7 @@ typedef struct {
|
|||||||
char *dhcp_fqdn;
|
char *dhcp_fqdn;
|
||||||
char *dhcp_vendor_class_identifier;
|
char *dhcp_vendor_class_identifier;
|
||||||
gint32 link_local;
|
gint32 link_local;
|
||||||
|
gint32 dhcp_ipv6_only_preferred;
|
||||||
} NMSettingIP4ConfigPrivate;
|
} NMSettingIP4ConfigPrivate;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -146,6 +148,26 @@ nm_setting_ip4_config_get_link_local(NMSettingIP4Config *setting)
|
|||||||
return NM_SETTING_IP4_CONFIG_GET_PRIVATE(setting)->link_local;
|
return NM_SETTING_IP4_CONFIG_GET_PRIVATE(setting)->link_local;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* nm_setting_ip4_config_get_dhcp_ipv6_only_preferred:
|
||||||
|
* @setting: the #NMSettingIP4Config
|
||||||
|
*
|
||||||
|
* Returns the value in the #NMSettingIP4Config:dhcp-ipv6-only-preferred
|
||||||
|
* property.
|
||||||
|
*
|
||||||
|
* Returns: the DHCP IPv6-only preferred property value
|
||||||
|
*
|
||||||
|
* Since: 1.52
|
||||||
|
**/
|
||||||
|
NMSettingIP4DhcpIpv6OnlyPreferred
|
||||||
|
nm_setting_ip4_config_get_dhcp_ipv6_only_preferred(NMSettingIP4Config *setting)
|
||||||
|
{
|
||||||
|
g_return_val_if_fail(NM_IS_SETTING_IP4_CONFIG(setting),
|
||||||
|
NM_SETTING_IP4_DHCP_IPV6_ONLY_PREFERRED_DEFAULT);
|
||||||
|
|
||||||
|
return NM_SETTING_IP4_CONFIG_GET_PRIVATE(setting)->dhcp_ipv6_only_preferred;
|
||||||
|
}
|
||||||
|
|
||||||
static gboolean
|
static gboolean
|
||||||
verify(NMSetting *setting, NMConnection *connection, GError **error)
|
verify(NMSetting *setting, NMConnection *connection, GError **error)
|
||||||
{
|
{
|
||||||
@@ -1315,6 +1337,38 @@ nm_setting_ip4_config_class_init(NMSettingIP4ConfigClass *klass)
|
|||||||
* ---end---
|
* ---end---
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* NMSettingIP4Config:dhcp-ipv6-only-preferred
|
||||||
|
*
|
||||||
|
* Controls the "IPv6-Only Preferred" DHCPv4 option (RFC 8925).
|
||||||
|
*
|
||||||
|
* When set to %NM_SETTING_IP4_DHCP_IPV6_ONLY_PREFERRED_YES, the host adds the
|
||||||
|
* option to the parameter request list; if the DHCP server sends the option back,
|
||||||
|
* the host stops the DHCP client for the time interval specified in the option.
|
||||||
|
*
|
||||||
|
* Enable this feature if the host supports an IPv6-only mode, i.e. either all
|
||||||
|
* applications are IPv6-only capable or there is a form of 464XLAT deployed.
|
||||||
|
*
|
||||||
|
* When set to %NM_SETTING_IP4_DHCP_IPV6_ONLY_PREFERRED_DEFAULT, the actual value
|
||||||
|
* is looked up in the global configuration; if not specified, it defaults to
|
||||||
|
* %NM_SETTING_IP4_DHCP_IPV6_ONLY_PREFERRED_NO.
|
||||||
|
*
|
||||||
|
* If the connection has IPv6 method set to "disabled", this property does not
|
||||||
|
* have effect and the "IPv6-Only Preferred" option is always disabled.
|
||||||
|
*
|
||||||
|
* Since: 1.52
|
||||||
|
*/
|
||||||
|
_nm_setting_property_define_direct_enum(properties_override,
|
||||||
|
obj_properties,
|
||||||
|
NM_SETTING_IP4_CONFIG_DHCP_IPV6_ONLY_PREFERRED,
|
||||||
|
PROP_DHCP_IPV6_ONLY_PREFERRED,
|
||||||
|
NM_TYPE_SETTING_IP4_DHCP_IPV6_ONLY_PREFERRED,
|
||||||
|
NM_SETTING_IP4_DHCP_IPV6_ONLY_PREFERRED_DEFAULT,
|
||||||
|
NM_SETTING_PARAM_NONE,
|
||||||
|
NULL,
|
||||||
|
NMSettingIP4ConfigPrivate,
|
||||||
|
dhcp_ipv6_only_preferred);
|
||||||
|
|
||||||
g_object_class_install_properties(object_class, _PROPERTY_ENUMS_LAST, obj_properties);
|
g_object_class_install_properties(object_class, _PROPERTY_ENUMS_LAST, obj_properties);
|
||||||
|
|
||||||
_nm_setting_class_commit(setting_class,
|
_nm_setting_class_commit(setting_class,
|
||||||
|
@@ -4088,6 +4088,7 @@ test_connection_diff_a_only(void)
|
|||||||
{NM_SETTING_IP4_CONFIG_DHCP_VENDOR_CLASS_IDENTIFIER, NM_SETTING_DIFF_RESULT_IN_A},
|
{NM_SETTING_IP4_CONFIG_DHCP_VENDOR_CLASS_IDENTIFIER, NM_SETTING_DIFF_RESULT_IN_A},
|
||||||
{NM_SETTING_IP_CONFIG_DHCP_REJECT_SERVERS, NM_SETTING_DIFF_RESULT_IN_A},
|
{NM_SETTING_IP_CONFIG_DHCP_REJECT_SERVERS, NM_SETTING_DIFF_RESULT_IN_A},
|
||||||
{NM_SETTING_IP4_CONFIG_LINK_LOCAL, NM_SETTING_DIFF_RESULT_IN_A},
|
{NM_SETTING_IP4_CONFIG_LINK_LOCAL, NM_SETTING_DIFF_RESULT_IN_A},
|
||||||
|
{NM_SETTING_IP4_CONFIG_DHCP_IPV6_ONLY_PREFERRED, NM_SETTING_DIFF_RESULT_IN_A},
|
||||||
{NM_SETTING_IP_CONFIG_AUTO_ROUTE_EXT_GW, NM_SETTING_DIFF_RESULT_IN_A},
|
{NM_SETTING_IP_CONFIG_AUTO_ROUTE_EXT_GW, NM_SETTING_DIFF_RESULT_IN_A},
|
||||||
{NM_SETTING_IP_CONFIG_REPLACE_LOCAL_RULE, NM_SETTING_DIFF_RESULT_IN_A},
|
{NM_SETTING_IP_CONFIG_REPLACE_LOCAL_RULE, NM_SETTING_DIFF_RESULT_IN_A},
|
||||||
{NM_SETTING_IP_CONFIG_DHCP_SEND_RELEASE, NM_SETTING_DIFF_RESULT_IN_A},
|
{NM_SETTING_IP_CONFIG_DHCP_SEND_RELEASE, NM_SETTING_DIFF_RESULT_IN_A},
|
||||||
|
@@ -32,6 +32,7 @@ G_BEGIN_DECLS
|
|||||||
#define NM_SETTING_IP4_CONFIG_DHCP_CLIENT_ID "dhcp-client-id"
|
#define NM_SETTING_IP4_CONFIG_DHCP_CLIENT_ID "dhcp-client-id"
|
||||||
#define NM_SETTING_IP4_CONFIG_DHCP_FQDN "dhcp-fqdn"
|
#define NM_SETTING_IP4_CONFIG_DHCP_FQDN "dhcp-fqdn"
|
||||||
#define NM_SETTING_IP4_CONFIG_DHCP_VENDOR_CLASS_IDENTIFIER "dhcp-vendor-class-identifier"
|
#define NM_SETTING_IP4_CONFIG_DHCP_VENDOR_CLASS_IDENTIFIER "dhcp-vendor-class-identifier"
|
||||||
|
#define NM_SETTING_IP4_CONFIG_DHCP_IPV6_ONLY_PREFERRED "dhcp-ipv6-only-preferred"
|
||||||
#define NM_SETTING_IP4_CONFIG_LINK_LOCAL "link-local"
|
#define NM_SETTING_IP4_CONFIG_LINK_LOCAL "link-local"
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -103,6 +104,23 @@ typedef enum {
|
|||||||
NM_SETTING_IP4_LL_FALLBACK = 4,
|
NM_SETTING_IP4_LL_FALLBACK = 4,
|
||||||
} NMSettingIP4LinkLocal;
|
} NMSettingIP4LinkLocal;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* NMSettingIP4DhcpIpv6OnlyPreferred:
|
||||||
|
* @NM_SETTING_IP4_DHCP_IPV6_ONLY_PREFERRED_DEFAULT: use the global default value
|
||||||
|
* @NM_SETTING_IP4_DHCP_IPV6_ONLY_PREFERRED_NO: the option is disabled
|
||||||
|
* @NM_SETTING_IP4_DHCP_IPV6_ONLY_PREFERRED_YES: the option is enabled
|
||||||
|
*
|
||||||
|
* #NMSettingIP4DhcpIpv6OnlyPreferred values specify if the "IPv6-Only Preferred"
|
||||||
|
* option (RFC 8925) for DHCPv4 is enabled.
|
||||||
|
*
|
||||||
|
* Since: 1.52
|
||||||
|
*/
|
||||||
|
typedef enum {
|
||||||
|
NM_SETTING_IP4_DHCP_IPV6_ONLY_PREFERRED_DEFAULT = -1,
|
||||||
|
NM_SETTING_IP4_DHCP_IPV6_ONLY_PREFERRED_NO = 0,
|
||||||
|
NM_SETTING_IP4_DHCP_IPV6_ONLY_PREFERRED_YES = 1,
|
||||||
|
} NMSettingIP4DhcpIpv6OnlyPreferred;
|
||||||
|
|
||||||
typedef struct _NMSettingIP4ConfigClass NMSettingIP4ConfigClass;
|
typedef struct _NMSettingIP4ConfigClass NMSettingIP4ConfigClass;
|
||||||
|
|
||||||
GType nm_setting_ip4_config_get_type(void);
|
GType nm_setting_ip4_config_get_type(void);
|
||||||
@@ -119,6 +137,10 @@ const char *nm_setting_ip4_config_get_dhcp_vendor_class_identifier(NMSettingIP4C
|
|||||||
NM_AVAILABLE_IN_1_42
|
NM_AVAILABLE_IN_1_42
|
||||||
NMSettingIP4LinkLocal nm_setting_ip4_config_get_link_local(NMSettingIP4Config *setting);
|
NMSettingIP4LinkLocal nm_setting_ip4_config_get_link_local(NMSettingIP4Config *setting);
|
||||||
|
|
||||||
|
NM_AVAILABLE_IN_1_52
|
||||||
|
NMSettingIP4DhcpIpv6OnlyPreferred
|
||||||
|
nm_setting_ip4_config_get_dhcp_ipv6_only_preferred(NMSettingIP4Config *setting);
|
||||||
|
|
||||||
G_END_DECLS
|
G_END_DECLS
|
||||||
|
|
||||||
#endif /* __NM_SETTING_IP4_CONFIG_H__ */
|
#endif /* __NM_SETTING_IP4_CONFIG_H__ */
|
||||||
|
@@ -6422,6 +6422,9 @@ static const NMMetaPropertyInfo *const property_infos_IP4_CONFIG[] = {
|
|||||||
PROPERTY_INFO_WITH_DESC (NM_SETTING_IP4_CONFIG_DHCP_VENDOR_CLASS_IDENTIFIER,
|
PROPERTY_INFO_WITH_DESC (NM_SETTING_IP4_CONFIG_DHCP_VENDOR_CLASS_IDENTIFIER,
|
||||||
.property_type = &_pt_gobject_string,
|
.property_type = &_pt_gobject_string,
|
||||||
),
|
),
|
||||||
|
PROPERTY_INFO_WITH_DESC (NM_SETTING_IP4_CONFIG_DHCP_IPV6_ONLY_PREFERRED,
|
||||||
|
.property_type = &_pt_gobject_enum,
|
||||||
|
),
|
||||||
PROPERTY_INFO_WITH_DESC (NM_SETTING_IP4_CONFIG_LINK_LOCAL,
|
PROPERTY_INFO_WITH_DESC (NM_SETTING_IP4_CONFIG_LINK_LOCAL,
|
||||||
.property_type = &_pt_gobject_enum,
|
.property_type = &_pt_gobject_enum,
|
||||||
.property_typ_data = DEFINE_PROPERTY_TYP_DATA (
|
.property_typ_data = DEFINE_PROPERTY_TYP_DATA (
|
||||||
|
@@ -186,6 +186,7 @@
|
|||||||
#define DESCRIBE_DOC_NM_SETTING_IP4_CONFIG_DHCP_HOSTNAME N_("If the \"dhcp-send-hostname\" property is TRUE, then the specified name will be sent to the DHCP server when acquiring a lease. This property and \"dhcp-fqdn\" are mutually exclusive and cannot be set at the same time.")
|
#define DESCRIBE_DOC_NM_SETTING_IP4_CONFIG_DHCP_HOSTNAME N_("If the \"dhcp-send-hostname\" property is TRUE, then the specified name will be sent to the DHCP server when acquiring a lease. This property and \"dhcp-fqdn\" are mutually exclusive and cannot be set at the same time.")
|
||||||
#define DESCRIBE_DOC_NM_SETTING_IP4_CONFIG_DHCP_HOSTNAME_FLAGS N_("Flags for the DHCP hostname and FQDN. Currently, this property only includes flags to control the FQDN flags set in the DHCP FQDN option. Supported FQDN flags are \"fqdn-serv-update\" (0x1), \"fqdn-encoded\" (0x2) and \"fqdn-no-update\" (0x4). When no FQDN flag is set and \"fqdn-clear-flags\" (0x8) is set, the DHCP FQDN option will contain no flag. Otherwise, if no FQDN flag is set and \"fqdn-clear-flags\" (0x8) is not set, the standard FQDN flags are set in the request: \"fqdn-serv-update\" (0x1), \"fqdn-encoded\" (0x2) for IPv4 and \"fqdn-serv-update\" (0x1) for IPv6. When this property is set to the default value \"none\" (0x0), a global default is looked up in NetworkManager configuration. If that value is unset or also \"none\" (0x0), then the standard FQDN flags described above are sent in the DHCP requests.")
|
#define DESCRIBE_DOC_NM_SETTING_IP4_CONFIG_DHCP_HOSTNAME_FLAGS N_("Flags for the DHCP hostname and FQDN. Currently, this property only includes flags to control the FQDN flags set in the DHCP FQDN option. Supported FQDN flags are \"fqdn-serv-update\" (0x1), \"fqdn-encoded\" (0x2) and \"fqdn-no-update\" (0x4). When no FQDN flag is set and \"fqdn-clear-flags\" (0x8) is set, the DHCP FQDN option will contain no flag. Otherwise, if no FQDN flag is set and \"fqdn-clear-flags\" (0x8) is not set, the standard FQDN flags are set in the request: \"fqdn-serv-update\" (0x1), \"fqdn-encoded\" (0x2) for IPv4 and \"fqdn-serv-update\" (0x1) for IPv6. When this property is set to the default value \"none\" (0x0), a global default is looked up in NetworkManager configuration. If that value is unset or also \"none\" (0x0), then the standard FQDN flags described above are sent in the DHCP requests.")
|
||||||
#define DESCRIBE_DOC_NM_SETTING_IP4_CONFIG_DHCP_IAID N_("A string containing the \"Identity Association Identifier\" (IAID) used by the DHCP client. The string can be a 32-bit number (either decimal, hexadecimal or as colon separated hexadecimal numbers). Alternatively it can be set to the special values \"mac\", \"perm-mac\", \"ifname\" or \"stable\". When set to \"mac\" (or \"perm-mac\"), the last 4 bytes of the current (or permanent) MAC address are used as IAID. When set to \"ifname\", the IAID is computed by hashing the interface name. The special value \"stable\" can be used to generate an IAID based on the stable-id (see connection.stable-id), a per-host key and the interface name. When the property is unset, the value from global configuration is used; if no global default is set then the IAID is assumed to be \"ifname\". For DHCPv4, the IAID is only used with \"ipv4.dhcp-client-id\" values \"duid\" and \"ipv6-duid\" to generate the client-id. For DHCPv6, note that at the moment this property is only supported by the \"internal\" DHCPv6 plugin. The \"dhclient\" DHCPv6 plugin always derives the IAID from the MAC address. The actually used DHCPv6 IAID for a currently activated interface is exposed in the lease information of the device.")
|
#define DESCRIBE_DOC_NM_SETTING_IP4_CONFIG_DHCP_IAID N_("A string containing the \"Identity Association Identifier\" (IAID) used by the DHCP client. The string can be a 32-bit number (either decimal, hexadecimal or as colon separated hexadecimal numbers). Alternatively it can be set to the special values \"mac\", \"perm-mac\", \"ifname\" or \"stable\". When set to \"mac\" (or \"perm-mac\"), the last 4 bytes of the current (or permanent) MAC address are used as IAID. When set to \"ifname\", the IAID is computed by hashing the interface name. The special value \"stable\" can be used to generate an IAID based on the stable-id (see connection.stable-id), a per-host key and the interface name. When the property is unset, the value from global configuration is used; if no global default is set then the IAID is assumed to be \"ifname\". For DHCPv4, the IAID is only used with \"ipv4.dhcp-client-id\" values \"duid\" and \"ipv6-duid\" to generate the client-id. For DHCPv6, note that at the moment this property is only supported by the \"internal\" DHCPv6 plugin. The \"dhclient\" DHCPv6 plugin always derives the IAID from the MAC address. The actually used DHCPv6 IAID for a currently activated interface is exposed in the lease information of the device.")
|
||||||
|
#define DESCRIBE_DOC_NM_SETTING_IP4_CONFIG_DHCP_IPV6_ONLY_PREFERRED N_("Controls the \"IPv6-Only Preferred\" DHCPv4 option (RFC 8925). When set to \"yes\" (1), the host adds the option to the parameter request list; if the DHCP server sends the option back, the host stops the DHCP client for the time interval specified in the option. Enable this feature if the host supports an IPv6-only mode, i.e. either all applications are IPv6-only capable or there is a form of 464XLAT deployed. When set to \"default\" (-1), the actual value is looked up in the global configuration; if not specified, it defaults to \"no\" (0). If the connection has IPv6 method set to \"disabled\", this property does not have effect and the \"IPv6-Only Preferred\" option is always disabled.")
|
||||||
#define DESCRIBE_DOC_NM_SETTING_IP4_CONFIG_DHCP_REJECT_SERVERS N_("Array of servers from which DHCP offers must be rejected. This property is useful to avoid getting a lease from misconfigured or rogue servers. For DHCPv4, each element must be an IPv4 address, optionally followed by a slash and a prefix length (e.g. \"192.168.122.0/24\"). This property is currently not implemented for DHCPv6.")
|
#define DESCRIBE_DOC_NM_SETTING_IP4_CONFIG_DHCP_REJECT_SERVERS N_("Array of servers from which DHCP offers must be rejected. This property is useful to avoid getting a lease from misconfigured or rogue servers. For DHCPv4, each element must be an IPv4 address, optionally followed by a slash and a prefix length (e.g. \"192.168.122.0/24\"). This property is currently not implemented for DHCPv6.")
|
||||||
#define DESCRIBE_DOC_NM_SETTING_IP4_CONFIG_DHCP_SEND_HOSTNAME N_("If TRUE, a hostname is sent to the DHCP server when acquiring a lease. Some DHCP servers use this hostname to update DNS databases, essentially providing a static hostname for the computer. If the \"dhcp-hostname\" property is NULL and this property is TRUE, the current persistent hostname of the computer is sent.")
|
#define DESCRIBE_DOC_NM_SETTING_IP4_CONFIG_DHCP_SEND_HOSTNAME N_("If TRUE, a hostname is sent to the DHCP server when acquiring a lease. Some DHCP servers use this hostname to update DNS databases, essentially providing a static hostname for the computer. If the \"dhcp-hostname\" property is NULL and this property is TRUE, the current persistent hostname of the computer is sent.")
|
||||||
#define DESCRIBE_DOC_NM_SETTING_IP4_CONFIG_DHCP_SEND_RELEASE N_("Whether the DHCP client will send RELEASE message when bringing the connection down. The default value is \"default\" (-1). When the default value is specified, then the global value from NetworkManager configuration is looked up, if not set, it is considered as FALSE.")
|
#define DESCRIBE_DOC_NM_SETTING_IP4_CONFIG_DHCP_SEND_RELEASE N_("Whether the DHCP client will send RELEASE message when bringing the connection down. The default value is \"default\" (-1). When the default value is specified, then the global value from NetworkManager configuration is looked up, if not set, it is considered as FALSE.")
|
||||||
|
@@ -1410,6 +1410,10 @@
|
|||||||
<property name="dhcp-vendor-class-identifier"
|
<property name="dhcp-vendor-class-identifier"
|
||||||
nmcli-description="The Vendor Class Identifier DHCP option (60). Special characters in the data string may be escaped using C-style escapes, nevertheless this property cannot contain nul bytes. If the per-profile value is unspecified (the default), a global connection default gets consulted. If still unspecified, the DHCP option is not sent to the server."
|
nmcli-description="The Vendor Class Identifier DHCP option (60). Special characters in the data string may be escaped using C-style escapes, nevertheless this property cannot contain nul bytes. If the per-profile value is unspecified (the default), a global connection default gets consulted. If still unspecified, the DHCP option is not sent to the server."
|
||||||
format="string" />
|
format="string" />
|
||||||
|
<property name="dhcp-ipv6-only-preferred"
|
||||||
|
nmcli-description="Controls the "IPv6-Only Preferred" DHCPv4 option (RFC 8925). When set to "yes" (1), the host adds the option to the parameter request list; if the DHCP server sends the option back, the host stops the DHCP client for the time interval specified in the option. Enable this feature if the host supports an IPv6-only mode, i.e. either all applications are IPv6-only capable or there is a form of 464XLAT deployed. When set to "default" (-1), the actual value is looked up in the global configuration; if not specified, it defaults to "no" (0). If the connection has IPv6 method set to "disabled", this property does not have effect and the "IPv6-Only Preferred" option is always disabled."
|
||||||
|
format="choice (NMSettingIP4DhcpIpv6OnlyPreferred)"
|
||||||
|
values="default (-1), no (0), yes (1)" />
|
||||||
<property name="link-local"
|
<property name="link-local"
|
||||||
nmcli-description="Enable and disable the IPv4 link-local configuration independently of the ipv4.method configuration. This allows a link-local address (169.254.x.y/16) to be obtained in addition to other addresses, such as those manually configured or obtained from a DHCP server. When set to "auto", the value is dependent on "ipv4.method". When set to "default", it honors the global connection default, before falling back to "auto". Note that if "ipv4.method" is "disabled", then link local addressing is always disabled too. The default is "default". Since 1.52, when set to "fallback", a link-local address is obtained if no other IPv4 address is set."
|
nmcli-description="Enable and disable the IPv4 link-local configuration independently of the ipv4.method configuration. This allows a link-local address (169.254.x.y/16) to be obtained in addition to other addresses, such as those manually configured or obtained from a DHCP server. When set to "auto", the value is dependent on "ipv4.method". When set to "default", it honors the global connection default, before falling back to "auto". Note that if "ipv4.method" is "disabled", then link local addressing is always disabled too. The default is "default". Since 1.52, when set to "fallback", a link-local address is obtained if no other IPv4 address is set."
|
||||||
format="choice (NMSettingIP4LinkLocal)"
|
format="choice (NMSettingIP4LinkLocal)"
|
||||||
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user