RFC 7075
Realm-Based Redirection In Diameter
Realm-Based Redirection In Diameter ๐
okay bestie, this one is RFC 7075 and it's a Standards Track doc from November 2013 ๐ฆ. It's written by T. Tsou and R. Hao, with T. Taylor as editor (Ed.) ๐
. Tsou and Taylor are at Huawei Technologies, Hao is at Comcast Cable, and the ISSN is 2070-1721 โจ. It updates RFC 6733 (Updates: 6733) ๐ธ.
Abstract โจ
so the Diameter protocol has this redirection thing ๐ where an application-independent "redirect agent" can point messages somewhere else. sometimes an operator wants to send messages to a whole alternate domain without listing out individual hosts ๐. this doc specifies an application-specific mechanism that lets a Diameter server or proxy (a node) do that redirect when the Straightforward-Naming Authority Pointer (S-NAPTR) is not being used for dynamic peer discovery ๐ฅ. the node doing this is called a "Realm-based Redirect Server" ๐.
this memo updates Sections 6.13 and 6.14 of RFC 6733 with respect to the usage of the Redirect-Host-Usage and Redirect-Max-Cache-Time Attribute-Value Pairs (AVPs) ๐.
Status of This Memo ๐
this is an Internet Standards Track document โญ.
it's a product of the Internet Engineering Task Force (IETF) ๐ซถ. it represents the consensus of the IETF community, it got public review, and the Internet Engineering Steering Group (IESG) approved it for publication ๐. if you want more info on Internet Standards, check Section 2 of RFC 5741 ๐ง.
for the current status, any errata, and how to send feedback, go to http://www.rfc-editor.org/info/rfc7075 ๐.
Copyright Notice ๐
Copyright (c) 2013 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 (http://trustee.ietf.org/license-info) as they're in effect on the date of publication ๐. please read these carefully, because they explain your rights and restrictions with respect to this document ๐. any Code Components pulled out of this document have to include Simplified BSD License text, as described in Section 4.e of the Trust Legal Provisions, and they come with no warranty, as described in the Simplified BSD License โจ.
Table of Contents ๐
1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3
1.1. Terminology . . . . . . . . . . . . . . . . . . . . . . . 3
2. Support of Realm-Based Redirection Within Applications . . . 4
3. Realm-Based Redirection . . . . . . . . . . . . . . . . . . . 5
3.1. Configuration of the Realm-Based Redirect Server . . . . 5
3.2. Behavior of Diameter Nodes . . . . . . . . . . . . . . . 6
3.2.1. Behavior at the Realm-Based Redirect Server . . . . . 6
3.2.2. Proxy Behavior . . . . . . . . . . . . . . . . . . . 6
3.2.3. Client Behavior . . . . . . . . . . . . . . . . . . . 7
3.3. The Redirect-Realm AVP . . . . . . . . . . . . . . . . . 7
3.4. DIAMETER_REALM_REDIRECT_INDICATION Protocol Error Code . 7
4. Security Considerations . . . . . . . . . . . . . . . . . . . 8
5. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 8
6. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 9
7. References . . . . . . . . . . . . . . . . . . . . . . . . . 9
7.1. Normative References . . . . . . . . . . . . . . . . . . 9
7.2. Informative References . . . . . . . . . . . . . . . . . 9
1. Introduction ๐ง
the Diameter base protocol [RFC6733] has a basic redirection service that a redirect agent provides ๐. the redirect indication that comes back from the redirect agent is described in Section 6.1.8 and Sections 6.12 through 6.14 of [RFC6733] ๐. it hands the message sender one or more individual hosts as the destination of the redirected message ๐ธ.
but here's the tea ๐ซ. imagine an operator who offered a specific service and now doesn't want to anymore ๐ญ. they've set up an alternative domain to provide the service instead ๐ฆ. to make the switch smooth, the original operator keeps a redirect server around to tell the message sender which alternative domain the request should be sent to ๐ . the thing is, the original operator shouldn't have to configure that redirect server with a list of hosts to contact in the alternative operator's domain ๐. the original operator should just be able to give redirect indications for the domain as a whole ๐.
1.1. 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] โจ.
in this spec, "realm-based redirection" means a mode of operation where a realm, instead of an individual host, is returned as the redirect indication ๐ฆ.
"Realm-based Redirect Server" is the Diameter node (Diameter server or proxy) that returns the realm-based redirection ๐. its behavior is a slight tweak on the basic redirect agent behavior from Section 6.1.8 of [RFC6733] ๐.
this document uses a bunch of terms the same way [RFC6733] does: "Diameter client", "Diameter node", "Diameter peer", "Diameter server", "proxy", "realm" or "domain", "redirect agent", and "session" (as defined in Section 1.2), plus "application", which is defined implicitly by Sections 1.3.4, 2.3, and 2.4 ๐.
2. Support of Realm-Based Redirection Within Applications ๐
the DNS-based dynamic peer discovery mechanism in the Diameter base protocol [RFC6733] gives you a simple way to do realm-based redirection using the S-NAPTR DDDS application [RFC3958] ๐ง. when S-NAPTR is used for peer discovery, you can redirect Diameter requests from the original realm to a new realm by updating the existing NAPTR resource records (RRs) for the original realm like this ๐ฆ: the NAPTR RR for the desired application(s) and supported application protocol(s) provided by the new realm has an empty FLAG field, and the REPLACEMENT field holds the new realm to use for the next DNS lookup ๐. the new realm can be arbitrary ๐ธ. the restriction in [RFC6733] that the NAPTR replacement field match the domain of the original query does not apply for realm-based redirect purposes ๐.
however, using DNS-based dynamic peer discovery is optional for Diameter implementations ๐ซถ. for deployments that don't use S-NAPTR peer discovery, support for realm-based redirection needs to be specified as part of the functionality a Diameter application supports ๐. that way, support of the Diameter application (found during the capabilities exchange phase defined in the Diameter base protocol [RFC6733]) implicitly indicates support for the realm-based redirection mechanism โจ. a new application specification can bring in the mechanism specified here by making it mandatory to implement for the application and referencing this specification normatively ๐.
the big deal: if realm-based redirection is an application-specific behavior, a basic redirect agent from [RFC6733] can't do it. it MUST be performed instead by an application-aware Diameter node (Diameter server or proxy), which this doc calls a "Realm-based Redirect Server" ๐ฅ.
an application can say whether realm-based redirection works only on complete sessions that start with the initial message, or on every message within the application, even if earlier messages in the same session weren't redirected ๐. this distinction only matters when realm-based redirection is first kicked off ๐ง. in the first case, existing sessions won't get disrupted when realm-based redirection gets deployed ๐. in the second case, existing sessions will be disrupted if they're stateful ๐ญ.
3. Realm-Based Redirection ๐ฆ
this section specifies an extension to the Diameter base protocol [RFC6733] to get realm-based redirection working ๐ . the pieces of this solution are:
- a new result code,
DIAMETER_REALM_REDIRECT_INDICATION (3011)๐ธ; - a new attribute-value pair (AVP),
Redirect-Realm (620)๐; and - associated behavior at Diameter nodes that implement this specification ๐.
this behavior includes the optional use of the Redirect-Host-Usage and Redirect-Max-Cache-Time AVPs โจ. in this doc, these AVPs apply to the peer discovered by a node acting on the redirect server's response, which is an extension of their normal usage as described in Sections 6.13 and 6.14 of [RFC6733] ๐.
Section 3.2.2 and Section 3.2.3 describe how a proxy or client may update its routing table for the application and initial realm after it selects a peer in the new realm following realm-based redirection ๐ง. heads up, though: the proxy or client will then automatically route later requests for that application to the new realm (except maybe requests within sessions already established with the initial realm) until the cached routing entry expires ๐. keep this in mind if the rerouting is meant to be temporary โณ.
3.1. Configuration of the Realm-Based Redirect Server ๐
a Diameter node (Diameter server or proxy) acting as a Realm-based Redirect Server MUST be configured as follows to run realm-based redirection ๐ฅ:
- configured with an application that incorporates realm-based redirection ๐ ;
- the Local Action field of the routing table described in Section 2.7 of [RFC6733] is set to
LOCAL๐ฆ; - an application-specific field is set to indicate that the required local action is to perform realm-based redirection ๐;
- an associated application-specific field is configured with the identities of one or more realms to which the request should be redirected ๐.
3.2. Behavior of Diameter Nodes ๐
3.2.1. Behavior at the Realm-Based Redirect Server
okay so bestie, remember how Section 2 talked about this? ๐ An application can say realm-based redirection only kicks in for complete sessions starting from the initial message (so established sessions don't get disrupted ๐ซถ), OR it can apply to every single message in the app, even if earlier messages in the same session weren't redirected ๐.
If a Realm-based Redirect Server set up the way Section 3.1 describes gets a request that realm-based redirection applies to, it MUST reply with an answer message that has the 'E' bit set ๐ฅ, and it MUST keep the Hop-by-Hop Identifier in the header. It MUST also include the Result-Code AVP set to DIAMETER_REALM_REDIRECT_INDICATION ๐ , and it MUST include the alternate realm identifier(s) it was configured with, each one in its own Redirect-Realm AVP instance โจ.
The Realm-based Redirect Server MAY include a copy of the Redirect-Host-Usage AVP ๐ง, and if it does, that AVP SHOULD be set to REALM_AND_APPLICATION. If this AVP gets added, the Redirect-Max-Cache-Time AVP MUST also be included ๐ธ. Heads up that these AVPs apply to the peer discovered by a node acting on the server's response (more on that in the next section) ๐. This is a bit of an extension of how they normally work, as described in Sections 6.13 and 6.14 of [RFC6733] ๐.
Realm-based redirection MAY be applied even if a Destination-Host AVP is present in the request, depending on the operator-based policy. ๐
3.2.2. Proxy Behavior
A proxy that follows this spec and gets an answer message with the Result-Code AVP set to DIAMETER_REALM_REDIRECT_INDICATION MUST try to reroute the original request to a server in a realm named by a Redirect-Realm AVP instance in that answer ๐ฆ. If that fails, it MUST forward the indication toward the client ๐. To reroute, it MUST do the following:
- Pick one specific realm from the ones listed in the Redirect-Realm AVP instances in the answer message ๐.
- If that worked, find and set up a route to a peer in the realm given by the Redirect-Realm AVP, using the normal discovery steps in Section 5.2 of [RFC6733] ๐.
- If that worked too: A. Update its cache of routing entries for the realm and application the original request was aimed at, taking into account the Redirect-Host-Usage and Redirect-Max-Cache-Time AVPs if they're in the answer ๐๏ธ. B. Remove the Destination-Host (if present) and Destination-Realm AVPs from the original request, then add a new Destination-Realm AVP containing the realm picked in the first step ๐. C. Forward the modified request ๐.
- If either step 2 or step 3 fails and the original answer had more realms, pick another Redirect-Realm AVP instance from that answer and repeat steps 2-3 for the realm it names ๐ญ.
3.2.3. Client Behavior
A client that follows this spec MUST be ready to get either an answer message with a Result-Code AVP set to DIAMETER_REALM_REDIRECT_INDICATION, OR, as a result of proxy action, some other result from a realm that's different from the one it sent the original request to ๐ซ . When it gets DIAMETER_REALM_REDIRECT_INDICATION, the client SHOULD follow the same steps the previous section lays out for a proxy ๐ . The goal is to update its routing table AND get service for the original request ๐ฅ.
3.3. The Redirect-Realm AVP
The Redirect-Realm AVP (620) is of type DiameterIdentity. It specifies a realm where a node that receives a redirect indication containing the result code value DIAMETER_REALM_REDIRECT_INDICATION and the Redirect-Realm AVP SHOULD route the original request ๐ง.
3.4. DIAMETER_REALM_REDIRECT_INDICATION Protocol Error Code
The DIAMETER_REALM_REDIRECT_INDICATION (3011) Protocol error code means a server figured out that the request, inside an application that supports realm-based redirection, couldn't be handled locally ๐ โโ๏ธ. The initiator of the request SHOULD send it directly to a peer in a realm that's been named in the response ๐ฏ. When this code is set, the Redirect-Realm AVP MUST be present ๐.
4. Security Considerations โ ๏ธ
The general recommendations in Section 13 of the Diameter base protocol [RFC6733] apply here ๐. The specific security recommendations for the realm-based redirection defined in this document are below ๐.
Realm-based redirection changes the business relationship between organizations ๐ข. Before redirecting a request toward a realm that's different from the initial realm, the client or proxy MUST make sure the authorization checks have been done at each connection along the path toward the realm named in the realm-based redirect indication ๐ง. Details on setting up the Diameter authorization path are in Section 2.9 of [RFC6733] ๐. Section 13 of [RFC6733] gives recommendations on how to authenticate and secure each peer-to-peer connection (using TLS, DTLS, or IPsec) along the way, which allows the necessary hop-by-hop authorization checks ๐.
Even though the administrative domains are assumed to be secure, a compromised Diameter node acting as a Realm-based Redirect Server could redirect a huge number of Diameter requests toward a victim domain, which would then get flooded with unwanted Diameter requests ๐ฑ๐จ. Secure Diameter peer-to-peer connections and authorization checks are still the discouraged option for this attack, since they'd let a potential victim domain figure out where the attack is coming from ๐ต๏ธโโ๏ธ. That alone, though, doesn't stop the DoS attack ๐.
Because realm-based redirection in this document means the Destination-Realm AVP in a client-initiated request can be changed by a Diameter proxy on the path between client and server, any cryptographic algorithm that uses the Destination-Realm AVP as input to the calculation done by the client and server would be broken by this form of redirection ๐. Application specifications that rely on such cryptographic algorithms SHOULD NOT incorporate this realm-based redirection ๐ โโ๏ธ.
5. IANA Considerations ๐๏ธ
This specification allocates a new AVP code, Redirect-Realm (620), in the "AVP Codes" registry under "Authentication, Authorization, and Accounting (AAA) Parameters" ๐.
This specification allocates a new Result-Code value, DIAMETER_REALM_REDIRECT_INDICATION (3011), in the "Result-Code AVP Values (code 268) - Protocol Errors" registry under "Authentication, Authorization, and Accounting (AAA) Parameters" โจ.
6. Acknowledgements ๐ซถ
Glen Zorn, Sebastien Decugis, Wolfgang Steigerwald, Mark Jones, Victor Fajardo, Jouni Korhonen, Avi Lior, and Lionel Morand contributed comments that helped shape this document ๐. As shepherd, Lionel added a second set of comments that polished the document before it went to the IESG ๐ . Benoit Claise picked up extra points that were quickly resolved with Lionel's help ๐ธ. During IETF Last Call Review, Enrico Marocco caught some important editorial corrections ๐. Stefan Winter contributed text on using S-NAPTR as an alternative method of realm-based redirection already specified in [RFC6733] ๐งญ. Derek Atkins did a review on behalf of the Security Directorate ๐. Lionel noted one more correction ๐.
Finally, this document benefited from comments and discussion raised by IESG members Stewart Bryant, Stephen Farrell, Barry Leiba, Pete Resnick, Jari Arkko, and Sean Turner during IESG review ๐.
The authors are so grateful to Lionel Morand for his active role as document shepherd. At each stage he worked to summarize and resolve comments, which made the editor's role easy. Thank you, Lionel ๐ฅน๐ซถ.
7. References ๐
7.1. Normative References
[RFC2119] Bradner, S., "Key words for use in RFCs to Indicate Requirement Levels", BCP 14, RFC 2119, March 1997.
[RFC6733] Fajardo, V., Arkko, J., Loughney, J., and G. Zorn, "Diameter Base Protocol", RFC 6733, October 2012.
7.2. Informative References
[RFC3958] Daigle, L. and A. Newton, "Domain-Based Application Service Location Using SRV RRs and the Dynamic Delegation Discovery Service (DDDS)", RFC 3958, January 2005.
Authors' Addresses ๐ฎ
Tina Tsou Huawei Technologies (USA) 2330 Central Expressway Santa Clara, CA 95050 USA
Phone: +1 408 330 4424 EMail: Tina.Tsou.Zouting@huawei.com URI: http://tinatsou.weebly.com/contact.html
Ruibing Hao Comcast Cable One Comcast Center Philadelphia, PA 19103 USA
Phone: +1 215 286 3991(O) EMail: Ruibing_Hao@cable.comcast.com
Tom Taylor (editor) Huawei Technologies Ottawa Canada
EMail: tom.taylor.stds@gmail.com
๐ฆ where this page comes from
- ietf: rfc7075 2013-11
- ๐ girlified by claude-haiku-5-5 on : a language model's rewrite of the original, under its terms