⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 protocol.h

📁 QQ2005beta2协议分析 在linux下实现 有源码
💻 H
字号:
/* * (C) 2005- * Author: Anda * missanda@hotmail.com * QQ 8907673   348498666 * **/#ifndef __QQ_PROTOCOL_H__#define __QQ_PROTOCOL_H__#define QQ_LOGIN_MODE_NORMAL  		0x0a#define QQ_LOGIN_MODE_HIDDEN        	0x28#define QQ_PROXY_NONE		0#define QQ_PROXY_SOCKET5	1// online status#define QQ_ONLINE_NORMAL	0x0a#define QQ_ONLINE_OFFLINE 	0x14#define QQ_ONLINE_AWAY 		0x1e#define QQ_ONLINE_INVISIBLE 	0x40struct qq_client{	int       server;       /*server socket handle*/	uint32_t  id;   	/*your qq id*/	char      pass[24]; 	/*password. text.*/	/*         * QQ_LOGIN_MODE_HIDDEN         * QQ_LOGIN_MODE_NORMAL         */	unsigned char login_mode; 	unsigned char online_status; 	/*online people*/	uint32_t  online_count;	/*not support proxy at present*/	int proxy_type;	unsigned char session_token[64];	unsigned char pass_encrypted[32];	unsigned char init_key[32];	uint16_t  local_port; 	/*local port default is 6666*/	char      local_ip[32];	/*local listen ip address*/	uint16_t  detected_port;  /*qq server detected my port*/	char      detected_ip[32];	uint16_t  server_port;  /* QQ default is 8000*/	char      server_ip[32];/* QQ server ip address*/	int       logined;		uint16_t  seq;		int login_retry;  //max is 10};int qq_send_message(struct qq_client*qc,const char*dest,const char*message);int qq_keep_alive(struct qq_client*qc);int qq_change_status(struct qq_client*qc);int qq_send_command(struct qq_client*qc,uint16_t cmd,unsigned char*data,int len,uint16_t seq);int qq_logout(struct qq_client *qc);int qq_request_login_token(struct qq_client *qc,unsigned char*token);int qq_login(	struct qq_client *qc,		const char*id,const char *pass,		unsigned char login_mode,		const char*local_ip,int local_port,		const char*server_ip,int server_port );struct qq_client * qq_create_client(void);void qq_release_client(struct qq_client*qc);#endif/*__QQ_PROTOCOL_H__*/

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -