Protocols/OSCAR/SNAC/ICBM CLIENT ERR

From NINA Wiki
Jump to navigation Jump to search
OSCAR Protocol
IntroductionTermsClients
Basic
DatatypesFLAPSNACTLV
UUIDsErrorsTool IDs
Host Interaction
Rate LimitsMigrationMessages
Other Services
ADMINADVERTALERT
BARTBOSBUCPCHAT
CHAT_NAV
Tutorials
Sign OnBARTRendezvous
ICBMLocateBuddies
Foodgroups
OSERVICE (0x0001)
LOCATE (0x0002)
BUDDY (0x0003)
ICBM (0x0004)
ADVERT (0x0005)
INVITE (0x0006)
ADMIN (0x0007)
POPUP (0x0008)
PD (0x0009)
USER_LOOKUP (0x000A)
STATS (0x000B)
TRANSLATE (0x000C)
CHAT_NAV (0x000D)
CHAT (0x000E)
ODIR (0x000F)
BART (0x0010)
FEEDBAG (0x0013)
ICQ (0x0015)
BUCP (0x0017)
ALERT (0x0018)
PLUGIN (0x0022)
UNNAMED_FG_24 (0x0024)
MDIR (0x0025)
ARS (0x044A)
ID Origin Name Foodgroup Service Status Version
0x0004, 0x000B Any ICBM__CLIENT_ERR Unspecified BOS Active 1.25

This error notice is one of the few SNACs that can be sent to the host and received by a client.

The SNAC can come from either origin source, this is because the message is basically forwarded from the source client, to the server, to the destination client.

This SNAC may only be sent as a programmatic response to an inter-client message. It is used to indicate that there was some problem with the original message received by the sender. If this SNAC is not immediately generated as a response, the client loses the right to send it at all and attempts to send it will be rejected by the server.

As transmitted, "cookie", "channel", and "username" are to be those which were presented in the inter-client message being rejected. As received, "username" has been changed to indicate the source of the error. It is not allowed to respond to a CLIENT_ERR SNAC with another CLIENT_ERR SNAC. Receiving a CLIENT_ERR SNAC does not grant the right to EVIL.

SNAC Header

Foodgroup uint16 (word) 00 04
Subgroup uint16 (word) 00 0B
Flags uint16 (word) 00 00
Request ID uint32 (dword) 00 00 00 00

SNAC Data

Name Type Notes
cookie ICBM Cookie Opaque data generated by conversation initiator and used to link up the conversation and errors
channel uint16 (word) [Class: ICBM__CHANNELS] Channel the message is on
username string08 Destination username when sending and the source username when received
code uint16 (word) [Class: ICBM__CLIENT_ERR] Error code
errorInfo blob Optional error info

Class: ICBM__CLIENT_ERRORS

The following are Inter-Client error codes.

Name Value Notes
ICBM__CLIENT_ERR_UNSUPPORTED_CHANNEL 0x01 Receiving client does not understand the channel
ICBM__CLIENT_ERR_BUSTED_ICBM_PAYLOAD 0x02 Receiving client thinks the payload is busted
ICBM__CLIENT_ERR_CHANNEL_SPECIFIC_ERROR 0x03 See ICBM__RENDEZVOUS_NAK which will be inside the errorInfo for values for ICBM__CHANNEL_RENDEZVOUS

From Aleksandr Shutko: SNAC(04,0B) client message error or data SNAC(04,0B) ICBM__CLIENT_ERR


Client send this snac as reply to SNAC(04,07). Server transfer it to client without changes, but only if its format is valid. This snac also used for auto-messages (away message/busy message/chat message/etc).

First dword in msg-id cookies is actually the computer uptime in milliseconds (ie GetTickCount(), at least this is what the ICQ Lite and the other official clients I have tested uses).

 00 04   word   SNAC family
 00 0B   word   SNAC subtype
 00 00   word   SNAC flags
 xx xx xx xx   dword   SNAC request-id
 xx xx xx xx
 xx xx xx xx
  qword   msg-id cookie
 
 xx xx   word   message channel (see table below)
 xx   byte   screenname string length
 xx ..   string   screenname string
 00 03   word   reason code (1 - unsupported channel, 2 - busted payload, 3 - channel specific)

 If channel is supported, here is channel-specific data (see references below).


 Channel 1    Channel 1 data format (plain-text messages)
 Channel 2    Channel 2 data format (rtf messages, rendezvous)



