linux-stable/net
Alex Henrie f4bcbf360a net: ipv6/addrconf: clamp preferred_lft to the minimum required
If the preferred lifetime was less than the minimum required lifetime,
ipv6_create_tempaddr would error out without creating any new address.
On my machine and network, this error happened immediately with the
preferred lifetime set to 5 seconds or less, after a few minutes with
the preferred lifetime set to 6 seconds, and not at all with the
preferred lifetime set to 7 seconds. During my investigation, I found a
Stack Exchange post from another person who seems to have had the same
problem: They stopped getting new addresses if they lowered the
preferred lifetime below 3 seconds, and they didn't really know why.

The preferred lifetime is a preference, not a hard requirement. The
kernel does not strictly forbid new connections on a deprecated address,
nor does it guarantee that the address will be disposed of the instant
its total valid lifetime expires. So rather than disable IPv6 privacy
extensions altogether if the minimum required lifetime swells above the
preferred lifetime, it is more in keeping with the user's intent to
increase the temporary address's lifetime to the minimum necessary for
the current network conditions.

With these fixes, setting the preferred lifetime to 5 or 6 seconds "just
works" because the extra fraction of a second is practically
unnoticeable. It's even possible to reduce the time before deprecation
to 1 or 2 seconds by setting /proc/sys/net/ipv6/conf/*/regen_min_advance
and /proc/sys/net/ipv6/conf/*/dad_transmits to 0. I realize that that is
a pretty niche use case, but I know at least one person who would gladly
sacrifice performance and convenience to be sure that they are getting
the maximum possible level of privacy.

