RFC 3861

Address Resolution for Instant Messaging and Presence

πŸ“… published August 2004, from ietf

Address Resolution for Instant Messaging and Presence ✨

Okay bestie, this is RFC 3861 πŸ’Œ It's a Standards Track spec from the Network Working Group, written by J. Peterson of NeuStar and dated August 2004. The title block doesn't list anything it obsoletes or updates, so there's no older RFC to chase down πŸ¦‹

Standards Track means it's a real protocol spec that implementers are meant to follow, not just a vibe-check or a discussion doc πŸ‘‘


Status of this Memo

This document specifies an Internet standards track protocol for the Internet community, and requests discussion and suggestions for improvements. Please refer to the current edition of the "Internet Official Protocol Standards" (STD 1) for the standardization state and status of this protocol. Distribution of this memo is unlimited.

Copyright (C) The Internet Society (2004).

Abstract

Okay so the big idea is that presence and instant messaging are defined in RFC 2778, and the Common Profiles for Presence and Instant Messaging define two URI schemes: im for INSTANT INBOXes and pres for PRESENTITIES. This doc gives guidance on how to find the resources behind URIs that use those schemes πŸ”

Table of Contents

   1.  Introduction. . . . . . . . . . . . . . . . . . . . . . . . . . 2
   2.  Terminology . . . . . . . . . . . . . . . . . . . . . . . . . . 3
   3.  Address Resolution. . . . . . . . . . . . . . . . . . . . . . . 3
   4.  Domain Name Lookup. . . . . . . . . . . . . . . . . . . . . . . 4
   5.  Processing SRV RRs. . . . . . . . . . . . . . . . . . . . . . . 4
   6.  Processing Multiple Addresses . . . . . . . . . . . . . . . . . 5
   7.  Security Considerations . . . . . . . . . . . . . . . . . . . . 5
   8.  IANA Considerations . . . . . . . . . . . . . . . . . . . . . . 5
   9.  Contributors. . . . . . . . . . . . . . . . . . . . . . . . . . 6
   10. Normative References. . . . . . . . . . . . . . . . . . . . . . 6
   11. Author's Address. . . . . . . . . . . . . . . . . . . . . . . . 7
   12. Full Copyright Statement. . . . . . . . . . . . . . . . . . . . 8

1. Introduction πŸŽ€

Presence and instant messaging are defined in RFC 2778 [5]. The Common Profiles for Presence (CPP) [2] and Instant Messaging (CPIM) [1] define two Universal Resource Identifier (URI) schemes: im for INSTANT INBOXes and pres for PRESENTITIES. This document gives rules for finding the resources behind URIs that use these schemes, via the Domain Name Service (DNS) [4]. Honestly these rules could probably be used for other URI schemes that have nothing to do with IM or presence too 🌈

CPIM and CPP both have operations with 'source' and 'destination' attributes. CPIM and CPP only define what these attributes mean, not how they're written down. But lots of IM and presence protocols today let you use URIs for source and destination, so the principals in an exchange can be identified. The im and pres schemes let those protocols do exactly that. When these operations go through a CPIM or CPP gateway, the URIs can be passed along unchanged, which is super useful for interoperability πŸ’–

These URI schemes are also handy when there's no CPIM/CPP gatewaying at all. Say a principal's endpoint supports several IM apps. Then the domain for that host can publish the kind of DNS records described in this document, so clients that only speak one IM protocol can still connect. A client looks up the record for the protocol it supports and learns how to reach the endpoint over that protocol. In this case, the principal would use an IM URI as their canonical address 🧚

In some architectures these URIs might also be used to find a CPIM or CPP gateway that serves a particular domain. Say an IM service provider runs CPIM/CPP gateways in its own domain that translate standard Internet protocols to an internal proprietary one. That gateway could be identified with an IM URI. In that case, the DNS records used to dereference the IM URI would do a job similar to Mail Exchange (MX) records πŸ“¬

The system in this document relies on DNS service (SRV) [7] records and address (A) records.

2. Terminology

Here's the vocab section, bestie πŸ“– In this document, the key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "OPTIONAL" are to be interpreted as described in BCP 14, RFC 2119 [3], and they indicate requirement levels for compliant implementations. Those key words are not up for interpretation, so take them seriously πŸ’…

This memo uses the vocabulary defined in RFC 2778 [5]. Terms like CLOSED, INSTANT INBOX, INSTANT MESSAGE, and OPEN mean the same thing here that they mean there 🌸

3. Address Resolution πŸ”

A client finds the address of an appropriate system running a server, on behalf of the system the domain refers to. It does this by resolving the destination domain name that's part of the identifier, and the result is either an intermediate relay system or a final target system. Lowkey it's a two-hop vibe sometimes πŸ¦‹

Only resolvable, fully-qualified, domain names (FQDNs) are permitted when domain names are used in an Instant Messaging (IM) URI. In other words, the domain names have to be resolvable to SRV [7] or A Resource Record (RR) βœ…

The symbolic name in the Service field of the SRV record is "_im" for instant messaging and "_pres" for presence, which matches their URI schemes. But advertising these services in DNS is incomplete unless it also includes the protocol that will carry the instant messaging or presence operations. So the Protocol field of the SRV record holds an IANA-registered label for the underlying IM or presence protocol being advertised. See Section 8 for more on valid Protocol fields πŸŽ€

