Internet-Draft | RISAV | October 2023 |
Xu, et al. | Expires 25 April 2024 | [Page] |
This document presents RISAV, a protocol for establishing and using IPsec security between Autonomous Systems (ASes) using the RPKI identity system. In this protocol, the originating AS adds authenticating information to each outgoing packet at its Border Routers (ASBRs), and the receiving AS verifies and strips this information at its ASBRs. Packets that fail validation are dropped by the ASBR. RISAV achieves Source Address Validation among all participating ASes.¶
This note is to be removed before publishing as an RFC.¶
Source for this draft and an issue tracker can be found at https://github.com/bemasc/draft-xu-risav.¶
This Internet-Draft is submitted in full conformance with the provisions of BCP 78 and BCP 79.¶
Internet-Drafts are working documents of the Internet Engineering Task Force (IETF). Note that other groups may also distribute working documents as Internet-Drafts. The list of current Internet-Drafts is at https://datatracker.ietf.org/drafts/current/.¶
Internet-Drafts are draft documents valid for a maximum of six months and may be updated, replaced, or obsoleted by other documents at any time. It is inappropriate to use Internet-Drafts as reference material or to cite them other than as "work in progress."¶
This Internet-Draft will expire on 25 April 2024.¶
Copyright (c) 2023 IETF Trust and the persons identified as the document authors. All rights reserved.¶
This document is subject to BCP 78 and the IETF Trust's Legal Provisions Relating to IETF Documents (https://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 Revised BSD License text as described in Section 4.e of the Trust Legal Provisions and are provided without warranty as described in the Revised BSD License.¶
Source address spoofing is the practice of using a source IP address without proper authorization from its owner. The basic Internet routing architecture does not provide any defense against spoofing, so any system can send packets that claim any source address. This practice enables a variety of attacks, and we have summarized malicious attacks launched or amplified by spoofing address in Appendix A.¶
There are many possible approaches to preventing address spoofing. Section 2.1 of [RFC5210] describes three classes of Source Address Validation (SAV): Access Network, Intra-AS, and Inter-AS. Inter-AS SAV is the most challenging class because different ASes have different policies and operate independently. Inter-AS SAV requires the different ASes to collaborate to verify the source address. However, in the absence of total trust between all ASes, Inter-AS SAV is a prerequisite to defeating source address spoofing.¶
Despite years of effort, current Inter-AS SAV protocols are not widely deployed. An important reason is the difficulty of balancing the clear security benefits of partial implementations with the scalability of large-scale deployments. uRPF [RFC5635] [RFC8704], for example, is a routing-based scheme that filters out spoofed traffic. In cases where the routing is dynamic or unknown, uRPF deployments must choose between false negatives (i.e. incomplete SAV) and false positives (i.e. broken routing).¶
This document provides an RPKI- [RFC6480] and IPsec-based [RFC4301] approach to inter-AS source address validation (RISAV). RISAV is a cryptography-based SAV mechanism to reduce the spoofing of source addresses. In RISAV, the RPKI database acts as a root of trust for IPsec between participating ASes. Each pair of ASes uses IKEv2 to negotiate an IPsec Security Association (SA). Packets between those ASes are then protected by a modified IPsec Authentication Header (AH) [RFC4302] or an Encapsulating Security Payload (ESP)[RFC4303]. IPsec authenticates the source address, allowing spoofed packets to be dropped at the border of the receiving AS.¶
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in BCP14 [RFC2119] [RFC8174] when, and only when, they appear in all capitals, as shown here.¶
Commonly used terms in this document are described below.¶
AS Contact Server, which is the logical representation of one AS and is responsible for delivering session keys and other information to ASBR.¶
The IP address of the ACS.¶
AS border router, which is at the boundary of an AS.¶
Source Address Validation, which verifies the source address of an IP packet and guarantees the source address is valid.¶
The goal of this section is to provide a high-level description of what RISAV is and how RISAV works.¶
RISAV is a cryptographically-based inter-AS source address validation protocol that provides clear security benefits even at partial deployment. It is lightweight and efficient and provides incremental deployment incentives.¶
RISAV adds IP packet header authentication to IPsec. It aims to prove that each IP datagram was sent from inside the AS that owns its source address, defeating spoofing and replay attacks. It supports, but does not require, encryption of the whole IP packet.¶
RISAV does not aim to defend against specific network attacks such as DoS or DDoS, though RISAV could do more help to avert them.¶
A typical workflow of RISAV is shown in Figure 1.¶
RPKI [RFC6480] is a prerequisite for RISAV.¶
The five Regional Internet Registries (RIR), authorized by IANA, use their root certificate to sign the Certificate Authority (CA) certificate of the Local Internet Registry (LIR), which is used to authorize the Autonomous System (AS) (sometimes indirectly via the Internet Service Provider (ISP)). When they obtain their own CA certificate, the AS would sign an End Entity (EE) certificate with a Route Origin Authorisation (ROA) which is a cryptographically signed object that states which AS is authorized to originate a certain prefix, descripted in [RFC6482]. This authenticated binding of the ASN to its IP prefixes is published in the RPKI database.¶
Beyond ROA, RISAV also REQUIRED RPKI to provide the binding relationship between AS numbers, IP prefixes, contact IPs, and public keys. This process requires RISAV announcement, which tells other AS that this AS enables RISAV. Before deploying RISAV, each AS selects one or more representative contact IPs and publishes them in the RPKI database. When negotiating or consulting with one AS, the peer MUST first communicate with one of these contact IPs. Each contact IP is used to enable RISAV only for its own address family (i.e. IPv4 or IPv6), so ASes wishing to offer RISAV on both IPv4 and IPv6 must publish at least two contact IPs.¶
The entity who occupis the contact IPs are the AS Contact Server (ACS). The ACS initiates the RISAV announcement. In practice, each participating AS is REQUIRED to announce its support for RISAV in the RPKI database.¶
RISAV uses IKEv2 to negotiate IPsec security associations (SA) between any two ASes. ACS represents the AS to negotiate IPsec SAs with pair ASes. The ACS needs its own EE certificate for IKEv2. This EE certificate is REQUIRED like the BGPsec Router Certificate defined in [RFC8209].¶
After SAs negotiation and synchronization, all ASBRs would get the SAs from its local AS's ACS, including the session key and other parameters.¶
After SA negotiation and RPKI synchronization, RISAV is established. All packets between these ASes SHOULD be secured by adding a modified AH header or a standard ESP header.¶
Basically, at the source AS Border Router, RISAV adds a MAC (Message Authentication Code) to each outgoing packet that proves ownership of the packet's source address. At the recipient's ASBR, RISAV verifies and removes this MAC from the incoming traffic, recovering the unmodified original packet. The MAC is located in the Integrity Check Value (ICV) field of a modified IPsec AH or as part of the standard IPsec ESP payload.¶
RISAV uses modified IPsec AH for authentication of the IP source address by default. It uses ESP-NULL encryption when using IPsec ESP.¶
The functions of the control plane of RISAV include enabling and disabling RISAV, and it provides a green channel for quickly restarting the system in exceptional cases.¶
When RISAV is to be enabled, it should:¶
announce that this AS supports RISAV,¶
publish contact IPs,¶
and perform IPsec session initialization (i.e. IKEv2).¶
These functions are achieved in two steps. First, each participating AS publishes a Signed Object [RFC6488] in its RPKI Repository containing a RISAVAnnouncement
. The ASN.1 form of RISAVAnnouncement
is as follows:¶
RPKI-RISAV-2023 { iso(1) member-body(2) us(840) rsadsi(113549) pkcs(1) pkcs-9(9) smime(16) modules(0) id-mod-rpki-risav-2023(TBD) } DEFINITIONS EXPLICIT TAGS ::= BEGIN IMPORTS CONTENT-TYPE FROM CryptographicMessageSyntax-2010 -- in [RFC6268] { iso(1) member-body(2) us(840) rsadsi(113549) pkcs(1) pkcs-9(9) smime(16) modules(0) id-mod-cms-2009(58) } ; IPAddressFamily, IPAddress FROM IPAddrAndASCertExtn -- In [RFC3779] { iso(1) identified-organization(3) dod(6) internet(1) security(5) mechanisms(5) pkix(7) mod(0) id-mod-ip-addr-and-as-ident(30) } ; ct-rpkiRISAVAnnouncement CONTENT-TYPE ::= { TYPE RISAVAnnouncement IDENTIFIED BY id-ct-risav } id-ct-risav OBJECT IDENTIFIER ::= { iso(1) member-body(2) us(840) rsadsi(113549) pkcs(1) pkcs-9(9) id-smime(16) id-ct(1) risav(TDB2) } RISAVAnnouncement ::= SEQUENCE { version [0] INTEGER DEFAULT 0, asID ASID, contactIP SEQUENCE (SIZE(1..2)) OF IPAddressFamily, testing BOOLEAN DEFAULT FALSE } ASID ::= INTEGER END¶
version: The version number of RISAVAnnouncement here MUST be 0.¶
asID: The asID field contains the AS number of one Autonomous System that is going to support RISAV.¶
contactIP: Within the IPAddressFamily structure, addressFamily contains the Address Family Identifier (AFI) of an IP address family. Contact IP of RISAV only supports IPv4 and IPv6 but there could be one more IPv4 or IPv6 address. Therefore, addressFamily MUST be either 0001 or 0002 while addresses are a list of IP addresses. The inherit attribute MUST be prohibited in IPAddressChoice as there is no need to look into the list of historical contactIPs.¶
testing: The "testing" field indicates whether this contact IP is potentially unreliable. When this field is set to true
, other ASes MUST fall back to ordinary operation if IKE negotiation fails. Otherwise, the contact IP is presumed to be fully reliable, and other ASes SHOULD drop all non-RISAV traffic from this AS if IKE negotiation fails (see Section 8.1.2). So it has the default value of FALSE.¶
When a participating AS discovers another participating AS (via its general synchronization process of the RPKI database), it initiates an IKEv2 handshake between its own contact IP and the other AS's contact IP. This handshake MUST include an IKE_AUTH exchange that authenticates both ASes with their RPKI ROA certificates.¶
Once this handshake is complete, each AS MUST activate RISAV on all outgoing packets, and SHOULD drop all non-RISAV traffic from the other AS after a reasonable grace period (e.g. 60 seconds).¶
RISAV participants add one or more RISAVAnnouncement
s to the repository of RPKI. The RPKI procedures are otherwise the same as in the traditional RPKI. For more information about RPKI, see [RFC6480].¶
IKEv2 SAs can be terminated on demand using the Delete payload ([RFC7296], Section 1.4.1). In ordinary uses of IKEv2, the SAs exist in inbound-outbound pairs, and deletion of one triggers a response deleting the other.¶
In RISAV, SAs do not necessarily exist in pairs. Instead, RISAV's use of IPsec is strictly unidirectional, so deletion does not trigger an explicit response. Instead, ASes are permitted to delete both inbound and outbound SAs, and deletion of an inbound SA SHOULD cause the other network to retry RISAV negotiation. If this, or any, RISAV IKEv2 handshake fails with a NO_ADDITIONAL_SAS notification ([RFC7296], Section 1.3), the following convention applies:¶
AS $A is said to have signaled a "RISAV shutdown" to $B if it sends NO_ADDITIONAL_SAS on a handshake with no child SAs.¶
In response, $B MUST halt all further RISAV negotiation to $A until:¶
After at most 24 hours, $B SHOULD resume its regular negotiation policy with $A.¶
This convention enables participating ASes to shut down RISAV with any other AS, by deleting all SAs and rejecting all new ones. It also avoids tight retry loops after a shutdown has occurred, but ensures that RISAV is retried at least once a day.¶
To disable RISAV entirely, a participating AS MUST perform the following steps in order:¶
Apply a targeted shutdown (Section 3.2.1) to all other networks and delete all existing SAs. - Note that the shutdown procedure can fail if another network's ACS is unreachable.¶
Stop requiring RISAV authentication of incoming packets.¶
Remove the RISAVAnnouncement
from the RPKI Repository.¶
Wait at least 24 hours.¶
Shut down the contact IP.¶
Conversely, if any AS no longer publishes a RISAVAnnouncement
, other ASes MUST immediately stop sending RISAV to that AS, but MUST NOT delete any active Tunnel Mode SAs for at least 24 hours, in order to continue to process encrypted incoming traffic.¶
TODO: Discuss changes to the contact IP, check if there are any race conditions between activation and deactivation, IKEv2 handshakes in progress, SA expiration, etc.¶
In the event of a misconfiguration or loss of state, it is possible that a negotiated SA could become nonfunctional before its expiration time. For example, if one AS is forced to reset its ACS and ASBRs, it may lose the private keys for all active RISAV SAs. If RISAV were applied to the IKEv2 traffic used for bootstrapping, the participating ASes would be unable to communicate until these broken SAs expire, likely after multiple hours or days.¶
To ensure that RISAV participants can rapidly recover from this error state, RISAV places control plane traffic in a "green channel" that is exempt from RISAV's protections. This "channel" is defined by two requirements:¶
RISAV senders MUST NOT add RISAV protection to packets to or from any announced contact IP¶
RISAV recipients MUST NOT enforce RISAV validation on packets sent to or from any announced contact IP.¶
Although the green channel denies RISAV protection to the ACS, the additional mitigations described in Section 4 ensure that the ACS has limited exposure to address-spoofing and DDoS attacks. In addition, the ACS can use the IKEv2 COOKIE (Section 2.6 of [RFC7296]) and PUZZLE ([RFC8019]) systems to reject attacks based on source address spoofing.¶
All the ASBRs of the AS are REQUIRED to enable RISAV. The destination ASBR uses the IPsec SPI, destination address, and source address to locate the correct SA.¶
As defined in [RFC4301], the Security Association Database (SAD) stores all the SAs. Each data item in the SAD includes a cryptographic algorithm (e.g. HMAC-SHA-256), its corresponding key, and other relevant parameters.¶
When an outgoing packet arrives at the source ASBR, its treatment depends on the source and destination address. If the source address belongs to the AS in which the ASBR is located, and the destination address is in an AS for which the ASBR has an active RISAV SA, then the packet needs to be modified for RISAV.¶
The modification that is applied depends on whether IPsec "transport mode" or "tunnel mode" is active. RISAV implementations MUST support transport mode, and MAY support tunnel mode. The initiator chooses the mode by including or omitting the USE_TRANSPORT_MODE notification in the IKEv2 handshake, retrying in the other configuration if necessary.¶
When a packet arrives at the destination ASBR, it will check the destination address and the source address. If the destination belongs to the AS in which the destination ASBR is located, and the source address is in an AS with which this AS has an active RISAV SA, then the packet is subject to RISAV processing.¶
To avoid DoS attacks, participating ASes MUST drop any outgoing packet to the contact IP of another AS. Only the AS operator's systems (i.e. the ACS and ASBRs) are permitted to send packets to the contact IPs of other ASes. ASBRs MAY drop inbound packets to the contact IP from non-participating ASes.¶
To avoid conflict with other uses of IPsec (Section 8.3.1), RISAV updates the IPsec Authentication Header (AH) format, converting one RESERVED octet (which is previously required to always be zero) into a new "Scope" field. The updated format is shown in Figure 2.¶
The "Scope" field identifies the scope of protection for this authentication header, i.e. the entities that are expected to produce and consume it. Two Scope values are defined:¶
0: IP. This is the pre-existing use of the Authentication Header, to authenticate packets from the source IP to the destination IP.¶
1: AS. This header authenticates the packet from the source AS to the destination AS.¶
Other Scope values could be defined in the future.¶
The AS-scoped AH headers are only for AS-to-AS communication. Sending ASes MUST NOT add such headers unless the receiving AS has explicitly opted to receive them. Receiving ASes MUST strip off all such headers for packets whose destination is inside the AS, even if the AS is not currently inspecting the ICV values.¶
Transport mode normally imposes a space overhead of 32 octets, no more than general IPsec AH.¶
There are several situations in which an intermediate router on the path may generate an ICMP response to a packet, such as a Packet Too Big (PTB) response for Path MTU Discovery, or a Time Exceeded message for Traceroute. These ICMP responses generally echo a portion of the original packet in their payload.¶
An ASBR considers an ICMP payload to match a Transport Mode RISAV SA if:¶
The payload's source address is in this AS, AND¶
The payload's destination address is in the other AS, AND¶
The payload contains a RISAV AH header whose SPI matches the SA's.¶
When an ASBR observes a matching ICMP response, it MUST forward it to the intended recipient, with the following modifications:¶
The ASBR MUST remove the RISAV AH header from the payload, so that the echoed payload data matches the packet sent by the original sender.¶
When processing a Packet Too Big message, the ASBR MUST reduce the indicated MTU
value by the total length of the RISAV AH header.¶
These changes ensure that RISAV remains transparent to the endpoints, similar to the ICMP rewriting required for Network Address Translation [RFC5508] (though much simpler).¶
As RISAV does not require encryption for packet, so it uses ESP-NULL to authenticate the packet in tunnel mode.¶
Traditionally, the ESP ICV is computed on the entire ESP packet, excluding the Authentication Data field. Here, in RISAV, the ESP ICV SHOULD be calculated including the IP Source Address at first, following by SPI, Sequence Number, Payload Data, Padding (if present), Pad Length, and Next Header. Destination Address is ignored.¶
In tunnel mode, a RISAV sender ASBR wraps each outgoing packet in an ESP payload ([RFC4303]) and sends it as directed by the corresponding SA. This may require the ASBR to set the Contact IP as the source address, even if it would not otherwise send packets from that address. (See also "Anycast", Section 9.1).¶
Tunnel mode imposes a space overhead of 73 octets in IPv6.¶
Like any IPsec tunnel, RISAV normally reduces the effective IP Maximum Transmission Unit (MTU) on all paths where RISAV is active. To ensure standards compliance and avoid operational issues, participating ASes MUST choose a minimum acceptable "inner MTU", and reject any RISAV negotiations whose inner MTU would be lower.¶
There are two ways for a participating AS to compute the inner MTU:¶
Prior knowledge of the outer MTU. If a participating AS knows the minimum outer MTU on all active routes to another AS (e.g., from the terms of a transit or peering agreement), it SHOULD use this information to calculate the inner MTU of a RISAV SA with that AS.¶
Estimation of the outer MTU. If the outer MTU is not known in advance, the participating ASes MUST estimate and continuously monitor the MTU, disabling the SA if the inner MTU falls below the minimum acceptable value. An acceptable MTU estimation procedure is described in Section 5.2.¶
If the minimum acceptable inner MTU is close or equal to a common outer MTU value (e.g., 1500 octets), RISAV will not be usable in its baseline configuration. To enable larger inner MTUs, participating ASes MAY offer support for AGGFRAG [RFC9347] in the IKEv2 handshake if they are able to deploy it (see Section 6).¶
In tunnel mode, RISAV ASBRs MUST treat the tunnel as a single IP hop whose MTU is given by the current (estimated) inner MTU. Oversize packets that reach the ASBR SHALL generate Packet Too Big (PTB) ICMP responses (or be fragmented forward, in IPv4) as usual.¶
In transport mode, RISAV ASBRs SHOULD NOT enforce the estimated inner MTU. Instead, ASBRs SHOULD add RISAV headers and attempt to send packets as normal, regardless of size. (This may cause a PTB ICMP response at the current router or a later hop, which is modified and forwarded as described in Section 4.1.1.)¶
In either mode, the ASBR SHOULD apply TCP MSS clamping [RFC4459], Section 3.2 to outbound packets based on the current estimated inner MTU.¶
This section describes an MTU estimation procedure that is considered acceptable for deployment of RISAV. Other procedures with similar performance may also be acceptable.¶
To compute an initial estimate, the participating ASes use IKEv2 Path MTU Discovery (PMTUD) [RFC7383], Section 2.5.2 between their ACSes during the IKEv2 handshake. However, unlike the recommendations in [RFC7383], the PMTUD process is performed to single-octet granularity. The IKEv2 handshake only proceeds if the resulting outer MTU estimate is compatible with the minimum acceptable inner MTU when using the intended SA parameters.¶
The initial MTU estimate may not be correct indefinitely:¶
The Path MTU may change due to a configuration change in either participating AS.¶
The Path MTU may change due to a routing change outside of either AS.¶
The Path MTU may be different for packets to or from different portions of the participating ASes.¶
To ensure that the MTU estimate remains acceptable, and allow for different MTUs across different paths, each ASBR maintains an MTU estimate for each active SA, and updates its MTU estimate whenever it observes a PTB message. The ASBR's procedure is as follows:¶
Find the matching SA ({icmp-rewriting}) for this PTB message. If there is none, abort.¶
Check the SA's current estimated outer MTU against the PTB MTU. If the current estimate is smaller or equal, abort.¶
Perform an outward Traceroute to the PTB payload's destination IP, using packets whose size is the current outer MTU estimate, stopping at the first IP that is equal to the PTB message's sender IP or is inside the destination AS.¶
If a PTB message is received, reduce the current MTU estimate accordingly.¶
If the new estimated inner MTU is below the AS's minimum acceptable MTU, notify the ACS to tear down this SA.¶
Note that the PTB MTU value is not used, because it could have been forged by an off-path attacker. To preclude such attacks, all Traceroute and PMTUD probe packets contain at least 16 bytes of entropy, which the ASBR checks in the echoed payload.¶
To prevent wasteful misbehaviors and reflection attacks, this procedure is rate-limited to some reasonable frequency (e.g., at most once per minute per SA).¶
The IKEv2 configuration protocol is highly flexible, allowing participating ASes to negotiate many different RISAV configurations. For RISAV, two important IKEv2 parameters are the Traffic Selector ([RFC7296], Section 2.9) and the Replay Status.¶
TODO: Write draft porting Replay Status from RFC 2407 to IKEv2.¶
In the simplest RISAV configuration, the sending AS requests creation of a single "Child SA" whose Traffic Selector-initiator (TSi) lists all the IP ranges of the sending AS, and the Traffic Selector-responder (TSr) lists all the IP ranges of the receiving AS. This allows a single SA to carry all RISAV traffic from one AS to another. However, this SA is likely to be shared across many ASBRs, and potentially many cores within each ASBR, in both participating ASes.¶
It is difficult or impossible for a multi-sender SA to use monotonic sequence numbers, as required for anti-replay defense and Extended Sequence Numbers (ESN) (see [RFC4303], Section 2.2). If the sender cannot ensure correctly ordered sequence numbers, it MUST set the REPLAY-STATUS indication to FALSE in the CREATE_CHILD_SA notification, and MUST delete the SA if the recipient does not confirm that replay detection is disabled.¶
If the sender wishes to allow replay detection, it can create many Child SAs, one for each of its ASBRs (or each core within an ASBR). The OPTIONAL CPU_QUEUES
IKEv2 notification [I-D.ietf-ipsecme-multi-sa-performance] may make this process more efficient. If the sending ASBRs are used for distinct subsets of the sender's IP addresses, the TSi values SHOULD be narrowed accordingly to allow routing optimizations by the receiver.¶
Even if the sender creates many separate SAs, the receiver might not be able to perform replay detection unless each SA is processed by a single receiving ASBR. In Tunnel Mode, the receiver can route each SA to a specific ASBR using IKEv2 Active Session Redirect ([RFC5685], Section 5).¶
In Transport Mode, assignment of SAs to receiving ASBRs may be possible in cases where each ASBR in the receiving AS is responsible for a distinct subset of its IPs. To support this configuration, the receiving AS MAY narrow the initial TSr to just the IP ranges for a single ASBR, returning ADDITIONAL_TS_POSSIBLE. In response, the sending AS MUST reissue the CREATE_CHILD_SA request, with TSr containing the remainder of the IP addresses, allowing the negotiation of separate SAs for each receiving ASBR.¶
Future IKEv2 extensions such as Sequence Number Subspaces [I-D.ponchon-ipsecme-anti-replay-subspaces] or Lightweight SAs [I-D.mrossberg-ipsecme-multiple-sequence-counters] may enable more efficient and easily deployed anti-replay configurations for RISAV.¶
If the ACS receives a TSi value that includes IP addresses not owned by the counterpart AS, it MUST reject the SA to prevent IP hijacking. However, each AS's copy of the RPKI database can be up to 24 hours out of date. Therefore, when an AS acquires a new IP range, it MUST wait at least 24 hours before including it in a RISAV TSi.¶
If a tunnel mode SA is established, the receiving AS MUST drop any packet from the tunnel whose source address is not within the tunnel's TSi.¶
This section presents potential additions to the design.¶
TODO: Remove this section once we have consensus on whether these extensions are worthwhile.¶
An IPsec Authentication Header authenticates the whole constant part of a packet, including the entire payload. To improve efficiency, we could define an IKE parameter to negotiate a header-only variant of transport mode that only authenticates the IP source address, IP destination address, etc.¶
This would likely result in a 10-30x decrease in cryptographic cost compared to standard IPsec. However, it would also offer no SAV defense against any attacker who can view legitimate traffic. An attacker who can read a single authenticated packet could simply replace the payload, allowing it to issue an unlimited number of spoofed packets.¶
Each IKEv2 handshake negotiates a fixed shared secret, known to both parties. In some cases, it might be desirable to rotate the shared secret frequently:¶
In transport mode, frequent rotation would limit how long a single packet can be replayed by a spoofing attacker.¶
If the ASBRs are less secure than the ACS, frequent rotation could limit the impact of a compromised ASBR.¶
However, increasing the frequency of IKEv2 handshakes would increase the burden on the ACS. One alternative possibility is to use a state machine. The state machine runs and triggers the state transition when time is up. The tag is generated in the process of state transition as the side product. The two ACS in peer AS respectively before data transmission will maintain one state machine pair for each bound. The state machine runs simultaneously after the initial state, state transition algorithm, and state transition interval are negotiated, thus they generate the same tag at the same time. Time triggers state transition which means the ACS MUST synchronize the time to the same time base using like NTP defined in [RFC5905].¶
For the tag generation method, it MUST be to specify the initial state and initial state length of the state machine, the identifier of a state machine, state transition interval, length of generated Tag, and Tag. For the SA, they will transfer all these payloads in a secure channel between ACS and ASBRs, for instance, in ESP [RFC4303]. It is RECOMMENDED to transfer the tags rather than the SA for security and efficiency considerations. The initial state and its length can be specified at the Key Exchange Payload with nothing to be changed. The state machine identifier is the SPI value as the SPI value is uniquely in RISAV. The state transition interval and length of generated Tag should be negotiated by the pair ACS, which will need to allocate one SA attribute. The generated Tag will be sent from ACS to ASBR in a secure channel which MAY be, for example, ESP [RFC4303].¶
The use of IKEv2 between ASes might be fragile, and creates a number of potential race conditions (e.g. if the RPKI database contents change during the handshake). It is also potentially costly to implement, requiring O(N^2) network activity for N participating ASes. If these challenges prove significant, one alternative would be to perform the handshake statically via the RPKI database. For example, static-static ECDH [RFC6278] would allow ASes to agree on shared secrets simply by syncing the RPKI database.¶
Static negotiation makes endpoints nearly stateless, which simplifies the provisioning of ASBRs. However, it requires inventing a novel IPsec negotiation system, so it seems best to try a design using IKEv2 first.¶
In general, RISAV seeks to provide a strong defense against arbitrary active attackers who are external to the source and destination ASes. However, different RISAV modes and configurations offer different security properties.¶
When replay detection is disabled, off-path attackers cannot spoof the source IPs of a participating AS, but any attacker with access to valid traffic can replay it (from anywhere), potentially enabling DoS attacks by replaying expensive traffic (e.g. TCP SYNs, QUIC Initials). ASes that wish to have replay defense must enable it during the IKEv2 handshake (see Section 6).¶
An on-path attacker between two participating ASes could attempt to defeat RISAV by blocking IKEv2 handshakes to the Contact IP of a target AS. If the AS initiating the handshake falls back to non-RISAV behavior after a handshake failure, this enables the attacker to remove all RISAV protection.¶
This vulnerable behavior is required when the "testing" flag is set, but is otherwise discouraged.¶
RISAV provides significant security benefits even if it is only deployed by a fraction of all ASes. This is particularly clear in the context of reflection attacks. If two networks implement RISAV, no one in any other network can trigger a reflection attack between these two networks. Thus, if X% of ASes (selected at random) implement RISAV, participating ASes should see an X% reduction in reflection attack traffic volume.¶
When RISAV is used in transport mode, there is a risk of confusion between the RISAV AH header and end-to-end AH headers used by applications. (In tunnel mode, no such confusion is possible.) This risk is particularly clear during transition periods, when the recipient is not sure whether the sender is using RISAV or not.¶
To prevent any such confusion, RISAV's transport mode uses a distinctive Scope value in the Authentication Header. The receiving AS absorbs (and strips) all AH headers with this scope, and ignores those with any other scope, including ordinary end-to-end AH headers.¶
RISAV is independent from intra-domain SAV and access-layer SAV, such as [RFC8704] or SAVI [RFC7039]. When these techniques are used together, intra-domain and access-layer SAV checks MUST be enforced before applying RISAV.¶
The ACS, represented by a contact IP, must be a high-availability, high-performance service to avoid outages. There are various strategies to achieve this, including:¶
Election. This might be achieved by electing one distinguished ASBR as the ACS. The distinguished ASBR acting as an ACS will represent the whole AS to communicate with peer AS's ACS. This election takes place prior to the IKE negotiation. In this arrangement, an ASBR MUST be a BGP speaker before it is elected as the distinguished ASBR, and a new election MUST replace the ACS if it fails.¶
Anycast. The ACS could be implemented as an anycast service operated by all the ASBRs. Route flapping can be mitigated using IKEv2 redirection ([RFC5685], Section 4). Negotiated SAs must be written into a database that is replicated across all ASBRs.¶
To ensure coherent behavior across the AS, the ACS MUST deliver each SA to all relevant ASBRs in the AS immediately after it is negotiated. RISAV does not standardize a mechanism for this update broadcast.¶
During the SA broadcast, ASBRs will briefly be out of sync. RISAV recommends a grace period to prevent outages during the update process.¶
RISAV requires participating ASes to perform symmetric cryptography on every RISAV-protected packet that they originate or terminate. This will require significant additional compute capacity that may not be present on existing networks. However, until most ASes actually implement RISAV, the implementation cost for the few that do is greatly reduced. For example, if 5% of networks implement RISAV, then participating networks will only need to apply RISAV to 5% of their traffic.¶
Thanks to broad interest in optimization of IPsec, very high performance implementations are already available. For example, as of 2021 an IPsec throughput of 1 Terabit per second was achievable using optimized software on a single server [INTEL].¶
As all the outer IP header should be the unicast IP address, NAT-traversal mode is not necessary in inter-AS SAV.¶
RISAV modifies the handling of IPv6 packets as they traverse the network, resulting in novel networking behaviors. This section describes why those behaviors should not be viewed as violating the requirements of [RFC8200].¶
IPv6 requires that every link in the Internet have an MTU of 1280 octets or greater. This is known as the IPv6 minimum link MTU.¶
RISAV adds ~30-80 octets of overhead to each packet, reducing the effective link MTU. A naive version of RISAV could violate the 1280-octet rule, when running over a (compliant) path with a Path MTU of 1280 octets.¶
This violation is avoided by the requirements described in Section 5. The resulting behavior is fully compliant when the underlying Path MTU is stable, and should compensate or disable RISAV within a few seconds if the Path MTU changes.¶
Extension headers (except for the Hop-by-Hop Options header) are not processed, inserted, or deleted by any node along a packet's delivery path, until the packet reaches the node (or each of the set of nodes, in the case of multicast) identified in the Destination Address field of the IPv6 header.¶
In "tunnel mode" (Section 4.2), RISAV acts as a classic site-to-site tunnel, potentially adding its own extension headers. Section 4.1 of [RFC8200] specifically allows such tunnels, and they are commonly used.¶
In "transport mode" (Section 4.1), a RISAV ASBR does insert a new extension header, which could be viewed as a violation of this guidance. However, this new extension header is an implementation detail of a lightweight tunnel: it is only added after confirming that another router on the path will remove it, so that its presence is not detectable by either endpoint. (Section 4.1.1 adds further requirements to ensure that this header cannot be detected in ICMP responses either.)¶
In some RISAV configurations, it is expected that many ASBRs will decrypt and process packets with the destination IP of the ACS and/or emit packets using the source IP of the ACS. This can be viewed as replacing the central ACS with an "anycast" service, which is generally considered permissible.¶
[RFC9255] describes limits on the use of RPKI certificates for new purposes, including the following excerpts:¶
The RPKI was designed and specified to sign certificates for use within the RPKI itself and to generate Route Origin Authorizations (ROAs) [RFC6480] for use in routing. Its design intentionally precluded use for attesting to real-world identity...¶
RPKI-based credentials of INRs MUST NOT be used to authenticate real-world documents or transactions.¶
When a document is signed with the private key associated with an RPKI certificate, the signer is speaking for the INRs (the IP address space and AS numbers) in the certificate. ... If the signature is valid, the message content comes from a party that is authorized to speak for that subset of INRs.¶
RISAV's usage of RPKI key material falls squarely within these limits. The RPKI signature used in the IKEv2 handshake serves only to confirm that this party is authorized to originate and terminate IP packets using the corresponding IP ranges. The "identity" of this party is not relevant to RISAV.¶
TODO: Register RISAVAnnouncement.¶
Please add the id-mod-rpki-risav-2023 to the SMI Security for S/MIME Module Identifier (1.2.840.113549.1.9.16.0) registry (https://www.iana.org/assignments/smi-numbers/smi-numbers.xml#security-smime-0) as follows:¶
Decimal Description Specification --------------------------------------------------------------------- TBD id-mod-rpki-risav-2023 [RFC-to-be]¶
Please add the RISAVAnnouncement to the SMI Security for S/MIME CMS Content Type (1.2.840.113549.1.9.16.1) registry (https://www.iana.org/assignments/smi-numbers/smi-numbers.xml#security-smime-1) as follows:¶
Decimal Description Specification --------------------------------------------------------------------- TBD id-ct-risav [RFC-to-be]¶
Please add RISAVAnnouncement to the RPKI Signed Object registry (https://www.iana.org/assignments/rpki/rpki.xhtml#signed-objects) as follows:¶
Name OID Specification --------------------------------------------------------------------- RISAV Announcement 1.2.840.113549.1.9.16.1.TBD [RFC-to-be]¶
Please add an item for the RISAV Announcement file extension to the "RPKI Repository Name Scheme" registry created by [RFC6481] as follows:¶
Filename Extension RPKI Object Reference --------------------------------------------------------------------- .ra RISAVAnnouncement [RFC-to-be]¶
The malicious attacks that spoofing addresses can launch can be classified into two types: direct attacks and reflection attacks. Regardless of the scenario, the packets sent out by the attacker would use a spoofed IP address as its source address.¶
The packet with a spoofed address will go to the victim directly. These attacks include DoS, DDoS, flooding-based attacks, etc. In this case, it is hard to say whether this action is launched by the user's misconfiguration or a malicious attacker's intent even if SAV is deployed. But SAV could help to locate where the abnormal traffic originates and to stop it as soon as possible.¶
Attackers would not send packets to victims directly, but they would send packets to a server that runs amplification services, such as DNS, NTP, SNMP, SSDP, and other UDP/TCP-based services. The packet sent to the public server would be multiplicatively amplified and replied to the victim, which would be more destructive than a direct attack. In this case, if SAV is deployed, attackers can almost not launch such attacks.¶