Link: https://serverfault.com/a/1031168/310447
Signed-off-by: Alex Henrie <alexhenrie24@gmail.com>
Reviewed-by: David Ahern <dsahern@kernel.org>
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
2024-02-15 15:34:40 +01:00
..
6lowpan
9p net: 9p: avoid freeing uninit memory in p9pdu_vreadf 2023-12-13 05:44:30 +09:00
802 net: fill in MODULE_DESCRIPTION()s under net/802* 2023-10-28 11:29:28 +01:00
8021q vlan: use netdev_lockdep_set_classes() 2024-02-13 18:45:06 -08:00
appletalk net: remove SOCK_DEBUG leftovers 2023-12-26 20:31:01 +00:00
atm net: fill in MODULE_DESCRIPTION()s for ATM 2024-01-05 08:04:23 -08:00
ax25
batman-adv This cleanup patchset includes the following patches: 2024-02-02 12:44:16 +00:00
bluetooth TTY/Serial changes for 6.8-rc1 2024-01-18 11:37:24 -08:00
bpf bpf, net: switch to dynamic registration 2024-01-23 17:12:46 -08:00
bridge net-sysfs: convert dev->operstate reads to lockless ones 2024-02-14 11:20:13 +00:00
caif net: fill in MODULE_DESCRIPTION()s for CAIF 2024-01-05 08:06:35 -08:00
can can: canxl: add virtual CAN network identifier support 2024-02-13 11:47:13 +01:00
ceph libceph: remove MAX_EXTENTS check for sparse reads 2024-01-15 15:40:50 +01:00
core net: remove dev_base_lock 2024-02-14 11:20:14 +00:00
dcb
dccp net: dccp: Simplify the allocation of slab caches in dccp_ackvec_init 2024-02-02 12:19:26 +00:00
devlink devlink: avoid potential loop in devlink_rel_nested_in_notify_work() 2024-02-06 18:45:16 -08:00
dns_resolver Networking changes for 6.8. 2024-01-11 10:07:29 -08:00
dsa net: dsa: tag_sja1105: remove "inline" keyword 2024-02-08 19:03:57 -08:00
ethernet
ethtool ethtool: do not use rtnl in ethnl_default_dumpit() 2024-02-08 19:08:51 -08:00
handshake Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2023-10-26 13:46:28 -07:00
hsr net: add netdev_set_operstate() helper 2024-02-14 11:20:13 +00:00
ieee802154 net: fill in MODULE_DESCRIPTION()s for ieee802154 2024-01-29 12:12:51 +00:00
ife net: sched: ife: fix potential use-after-free 2023-12-15 10:50:18 +00:00
ipv4 tcp: no need to use acceptable for conn_request 2024-02-15 12:57:11 +01:00
ipv6 net: ipv6/addrconf: clamp preferred_lft to the minimum required 2024-02-15 15:34:40 +01:00
iucv iucv: make iucv_bus const 2023-12-29 07:46:38 +00:00
kcm net: kcm: fix direct access to bv_len 2024-01-03 18:37:22 -08:00
key
l2tp ipv4: Set the routing scope properly in ip_route_output_ports(). 2024-02-12 17:33:05 -08:00
l3mdev
lapb
llc llc: call sock_orphan() at release time 2024-01-30 13:49:09 +01:00
mac80211 wifi: mac80211: accept broadcast probe responses on 6 GHz 2024-02-02 13:11:59 +01:00
mac802154 mac802154: Avoid new associations while disassociating 2023-12-15 11:14:57 +01:00
mctp
mpls
mptcp mptcp: annotate lockless accesses around read-mostly fields 2024-02-05 11:18:09 +00:00
ncsi net/ncsi: Add NC-SI 1.2 Get MC MAC Address command 2023-11-18 15:00:51 +00:00
netfilter netfilter: conntrack: expedite rcu in nf_conntrack_cleanup_net_list 2024-02-12 12:17:03 +00:00
netlabel netlabel: cleanup struct netlbl_lsm_catmap 2024-02-07 12:38:30 +00:00
netlink Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2024-01-25 14:20:08 -08:00
netrom
nfc nfc: hci: Save a few bytes of memory when registering a 'nfc_llc' engine 2024-02-06 15:36:06 +01:00
nsh
openvswitch net/sched: act_ct: Always fill offloading tuple iifidx 2023-11-08 17:47:08 -08:00
packet sock_diag: add module pointer to "struct sock_diag_handler" 2024-01-23 15:13:54 +01:00
phonet
psample genetlink: Use internal flags for multicast groups 2023-12-29 08:43:59 +00:00
qrtr net: qrtr: ns: Return 0 if server port is not present 2024-01-01 18:41:29 +00:00
rds net: rds: Simplify the allocation of slab caches in rds_conn_init 2024-01-30 17:08:19 -08:00
rfkill Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2023-12-21 22:17:23 +01:00
rose net/rose: fix races in rose_kill_by_device() 2023-12-15 11:59:53 +00:00
rxrpc rxrpc: Fix counting of new acks and nacks 2024-02-05 12:34:07 +00:00
sched net: sched: codel replace GPLv2/BSD boilerplate 2024-02-13 13:45:19 +01:00
sctp sctp: Simplify the allocation of slab caches 2024-02-02 12:17:32 +00:00
smc net/smc: change the term virtual ISM to Emulated-ISM 2024-02-07 18:24:19 -08:00
strparser
sunrpc NFSv4.1: Assign the right value for initval and retries for rpc timeout 2024-01-29 13:39:48 -05:00
switchdev
tipc tipc: Cleanup tipc_nl_bearer_add() error paths 2024-02-15 13:18:19 +01:00
tls net: tls, fix WARNIING in __sk_msg_free 2024-01-14 12:17:14 +00:00
unix Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2024-02-08 15:30:33 -08:00
vmw_vsock sock_diag: add module pointer to "struct sock_diag_handler" 2024-01-23 15:13:54 +01:00
wireless wifi: cfg80211: detect stuck ECSA element in probe resp 2024-02-02 13:08:58 +01:00
x25 net: remove SOCK_DEBUG leftovers 2023-12-26 20:31:01 +00:00
xdp Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2024-01-25 14:20:08 -08:00
xfrm xfrm: interface: use exit_batch_rtnl() method 2024-02-07 18:55:12 -08:00
compat.c file: stop exposing receive_fd_user() 2023-12-12 14:24:14 +01:00
devres.c
Kconfig bpfilter: remove bpfilter 2024-01-04 10:23:10 -08:00
Kconfig.debug
Makefile af_unix: Remove CONFIG_UNIX_SCM. 2024-01-31 16:41:16 -08:00
socket.c vfs-6.8.iov_iter 2024-01-08 11:43:04 -08:00
sysctl_net.c