RFC 7217:为 IPv6 无状态地址自动配置(SLAAC)生成语义不透明接口标识符的方法 原文标题:RFC 7217: A Method for Generating Semantically Opaque Interface Identifiers with IPv6 Stateless Address Autoconfiguration (SLAAC) | RFC Editor
内容概要总结
IETF 标准轨道 RFC 7217(2014 年 4 月,Gont 著),规定一种为 IPv6 SLAAC 生成接口标识符(IID)的方法:所配置的地址在每个子网内稳定,但当主机从一个网络移动到另一个网络时 IID 会改变。方法作为基于硬件地址(IEEE MAC)生成 IID 的替代方案,在不牺牲安全与隐私的前提下获得稳定地址的好处。核心算法为 RID = F(Prefix, Net_Iface, Network_ID, DAD_Counter, secret_key),其中 F() 是外部不可计算、难以逆转的伪随机函数(推荐 SHA-1/SHA-256,明确禁用 MD5),F() 输出至少 64 位,IID 取 RID 最低有效位。文档阐明设计目标(前缀间 IID 统计不同、外部不可预测、可独立于硬件)、Net_Iface 的稳定性要求、Network_ID 可选参数对缓解跨网络关联的作用、secret_key 至少 128 位、DAD 冲突解决流程(DAD_Counter 递增,常量 IDGEN_RETRIES 默认 3、IDGEN_DELAY 默认 1 秒),以及安全考量(防主机跟踪与地址扫描、但无法抵御伪造路由器通告,需配合 RA-Guard/SEND)。附录 A 讨论 Net_Iface 的可能来源(接口索引、接口名、链路层地址、逻辑网络服务标识 UUID)。
翻译内容
原文内容(English)
RFC 7217:一种为 IPv6 无状态地址自动配置(SLAAC)生成语义不透明接口标识符的方法
类别:标准轨道(Standards Track)
ISSN: 2070-1721
F. Gont
SI6 Networks / UTN-FRH
2014 年 4 月
摘要
本文档规定了一种为 IPv6 无状态地址自动配置(SLAAC)生成 IPv6 接口标识符的方法,使得用该方法配置的 IPv6 地址在每个子网内是稳定的,但当主机从一个网络移动到另一个网络时,相应的接口标识符会改变。该方法的用意是作为"基于硬件地址(例如 IEEE 局域网媒体访问控制 (MAC) 地址)生成接口标识符"的一种替代方案,从而既能获得稳定地址的好处,又不牺牲用户的安全与隐私。本文档规定的方法适用于主机可能采用的所有前缀,包括链路本地、全局和唯一本地前缀(及其对应的地址)。
本文档状态(Status of This Memo)
这是一份 Internet Standards Track 文档。
本文档是 Internet Engineering Task Force (IETF) 的产物。它代表 IETF 社区的共识。它已经过公开审查,并已获 Internet Engineering Steering Group (IESG) 批准发布。关于 Internet Standards 的更多信息见 RFC 5741 第 2 节。
关于本文档当前状态、任何勘误以及如何提供反馈的信息,可从 http://www.rfc-editor.org/info/rfc7217 获取。
版权声明(Copyright Notice)
Copyright (c) 2014 IETF Trust 及被标识为本文档作者的人员。保留所有权利。
本文档受 BCP 78 以及本文档发布之日生效的 IETF Trust《与 IETF 文档相关的法律条款》(http://trustee.ietf.org/license-info)约束。请仔细阅读这些文档,因为它们描述了您对本文档的权利和限制。从本文档中提取的代码组件必须包含《Trust 法律条款》第 4.e 节所述的精简 BSD 许可证文本,并按精简 BSD 许可证所述不提供任何担保。
目录
- 引言
- 术语
- 与其他标准的关系
- 设计目标
- 算法规范
- 解决 DAD 冲突
- 规定的常量
- 安全考量
- 致谢
- 参考文献 10.1. 规范性引用 10.2. 参考性引用
附录 A. Net_Iface 参数的可能来源
A.1. 接口索引(Interface Index)
A.2. 接口名(Interface Name)
A.3. 链路层地址(Link-Layer Addresses)
A.4. 逻辑网络服务标识(Logical Network Service Identity)
1. 引言
[RFC4862] 规定了 IPv6 [RFC2460] 的无状态地址自动配置(SLAAC),它通常使主机配置一个或多个"稳定"地址,这些地址由一个本地路由器通告的网络前缀和一个通常内嵌硬件地址(例如 IEEE 局域网 MAC 地址)的接口标识符(IID)组成 [RFC4291]。密码学生成地址(CGA)[RFC3972] 是生成接口标识符的另一种方法;CGA 在安全邻居发现(SEND)[RFC3971] 协议中把一个公共签名密钥绑定到一个 IPv6 地址。
一般而言,传统 SLAAC 地址被认为能简化网络管理,因为它们简化了访问控制列表(ACL)和日志记录。然而,它们有许多缺点:
- 由于所得到的接口标识符不随时间变化,它们允许关联同一网络内主机的活动,从而对用户隐私产生负面影响(见 [ADDR-GEN-PRIVACY] 和 [IAB-PRIVACY])。
- 由于所得到的接口标识符跨网络恒定,所得到的 IPv6 地址可被利用来跨多个网络跟踪和关联主机的活动(例如跟踪和关联一个典型客户端从不同位置接入公共 Internet 的活动),从而对用户隐私产生负面影响。
- 由于在接口标识符中内嵌底层链路层地址会导致特定的地址模式,攻击者可利用此类模式在执行地址扫描攻击时缩小搜索空间 [IPV6-RECON]。例如,同一厂商(在给定时段内)生产的所有主机的 IPv6 地址,其接口标识符中很可能含有相同的 IEEE 组织唯一标识符(OUI)。
- 在接口标识符中内嵌底层硬件地址会泄露设备特定信息,可被利用来发起针对设备的攻击。
- 在接口标识符中内嵌底层链路层地址意味着,替换底层接口硬件将导致分配给该接口的 IPv6 地址发生变化。
[ADDR-GEN-PRIVACY] 提供了关于上述漏洞如何可被利用、以及本文档所讨论方法在多大程度上缓解它们的更多细节。
"IPv6 中无状态地址自动配置的隐私扩展" [RFC4941](下文称"临时地址")被引入,是为了增加窃听者和其他信息收集者(例如 Web 服务器日志或电子邮件头中的 IPv6 地址等)关联主机活动的难度,其本质上会产生临时的(且随机的)接口标识符。这些临时地址是在基于 IEEE 局域网 MAC 地址的传统 IPv6 地址之外额外生成的,其中临时地址用于"出站通信",而传统 SLAAC 地址用于"服务器"功能(即接收入站连接)。
应当注意,临时地址在若干方面可能颇具挑战。例如,从网络管理角度看,它们往往增加事件日志记录、故障排查、访问控制执行和服务质量等方面的复杂性。因此,一些组织禁用了临时地址的使用,即使以降低隐私为代价 [BROERSMA]。临时地址还可能导致实现复杂度增加,这在某些实现(例如某些嵌入式设备)中可能不可行或不理想。
在故意不使用临时地址的场景中(可能出于上述任一原因),主机只剩那些通常由底层硬件地址生成的稳定地址。在此类场景中,仍然希望拥有能够缓解地址扫描攻击、并且至少不会在从一个网络漫游到另一个网络时暴露主机身份的地址——同时不使相应网络的运维复杂化。
然而,即使部署了临时地址,仍有若干问题有待缓解。即:
- 由于临时地址 [RFC4941] 并未消除为类服务器功能使用固定标识符,它们只能部分缓解跨网络的主机跟踪和活动关联(关于使用临时地址时仍然可能的攻击示例,见 [ADDR-GEN-PRIVACY])。
- 由于临时地址 [RFC4941] 并未取代传统 SLAAC 地址,攻击者仍可利用 SLAAC 地址中的模式来大幅缩小"存活"节点的搜索空间 [GONT-DEEPSEC2011] [CPNI-IPV6] [IPV6-RECON]。
因此,无论是否采用临时地址,都有改进"稳定"地址属性的动机。
本文档规定了一种生成接口标识符的方法:这些标识符在每个子网内对每个网络接口是稳定的,但当主机从一个网络移动到另一个网络时会改变。因此,该方法既能保持 [RFC4291] 所规定接口标识符的"稳定性"属性,又能缓解地址扫描攻击,并防止主机从一个网络移动到另一个网络时其活动被关联。
2. 术语
本文档中的关键词 "MUST"、"MUST NOT"、"REQUIRED"、"SHALL"、"SHALL NOT"、"SHOULD"、"SHOULD NOT"、"RECOMMENDED"、"MAY" 和 "OPTIONAL" 应按 [RFC2119] 所述进行解释。
3. 与其他标准的关系
本文档规定的方法与临时地址 [RFC4941] 的使用是正交的,因为它的用意是改进与上述临时地址一起使用的稳定地址的安全与隐私属性。在采用临时地址的场景中,实现本文档所述机制(用以替代例如基于 IEEE 局域网 MAC 地址的稳定地址)将缓解地址扫描攻击,并缓解基于主机恒定(即跨网络稳定)接口标识符关联主机活动的其余向量。另一方面,对于目前禁用临时地址 [RFC4941] 的主机,实现该机制将缓解第 1 节所讨论的主机跟踪和地址扫描问题。
虽然本文档规定的方法意在用于 SLAAC,但这并不排除该算法被用于其他地址配置机制,例如 DHCPv6 [RFC3315] 或手工地址配置。
4. 设计目标
本文档规定了一种为 IPv6 SLAAC 生成接口标识符的方法,具有以下目标:
- 所得到的接口标识符在同一网络接口、同一子网内对每个用于 SLAAC 的前缀保持稳定。也就是说,在为同一子网内属于同一前缀的地址(同一接口)进行配置时,算法生成相同的接口标识符。
- 当为不同前缀配置地址时,所得到的接口标识符必须改变。也就是说,如果使用不同的自动配置前缀为同一网卡配置地址,所得到的接口标识符必须(在统计上)不同。这意味着,给定由本文档规定方法生成的两个地址,攻击者必须难以判断这些地址是否由同一主机生成。
- 外部人员必须难以预测算法将生成的接口标识符,即使其了解为配置其他地址而生成的接口标识符。
- 取决于具体的实现方式(见第 5 节和附录 A),所得到的接口标识符可以独立于底层硬件(例如 IEEE 局域网 MAC 地址)。例如,这意味着替换网卡(NIC)或向链路聚合组(LAG)动态添加链路,将不会产生改变该网络接口所用 IPv6 地址这一(通常不受欢迎的)效果。
- 本文档规定的方法意在作为"基于硬件地址(例如 [RFC2464] 规定的 IEEE 局域网 MAC 地址)生成 IPv6 地址"的一种替代方案。也就是说,本文档并不正式废止或弃用任何现有的接口标识符生成算法。它的用意是用于为给定接口、通过 SLAAC 配置的所有稳定(即非临时)IPv6 地址,包括全局、链路本地和唯一本地 IPv6 地址。
- 我们注意到,该方法是可增量部署的,因为将其部署在其他节点未实现或未采用它的网络上时,不会带来任何互操作性影响。此外,我们注意到本文档不更新或修改 IPv6 无状态地址自动配置(SLAAC)[RFC4862] 本身,而只是规定了一种生成接口标识符的替代算法。因此,当使用本文档规定的算法与 SLAAC [RFC4862] 一起生成 IPv6 地址时,通常的地址生存期属性(如相应前缀信息选项中规定的那样)仍然适用。此外,从重新编号(renumbering)的角度看,我们注意到这些地址的行为与由 SLAAC [RFC4862] 产生的传统 IPv6 地址(内嵌硬件地址)一样。
5. 算法规范
符合本规范的 IPv6 实现必须使用本节规定的算法生成接口标识符,以替代任何其他用 SLAAC 生成"稳定"地址的算法(例如 [RFC2464]、[RFC2467] 和 [RFC2470] 中规定的那些)。然而,符合本规范的实现可以在用本文档规定算法生成的地址之外,采用 [RFC4941] 规定的算法生成临时地址。本文档规定的方法必须用于为所有稳定地址(包括 IPv6 全局、链路本地和唯一本地地址)生成 SLAAC 接口标识符。
符合本规范的实现应当为系统管理员提供启用或禁用"使用本算法生成接口标识符"的手段。
除非另有说明,下面表达式中包含的所有参数在生成接口标识符时都必须包含。
- 用以下表达式计算一个随机(但稳定)的标识符:
RID = F(Prefix, Net_Iface, Network_ID, DAD_Counter, secret_key)
其中:
- RID:随机(但稳定)标识符(Random (but stable) Identifier)。
- F():一个伪随机函数(PRF),必须不能从外部计算(在不了解密钥的情况下)。F() 还必须难以逆转,从而即使给定 F() 输出的样本、并了解或控制其他输入参数,也能抵抗获取 secret_key 的尝试。F() 应当产生至少 64 位的输出。F() 可以实现为对每个函数参数拼接结果的密码学哈希。SHA-1 [FIPS-SHS] 和 SHA-256 是 F() 的两种可能选择。注意:MD5 [RFC1321] 被认为不可接受用于 F() [RFC6151]。
- Prefix:用于 SLAAC 的前缀,从 ICMPv6 路由器通告消息中获知,或链路本地 IPv6 单播前缀 [RFC4291]。
- Net_Iface:一个与实现相关的稳定标识符,与正在为其生成 RID 的网络接口相关联。实现可以提供配置选项,以选择用于 Net_Iface 参数的标识符来源。该值可能来源的讨论(以及相应的权衡)见附录 A。
- Network_ID:一些网络特定数据,用于标识该接口所接入的子网——例如,与该接口所关联网络对应的 IEEE 802.11 服务集标识符(SSID)。此外,Simple DNA [RFC6059] 描述了可用于生成 Network_ID 参数的一些思路。该参数是可选的(OPTIONAL)。
- DAD_Counter:一个用于解决重复地址检测(DAD)冲突的计数器。它必须初始化为 0,并对因 DAD 冲突而配置的每个新的试探地址(tentative address)加 1。对每个 {Prefix, Net_Iface, Network_ID} 元组在非易失性存储器中记录 DAD_Counter 的实现,如果非易失性存储器中存在这样的条目,则必须将 DAD_Counter 初始化为所记录的值。更多细节见第 6 节。
- secret_key:一个攻击者不知道的密钥。密钥应当至少为 128 位。在操作系统安装时、或在 IPv6 协议栈首次"引导(bootstrapped)"时,必须将其初始化为一个伪随机数(随机性要求见 [RFC4086])。实现可以提供手段让系统管理员显示和更改密钥。
- 接口标识符最终通过从 RID 值(上一步计算的)中,从最低有效位开始取所需数量的比特得到。
我们注意到 [RFC4291] 要求所有单播地址的 Interface ID(除那些以二进制值 000 开头的地址外)都为 64 位长。然而,本文档讨论的方法可用于生成任意长度的 Interface ID,只不过(在采用小于 64 位的 Interface ID 时)以降低熵为代价。
所得到的接口标识符应当与保留的 IPv6 接口标识符 [RFC5453] [IANA-RESERVED-IID] 进行比较,并与同一网络接口、同一网络前缀的地址中已使用的接口标识符进行比较。若生成了不可接受的标识符,此情形应当按与重复地址情形相同的方式处理(见第 6 节)。
本文档不要求为上述函数 F() 使用任何特定的 PRF,因为此类 PRF 的选择通常是在若干属性(处理需求、实现难易、可能的知识产权等)之间的权衡,也因为 F() 的最佳选择对于不同类型的设备(例如嵌入式系统与常规服务器)可能不同,且可能随时间变化。
将 SLAAC 前缀包含进 PRF 计算中,会使接口标识符在主机所采用的每个前缀(链路本地、全局等)之间变化,因而也会跨网络变化。这缓解了多宿主(multihomed)主机活动的关联(因为相应的每个地址通常会采用不同前缀)、主机跟踪(因为网络前缀会随主机从一个网络移动到另一个网络而变化),以及任何其他受益于可预测接口标识符的攻击(例如 IPv6 地址扫描攻击)。
Net_Iface 是一个标识正在为其生成 IPv6 地址的网络接口的值。Net_Iface 参数要求具有以下属性:
- 它必须在系统引导序列和其他网络事件(例如将另一个接口 up 或 down)之间保持恒定。
- 对同时使用的每个网络接口,它必须不同。
由于用该方法生成的地址的稳定性依赖于 F() 所有参数的稳定性,Net_Iface 参数在系统引导序列和其他网络事件之间保持恒定至关重要。此外,Net_Iface 参数必须在主机内唯一标识一个接口,使连接到同一网络的两个接口不会导致重复地址。不同类型的操作系统可能受益于 Net_Iface 参数不同的稳定性属性。例如,面向客户端的操作系统可能希望采用附着于网卡的 Net_Iface 标识符,使得可移除网卡无论附着到哪个系统通信端口都始终获得相同的 IPv6 地址。另一方面,面向服务器的操作系统可能偏好附着于系统插槽/端口的 Net_Iface 标识符,使得替换网卡不会导致 IPv6 地址变化。附录 A 讨论了 Net_Iface 的可能来源及其优缺点。
在计算上述 RID 值时包含可选的 Network_ID 参数,会使算法在连接到不同网络时(即使配置属于同一前缀的地址)产生不同的接口标识符。这意味着主机在从一个网络移动到另一个网络时会采用不同的接口标识符,即使是对于 IPv6 链路本地地址或唯一本地地址(ULA)[RFC4193] 也是如此。在攻击者不知道 Network_ID 的场景中,包含该参数可能有助于缓解以下攻击:受害主机连接到与攻击者相同的子网,而攻击者试图获知受害主机为某个远程网络使用的接口标识符(更多细节见第 8 节)。
DAD_Counter 参数提供了一种手段,用来有意使该算法(在所有其他参数相同的情况下)产生不同的 IPv6 地址。这可能为解决 DAD 冲突所必需,详见第 6 节。
注意,上述算法中 F() 的结果并不比密钥更安全。如果攻击者知晓受害者正在使用的 PRF(我们应该预期如此),并且攻击者能够获得足够多的材料(即受害者配置的地址),攻击者可以简单地搜索整个密钥空间来找到匹配。为防止这一点,至少 128 位的密钥长度应当足够。密钥在系统安装时被初始化为一个伪随机数,从而使该机制能够在无需用户干预的情况下被自动启用和使用。提供一种显示和更改 secret_key 的机制,将使管理员能够使一个新的/替换系统(采用本规范的同一实现)生成与被替换系统相同的 IPv6 地址。我们注意到,由于本文档规定方案的隐私性依赖于 secret_key 参数的保密性,实现应在可行范围内限制对 secret_key 参数的访问(例如要求超级用户权限才能访问它)。此外,为防止 secret_key 参数泄露,它不应被用于本文档规定方案参数之外的任何用途。
我们注意到,所得到 Interface ID 中的所有比特都被视为"不透明"比特 [RFC7136]。例如,修改版 EUI-64 格式标识符的 universal/local 位被当作该标识符的任何其他比特一样对待。理论上,这可能导致本来不会遇到的 IPv6 地址冲突和 DAD 失败。然而,出于以下考虑,这不被视为可能的问题:
- 所有地址的 Interface ID(除那些以二进制值 000 开头的地址外)都为 64 位长。由于本文档规定的方法产生随机的 Interface ID,DAD 失败的概率非常小。
- 现实世界的数据表明,MAC 地址复用远比所假定的更为常见 [HD-MOORE]。这意味着即使是采用(据称)唯一标识符(例如 IEEE 局域网 MAC 地址)的 IPv6 地址也可能导致 DAD 失败,因此实现应准备好优雅地处理此类情况。此外,一些虚拟化技术已经采用随机选择的硬件地址,因而无法保证唯一 [IPV6-RECON]。
- 由于一些流行且广泛部署的操作系统(例如 Microsoft Windows)不在其稳定地址的 Interface ID 中内嵌硬件地址,在已部署的世界中对这类唯一标识符的依赖有所减少(更少的已部署系统依赖它们来避免地址冲突)。
最后,我们注意到,由于不同实现很可能为 secret_key 参数使用不同的值,并且还可能为 F() 采用不同的 PRF、为 Net_Iface 参数采用不同的来源,由本方案生成的地址不应期望在不同操作系统安装之间保持稳定。例如,一台双启动的主机、或被重新安装的主机,可能为每个操作系统和/或每次安装产生不同的 IPv6 地址。
6. 解决 DAD 冲突
如果由于执行 DAD [RFC4862],主机发现用第 5 节规定算法生成的试探地址是一个重复地址,它应当按如下方式通过尝试一个新的试探地址来解决地址冲突:
- DAD_Counter 加 1。
- 使用递增后的 DAD_Counter 值,用第 5 节规定的算法生成一个新的接口标识符。
主机在尝试一个新的试探地址之前,应当引入一个介于 0 到 IDGEN_DELAY 秒之间的随机延迟(见第 7 节),以避免多台主机的同步(lockstep)行为。
此过程可以重复若干次,直到地址冲突被解决。如果 DAD 对连续生成的地址都失败,主机应当至少尝试 IDGEN_RETRIES(见第 7 节)个试探地址,以期解决地址冲突。我们还注意到,主机必须限制所尝试的试探地址数量(而不是无限期地尝试新的试探地址直到冲突解决)。
在那些不太可能的场景中——检测到重复地址、且冲突主机配置其地址的顺序各不相同(例如因为它们可能以不同顺序被引导)——本节规定的解决 DAD 冲突的算法可能导致地址在同一子网内不稳定。为缓解这一潜在问题,主机可以在非易失性存储器中记录用于特定 {Prefix, Net_Iface, Network_ID} 元组的 DAD_Counter 值,使得在任一其他时间点为同一 Prefix 和子网配置地址时采用相同的 DAD_Counter 值。我们注意到,非易失性存储器的使用是可选的(OPTIONAL),未实现此特性的主机仍符合本协议规范。
在 DAD 冲突无法解决(可能是在尝试了若干不同地址之后)的情况下,地址配置将失败。在此类场景中,主机不得自动回退到采用其他生成接口标识符的算法。
7. 规定的常量
本文档规定以下常量:
- IDGEN_RETRIES:默认为 3。
- IDGEN_DELAY:默认为 1 秒。
8. 安全考量
本文档规定了一种为 IPv6 无状态地址自动配置(SLAAC)生成接口标识符的算法,作为例如内嵌硬件地址的接口标识符(如 [RFC2464]、[RFC2467] 和 [RFC2470] 中规定的那些)的替代方案。与这类标识符相比,本文档规定的标识符有许多优点:
- 它们防止基于 IPv6 地址的简单主机跟踪,因为当主机从一个网络移动到另一个网络时,用于自动配置的网络前缀和/或 Network ID(例如 IEEE 802.11 SSID)通常会改变;因此,所得到的接口标识符也会改变(见 [ADDR-GEN-PRIVACY])。
- 它们缓解利用可预测接口标识符(例如已知的组织唯一标识符)的地址扫描技术 [IPV6-RECON]。
- 如果采用适当的 Net_Iface 来源(见第 5 节),它们可能产生独立于底层硬件的 IPv6 地址(即如果网卡被替换,所得到的 IPv6 地址不改变)。
- 它们防止因在接口标识符中内嵌硬件地址而产生的信息泄露(后者可被利用来发起针对设备的攻击)。
- 由于本文档规定的方法将为每个已配置地址产生不同的接口标识符,一个稳定地址所用接口标识符的知悉或泄露不会对其他前缀(无论同一时间还是其他时间点)配置的其他稳定地址的安全/隐私产生负面影响。
我们注意到,虽然一些探测技术(例如使用 ICMPv6 Echo Request 和 ICMPv6 Echo Response 数据包)可以被目标主机上的个人防火墙缓解,但对于其他探测向量——例如监听指向目标地址的 ICMPv6 "Destination Unreachable, Address Unreachable"(类型 1,代码 3)错误消息 [IPV6-RECON]——主机无能为力(例如,目标主机上的个人防火墙无法缓解这种探测技术)。因此,本文档规定的方法对采用个人防火墙的主机仍有价值。
在攻击者能够连接到与受害主机相同子网的场景中,攻击者或许能够通过简单地针对某个前缀发送伪造的路由器通告 [RFC4861],随后获知受害主机配置的相应地址(要么监听重复地址检测数据包,要么监听采用新配置地址的任何其他流量),来获知受害主机为任意前缀使用的接口标识符。我们注意到,若干因素可能限制攻击者成功实施此类攻击的能力:
- 第一跳安全机制,例如路由器通告防护(RA-Guard)[RFC6105] [RFC7113],可以阻止伪造的路由器通告到达受害主机。
- 如果受害实现包含(可选的)Network_ID 参数用于计算 F()(见第 5 节),且攻击者不知道受害者为某个远程网络使用的 Network_ID,则攻击者获知的接口标识符将不同于受害者在连接到合法网络时使用的接口标识符。
无论如何,我们注意到,当这类攻击成为一个关切点时,主机应考虑采用 SEND [RFC3971] 来防止攻击者非法宣称对某个网络前缀的权威。
我们注意到,本算法意在作为 [RFC2464] 等所规定接口标识符的替代方案,但它并非意在作为临时接口标识符(如 [RFC4941] 所规定的那些)的替代方案。显然,临时地址可能有助于缓解同一网络内主机活动的关联,并且它们还可能缩小攻击暴露窗口(因为与本文档规定方法生成的地址相比,临时地址寿命短)。我们注意到,本规范的实现仍将使采用临时地址的主机受益,因为它会缓解使用此类地址时仍然存在的主机跟踪向量(见 [ADDR-GEN-PRIVACY]),并且还会缓解利用内嵌 IEEE 局域网 MAC 地址的 IPv6 地址中模式的地址扫描技术。最后,我们注意到本文档所述方法在不使用临时地址的情况下,解决了因使用内嵌 IEEE 局域网 MAC 地址的 IPv6 地址而产生的一些隐私关切,从而可能为那些使用临时地址不可行的场景提供一个有意思的权衡。
9. 致谢
本文档规定的算法受 Steven Bellovin 在 TCP 序列号领域的工作([RFC1948])启发。
作者要感谢(按字母顺序)Mikael Abrahamsson、Ran Atkinson、Karl Auer、Steven Bellovin、Matthias Bethke、Ben Campbell、Brian Carpenter、Tassos Chatzithomaoglou、Tim Chown、Alissa Cooper、Dominik Elsbroek、Stephen Farrell、Eric Gray、Brian Haberman、Bob Hinden、Christian Huitema、Ray Hunter、Jouni Korhonen、Suresh Krishnan、Eliot Lear、Jong-Hyouk Lee、Andrew McGregor、Thomas Narten、Simon Perreault、Tom Petch、Michael Richardson、Vincent Roca、Mark Smith、Hannes Frederic Sowa、Martin Stiemerling、Dave Thaler、Ole Troan、Lloyd Wood、James Woodyatt 和 He Xuan,感谢他们对本文档早期版本提供的宝贵意见。
Hannes Frederic Sowa 为本规范产出了一个面向 Linux 内核的参考实现。
最后,作者要感谢 Nelida Garcia 和 Guillermo Gont 的爱与支持。
10. 参考文献
(按规范,本节参考文献条目保留原文著录信息,不做中译。)
10.1. 规范性引用(Normative References)
- [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate Requirement Levels", BCP 14, RFC 2119, March 1997.
- [RFC2460] Deering, S. and R. Hinden, "Internet Protocol, Version 6 (IPv6) Specification", RFC 2460, December 1998.
- [RFC3315] Droms, R., Bound, J., Volz, B., Lemon, T., Perkins, C., and M. Carney, "Dynamic Host Configuration Protocol for IPv6 (DHCPv6)", RFC 3315, July 2003.
- [RFC3971] Arkko, J., Kempf, J., Zill, B., and P. Nikander, "SEcure Neighbor Discovery (SEND)", RFC 3971, March 2005.
- [RFC3972] Aura, T., "Cryptographically Generated Addresses (CGA)", RFC 3972, March 2005.
- [RFC4086] Eastlake, D., Schiller, J., and S. Crocker, "Randomness Requirements for Security", BCP 106, RFC 4086, June 2005.
- [RFC4122] Leach, P., Mealling, M., and R. Salz, "A Universally Unique IDentifier (UUID) URN Namespace", RFC 4122, July 2005.
- [RFC4193] Hinden, R. and B. Haberman, "Unique Local IPv6 Unicast Addresses", RFC 4193, October 2005.
- [RFC4291] Hinden, R. and S. Deering, "IP Version 6 Addressing Architecture", RFC 4291, February 2006.
- [RFC4861] Narten, T., Nordmark, E., Simpson, W., and H. Soliman, "Neighbor Discovery for IP version 6 (IPv6)", RFC 4861, September 2007.
- [RFC4862] Thomson, S., Narten, T., and T. Jinmei, "IPv6 Stateless Address Autoconfiguration", RFC 4862, September 2007.
- [RFC4941] Narten, T., Draves, R., and S. Krishnan, "Privacy Extensions for Stateless Address Autoconfiguration in IPv6", RFC 4941, September 2007.
- [RFC5453] Krishnan, S., "Reserved IPv6 Interface Identifiers", RFC 5453, February 2009.
- [RFC7136] Carpenter, B. and S. Jiang, "Significance of IPv6 Interface Identifiers", RFC 7136, February 2014.
10.2. 参考性引用(Informative References)
- [ADDR-GEN-PRIVACY] Cooper, A., Gont, F., and D. Thaler, "Privacy Considerations for IPv6 Address Generation Mechanisms", Work in Progress, February 2014.
- [BROERSMA] Broersma, R., "IPv6 Everywhere: Living with a Fully IPv6-enabled environment", Australian IPv6 Summit 2010, Melbourne, VIC Australia, October 2010, <http://www.ipv6.org.au/10ipv6summit/talks/Ron_Broersma.pdf>.
- [CPNI-IPV6] Gont, F., "Security Assessment of the Internet Protocol version 6 (IPv6)", UK Centre for the Protection of National Infrastructure, (available on request).
- [FIPS-SHS] NIST, "Secure Hash Standard (SHS)", FIPS Publication 180-4, March 2012, <http://csrc.nist.gov/publications/fips/fips180-4/fips-180-4.pdf>.
- [GONT-DEEPSEC2011] Gont, F., "Results of a Security Assessment of the Internet Protocol version 6 (IPv6)", DEEPSEC 2011 Conference, Vienna, Austria, November 2011, <http://www.si6networks.com/presentations/deepsec2011/fgont-deepsec2011-ipv6-security.pdf>.
- [HD-MOORE] Moore, HD., "The Wild West", Louisville, Kentucky, U.S.A, DerbyCon 2012, September 2012, <https://speakerdeck.com/hdm/derbycon-2012-the-wild-west>.
- [IAB-PRIVACY] IAB, "Privacy and IPv6 Addresses", July 2011, <http://www.iab.org/wp-content/IAB-uploads/2011/07/IPv6-addresses-privacy-review.txt>.
- [IANA-RESERVED-IID] IANA, "Reserved IPv6 Interface Identifiers", <http://www.iana.org/assignments/ipv6-interface-ids>.
- [IPV6-RECON] Gont, F. and T. Chown, "Network Reconnaissance in IPv6 Networks", Work in Progress, January 2014.
- [RFC1321] Rivest, R., "The MD5 Message-Digest Algorithm", RFC 1321, April 1992.
- [RFC1948] Bellovin, S., "Defending Against Sequence Number Attacks", RFC 1948, May 1996.
- [RFC2464] Crawford, M., "Transmission of IPv6 Packets over Ethernet Networks", RFC 2464, December 1998.
- [RFC2467] Crawford, M., "Transmission of IPv6 Packets over FDDI Networks", RFC 2467, December 1998.
- [RFC2470] Crawford, M., Narten, T., and S. Thomas, "Transmission of IPv6 Packets over Token Ring Networks", RFC 2470, December 1998.
- [RFC3493] Gilligan, R., Thomson, S., Bound, J., McCann, J., and W. Stevens, "Basic Socket Interface Extensions for IPv6", RFC 3493, February 2003.
- [RFC3542] Stevens, W., Thomas, M., Nordmark, E., and T. Jinmei, "Advanced Sockets Application Program Interface (API) for IPv6", RFC 3542, May 2003.
- [RFC6059] Krishnan, S. and G. Daley, "Simple Procedures for Detecting Network Attachment in IPv6", RFC 6059, November 2010.
- [RFC6105] Levy-Abegnoli, E., Van de Velde, G., Popoviciu, C., and J. Mohacsi, "IPv6 Router Advertisement Guard", RFC 6105, February 2011.
- [RFC6151] Turner, S. and L. Chen, "Updated Security Considerations for the MD5 Message-Digest and the HMAC-MD5 Algorithms", RFC 6151, March 2011.
- [RFC7113] Gont, F., "Implementation Advice for IPv6 Router Advertisement Guard (RA-Guard)", RFC 7113, February 2014.
附录 A. Net_Iface 参数的可能来源
以下各小节描述第 5 节中 F() 函数所用 Net_Iface 参数的若干可能来源。为该值选择特定来源代表着若干权衡,这可能因实现而异。
A.1. 接口索引(Interface Index)
一个接口的接口索引 [RFC3493] [RFC3542] 在节点内唯一标识该接口。然而,这些标识符可能具有、也可能不具有本方法所用 Net_Iface 值所需的稳定性属性。例如,在移除或安装某个网络接口时(当使用此类命名方案时,通常是一个具有更小接口索引值的接口),或当网络接口恰好以不同顺序被初始化时,接口索引可能改变。我们注意到,已知一些实现提供了配置开关来为给定接口设置接口索引。此类配置开关可用于防止接口索引变化(例如因移除某个网络接口而变化)。
A.2. 接口名(Interface Name)
接口名(例如 "eth0"、"em0" 等)往往比底层接口索引更稳定,因为当接口名被用于网络配置(防火墙规则等)时,这种稳定性是必需或期望的。接口名的稳定性属性取决于实现细节,例如接口名使用什么命名空间。例如,"eth0" 或 "wlan0" 之类的"通用"接口名通常相对于网卡替换是不变的。另一方面,"rtk0" 之类的厂商相关接口名通常会在网卡被替换为不同厂商的网卡时改变。
我们注意到,一旦系统被引导,当添加或移除网络接口时,接口名仍可能改变(例如,考虑可能在系统引导后被添加或移除的基于 USB 的网卡)。
A.3. 链路层地址(Link-Layer Addresses)
链路层地址通常为网络接口提供唯一标识符;不过,出于显而易见的原因,它们通常会在网卡被替换时改变。在接口索引和接口名都不具备第 5 节为 Net_Iface 规定的稳定性属性的场景中,实现可能希望为 Net_Iface 参数采用接口的链路层地址,只不过代价是使相应的 IPv6 地址依赖于底层网卡(即相应的 IPv6 地址通常会在底层网卡被替换时改变)。
A.4. 逻辑网络服务标识(Logical Network Service Identity)
具有"逻辑网络服务标识"概念(区别于网络接口标识或索引)的主机操作系统,可以保存一个通用唯一标识符(UUID)[RFC4122] 或类似标识符,其稳定性属性适合用作 Net_Iface 参数。
作者地址(Author's Address)
Fernando Gont
SI6 Networks / UTN-FRH
Evaristo Carriego 2644
Haedo, Provincia de Buenos Aires 1706
Argentina
Phone: +54 11 4650 8472
EMail: fgont@si6networks.com
URI: http://www.si6networks.com
RFC 7217: A Method for Generating Semantically Opaque Interface Identifiers with IPv6 Stateless Address Autoconfiguration (SLAAC)
Internet Engineering Task Force (IETF) F. Gont
Request for Comments: 7217 SI6 Networks / UTN-FRH
Category: Standards Track April 2014
ISSN: 2070-1721
A Method for Generating Semantically Opaque Interface Identifiers
with IPv6 Stateless Address Autoconfiguration (SLAAC)
Abstract
This document specifies a method for generating IPv6 Interface
Identifiers to be used with IPv6 Stateless Address Autoconfiguration
(SLAAC), such that an IPv6 address configured using this method is
stable within each subnet, but the corresponding Interface Identifier
changes when the host moves from one network to another. This method
is meant to be an alternative to generating Interface Identifiers
based on hardware addresses (e.g., IEEE LAN Media Access Control
(MAC) addresses), such that the benefits of stable addresses can be
achieved without sacrificing the security and privacy of users. The
method specified in this document applies to all prefixes a host may
be employing, including link-local, global, and unique-local prefixes
(and their corresponding addresses).
Status of This Memo
This is an Internet Standards Track document.
This document is a product of the Internet Engineering Task Force
(IETF). It represents the consensus of the IETF community. It has
received public review and has been approved for publication by the
Internet Engineering Steering Group (IESG). Further information on
Internet Standards is available in [Section 2 of RFC 5741](https://www.rfc-editor.org/info/rfc5741/#section-2).
Information about the current status of this document, any errata,
and how to provide feedback on it may be obtained at
[http://www.rfc-editor.org/info/rfc7217](https://www.rfc-editor.org/info/rfc7217).
Gont Standards Track [Page 1]
RFC 7217 Stable and Opaque IIDs with SLAAC April 2014
Copyright Notice
Copyright (c) 2014 IETF Trust and the persons identified as the
document authors. All rights reserved.
This document is subject to [BCP 78](https://www.rfc-editor.org/bcp/bcp78) and the IETF Trust's Legal
Provisions Relating to IETF Documents
([http://trustee.ietf.org/license-info](http://trustee.ietf.org/license-info)) in effect on the date of
publication of this document. Please review these documents
carefully, as they describe your rights and restrictions with respect
to this document. Code Components extracted from this document must
include Simplified BSD License text as described in Section 4.e of
the Trust Legal Provisions and are provided without warranty as
described in the Simplified BSD License.
Table of Contents
1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3
2. Terminology . . . . . . . . . . . . . . . . . . . . . . . . . 5
3. Relationship to Other Standards . . . . . . . . . . . . . . . 5
4. Design Goals . . . . . . . . . . . . . . . . . . . . . . . . 6
5. Algorithm Specification . . . . . . . . . . . . . . . . . . . 7
6. Resolving DAD Conflicts . . . . . . . . . . . . . . . . . . . 12
7. Specified Constants . . . . . . . . . . . . . . . . . . . . . 13
8. Security Considerations . . . . . . . . . . . . . . . . . . . 13
9. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 15
10. References . . . . . . . . . . . . . . . . . . . . . . . . . 15
10.1. Normative References . . . . . . . . . . . . . . . . . . 15
10.2. Informative References . . . . . . . . . . . . . . . . . 16
Appendix A. Possible Sources for the Net_Iface Parameter . . . . 19
A.1. Interface Index . . . . . . . . . . . . . . . . . . . . . 19
A.2. Interface Name . . . . . . . . . . . . . . . . . . . . . 19
A.3. Link-Layer Addresses . . . . . . . . . . . . . . . . . . 19
A.4. Logical Network Service Identity . . . . . . . . . . . . 20
Gont Standards Track [Page 2]
RFC 7217 Stable and Opaque IIDs with SLAAC April 2014
1. Introduction
[[RFC4862](https://www.rfc-editor.org/info/rfc4862/)] specifies Stateless Address Autoconfiguration (SLAAC) for
IPv6 [[RFC2460](https://www.rfc-editor.org/info/rfc2460/)], which typically results in hosts configuring one or
more "stable" addresses composed of a network prefix advertised by a
local router, and an Interface Identifier (IID) that typically embeds
a hardware address (e.g., an IEEE LAN MAC address) [[RFC4291](https://www.rfc-editor.org/info/rfc4291/)].
Cryptographically Generated Addresses (CGAs) [[RFC3972](https://www.rfc-editor.org/info/rfc3972/)] are yet
another method for generating Interface Identifiers; CGAs bind a
public signature key to an IPv6 address in the SEcure Neighbor
Discovery (SEND) [[RFC3971](https://www.rfc-editor.org/info/rfc3971/)] protocol.
Generally, the traditional SLAAC addresses are thought to simplify
network management, since they simplify Access Control Lists (ACLs)
and logging. However, they have a number of drawbacks:
o Since the resulting Interface Identifiers do not vary over time,
they allow correlation of host activities within the same network,
thus negatively affecting the privacy of users (see
[ADDR-GEN-PRIVACY] and [IAB-PRIVACY]).
o Since the resulting Interface Identifiers are constant across
networks, the resulting IPv6 addresses can be leveraged to track
and correlate the activity of a host across multiple networks
(e.g., track and correlate the activities of a typical client
connecting to the public Internet from different locations), thus
negatively affecting the privacy of users.
o Since embedding the underlying link-layer address in the Interface
Identifier will result in specific address patterns, such patterns
may be leveraged by attackers to reduce the search space when
performing address-scanning attacks [IPV6-RECON]. For example,
the IPv6 addresses of all hosts manufactured by the same vendor
(within a given time frame) will likely contain the same IEEE
Organizationally Unique Identifier (OUI) in the Interface
Identifier.
o Embedding the underlying hardware address in the Interface
Identifier leaks device-specific information that could be
leveraged to launch device-specific attacks.
o Embedding the underlying link-layer address in the Interface
Identifier means that replacement of the underlying interface
hardware will result in a change of the IPv6 address(es) assigned
to that interface.
Gont Standards Track [Page 3]
RFC 7217 Stable and Opaque IIDs with SLAAC April 2014
[ADDR-GEN-PRIVACY] provides additional details regarding how the
aforementioned vulnerabilities could be exploited and the extent to
which the method discussed in this document mitigates them.
The "Privacy Extensions for Stateless Address Autoconfiguration in
IPv6" [[RFC4941](https://www.rfc-editor.org/info/rfc4941/)] (henceforth referred to as "temporary addresses")
were introduced to complicate the task of eavesdroppers and other
information collectors (e.g., IPv6 addresses in web server logs or
email headers, etc.) to correlate the activities of a host, and
basically result in temporary (and random) Interface Identifiers.
These temporary addresses are generated in addition to the
traditional IPv6 addresses based on IEEE LAN MAC addresses, with the
temporary addresses being employed for "outgoing communications", and
the traditional SLAAC addresses being employed for "server" functions
(i.e., receiving incoming connections).
It should be noted that temporary addresses can be challenging in a
number of areas. For example, from a network-management point of
view, they tend to increase the complexity of event logging,
troubleshooting, enforcement of access controls, and quality of
service, etc. As a result, some organizations disable the use of
temporary addresses even at the expense of reduced privacy
[BROERSMA]. Temporary addresses may also result in increased
implementation complexity, which might not be possible or desirable
in some implementations (e.g., some embedded devices).
In scenarios in which temporary addresses are deliberately not used
(possibly for any of the aforementioned reasons), all a host is left
with is the stable addresses that have typically been generated from
the underlying hardware addresses. In such scenarios, it may still
be desirable to have addresses that mitigate address-scanning attacks
and that, at the very least, do not reveal the host's identity when
roaming from one network to another -- without complicating the
operation of the corresponding networks.
However, even with temporary addresses in place, a number of issues
remain to be mitigated. Namely,
o since temporary addresses [RFC4941] do not eliminate the use of
fixed identifiers for server-like functions, they only partially
mitigate host-tracking and activity correlation across networks
(see [ADDR-GEN-PRIVACY] for some example attacks that are still
possible with temporary addresses).
o since temporary addresses [RFC4941] do not replace the traditional
SLAAC addresses, an attacker can still leverage patterns in SLAAC
addresses to greatly reduce the search space for "alive" nodes
[GONT-DEEPSEC2011] [CPNI-IPV6] [IPV6-RECON].
Gont Standards Track [Page 4]
RFC 7217 Stable and Opaque IIDs with SLAAC April 2014
Hence, there is a motivation to improve the properties of "stable"
addresses regardless of whether or not temporary addresses are
employed.
This document specifies a method to generate Interface Identifiers
that are stable for each network interface within each subnet, but
that change as a host moves from one network to another. Thus, this
method enables keeping the "stability" properties of the Interface
Identifiers specified in [RFC4291], while still mitigating address-
scanning attacks and preventing correlation of the activities of a
host as it moves from one network to another.
2. Terminology
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
"SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
document are to be interpreted as described in [[RFC2119](https://www.rfc-editor.org/info/rfc2119/)].
3. Relationship to Other Standards
The method specified in this document is orthogonal to the use of
temporary addresses [RFC4941], since it is meant to improve the
security and privacy properties of the stable addresses that are
employed along with the aforementioned temporary addresses. In
scenarios in which temporary addresses are employed, implementation
of the mechanism described in this document (in replacement of stable
addresses based on, e.g., IEEE LAN MAC addresses) will mitigate
address-scanning attacks and also mitigate the remaining vectors for
correlating host activities based on the host's constant (i.e.,
stable across networks) Interface Identifiers. On the other hand,
for hosts that currently disable temporary addresses [RFC4941],
implementation of this mechanism would mitigate the host-tracking and
address-scanning issues discussed in Section 1.
While the method specified in this document is meant to be used with
SLAAC, this does not preclude this algorithm from being used with
other address configuration mechanisms, such as DHCPv6 [[RFC3315](https://www.rfc-editor.org/info/rfc3315/)] or
manual address configuration.
Gont Standards Track [Page 5]
RFC 7217 Stable and Opaque IIDs with SLAAC April 2014
4. Design Goals
This document specifies a method for generating Interface Identifiers
to be used with IPv6 SLAAC, with the following goals:
o The resulting Interface Identifiers remain stable for each prefix
used with SLAAC within each subnet for the same network interface.
That is, the algorithm generates the same Interface Identifier
when configuring an address (for the same interface) belonging to
the same prefix within the same subnet.
o The resulting Interface Identifiers must change when addresses are
configured for different prefixes. That is, if different
autoconfiguration prefixes are used to configure addresses for the
same network interface card, the resulting Interface Identifiers
must be (statistically) different. This means that, given two
addresses produced by the method specified in this document, it
must be difficult for an attacker to tell whether the addresses
have been generated by the same host.
o It must be difficult for an outsider to predict the Interface
Identifiers that will be generated by the algorithm, even with
knowledge of the Interface Identifiers generated for configuring
other addresses.
o Depending on the specific implementation approach (see Section 5
and Appendix A), the resulting Interface Identifiers may be
independent of the underlying hardware (e.g., IEEE LAN MAC
address). For example, this means that replacing a Network
Interface Card (NIC) or adding links dynamically to a Link
Aggregation Group (LAG) will not have the (generally undesirable)
effect of changing the IPv6 addresses used for that network
interface.
o The method specified in this document is meant to be an
alternative to producing IPv6 addresses based on hardware
addresses (e.g., IEEE LAN MAC addresses, as specified in
[[RFC2464](https://www.rfc-editor.org/info/rfc2464/)]). That is, this document does not formally obsolete or
deprecate any of the existing algorithms to generate Interface
Identifiers. It is meant to be employed for all of the stable
(i.e., non-temporary) IPv6 addresses configured with SLAAC for a
given interface, including global, link-local, and unique-local
IPv6 addresses.
We note that this method is incrementally deployable, since it does
not pose any interoperability implications when deployed on networks
where other nodes do not implement or employ it. Additionally, we
note that this document does not update or modify IPv6 Stateless
Gont Standards Track [Page 6]
RFC 7217 Stable and Opaque IIDs with SLAAC April 2014
Address Autoconfiguration (SLAAC) [RFC4862] itself, but rather it
only specifies an alternative algorithm to generate Interface
Identifiers. Therefore, the usual address lifetime properties (as
specified in the corresponding Prefix Information Options) apply when
IPv6 addresses are generated as a result of employing the algorithm
specified in this document with SLAAC [RFC4862]. Additionally, from
the point of view of renumbering, we note that these addresses behave
like the traditional IPv6 addresses (that embed a hardware address)
resulting from SLAAC [RFC4862].
5. Algorithm Specification
IPv6 implementations conforming to this specification MUST generate
Interface Identifiers using the algorithm specified in this section
as a replacement for any other algorithms for generating "stable"
addresses with SLAAC (such as those specified in [RFC2464],
[[RFC2467](https://www.rfc-editor.org/info/rfc2467/)], and [[RFC2470](https://www.rfc-editor.org/info/rfc2470/)]). However, implementations conforming to
this specification MAY employ the algorithm specified in [RFC4941] to
generate temporary addresses in addition to the addresses generated
with the algorithm specified in this document. The method specified
in this document MUST be employed for generating the Interface
Identifiers with SLAAC for all the stable addresses, including IPv6
global, link-local, and unique-local addresses.
Implementations conforming to this specification SHOULD provide the
means for a system administrator to enable or disable the use of this
algorithm for generating Interface Identifiers.
Unless otherwise noted, all of the parameters included in the
expression below MUST be included when generating an Interface
Identifier.
1. Compute a random (but stable) identifier with the expression:
RID = F(Prefix, Net_Iface, Network_ID, DAD_Counter, secret_key)
Where:
RID:
Random (but stable) Identifier
F():
A pseudorandom function (PRF) that MUST NOT be computable from
the outside (without knowledge of the secret key). F() MUST
also be difficult to reverse, such that it resists attempts to
obtain the secret_key, even when given samples of the output
of F() and knowledge or control of the other input parameters.
F() SHOULD produce an output of at least 64 bits. F() could
Gont Standards Track [Page 7]
RFC 7217 Stable and Opaque IIDs with SLAAC April 2014
be implemented as a cryptographic hash of the concatenation of
each of the function parameters. SHA-1 [FIPS-SHS] and SHA-256
are two possible options for F(). Note: MD5 [[RFC1321](https://www.rfc-editor.org/info/rfc1321/)] is
considered unacceptable for F() [[RFC6151](https://www.rfc-editor.org/info/rfc6151/)].
Prefix:
The prefix to be used for SLAAC, as learned from an ICMPv6
Router Advertisement message, or the link-local IPv6 unicast
prefix [RFC4291].
Net_Iface:
An implementation-dependent stable identifier associated with
the network interface for which the RID is being generated.
An implementation MAY provide a configuration option to select
the source of the identifier to be used for the Net_Iface
parameter. A discussion of possible sources for this value
(along with the corresponding trade-offs) can be found in
Appendix A.
Network_ID:
Some network-specific data that identifies the subnet to which
this interface is attached -- for example, the IEEE 802.11
Service Set Identifier (SSID) corresponding to the network to
which this interface is associated. Additionally, Simple DNA
[[RFC6059](https://www.rfc-editor.org/info/rfc6059/)] describes ideas that could be leveraged to generate
a Network_ID parameter. This parameter is OPTIONAL.
DAD_Counter:
A counter that is employed to resolve Duplicate Address
Detection (DAD) conflicts. It MUST be initialized to 0, and
incremented by 1 for each new tentative address that is
configured as a result of a DAD conflict. Implementations
that record DAD_Counter in non-volatile memory for each
{Prefix, Net_Iface, Network_ID} tuple MUST initialize
DAD_Counter to the recorded value if such an entry exists in
non-volatile memory. See Section 6 for additional details.
secret_key:
A secret key that is not known by the attacker. The secret
key SHOULD be of at least 128 bits. It MUST be initialized to
a pseudo-random number (see [[RFC4086](https://www.rfc-editor.org/info/rfc4086/)] for randomness
requirements for security) when the operating system is
installed or when the IPv6 protocol stack is "bootstrapped"
for the first time. An implementation MAY provide the means
for the system administrator to display and change the secret
key.
Gont Standards Track [Page 8]
RFC 7217 Stable and Opaque IIDs with SLAAC April 2014
2. The Interface Identifier is finally obtained by taking as many
bits from the RID value (computed in the previous step) as
necessary, starting from the least significant bit.
We note that [RFC4291] requires that the Interface IDs of all
unicast addresses (except those that start with the binary
value 000) be 64 bits long. However, the method discussed in
this document could be employed for generating Interface IDs
of any arbitrary length, albeit at the expense of reduced
entropy (when employing Interface IDs smaller than 64 bits).
The resulting Interface Identifier SHOULD be compared against the
reserved IPv6 Interface Identifiers [[RFC5453](https://www.rfc-editor.org/info/rfc5453/)] [IANA-RESERVED-IID]
and against those Interface Identifiers already employed in an
address of the same network interface and the same network
prefix. In the event that an unacceptable identifier has been
generated, this situation SHOULD be handled in the same way as
the case of duplicate addresses (see Section 6).
This document does not require the use of any specific PRF for the
function F() above, since the choice of such PRF is usually a trade-
off between a number of properties (processing requirements, ease of
implementation, possible intellectual property rights, etc.), and
since the best possible choice for F() might be different for
different types of devices (e.g., embedded systems vs. regular
servers) and might possibly change over time.
Including the SLAAC prefix in the PRF computation causes the
Interface Identifier to vary across each prefix (link-local, global,
etc.) employed by the host and, consequently, also across networks.
This mitigates the correlation of activities of multihomed hosts
(since each of the corresponding addresses will typically employ a
different prefix), host-tracking (since the network prefix will
change as the host moves from one network to another), and any other
attacks that benefit from predictable Interface Identifiers (such as
IPv6 address-scanning attacks).
The Net_Iface is a value that identifies the network interface for
which an IPv6 address is being generated. The following properties
are required for the Net_Iface parameter:
o It MUST be constant across system bootstrap sequences and other
network events (e.g., bringing another interface up or down).
o It MUST be different for each network interface simultaneously in
use.
Gont Standards Track [Page 9]
RFC 7217 Stable and Opaque IIDs with SLAAC April 2014
Since the stability of the addresses generated with this method
relies on the stability of all arguments of F(), it is key that the
Net_Iface parameter be constant across system bootstrap sequences and
other network events. Additionally, the Net_Iface parameter must
uniquely identify an interface within the host, such that two
interfaces connecting to the same network do not result in duplicate
addresses. Different types of operating systems might benefit from
different stability properties of the Net_Iface parameter. For
example, a client-oriented operating system might want to employ
Net_Iface identifiers that are attached to the NIC, such that a
removable NIC always gets the same IPv6 address, irrespective of the
system communications port to which it is attached. On the other
hand, a server-oriented operating system might prefer Net_Iface
identifiers that are attached to system slots/ports, such that
replacement of a NIC does not result in an IPv6 address change.
Appendix A discusses possible sources for the Net_Iface along with
their pros and cons.
Including the optional Network_ID parameter when computing the RID
value above causes the algorithm to produce a different Interface
Identifier when connecting to different networks, even when
configuring addresses belonging to the same prefix. This means that
a host would employ a different Interface Identifier as it moves from
one network to another even for IPv6 link-local addresses or Unique
Local Addresses (ULAs) [[RFC4193](https://www.rfc-editor.org/info/rfc4193/)]. In those scenarios where the
Network_ID is unknown to the attacker, including this parameter might
help mitigate attacks where a victim host connects to the same subnet
as the attacker and the attacker tries to learn the Interface
Identifier used by the victim host for a remote network (see
Section 8 for further details).
The DAD_Counter parameter provides the means to intentionally cause
this algorithm to produce different IPv6 addresses (all other
parameters being the same). This could be necessary to resolve DAD
conflicts, as discussed in detail in Section 6.
Note that the result of F() in the algorithm above is no more secure
than the secret key. If an attacker is aware of the PRF that is
being used by the victim (which we should expect), and the attacker
can obtain enough material (i.e., addresses configured by the
victim), the attacker may simply search the entire secret-key space
to find matches. To protect against this, key lengths of at least
128 bits should be adequate. The secret key is initialized at system
installation time to a pseudorandom number, thus allowing this
mechanism to be enabled and used automatically, without user
intervention. Providing a mechanism to display and change the
secret_key would allow an administrator to cause a new/replacement
system (with the same implementation of this specification) to
Gont Standards Track [Page 10]
RFC 7217 Stable and Opaque IIDs with SLAAC April 2014
generate the same IPv6 addresses as the system being replaced. We
note that since the privacy of the scheme specified in this document
relies on the secrecy of the secret_key parameter, implementations
should constrain access to the secret_key parameter to the extent
practicable (e.g., require superuser privileges to access it).
Furthermore, in order to prevent leakages of the secret_key
parameter, it should not be used for any purposes other than being a
parameter to the scheme specified in this document.
We note that all of the bits in the resulting Interface IDs are
treated as "opaque" bits [[RFC7136](https://www.rfc-editor.org/info/rfc7136/)]. For example, the universal/local
bit of Modified EUI-64 format identifiers is treated as any other bit
of such an identifier. In theory, this might result in IPv6 address
collisions and DAD failures that would otherwise not be encountered.
However, this is not deemed as a likely issue because of the
following considerations:
o The interface IDs of all addresses (except those of addresses that
start with the binary value 000) are 64 bits long. Since the
method specified in this document results in random Interface IDs,
the probability of DAD failures is very small.
o Real-world data indicates that MAC address reuse is far more
common than assumed [HD-MOORE]. This means that even IPv6
addresses that employ (allegedly) unique identifiers (such as IEEE
LAN MAC addresses) might result in DAD failures and, hence,
implementations should be prepared to gracefully handle such
occurrences. Additionally, some virtualization technologies
already employ hardware addresses that are randomly selected, and,
hence, cannot be guaranteed to be unique [IPV6-RECON].
o Since some popular and widely deployed operating systems (such as
Microsoft Windows) do not embed hardware addresses in the
Interface IDs of their stable addresses, reliance on such unique
identifiers is reduced in the deployed world (fewer deployed
systems rely on them for the avoidance of address collisions).
Finally, we note that since different implementations are likely to
use different values for the secret_key parameter, and may also
employ different PRFs for F() and different sources for the Net_Iface
parameter, the addresses generated by this scheme should not expected
to be stable across different operating-system installations. For
example, a host that is dual-boot or that is reinstalled may result
in different IPv6 addresses for each operating system and/or
installation.
Gont Standards Track [Page 11]
RFC 7217 Stable and Opaque IIDs with SLAAC April 2014
6. Resolving DAD Conflicts
If, as a result of performing DAD [RFC4862], a host finds that the
tentative address generated with the algorithm specified in Section 5
is a duplicate address, it SHOULD resolve the address conflict by
trying a new tentative address as follows:
o DAD_Counter is incremented by 1.
o A new Interface Identifier is generated with the algorithm
specified in Section 5, using the incremented DAD_Counter value.
Hosts SHOULD introduce a random delay between 0 and IDGEN_DELAY
seconds (see Section 7) before trying a new tentative address, to
avoid lockstep behavior of multiple hosts.
This procedure may be repeated a number of times until the address
conflict is resolved. Hosts SHOULD try at least IDGEN_RETRIES (see
Section 7) tentative addresses if DAD fails for successive generated
addresses, in the hopes of resolving the address conflict. We also
note that hosts MUST limit the number of tentative addresses that are
tried (rather than indefinitely try a new tentative address until the
conflict is resolved).
In those unlikely scenarios in which duplicate addresses are detected
and the order in which the conflicting hosts configure their
addresses varies (e.g., because they may be bootstrapped in different
orders), the algorithm specified in this section for resolving DAD
conflicts could lead to addresses that are not stable within the same
subnet. In order to mitigate this potential problem, hosts MAY
record the DAD_Counter value employed for a specific {Prefix,
Net_Iface, Network_ID} tuple in non-volatile memory, such that the
same DAD_Counter value is employed when configuring an address for
the same Prefix and subnet at any other point in time. We note that
the use of non-volatile memory is OPTIONAL, and hosts that do not
implement this feature are still compliant to this protocol
specification.
In the event that a DAD conflict cannot be solved (possibly after
trying a number of different addresses), address configuration would
fail. In those scenarios, hosts MUST NOT automatically fall back to
employing other algorithms for generating Interface Identifiers.
Gont Standards Track [Page 12]
RFC 7217 Stable and Opaque IIDs with SLAAC April 2014
7. Specified Constants
This document specifies the following constant:
IDGEN_RETRIES:
defaults to 3.
IDGEN_DELAY:
defaults to 1 second.
8. Security Considerations
This document specifies an algorithm for generating Interface
Identifiers to be used with IPv6 Stateless Address Autoconfiguration
(SLAAC), as an alternative to e.g., Interface Identifiers that embed
hardware addresses (such as those specified in [RFC2464], [RFC2467],
and [RFC2470]). When compared to such identifiers, the identifiers
specified in this document have a number of advantages:
o They prevent trivial host-tracking based on the IPv6 address,
since when a host moves from one network to another the network
prefix used for autoconfiguration and/or the Network ID (e.g.,
IEEE 802.11 SSID) will typically change; hence, the resulting
Interface Identifier will also change (see [ADDR-GEN-PRIVACY]).
o They mitigate address-scanning techniques that leverage
predictable Interface Identifiers (e.g., known Organizationally
Unique Identifiers) [IPV6-RECON].
o They may result in IPv6 addresses that are independent of the
underlying hardware (i.e., the resulting IPv6 addresses do not
change if a network interface card is replaced) if an appropriate
source for Net_Iface (see Section 5) is employed.
o They prevent the information leakage produced by embedding
hardware addresses in the Interface Identifier (which could be
exploited to launch device-specific attacks).
o Since the method specified in this document will result in
different Interface Identifiers for each configured address,
knowledge or leakage of the Interface Identifier employed for one
stable address will not negatively affect the security/privacy of
other stable addresses configured for other prefixes (whether at
the same time or at some other point in time).
We note that while some probing techniques (such as the use of ICMPv6
Echo Request and ICMPv6 Echo Response packets) could be mitigated by
a personal firewall at the target host, for other probing vectors,
Gont Standards Track [Page 13]
RFC 7217 Stable and Opaque IIDs with SLAAC April 2014
such as listening to ICMPv6 "Destination Unreachable, Address
Unreachable" (Type 1, Code 3) error messages that refer to the target
addresses [IPV6-RECON], there is nothing a host can do (e.g., a
personal firewall at the target host would not be able to mitigate
this probing technique). Hence, the method specified in this
document is still of value for hosts that employ personal firewalls.
In scenarios in which an attacker can connect to the same subnet as a
victim host, the attacker might be able to learn the Interface
Identifier employed by the victim host for an arbitrary prefix by
simply sending a forged Router Advertisement [[RFC4861](https://www.rfc-editor.org/info/rfc4861/)] for that
prefix, and subsequently learning the corresponding address
configured by the victim host (either listening to the Duplicate
Address Detection packets or to any other traffic that employs the
newly configured address). We note that a number of factors might
limit the ability of an attacker to successfully perform such an
attack:
o First-Hop security mechanisms such as Router Advertisement Guard
(RA-Guard) [[RFC6105](https://www.rfc-editor.org/info/rfc6105/)] [[RFC7113](https://www.rfc-editor.org/info/rfc7113/)] could prevent the forged Router
Advertisement from reaching the victim host.
o If the victim implementation includes the (optional) Network_ID
parameter for computing F() (see Section 5), and the Network_ID
employed by the victim for a remote network is unknown to the
attacker, the Interface Identifier learned by the attacker would
differ from the one used by the victim when connecting to the
legitimate network.
In any case, we note that at the point in which this kind of attack
becomes a concern, a host should consider employing SEND [RFC3971] to
prevent an attacker from illegitimately claiming authority for a
network prefix.
We note that this algorithm is meant to be an alternative to
Interface Identifiers such as those specified in [RFC2464], but it is
not meant as an alternative to temporary Interface Identifiers (such
as those specified in [RFC4941]). Clearly, temporary addresses may
help to mitigate the correlation of activities of a host within the
same network, and they may also reduce the attack exposure window
(since temporary addresses are short-lived when compared to the
addresses generated with the method specified in this document). We
note that the implementation of this specification would still
benefit those hosts employing temporary addresses, since it would
mitigate host-tracking vectors still present when such addresses are
used (see [ADDR-GEN-PRIVACY]) and would also mitigate address-
scanning techniques that leverage patterns in IPv6 addresses that
embed IEEE LAN MAC addresses. Finally, we note that the method
Gont Standards Track [Page 14]
RFC 7217 Stable and Opaque IIDs with SLAAC April 2014
described in this document addresses some of the privacy concerns
arising from the use of IPv6 addresses that embed IEEE LAN MAC
addresses, without the use of temporary addresses, thus possibly
offering an interesting trade-off for those scenarios in which the
use of temporary addresses is not feasible.
9. Acknowledgements
The algorithm specified in this document has been inspired by Steven
Bellovin's work ([[RFC1948](https://www.rfc-editor.org/info/rfc1948/)]) in the area of TCP sequence numbers.
The author would like to thank (in alphabetical order) Mikael
Abrahamsson, Ran Atkinson, Karl Auer, Steven Bellovin, Matthias
Bethke, Ben Campbell, Brian Carpenter, Tassos Chatzithomaoglou, Tim
Chown, Alissa Cooper, Dominik Elsbroek, Stephen Farrell, Eric Gray,
Brian Haberman, Bob Hinden, Christian Huitema, Ray Hunter, Jouni
Korhonen, Suresh Krishnan, Eliot Lear, Jong-Hyouk Lee, Andrew
McGregor, Thomas Narten, Simon Perreault, Tom Petch, Michael
Richardson, Vincent Roca, Mark Smith, Hannes Frederic Sowa, Martin
Stiemerling, Dave Thaler, Ole Troan, Lloyd Wood, James Woodyatt, and
He Xuan, for providing valuable comments on earlier versions of this
document.
Hannes Frederic Sowa produced a reference implementation of this
specification for the Linux kernel.
Finally, the author wishes to thank Nelida Garcia and Guillermo Gont
for their love and support.
10. References
10.1. Normative References
[RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
Requirement Levels", [BCP 14](https://www.rfc-editor.org/bcp/bcp14), [RFC 2119](https://www.rfc-editor.org/info/rfc2119/), March 1997.
[RFC2460] Deering, S. and R. Hinden, "Internet Protocol, Version 6
(IPv6) Specification", [RFC 2460](https://www.rfc-editor.org/info/rfc2460/), December 1998.
[RFC3315] Droms, R., Bound, J., Volz, B., Lemon, T., Perkins, C.,
and M. Carney, "Dynamic Host Configuration Protocol for
IPv6 (DHCPv6)", [RFC 3315](https://www.rfc-editor.org/info/rfc3315/), July 2003.
[RFC3971] Arkko, J., Kempf, J., Zill, B., and P. Nikander, "SEcure
Neighbor Discovery (SEND)", [RFC 3971](https://www.rfc-editor.org/info/rfc3971/), March 2005.
[RFC3972] Aura, T., "Cryptographically Generated Addresses (CGA)",
[RFC 3972](https://www.rfc-editor.org/info/rfc3972/), March 2005.
Gont Standards Track [Page 15]
RFC 7217 Stable and Opaque IIDs with SLAAC April 2014
[RFC4086] Eastlake, D., Schiller, J., and S. Crocker, "Randomness
Requirements for Security", [BCP 106](https://www.rfc-editor.org/bcp/bcp106), [RFC 4086](https://www.rfc-editor.org/info/rfc4086/), June 2005.
[[RFC4122](https://www.rfc-editor.org/info/rfc4122/)] Leach, P., Mealling, M., and R. Salz, "A Universally
Unique IDentifier (UUID) URN Namespace", [RFC 4122](https://www.rfc-editor.org/info/rfc4122/), July
2005.
[RFC4193] Hinden, R. and B. Haberman, "Unique Local IPv6 Unicast
Addresses", [RFC 4193](https://www.rfc-editor.org/info/rfc4193/), October 2005.
[RFC4291] Hinden, R. and S. Deering, "IP Version 6 Addressing
Architecture", [RFC 4291](https://www.rfc-editor.org/info/rfc4291/), February 2006.
[RFC4861] Narten, T., Nordmark, E., Simpson, W., and H. Soliman,
"Neighbor Discovery for IP version 6 (IPv6)", [RFC 4861](https://www.rfc-editor.org/info/rfc4861/),
September 2007.
[RFC4862] Thomson, S., Narten, T., and T. Jinmei, "IPv6 Stateless
Address Autoconfiguration", [RFC 4862](https://www.rfc-editor.org/info/rfc4862/), September 2007.
[RFC4941] Narten, T., Draves, R., and S. Krishnan, "Privacy
Extensions for Stateless Address Autoconfiguration in
IPv6", [RFC 4941](https://www.rfc-editor.org/info/rfc4941/), September 2007.
[RFC5453] Krishnan, S., "Reserved IPv6 Interface Identifiers", RFC
5453, February 2009.
[RFC7136] Carpenter, B. and S. Jiang, "Significance of IPv6
Interface Identifiers", [RFC 7136](https://www.rfc-editor.org/info/rfc7136/), February 2014.
10.2. Informative References
[ADDR-GEN-PRIVACY]
Cooper, A., Gont, F., and D. Thaler, "Privacy
Considerations for IPv6 Address Generation Mechanisms",
Work in Progress, February 2014.
[BROERSMA] Broersma, R., "IPv6 Everywhere: Living with a Fully
IPv6-enabled environment", Australian IPv6 Summit 2010,
Melbourne, VIC Australia, October 2010,
<[http://www.ipv6.org.au/10ipv6summit/talks/](http://www.ipv6.org.au/10ipv6summit/talks/Ron_Broersma.pdf)
[Ron_Broersma.pdf](http://www.ipv6.org.au/10ipv6summit/talks/Ron_Broersma.pdf)>.
[CPNI-IPV6]
Gont, F., "Security Assessment of the Internet Protocol
version 6 (IPv6)", UK Centre for the Protection of
National Infrastructure, (available on request).
Gont Standards Track [Page 16]
RFC 7217 Stable and Opaque IIDs with SLAAC April 2014
[FIPS-SHS] NIST, "Secure Hash Standard (SHS)", FIPS Publication
180-4, March 2012, <[http://csrc.nist.gov/publications/](http://csrc.nist.gov/publications/fips/fips180-4/fips-180-4.pdf)
[fips/fips180-4/fips-180-4.pdf](http://csrc.nist.gov/publications/fips/fips180-4/fips-180-4.pdf)>.
[GONT-DEEPSEC2011]
Gont, F., "Results of a Security Assessment of the
Internet Protocol version 6 (IPv6)", DEEPSEC 2011
Conference, Vienna, Austria, November 2011,
<[http://www.si6networks.com/presentations/deepsec2011/](http://www.si6networks.com/presentations/deepsec2011/fgont-deepsec2011-ipv6-security.pdf)
[fgont-deepsec2011-ipv6-security.pdf](http://www.si6networks.com/presentations/deepsec2011/fgont-deepsec2011-ipv6-security.pdf)>.
[HD-MOORE] Moore, HD., "The Wild West", Louisville, Kentucky, U.S.A,
DerbyCon 2012, September 2012, <[https://speakerdeck.com/](https://speakerdeck.com/hdm/derbycon-2012-the-wild-west)
[hdm/derbycon-2012-the-wild-west](https://speakerdeck.com/hdm/derbycon-2012-the-wild-west)>.
[IAB-PRIVACY]
IAB, "Privacy and IPv6 Addresses", July 2011,
<[http://www.iab.org/wp-content/IAB-uploads/2011/07/](http://www.iab.org/wp-content/IAB-uploads/2011/07/IPv6-addresses-privacy-review.txt)
[IPv6-addresses-privacy-review.txt](http://www.iab.org/wp-content/IAB-uploads/2011/07/IPv6-addresses-privacy-review.txt)>.
[IANA-RESERVED-IID]
IANA, "Reserved IPv6 Interface Identifiers",
<[http://www.iana.org/assignments/ipv6-interface-ids](http://www.iana.org/assignments/ipv6-interface-ids)>.
[IPV6-RECON]
Gont, F. and T. Chown, "Network Reconnaissance in IPv6
Networks", Work in Progress, January 2014.
[RFC1321] Rivest, R., "The MD5 Message-Digest Algorithm", [RFC 1321](https://www.rfc-editor.org/info/rfc1321/),
April 1992.
[RFC1948] Bellovin, S., "Defending Against Sequence Number Attacks",
[RFC 1948](https://www.rfc-editor.org/info/rfc1948/), May 1996.
[RFC2464] Crawford, M., "Transmission of IPv6 Packets over Ethernet
Networks", [RFC 2464](https://www.rfc-editor.org/info/rfc2464/), December 1998.
[RFC2467] Crawford, M., "Transmission of IPv6 Packets over FDDI
Networks", [RFC 2467](https://www.rfc-editor.org/info/rfc2467/), December 1998.
[RFC2470] Crawford, M., Narten, T., and S. Thomas, "Transmission of
IPv6 Packets over Token Ring Networks", [RFC 2470](https://www.rfc-editor.org/info/rfc2470/), December
1998.
[[RFC3493](https://www.rfc-editor.org/info/rfc3493/)] Gilligan, R., Thomson, S., Bound, J., McCann, J., and W.
Stevens, "Basic Socket Interface Extensions for IPv6", RFC
3493, February 2003.
Gont Standards Track [Page 17]
RFC 7217 Stable and Opaque IIDs with SLAAC April 2014
[[RFC3542](https://www.rfc-editor.org/info/rfc3542/)] Stevens, W., Thomas, M., Nordmark, E., and T. Jinmei,
"Advanced Sockets Application Program Interface (API) for
IPv6", [RFC 3542](https://www.rfc-editor.org/info/rfc3542/), May 2003.
[RFC6059] Krishnan, S. and G. Daley, "Simple Procedures for
Detecting Network Attachment in IPv6", [RFC 6059](https://www.rfc-editor.org/info/rfc6059/), November
2010.
[RFC6105] Levy-Abegnoli, E., Van de Velde, G., Popoviciu, C., and J.
Mohacsi, "IPv6 Router Advertisement Guard", [RFC 6105](https://www.rfc-editor.org/info/rfc6105/),
February 2011.
[RFC6151] Turner, S. and L. Chen, "Updated Security Considerations
for the MD5 Message-Digest and the HMAC-MD5 Algorithms",
[RFC 6151](https://www.rfc-editor.org/info/rfc6151/), March 2011.
[RFC7113] Gont, F., "Implementation Advice for IPv6 Router
Advertisement Guard (RA-Guard)", [RFC 7113](https://www.rfc-editor.org/info/rfc7113/), February 2014.
Gont Standards Track [Page 18]
RFC 7217 Stable and Opaque IIDs with SLAAC April 2014
Appendix A. Possible Sources for the Net_Iface Parameter
The following subsections describe a number of possible sources for
the Net_Iface parameter employed by the F() function in Section 5.
The choice of a specific source for this value represents a number of
trade-offs, which may vary from one implementation to another.
A.1. Interface Index
The Interface Index [RFC3493] [RFC3542] of an interface uniquely
identifies that interface within the node. However, these
identifiers might or might not have the stability properties required
for the Net_Iface value employed by this method. For example, the
Interface Index might change upon removal or installation of a
network interface (typically one with a smaller value for the
Interface Index, when such a naming scheme is used) or when network
interfaces happen to be initialized in a different order. We note
that some implementations are known to provide configuration knobs to
set the Interface Index for a given interface. Such configuration
knobs could be employed to prevent the Interface Index from changing
(e.g., as a result of the removal of a network interface).
A.2. Interface Name
The Interface Name (e.g., "eth0", "em0", etc.) tends to be more
stable than the underlying Interface Index, since such stability is
required or desired when interface names are employed in network
configuration (firewall rules, etc.). The stability properties of
Interface Names depend on implementation details, such as what is the
namespace used for Interface Names. For example, "generic" interface
names such as "eth0" or "wlan0" will generally be invariant with
respect to network interface card replacements. On the other hand,
vendor-dependent interface names such as "rtk0" or the like will
generally change when a network interface card is replaced with one
from a different vendor.
We note that Interface Names might still change when network
interfaces are added or removed once the system has been bootstrapped
(for example, consider USB-based network interface cards that might
be added or removed once the system has been bootstrapped).
A.3. Link-Layer Addresses
Link-layer addresses typically provide for unique identifiers for
network interfaces; although, for obvious reasons, they generally
change when a network interface card is replaced. In scenarios in
which neither Interface Indexes nor Interface Names have the
stability properties specified in Section 5 for Net_Iface, an
Gont Standards Track [Page 19]
RFC 7217 Stable and Opaque IIDs with SLAAC April 2014
implementation might want to employ the link-layer address of the
interface for the Net_Iface parameter, albeit at the expense of
making the corresponding IPv6 addresses dependent on the underlying
network interface card (i.e., the corresponding IPv6 addresses would
typically change upon replacement of the underlying network interface
card).
A.4. Logical Network Service Identity
Host operating systems with a conception of logical network service
identity, distinct from network interface identity or index, may keep
a Universally Unique Identifier (UUID) [RFC4122] or similar
identifier with the stability properties appropriate for use as the
Net_Iface parameter.
Author's Address
Fernando Gont
SI6 Networks / UTN-FRH
Evaristo Carriego 2644
Haedo, Provincia de Buenos Aires 1706
Argentina
Phone: +54 11 4650 8472
EMail: fgont@si6networks.com
URI: http://www.si6networks.com
Gont Standards Track [Page 20]