14192
|
1 /**
|
15026
|
2 * @file header_info.h
|
14192
|
3 *
|
15026
|
4 * gaim
|
14192
|
5 *
|
15026
|
6 * Gaim is the legal property of its developers, whose names are too numerous
|
|
7 * to list here. Please refer to the COPYRIGHT file distributed with this
|
|
8 * source distribution.
|
14192
|
9 *
|
|
10 * This program is free software; you can redistribute it and/or modify
|
|
11 * it under the terms of the GNU General Public License as published by
|
|
12 * the Free Software Foundation; either version 2 of the License, or
|
|
13 * (at your option) any later version.
|
|
14 *
|
|
15 * This program is distributed in the hope that it will be useful,
|
|
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
18 * GNU General Public License for more details.
|
|
19 *
|
|
20 * You should have received a copy of the GNU General Public License
|
|
21 * along with this program; if not, write to the Free Software
|
|
22 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
23 */
|
|
24
|
|
25 #ifndef _QQ_HEADER_INFO_H_
|
|
26 #define _QQ_HEADER_INFO_H_
|
|
27
|
|
28 #include <glib.h>
|
|
29
|
|
30 #define QQ_UDP_HEADER_LENGTH 7
|
|
31 #define QQ_TCP_HEADER_LENGTH 9
|
|
32
|
|
33 #define QQ_PACKET_TAG 0x02 /* all QQ text packets starts with it */
|
|
34 #define QQ_PACKET_TAIL 0x03 /* all QQ text packets end with it */
|
|
35
|
15288
|
36 #define QQ_CLIENT 0x0f5f
|
14192
|
37
|
|
38 /* list of known QQ commands */
|
|
39 enum {
|
|
40 QQ_CMD_LOGOUT = 0x0001, /* log out */
|
|
41 QQ_CMD_KEEP_ALIVE = 0x0002, /* get onlines from tencent */
|
|
42 QQ_CMD_UPDATE_INFO = 0x0004, /* update information */
|
15253
|
43 QQ_CMD_SEARCH_USER = 0x0005, /* search for user */
|
14192
|
44 QQ_CMD_GET_USER_INFO = 0x0006, /* get user information */
|
|
45 QQ_CMD_ADD_FRIEND_WO_AUTH = 0x0009, /* add friend without auth */
|
|
46 QQ_CMD_DEL_FRIEND = 0x000a, /* delete a friend */
|
|
47 QQ_CMD_BUDDY_AUTH = 0x000b, /* buddy authentication */
|
|
48 QQ_CMD_CHANGE_ONLINE_STATUS = 0x000d, /* change my online status */
|
|
49 QQ_CMD_ACK_SYS_MSG = 0x0012, /* ack system message */
|
|
50 QQ_CMD_SEND_IM = 0x0016, /* send message */
|
|
51 QQ_CMD_RECV_IM = 0x0017, /* receive message */
|
|
52 QQ_CMD_REMOVE_SELF = 0x001c, /* remove self */
|
|
53 QQ_CMD_REQUEST_KEY = 0x001d, /* request key for file transfer */
|
|
54 QQ_CMD_CELL_PHONE_1 = 0x0021, /* cell phone 1 */
|
|
55 QQ_CMD_LOGIN = 0x0022, /* login */
|
|
56 QQ_CMD_GET_FRIENDS_LIST = 0x0026, /* retrieve my freinds list */
|
|
57 QQ_CMD_GET_FRIENDS_ONLINE = 0x0027, /* get my online friends list */
|
|
58 QQ_CMD_CELL_PHONE_2 = 0x0029, /* cell phone 2 */
|
|
59 QQ_CMD_GROUP_CMD = 0x0030, /* group command */
|
15139
|
60 QQ_CMD_GET_ALL_LIST_WITH_GROUP = 0x0058,
|
|
61 QQ_CMD_GET_LEVEL = 0x005C, /* get level for one or more buddies */
|
|
62 QQ_CMD_REQUEST_LOGIN_TOKEN = 0x0062, /* get login token */
|
14192
|
63 QQ_CMD_RECV_MSG_SYS = 0x0080, /* receive a system message */
|
|
64 QQ_CMD_RECV_MSG_FRIEND_CHANGE_STATUS = 0x0081, /* friends change status */
|
|
65 };
|
|
66
|
|
67 const gchar *qq_get_cmd_desc(gint type);
|
|
68
|
|
69 const gchar *qq_get_source_str(gint source);
|
|
70
|
|
71 #endif
|