Let's walk through the IM URI as an example. A lookup is done for SRVs for the target domain, a desired service (using the "_im" Service label), and a desired IM transfer protocol. Say the destination INSTANT INBOX is im:fred@example.com, and the sender wants to use an IM transfer protocol called "BIP". Assuming "_bip" was registered with IANA as a valid Protocol label for the IM Service, the SRV lookup is:

_im._bip.example.com.

PRES URIs use the exact same procedure, just with the "_pres" Service label ✨

Some clients support several IM or presence protocols. In those cases they may make several SRV queries, in an application-specific order, until they find one that they have in common with the target domain πŸ’œ

4. Domain Name Lookup 🧭

Once a client has lexically identified a domain that IM or presence operations will be delivered to for processing, a DNS lookup MUST be performed to resolve the domain. The names MUST be fully-qualified domain names (FQDNs). How you infer FQDNs from partial names or local aliases is a local matter 🏠

The lookup first tries to find SRV RRs associated with the domain. If a canonical name (CNAME) RR shows up instead, the resulting domain gets processed as if it were the initial domain πŸ”

If one or more SRV RRs are found for a given domain, a sender MUST NOT utilize any A RRs associated with that domain unless they're located using the SRV RRs. So SRV wins, no sneaking around it πŸ™…β€β™€οΈ If no SRV RRs are found but an A RR is, then the A RR is treated as if it were associated with an implicit SRV RR, with a preference of 0, pointing to that domain.

5. Processing SRV RRs πŸ› οΈ

The returned DNS RRs, if any, specify the next-hop server. That next hop might be a protocol gateway or an endpoint πŸ¦‹

Receiving systems that are registered for this DNS-based SRV resolution service list the transfer protocols they can be reached by, either directly or through a translating gateway. They do this using combinations of Service and Protocol labels, as described above πŸ“‹ The transfer-time choice of IM transfer protocol (and therefore which one gets resolved) is a local configuration option for each sending system. Your settings, your call βš™οΈ

Using this mechanism, seamless routing of IM traffic is possible, no matter whether a gateway is needed for interoperation. To get that transparency, a separate RR for a gateway must be present for each transfer protocol and domain pair that it serves. Real talk, that's a lot of records, but it's what makes everything line up πŸ’…

Part 1 ends here, bestie. Part 2 picks up with Section 6 (Processing Multiple Addresses) and carries on through the rest of the document, including the Security Considerations, IANA Considerations, References, and the Full Copyright Statement 🌈

10. Normative References πŸ“šβœ¨

okay so these are the docs this one leans on, bestie 🫢 if you're gonna read RFC 3861 you need these open in another tab, no cap.

  • [1] Peterson, J., "Common Profile for Instant Messaging (CPIM)", RFC 3860, August 2004. πŸ’¬
  • [2] Peterson, J., "Common Profile for Presence (CPP)", RFC 3859, August 2004. 🌸
  • [3] Bradner, S., "Key words for use in RFCs to indicate requirement levels", BCP 14, RFC 2119, March 1997. πŸ”‘
  • [4] Mockapetris, P., "Domain Names - Concepts and Facilities", STD 13, RFC 1034, November 1987. 🧚
  • [5] Day, M., Rosenberg, J., and H. Sugano, "A Model for Presence and Instant Messaging", RFC 2778, February 2000. πŸ¦‹
  • [6] Day, M., Aggarwal, S., and J. Vincent, "Instant Messaging / Presence Protocol Requirements", RFC 2779, February 2000. πŸ’œ
  • [7] Gulbrandsen, A., Vixie, P., and L. Esibov, "A DNS RR for Specifying the Location of Services (SRV)", RFC 2782, February 2000. πŸŽ€
  • [8] Narten, T. and H. Alvestrand, "Guidelines for Writing an IANA Considerations Section in RFCs", RFC 2434, BCP 26, October 1998. πŸ’…

11. Author's Address πŸŽ€

this is who wrote it, bestie! Jon Peterson, over at NeuStar, Inc. πŸ’–

Jon Peterson
NeuStar, Inc.
1800 Sutter St
Suite 570
Concord, CA  94520
US

Phone: +1 925/363-8720
EMail: jon.peterson@neustar.biz

okay this part is serious, so read it carefully πŸ™ˆ

Copyright (C) The Internet Society (2004). This document is subject to the rights, licenses and restrictions contained in BCP 78, and except as set forth therein, the authors retain all their rights. πŸ’œ

This document and the information contained herein are provided on an "AS IS" basis and THE CONTRIBUTOR, THE ORGANIZATION HE/SHE REPRESENTS OR IS SPONSORED BY (IF ANY), THE INTERNET SOCIETY AND THE INTERNET ENGINEERING TASK FORCE DISCLAIM ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 😭

Intellectual Property πŸ”

so the IETF takes no position on whether any IPR (intellectual property rights) that might be claimed over the tech in this doc are valid, how far they reach, or whether a license for them would even be available. it also doesn't claim it went looking for any of that stuff πŸ™ˆ if you want the procedures for rights in RFCs, check out BCP 78 and BCP 79.

copies of IPR disclosures made to the IETF Secretariat, any assurances of licenses to be made available, or the results of an attempt to get a general license or permission for implementers or users can be found in the IETF on-line IPR repository at:

http://www.ietf.org/ipr

and if you spot any copyrights, patents, patent applications, or other proprietary rights that might cover technology needed to implement this standard, the IETF invites you to tell them about it. send that info to:

ietf-ipr@ietf.org

Acknowledgement 🫢

funding for the RFC Editor function is currently provided by the Internet Society. thank you to them, honestly πŸ’–

πŸ“¦ where this page comes from