Configuring ipv4.dhcp-send-hostname globally



Hi All,

I'm trying to make a device which frequently roams between untrusted
wireless networks (in non-pandemic times) less easy to uniquely identify
by not sending the hostname in DHCP requests (in addition to other
measures like MAC address randomization).  It seems that this can be
accomplished with connection settings:

ipv4.dhcp-send-hostname=false
ipv6.dhcp-send-hostname=false

To avoid the need to configure these for every new wireless connection
profile, I added them to a .conf file in /etc/NetworkManager/conf.d/,
which causes `NetworkManager --print-config` to output:

# WARNING: unknown key 'ipv4.dhcp-send-hostname' in section [connection-no-dhcp-send-hostname] of file 
'/etc/NetworkManager/conf.d/50-no-dhcp-send-hostname.conf'
# WARNING: unknown key 'ipv6.dhcp-send-hostname' in section [connection-no-dhcp-send-hostname] of file 
'/etc/NetworkManager/conf.d/50-no-dhcp-send-hostname.conf'

Perhaps this is because the property does not support having a default
value configured, as it is not listed in NetworkManager.conf(5)
(although the error message does not make this clear).  If that is the
case, I'd be curious to understand the rationale and whether it might be
acceptable to support in the future.  (I'd be happy to send a patch/MR,
but would appreciate a pointer for how to do so.)

Alternatively, if I've made a mistake or there is an easier/better way
to accomplish this, so much the better.

Thanks,
Kevin


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]