From: Carsten Strotmann <cas@strotmann.de>
To: davem@davemloft.net, kuznet@ms2.inr.ac.ru,
yoshfuji@linux-ipv6.org, netdev@vger.kernel.org,
fgont@si6networks.com
Subject: Linux kernel and RFC 7217 support
Date: Sun, 3 Feb 2019 22:31:03 +0100 [thread overview]
Message-ID: <fae45803-d031-1897-073a-5edccf197426@strotmann.de> (raw)
Hi,
I'm testing IPv6 stable-secret identifiers SII under Linux RFC 7217.
<https://tools.ietf.org/html/rfc7217>
One important feature of RFC 7217 is to deliver stable IPv6 addresses
for server addressing use that will not change in case of new network
hardware (changed hardware address). Besides other benefits of SII, this
is an important feature compared with EUI64 IPv6 addresses.
However during my testing, the SII addresses were always changing when
changing the network hardware address. After investigating into
NetworkManager (Red Hat), wicked (SUSE) and disabling all these, working
with the kernel alone and sysctl values, the issue was still showing.
I'm not a C programmer, but I took a look into the source code and in
linux-4.20.6/net/ipv6/addrconf.c
I found:
[...]
sha_init(digest);
memset(&data, 0, sizeof(data));
memset(workspace, 0, sizeof(workspace));
---> memcpy(data.hwaddr, idev->dev->perm_addr, idev->dev->addr_len);
data.prefix[0] = address->s6_addr32[0];
data.prefix[1] = address->s6_addr32[1];
data.secret = secret;
data.dad_count = dad_count;
sha_transform(digest, data.__data, workspace);
temp = *address;
temp.s6_addr32[2] = (__force __be32)digest[0];
temp.s6_addr32[3] = (__force __be32)digest[1];
[...]
The marked line looks to me as if the interface hardware address is
mixed into the SHA hash that will generate the SII address.
Is this an correct observation?
If yes, what is the rationale for this?
If my suspected behavior of the Linux kernel is the true, it does really
reduce the usefulness of IPv6 SII addresses in datacenter/enterprise
environments.
Best regards
Carsten Strotmann
reply other threads:[~2019-02-03 21:40 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=fae45803-d031-1897-073a-5edccf197426@strotmann.de \
--to=cas@strotmann.de \
--cc=davem@davemloft.net \
--cc=fgont@si6networks.com \
--cc=kuznet@ms2.inr.ac.ru \
--cc=netdev@vger.kernel.org \
--cc=yoshfuji@linux-ipv6.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox