AIM/Oscar Protocol Specification: Section 10: Other Services


10.0 Other Services

10.1 Mail

Initially, the AIM client requests a new service of type 0x0005, advertisements. This is pseudo-required, as the service redirect for advertisements is the way we currently know when we're "online". However, there are a few other services of note.

AOL users (those of you with SN@aol.com mail accounts, mainly) can make use of service type 0x0018, which is how the newer AIM clients notify you of new mail. This is *not* POP-3, but an actual service extension. All other accounts added to the AIM client use POP-3.

Before anything happens, the normal service handshake must occur; this consists of essentially the same thing you do when signing on to the BOS - wait for the connection acknowledge, send your cookie, wait for "host ready", send a rate request, receive a rate response (and stare at it, wondering what it means :)), ack the response, and, finally, send a "client ready" command:

SNAC Information:

  • Family 0x0001
  • SubType 0x0002
  • Flags {0x00, 0x00}

Container Data TLV Type
RAW SNAC Header
RAW 0x0018  
RAW 0x0001  
RAW 0x0004  
RAW 0x0001  
RAW 0x0001  
RAW 0x0003  
RAW 0x0004  
RAW 0x076c  

 

* Optional: Client/server version information is also swapped, but it doesn't appear to be necessary. These are swapped before sending the initial rate request, and seem to always be swapped when establishing connections with services other than the BOS. It's probably a good idea to send this data. SNAC type 0x0001/0x0017 is the client version, and 0x0001/0x0018 is the server's response. These packets look like:


Container Data TLV Type
RAW SNAC Header
RAW SNAC Family (word: 0x0001, 0x0002, etc.)  
RAW Version supported (word)  

Adam sends: {1, 3}, {2, 1}, {3, 1}, {4, 1}, {6, 1}, {8, 1}, {9, 1}, {a, 1}, {b, 2}, {c, 1}, {15, 1}. This is all in the same packet (continuous), and your mileage may vary, depending on how much of the AIM protocol you choose to support.

10.2 Check for mail

This is sent to check for mail. Past the 0x0001 word, I'm not sure what the rest is. I had initially thought it to be a random ID (ala the ICBM cookies), but it stayed the same on multiple mail checks from multiple screen names, so I'm not sure.

SNAC Information:

  • Family 0x0018
  • SubType 0x0006
  • Flags {0x00, 0x00}

Container Data TLV Type
RAW SNAC Header
RAW 0x0001  
RAW 0x5d5e  
RAW 0x1708  
RAW 0x55aa  
RAW 0x11d3  
RAW 0xb143  
RAW 0x0060  
RAW 0xb0fb  
RAW 0x1ecb  

10.3 "You've got mail!"

This is sent to you by the AIM server in response to a mail request.

SNAC Information:

  • Family 0x0018
  • SubType 0x0007
  • Flags {0x00, 0x00}

Container Data TLV Type
RAW SNAC Header
RAW 8 bytes of zeros  
RAW "Mail cookie" returned (16 bytes)  
RAW 0x0003  
TLV HTTP redirect (usually http://aim.aol.com/redirects/inclient/aolmail.html) 0x0007
TLV "aol.com" (??) 0x0082
TLV One byte TLV -- value of 0x01 indicates we have new (unread) mail, and 0x00 indicates otherwise. 0x0081

 

 

   


Scott Werndorfer
Last modified: Sun Apr 09 12:48:00 EST 2000