• Home
  • History
  • Annotate
  • Line#
  • Navigate
  • Raw
  • Download
  • only in /netgear-R7000-V1.0.7.12_1.2.5/ap/gpl/amule/aMule-2.3.1/src/include/protocol/ed2k/Client2Server/
1//
2// This file is part of the aMule Project.
3//
4// Copyright (c) 2003-2011 aMule Team ( admin@amule.org / http://www.amule.org )
5// Copyright (c) 2002-2011 Merkur ( devs@emule-project.net / http://www.emule-project.net )
6//
7// Any parts of this program derived from the xMule, lMule or eMule project,
8// or contributed by third-party developers are copyrighted by their
9// respective authors.
10//
11// This program is free software; you can redistribute it and/or modify
12// it under the terms of the GNU General Public License as published by
13// the Free Software Foundation; either version 2 of the License, or
14// (at your option) any later version.
15//
16// This program is distributed in the hope that it will be useful,
17// but WITHOUT ANY WARRANTY; without even the implied warranty of
18// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
19// GNU General Public License for more details.
20//
21// You should have received a copy of the GNU General Public License
22// along with this program; if not, write to the Free Software
23// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301, USA
24//
25
26#ifndef ED2KC2STCP_H
27#define ED2KC2STCP_H
28
29enum OP_ClientToServerTCP {
30	OP_LOGINREQUEST				= 0x01,	// <HASH 16><ID 4><PORT 2><1 Tag_set>
31	OP_REJECT					= 0x05,	// (null)
32	OP_GETSERVERLIST			= 0x14,	// (null)client->server
33	OP_OFFERFILES				= 0x15,	// <count 4>(<HASH 16><ID 4><PORT 2><1 Tag_set>)[count]
34	OP_SEARCHREQUEST			= 0x16,	// <Query_Tree>
35	OP_DISCONNECT				= 0x18,	// (not verified)
36	OP_GETSOURCES				= 0x19,	// <HASH 16>
37										// v2 <HASH 16><SIZE_4> (17.3) (mandatory on 17.8)
38										// v2large <HASH 16><FILESIZE 4(0)><FILESIZE 8> (17.9) (large files only)
39	OP_SEARCH_USER				= 0x1A,	// <Query_Tree>
40	OP_CALLBACKREQUEST			= 0x1C,	// <ID 4>
41//	OP_QUERY_CHATS				= 0x1D,	// (deprecated, not supported by server any longer)
42//	OP_CHAT_MESSAGE				= 0x1E,	// (deprecated, not supported by server any longer)
43//	OP_JOIN_ROOM				= 0x1F,	// (deprecated, not supported by server any longer)
44	OP_QUERY_MORE_RESULT		= 0x21,	// (null)
45	OP_GETSOURCES_OBFU	= 0x23,
46	OP_SERVERLIST				= 0x32,	// <count 1>(<IP 4><PORT 2>)[count] server->client
47	OP_SEARCHRESULT				= 0x33,	// <count 4>(<HASH 16><ID 4><PORT 2><1 Tag_set>)[count]
48	OP_SERVERSTATUS				= 0x34,	// <USER 4><FILES 4>
49	OP_CALLBACKREQUESTED		= 0x35,	// <IP 4><PORT 2>
50	OP_CALLBACK_FAIL			= 0x36,	// (null notverified)
51	OP_SERVERMESSAGE			= 0x38,	// <len 2><Message len>
52//	OP_CHAT_ROOM_REQUEST		= 0x39,	// (deprecated, not supported by server any longer)
53//	OP_CHAT_BROADCAST			= 0x3A,	// (deprecated, not supported by server any longer)
54//	OP_CHAT_USER_JOIN			= 0x3B,	// (deprecated, not supported by server any longer)
55//	OP_CHAT_USER_LEAVE			= 0x3C,	// (deprecated, not supported by server any longer)
56//	OP_CHAT_USER				= 0x3D,	// (deprecated, not supported by server any longer)
57	OP_IDCHANGE					= 0x40,	// <NEW_ID 4>
58	OP_SERVERIDENT				= 0x41,	// <HASH 16><IP 4><PORT 2>{1 TAG_SET}
59	OP_FOUNDSOURCES				= 0x42,	// <HASH 16><count 1>(<ID 4><PORT 2>)[count]
60	OP_USERS_LIST				= 0x43,	// <count 4>(<HASH 16><ID 4><PORT 2><1 Tag_set>)[count]
61	OP_FOUNDSOURCES_OBFU = 0x44    // <HASH 16><count 1>(<ID 4><PORT 2><obf settings 1>(UserHash16 if obf&0x08))[count]
62};
63
64// Server TCP flags
65#define SRV_TCPFLG_COMPRESSION          0x00000001
66#define SRV_TCPFLG_NEWTAGS                      0x00000008
67#define SRV_TCPFLG_UNICODE                      0x00000010
68#define SRV_TCPFLG_RELATEDSEARCH        0x00000040
69#define SRV_TCPFLG_TYPETAGINTEGER       0x00000080
70#define SRV_TCPFLG_LARGEFILES           0x00000100
71#define SRV_TCPFLG_TCPOBFUSCATION	0x00000400
72
73#endif // ED2KC2STCP_H
74