Internet Draft Hisham Khartabil draft-khartabil-cpim-ucp-mapping-00.txt Category: Informational Anas Naim Hotsip January 2002 CPIM to UCP/EMI Mapping STATUS OF THIS MEMO This document is an Internet-Draft and is in full conformance with all provisions of Section 10 of RFC2026. Internet-Drafts are working documents of the Internet Engineering Task Force (IETF), its areas, and its working groups. Note that other groups may also distribute working documents as Internet- Drafts. 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 a reference material or to cite them other than as work in progress. The list of current Internet-Drafts can be accessed at http://www.ietf.org/ietf/1id-abstracts.txt The list of Internet-Draft Shadow Directories can be accessed at http://www.ietf.org/shadow.html. Copyright Notice Copyright (C) The Internet Society (2002). All Rights Reserved. Abstract Messaging is the fastest growing means of communication in the world. Mobile telephony and SMS have also been growing at an enormous rate, eventually bound to edge out traditional telephony systems in volumes and importance. Presence and Instant Messaging have become the cornerstones of modern communication. Mobile Presence integrates the concepts of presence over fixed and wireless networks for a wide variety of terminals. This memo introduces protocol mapping between CPIM [1], an IETF presence and messaging protocol, and UCP [2], an SMS protocol. This brings the Presence and Instant Messaging service to the mobile user. Khartabil [Page 1] Internet Draft CPIM to UCP/EMI Mapping January 2002 1.0 Introduction Until today, presence updates can only be done through accessing a PC or a PDA. The problem arises when a person needs to update his/her presence information whilst they are in a public place, on a street or any other place where there is no access to a PC. Also, PDA are very expensive and are very scarce in the market today. The average user on the street needing to update the presence information does not have means of doing so. This memo introduces protocol mapping between CPIM [1], an IETF presence and messaging protocol, and UCP [2], an SMS protocol, through some Gateway. This brings the Presence and Instant Messaging service to the mobile user. CPIM complaint client users want to send IMÆs to Mobile phones (GSM numbers) and the Mobile users need to be able to send replies back to the CPIM complaint client user by pushing just the REPLY button in their mobile phone. Therefore the IMs (SMSs) need to be sent between two legitimate GSM numbers. 2.0 Definitions and Acronyms CPIM: A Common Profile for Instant Messaging. From-header: The CPIM message From header. To-header: The CPIM message To header. Message-content: The message body content of a CPIM message. UCP: Universal Computer Protocol. ADC: Address code recipient for the short message. It is a UCP filed identifying the mobile phone number of the SMS recipient. OADC: Originator Address code for the short message. It is a UCP filed identifying the mobile phone number of the SMS recipient. AMsg: Numeric/Alphanumeric message. TRN: Transaction Reference Number. This number can have the value of 0-99. MVP: Modified Validity Period. SM: System Message. 3.0 CPIM-Side Originated Instant Message An example below shows a CPIM message, according to [4]: m: Content-type: Message/CPIM Khartabil [Page 2] Internet Draft CPIM to UCP/EMI Mapping January 2002 s: h: From: Hisham Khartabil h: To: Anas Naim h: Date: 2001-12-13T13:40:00-08:00 s: e: Content-type: text/plain; charset=utf-8 e: Content-ID: 1234567890@hotsip.com e: e: Here is the text of my message. The relevant parts from the CPIM message are the From-header, To- header and the Message-content. The following UCP message example shows the result of the mapping from the above CPIM message: stx37/00138/O/51/358400067890/358400012345/////////////////3//41202D 2D48657265206973207468652074657874206F66206D79206D6573736167652E//// /////////7Eetx More generic: stxTRN/00138/O/51/ADC/OADC/////////////////3//AMsg/////////////7Eetx 3.1 From-header mapping There are two options here: An ENUM [3] lookup is performed on the URL in the from-header. This lookup returns a phone number that is to be used. This phone number is stored in the UCP's OADC header. The second option is assigning a temporary number to the UCP OADC, this helps the gateway map any replies by the recipient to the original message. 3.2 To-header mapping An ENUM [3] lookup is performed on the URL in the to-header. This lookup returns a phone number that is to be used. This phone number is stored in the UCP's ADC header. If a phone number is alreadyin the user-name portion of the im URL, this number can be used as the ADC number. 3.3 Message-content mapping The CPIM Message-content is encoded according to [2] then copied directly into the UCP's AMsg header if the CPIM Message-content length is smaller than 160 characters. When the CPIM message Message-content is greater than 160 characters, there needs to be multiple UCP messages sent out. This is due to the limitations of the GSM SMS. Khartabil [Page 3] Internet Draft CPIM to UCP/EMI Mapping January 2002 The multiple UCP messages will have the same OADC and ADC, but the TRN value would increment for every message with the different Message-content. For example, if a message with content-length 430 is being sent from: Hisham Khartabil to: anas naim who is on a GSM phone connected to a UCP enabled SMSC, then that message needs to be mapped to a UCP message(s). The first 160 characters will be in the first mapped UCP message with an OADC value of Hisham's GSM number, ADC value of Anas's GSM number. The TRN value of, say, 37 is assigned. The second mapped UCP message will have the same OADC and ADC values of the first message, with the message content from 161 to 320. The TRN value will be 38. The final mapped UCP message will have the same OADC and ADC values with the last characters 321 to 430 with a TRN value of 39. 4.0 UCP-side Originated Instant Message (SMS) 4.1 OADC mapping The UCP OADC field will be in the form of a mobile phone number. This is made into a CPIM To-header by: - Either attaching the host name at the end of the number, and by adding the string ôim:ö in front of the number, or - Performing an ENUM lookup on the number and retrieving the im address of the intended recipient. 4.2 ADC mapping The UCP ADC field will be in the form of a mobile phone number. This is made into a CPIM To-header by: - Either attaching the host name at the end of the number, and by adding the string ôim:ö in front of the number, or - Performing an ENUM lookup on the number and retrieving the im address of the intended recipient. 4.3 AMsg mapping The message content of the UCP message stored in the AMsg field is converted into ASCII, UTF-8 or any other desired character set. It is then copied into the CMIP message-content field. 5.0 CPIM-Side Originated NOTIFY The from-header and to-header mapping are exactly as defined in section 3.1 and 3.2 respectively. This section will only talk about the message-content mapping. According to [5], a CPIM NOTIFY looks like this: m: Content-type: Message/CPIM s: Khartabil [Page 4] Internet Draft CPIM to UCP/EMI Mapping January 2002 h: From: Anas Naim h: To: Hisham Khartabil h: Date: 2001-12-13T13:40:00-08:00 s: e: Content-type: application/cpim-pidf+xml e: Content-ID: 1234567890@hotsip.com e: Content-Length: .. . open tel:09012345678 Call me please! AMsg is build from 3 components of the pidf mime body: presentity id, value and note. The final SMS could look like: "anas.naim@hotsip.com (open, Call me please!)" Or to save some SMS characters, you could represent is as follows: "anas naim (+, Call me please!)". 6.0 UCP-Side Originated NOTIFY The OADC and ADC mapping are exactly as defined in section 4.1 and 4.2 respectively. This section will only talk about the AMsg mapping. The AMg could look like "hisham.khartabil@hotsip.com (closed, sleeping)" or "Hisham (-, sleeping)" Building this is easy: - tuple id is mobile-phone - presentity id is found like the from-header (by ENUM lookup), or by just copying the from-header - value is closed (the - signed means closed) - contact is the originator's mobile phone number as a tel-url - note is also copied from the SMS itself. The final presence document would look like: closed tel:0407654321 Khartabil [Page 5] Internet Draft CPIM to UCP/EMI Mapping January 2002 sleeping 7.0 Open issues 8.0 Acknowledgments 9.0 References [1] D. Crocker et al., "Common Presence and Instant Messaging(CPIM)", draft-ietf-impp-cpim-02.txt, Work in Progress. [2] "SHORT MESSAGE SERVICE CENTRE: EMI û UCP INTERFACE" CMG Telecommunications & Utilities BV Division Advanced Technology. [3] P. Falstrom, E.164 number and DNS, RFC 2916 (Sep 2000) [4] D. Atkins, G. Klyne, "Common Presence and Instant Messaging Message Format", draft-ietf-impp-cpim-msgfmt-04.txt, Work in Progress. [5] H. Sugano, S. Fujimoto et al., "CPIM Presence Information Data Format", draft-ietf-impp-cpim-pidf-01.txt, Work in Progress. Khartabil [Page 6]