Example SNAC dump with flap header:


  2A 02 54 28 00 6E 00 04  00 0B 00 00 00 00 00 0B *.T(.n..........
  F3 3A C1 0C 70 18 00 00  00 02 07 36 32 31 38 38 .:..p......62188
  39 35 00 03 1B 00 07 00  00 00 00 00 00 00 00 00 95..............
  00 00 00 00 00 00 00 00  00 00 03 00 00 00 00 07 ................
  00 0E 00 07 00 00 00 00  00 00 00 00 00 00 00 00 ................
  00 E9 03 00 00 00 00 1B  00 55 73 65 72 20 69 73 .........User is
  20 63 75 72 72 65 6E 74  6C 79 20 4F 63 63 75 70  currently Occup
  69 65 64 00                                      ied.



Examples

Channel 1 Example

From Aleksandr Shutko: SNAC(04,0B)/CH1 ICBM__CLIENT_ERR/CH1


Client send this snac as reply to SNAC(04,07)/CH1. See also common description for SNAC(04,0B).

 00 04   word   SNAC family
 00 0B   word   SNAC subtype
 00 00   word   SNAC flags
 xx xx xx xx   dword   SNAC request-id
 xx xx xx xx
 xx xx xx xx
  qword   msg-id cookie
 00 01   word   message channel
 xx   byte   screenname string length
 xx ..   string   screenname string
 00 03   word   reason code (2 - busted payload, 3 - channel specific)
 05   char   fragment identifier (array of required capabilities)
 01   char   fragment version
 xx xx   word   Length of rest data
 xx ...   array   byte array of required capabilities (1 - text)
 01   char   fragment identifier (text message)
 01   char   fragment version
 xx xx   word   Length of rest data
 00 00   word   Message charset number
 ff ff   word   Message language number
 xx ..   string (ascii)   Message text string



Example SNAC dump with flap header:


  No example


Channel 2 Example

From Aleksandr Shutko: SNAC(04,0B)/CH2 ICBM__CLIENT_ERR/CH2


Client send this snac as reply to SNAC(04,07)/CH2. See also common description for SNAC(04,0B).

 00 04   word   SNAC family
 00 0B   word   SNAC subtype
 00 00   word   SNAC flags
 xx xx xx xx   dword   SNAC request-id
 xx xx xx xx
 xx xx xx xx
  qword   msg-id cookie
 
 00 02   word   message channel
 xx   byte   screenname string length
 xx ..   string   screenname string
 00 03   word   reason code (2 - busted payload, 3 - channel specific)
 Following contents is specific for capability, which was used in message with the same msg-id cookie
 
     Data format description for capability 
      {09461349-4C7F-11D1-8222-444553540000}
 xx xx   word (LE)   length of following data
 xx xx   word (LE)   protocol version
 xx .. xx   guid (LE)   plugin or zero bytes
 xx xx   word   unknown
 xx xx xx xx   dword (LE)   client capabilities flags
 xx   byte   unknown
 xx xx   word (LE)   seems to be a downcounter
 xx xx   word (LE)   length of following data
 xx xx   word (LE)   seems to be a downcounter as in first chunk above
 xx ..     unknown, usually zeros
if plugin field in first chunk above is zero, here is
      message, overwise here is
      plugin-specific data.



Example SNAC dump with flap header:


  2A 02 54 28 00 6E 00 04  00 0B 00 00 00 00 00 0B *.T(.n..........
  F3 3A C1 0C 70 18 00 00  00 02 07 36 32 31 38 38 .:..p......62188
  39 35 00 03 1B 00 07 00  00 00 00 00 00 00 00 00 95..............
  00 00 00 00 00 00 00 00  00 00 03 00 00 00 00 07 ................
  00 0E 00 07 00 00 00 00  00 00 00 00 00 00 00 00 ................
  00 E9 03 00 00 00 00 1B  00 55 73 65 72 20 69 73 .........User is
  20 63 75 72 72 65 6E 74  6C 79 20 4F 63 63 75 70  currently Occup
  69 65 64 00                                      ied.


ICBM SNACs

SNAC List
Subgroup Origin Name
0x0001 Any ICBM__ERR
This is the error SNAC for the ICBM foodgroup.
0x0002 Client ICBM__ADD_PARAMETERS
This SNAC is typically sent prior to sending the OSERVICE__CLIENT_ONLINE so that the host is properly initialized with the clients' preferences.
0x0003 Client ICBM__DEL_PARAMETERS
These are the delete all parameters for a given channel.
0x0004 Client ICBM__PARAMETER_QUERY
This SNAC requests ICBM parameters from the host.
0x0005 Host ICBM__PARAMETER_REPLY
This SNAC is sent by the host in response to a ICBM__PARAMETER_QUERY.
0x0006 Client ICBM__CHANNEL_MSG_TOHOST
This is the basic inter-client message after which the group was named (Inter-Client Basic Messages).
0x0007 Host ICBM__CHANNEL_MSG_TOCLIENT
This is the ICBM__CHANNEL_MSG_TOHOST after it has been reformatted by the host and sent to the destination client.
0x0008 Client ICBM__EVIL_REQUEST
This requests that the specified user is sent an EVIL notification.
0x0009 Host ICBM__EVIL_REPLY
The reply tells the requester, the sender of an ICBM__EVIL_REQUEST SNAC, how much EVIL, if any, was applied to the recipient.
0x000A Host ICBM__MISSED_CALLS
When the host is unable to send one or more messages to the client, the host sends this SNAC to the client to let it know that it missed some messages ("calls").
0x000B Any ICBM__CLIENT_ERR
This error notice is one of the few SNACs that can be sent to the host and received by a client.
0x000C Host ICBM__HOST_ACK
This SNAC is sent by the host upon receipt of any ICBM__CHANNEL_MSG_TOHOST which includes the optional ICBM__TLV_TAGS_REQUEST_HOST_ACK TLV.
0x000D NCD ICBM__SIN_STORED
This is not currently documented. Want to contribute?
0x000E NCD ICBM__SIN_LIST_QUERY
This is not currently documented. Want to contribute?
0x000F NCD ICBM__SIN_LIST_REPLY
This is not currently documented. Want to contribute?
0x0010 Client ICBM__SIN_RETRIEVE
This requests ICBM__CHANNEL_MSG_TOCLIENT messages be generated for each of the stored ICBMs. Any message retrieved is deleted.
0x0011 NCD ICBM__SIN_DELETE
This is not currently documented. Want to contribute?
0x0012 NCD ICBM__NOTIFY_REQUEST
This is not currently documented. Want to contribute?
0x0013 NCD ICBM__NOTIFY_REPLY
This is not currently documented. Want to contribute?
0x0014 Any ICBM__CLIENT_EVENT
This SNAC is sent as a control message, sent by a client to inform the recipient of an event, or by the host informing of an event.
0x0017 Host ICBM__SIN_REPLY
The host successfully processed the request to retrieve all the offline messages.