2018-09-29 14:57:32 +08:00
|
|
|
|
#ifndef _AV_SENDBACK_H
|
|
|
|
|
|
#define _AV_SENDBACK_H
|
|
|
|
|
|
|
|
|
|
|
|
/*ħ<><C4A7>*/
|
|
|
|
|
|
#define AV_MAGIC_VALUE 0x8739
|
|
|
|
|
|
|
|
|
|
|
|
/*<2A><>Ϣ<EFBFBD><CFA2><EFBFBD><EFBFBD>*/
|
|
|
|
|
|
#define AV_TYPE_META 0x01
|
|
|
|
|
|
#define AV_TYPE_DATA 0x02
|
|
|
|
|
|
#define AV_TYPE_RESULT 0x11
|
|
|
|
|
|
|
|
|
|
|
|
/*Э<><D0AD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
|
|
|
|
|
|
#define AV_PROTOCOL_HTTP 0x01
|
|
|
|
|
|
#define AV_PROTOCOL_SMTP 0x02
|
|
|
|
|
|
#define AV_PROTOCOL_POP3 0x03
|
|
|
|
|
|
#define AV_PROTOCOL_FTP 0x04
|
|
|
|
|
|
#define AV_PROTOCOL_IMAP 0x05
|
|
|
|
|
|
#define AV_PROTOCOL_HTTP_STREAM 0x81
|
|
|
|
|
|
#define AV_PROTOCOL_RTSP_RDT 0x82
|
|
|
|
|
|
#define AV_PROTOCOL_RTSP_RTP 0x83
|
|
|
|
|
|
#define AV_PROTOCOL_ED2K 0x85
|
|
|
|
|
|
#define AV_PROTOCOL_MMS 0x84
|
|
|
|
|
|
#define AV_PROTOCOL_RTMP 0x86
|
|
|
|
|
|
#define AV_PROTOCOL_SIP 0x91
|
|
|
|
|
|
#define AV_PROTOCOL_BT 0x08
|
|
|
|
|
|
|
|
|
|
|
|
/*ý<><C3BD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
|
|
|
|
|
|
#define FILE_UNKNOWN 0x00
|
|
|
|
|
|
#define FILE_VIDEO 0x60
|
|
|
|
|
|
#define FILE_WMV 0x61
|
|
|
|
|
|
#define FILE_MPG 0x62
|
|
|
|
|
|
#define FILE_FLV 0x63
|
|
|
|
|
|
#define FILE_RMFF 0x65
|
|
|
|
|
|
#define FILE_AVI 0x66
|
|
|
|
|
|
#define FILE_SWF 0x67
|
|
|
|
|
|
#define FILE_MPG4 0x68
|
|
|
|
|
|
#define FILE_AIFF 0x69
|
|
|
|
|
|
#define FILE_OGG 0x6A
|
|
|
|
|
|
#define FILE_DRC 0x6B
|
|
|
|
|
|
#define FILE_DIRECTSHOW 0x6C
|
|
|
|
|
|
#define FILE_FLIC 0x6D
|
|
|
|
|
|
#define FILE_INDEO 0x6E
|
|
|
|
|
|
#define FILE_MKV 0x6F
|
|
|
|
|
|
|
|
|
|
|
|
#define FILE_AUDIO 0x70
|
|
|
|
|
|
#define FILE_MP3 0x71
|
|
|
|
|
|
|
|
|
|
|
|
#define FILE_OSMF 0xA1
|
|
|
|
|
|
#define FILE_HLS 0xA2
|
|
|
|
|
|
#define FILE_IOS 0xA3
|
|
|
|
|
|
#define FILE_ANDRIOD 0xA4
|
|
|
|
|
|
#define FILE_APP 0xA5
|
|
|
|
|
|
|
|
|
|
|
|
#define AUDIO_UNKNOWN 0xB0
|
|
|
|
|
|
#define AUDIO_G711_ULAW 0xB1
|
|
|
|
|
|
#define AUDIO_G711_ALAW 0xB2
|
|
|
|
|
|
#define AUDIO_G722 0xB3
|
|
|
|
|
|
#define AUDIO_G723 0xB4
|
|
|
|
|
|
#define AUDIO_G726_40 0xB5
|
|
|
|
|
|
#define AUDIO_G726_32 0xB6
|
|
|
|
|
|
#define AUDIO_G726_24 0xB7
|
|
|
|
|
|
#define AUDIO_G726_16 0xB8
|
|
|
|
|
|
#define AUDIO_AAL2_G726_40 0xB9
|
|
|
|
|
|
#define AUDIO_AAL2_G726_32 0xBA
|
|
|
|
|
|
#define AUDIO_AAL2_G726_24 0xBB
|
|
|
|
|
|
#define AUDIO_AAL2_G726_16 0xBC
|
|
|
|
|
|
#define AUDIO_G728 0xBD
|
|
|
|
|
|
#define AUDIO_G729D 0xBE
|
|
|
|
|
|
#define AUDIO_G729E 0xBF
|
|
|
|
|
|
#define AUDIO_GSM 0xC0
|
|
|
|
|
|
#define AUDIO_GSM_EFR 0xC1
|
|
|
|
|
|
#define AUDIO_ILBC 0xC2
|
|
|
|
|
|
#define AUDIO_AMR 0xC3
|
|
|
|
|
|
#define AUDIO_AMR_WB 0xC4
|
|
|
|
|
|
#define AUDIO_SILK 0xC5
|
|
|
|
|
|
#define AUDIO_LPC 0xC6
|
|
|
|
|
|
#define AUDIO_LPC1016 0xC7
|
|
|
|
|
|
#define AUDIO_LPC1015 0xC8
|
|
|
|
|
|
#define AUDIO_L16 0xC9
|
|
|
|
|
|
#define AUDIO_SPEEX 0xCA
|
|
|
|
|
|
#define AUDIO_L8 0xCB
|
|
|
|
|
|
#define AUDIO_MPA 0xCC
|
|
|
|
|
|
#define AUDIO_DVI4 0xCD
|
|
|
|
|
|
#define AUDIO_VDVI 0xCE
|
|
|
|
|
|
#define AUDIO_CN 0xCF
|
|
|
|
|
|
#define AUDIO_RED 0xD0
|
|
|
|
|
|
#define AUDIO_QCELP 0xD1
|
|
|
|
|
|
#define AUDIO_EVRC0 0xD2
|
|
|
|
|
|
#define AUDIO_EVRCB0 0xD3
|
|
|
|
|
|
#define AUDIO_G729 0xD4
|
|
|
|
|
|
#define AUDIO_VIVOX 0xD5
|
|
|
|
|
|
#define BE_FRAG_TYPE(t) ((t>=FILE_OSMF) && (t<=0xA2))
|
|
|
|
|
|
#define BE_APP_TYPE(t) ((t>=FILE_IOS) && (t<=0xA5))
|
|
|
|
|
|
#define BE_IMAGE_TYPE(t) ((t>=FILE_IMAGE) && (t<0x90))
|
|
|
|
|
|
#define BE_VIDEO_TYPE(t) ((t>=FILE_VIDEO) && (t<0x70))
|
|
|
|
|
|
#define BE_AUDIO_TYPE(t) ((t>=FILE_AUDIO) && (t<0x80))
|
|
|
|
|
|
#define BE_VOIP_TYPE(t) ((t>=AUDIO_UNKNOWN) && (t<=AUDIO_VIVOX))
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#define FILE_IMAGE 0x80
|
|
|
|
|
|
|
|
|
|
|
|
#define FILE_JPG 0x84
|
|
|
|
|
|
#define FILE_BMP 0x85
|
|
|
|
|
|
#define FILE_GIF 0x86
|
|
|
|
|
|
|
|
|
|
|
|
#define MMS_TYPE 0x90
|
|
|
|
|
|
#define HTTP_STREAM_TYPE 0x90
|
|
|
|
|
|
#define RTSP_RDT_TYPE 0x92
|
|
|
|
|
|
#define RTSP_RTP_TYPE 0x91
|
|
|
|
|
|
|
|
|
|
|
|
/*ҵ<><D2B5><EFBFBD><EFBFBD><EFBFBD><EFBFBD>*/
|
|
|
|
|
|
#define SERVICE_FLAG_FD 0 // FenDu Flag
|
|
|
|
|
|
#define SERVICE_FLAG_JC 1 // JianCe Flag
|
|
|
|
|
|
// Defination of service type ;
|
2018-11-28 21:15:34 +08:00
|
|
|
|
#define SERVICE_IPPORT_WHITE 0x01 //IP+PORT whitelist
|
|
|
|
|
|
#define SERVICE_IPPORT_BLACK 0x02 //IP+PORT blacklist
|
|
|
|
|
|
#define SERVICE_URL_WHITE 0x03 //<2F><>Ŀ<EFBFBD><C4BF>ַblacklist
|
|
|
|
|
|
#define SERVICE_URL_BLACK 0x04 //<2F><>Ŀ<EFBFBD><C4BF>ַblacklist
|
|
|
|
|
|
#define SERVICE_HOST_WHITE 0x05 //<2F><>Ŀ<EFBFBD><C4BF>ַblacklist
|
|
|
|
|
|
#define SERVICE_HOST_BLACK 0x06 //<2F><>Ŀ<EFBFBD><C4BF>ַblacklist
|
2018-09-29 14:57:32 +08:00
|
|
|
|
//add by lqy 20120427
|
|
|
|
|
|
#define SERVICE_FAKE_SERVERIP 0x07 //<2F><><EFBFBD>ٷ<EFBFBD><D9B7><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ڵ<EFBFBD>
|
|
|
|
|
|
|
|
|
|
|
|
// added by cxj 20100811
|
|
|
|
|
|
#define SERVICE_P2P_STATIC_WHITEIP 0x15
|
|
|
|
|
|
#define SERVICE_P2P_BI_WHITEIP 0x16
|
|
|
|
|
|
#define SERVICE_P2P_MI_WHITEIP 0x17
|
|
|
|
|
|
|
|
|
|
|
|
#define SERVICE_AUDIO_SAMPLE_FD 0x11
|
|
|
|
|
|
#define SERVICE_VIDEO_LABEL_FD 0x21
|
|
|
|
|
|
#define SERVICE_SPEEKER_FD 0x22
|
|
|
|
|
|
#define SERVICE_VIDEO_SAMPLE_FD 0x23
|
|
|
|
|
|
#define SERVICE_VIDEO_FACE_FD 0x24
|
|
|
|
|
|
#define SERVICE_AUDIO_SEX_FD 0x25
|
|
|
|
|
|
|
|
|
|
|
|
#define SERVICE_IMAGE_SAMPLE_FD 0x31
|
|
|
|
|
|
#define SERVICE_DYN_SUBSTR_FD 0x32
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#define SERVICE_P2P_EMULE_SERVER 0x51 //
|
|
|
|
|
|
#define SERVICE_P2P_EMULE_KEY 0x52 //
|
|
|
|
|
|
#define SERVICE_P2P_EMULE_FILEID 0x53 //
|
|
|
|
|
|
#define SERVICE_P2P_EMULE_NODE 0x54 //
|
|
|
|
|
|
|
|
|
|
|
|
#define SERVICE_P2P_BT_INFOHASH 0x41 // BT Infohash Black List
|
|
|
|
|
|
#define SERVICE_P2P_BT_NODE 0x44 // BT Bone Node
|
|
|
|
|
|
#define SERVICE_P2P_BT_SERVICE 0x61 // BT DHT Index Server List
|
|
|
|
|
|
|
|
|
|
|
|
#define SERVICE_P2P_BT_ECLIPSE_IPLIST 0x45
|
|
|
|
|
|
#define SERVICE_P2P_BT_POLLUTION_IPLIST 0x46
|
|
|
|
|
|
#define SERVICE_P2P_EMULE_POLLUTION_IPLIST 0x55
|
|
|
|
|
|
|
|
|
|
|
|
#define SERVICE_P2P_BT_TRACKEIP 0x43 // BT tracke ip
|
|
|
|
|
|
#define SERVICE_P2P_BT_PEERIP 0x47 // BT peer ip
|
|
|
|
|
|
#define SERVICE_P2P_EMULE_PEERIP 0x56 // emule peer ip
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//
|
2018-11-28 21:15:34 +08:00
|
|
|
|
#define SERVICE_EMULE_SERVER 0x71 //<2F><>ĿΨһID whitelist
|
|
|
|
|
|
#define SERVICE_EMULE_KEYS 0x72 //<2F><>ĿΨһID blacklist
|
|
|
|
|
|
#define SERVICE_EMULE_FHID 0x73 //emule<6C><65>hashkey blacklist
|
|
|
|
|
|
#define SERVICE_EMULE_FNAME 0x74 //emule<6C><65>hashkey blacklist
|
|
|
|
|
|
#define SERVICE_EMULE_NODE 0x75 //emule<6C><65>hashkey blacklist
|
|
|
|
|
|
|
|
|
|
|
|
#define SERVICE_IPPORT_WHITE_JC 0x81 //IP+PORT whitelist
|
|
|
|
|
|
#define SERVICE_IPPORT_BLACK_JC 0x82 //IP+PORT blacklist
|
|
|
|
|
|
#define SERVICE_URL_WHITE_JC 0x83 //IP+PORT whitelist
|
|
|
|
|
|
#define SERVICE_URL_BLACK_JC 0x84 //IP+PORT blacklist
|
|
|
|
|
|
#define SERVICE_HOST_WHITE_JC 0x85 //IP+PORT blacklist
|
|
|
|
|
|
#define SERVICE_HOST_BLACK_JC 0x86 //IP+PORT blacklist
|
2018-09-29 14:57:32 +08:00
|
|
|
|
#define SERVICE_LOAD_ACTION_JC 0x87 /* liuxueli */
|
|
|
|
|
|
#define SERVICE_USER_REGION_JC 0x88 /* liuxueli */
|
|
|
|
|
|
|
|
|
|
|
|
#define SERVICE_AUDIO_SAMPLE_JC 0x91
|
|
|
|
|
|
#define SERVICE_SPEEKER_JC 0x92
|
|
|
|
|
|
#define SERVICE_AUDIO_CONT_JC 0x93
|
|
|
|
|
|
#define SERVICE_AUDIO_SECEN_JC 0x94
|
|
|
|
|
|
#define SERVICE_AUDIO_LANG_JC 0x97
|
|
|
|
|
|
#define SERVICE_AUDIO_LANG_FULL_JC 0x98
|
|
|
|
|
|
|
|
|
|
|
|
#define SERVICE_VIDEO_LOGO_JC 0xA1
|
|
|
|
|
|
#define SERVICE_VIDEO_SRT_JC 0xA2
|
|
|
|
|
|
#define SERVICE_VIDEO_SAMPLE_JC 0xA3
|
|
|
|
|
|
#define SERVICE_VIDEO_FACE_JC 0xA4
|
|
|
|
|
|
#define SERVICE_VIDEO_SEC_JC 0xA5
|
|
|
|
|
|
|
|
|
|
|
|
#define SERVICE_IMAGE_SAMPLE_JC 0xB1
|
|
|
|
|
|
#define SERVICE_IMAGE_KEYWORD_JC 0xB2
|
|
|
|
|
|
#define SERVICE_IMG_FEEDBACK_IP 0xB3
|
|
|
|
|
|
#define SERVICE_IMG_FEEDBACK_SIZE 0xB4
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/*==================================<3D><>Ϣͷ<CFA2><CDB7>==============================================*/
|
|
|
|
|
|
typedef struct msg_header_s
|
|
|
|
|
|
{
|
|
|
|
|
|
uint16_t magic;
|
|
|
|
|
|
uint16_t m_type;
|
|
|
|
|
|
uint32_t c_len;
|
|
|
|
|
|
}msg_header_t;
|
|
|
|
|
|
|
|
|
|
|
|
/*==================================ָ<><D6B8><EFBFBD><EFBFBD>Ϣ==============================================*/
|
|
|
|
|
|
typedef struct metainfo_s
|
|
|
|
|
|
{
|
|
|
|
|
|
char pid[8]; //ID<49><44><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ݻ<EFBFBD>ȡ<EFBFBD>ڵ<EFBFBD><DAB5><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
|
uint64_t proglen; //<2F><><EFBFBD>ļ<EFBFBD><C4BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ֽڳ<D6BD><DAB3>ȣ<EFBFBD>Ϊ0<CEAA><30>ʾ<EFBFBD><CABE><EFBFBD><EFBFBD>δ֪
|
|
|
|
|
|
uint32_t capip; // <20><>ȡ<EFBFBD>ڵ<EFBFBD><DAB5><EFBFBD>IP
|
|
|
|
|
|
uint8_t protocol; // <20><><EFBFBD><EFBFBD>Э<EFBFBD><D0AD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
|
uint8_t mediatype; // <20><><EFBFBD>ܵ<EFBFBD>ý<EFBFBD><C3BD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
|
uint16_t pad2; // <20>̶<EFBFBD><CCB6><EFBFBD>0
|
|
|
|
|
|
}metainfo_t;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/*==================================<3D><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϣ==============================================*/
|
|
|
|
|
|
typedef struct av_data_s
|
|
|
|
|
|
{
|
|
|
|
|
|
char pid[8]; // <20><><EFBFBD>ļ<EFBFBD><C4BC><EFBFBD>ID<49><44><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ݻ<EFBFBD>ȡ<EFBFBD>ڵ<EFBFBD><DAB5><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
|
uint16_t frag_seq; // Ƭ<><C6AC><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
|
int64_t offset:48; // <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ļ<EFBFBD><C4BC>е<EFBFBD>ƫ<EFBFBD><C6AB>λ<EFBFBD><CEBB>
|
|
|
|
|
|
char* avs; // <20><><EFBFBD><EFBFBD>Ƶ<EFBFBD><C6B5><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
|
}av_data_t;
|
|
|
|
|
|
|
|
|
|
|
|
/*==================================<3D><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϣ==================================================*/
|
|
|
|
|
|
typedef struct msg_result_s
|
|
|
|
|
|
{
|
|
|
|
|
|
char pid[8]; // <20><><EFBFBD><EFBFBD><EFBFBD>ļ<EFBFBD><C4BC><EFBFBD>ID<49><44><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ݻ<EFBFBD>ȡ<EFBFBD>ڵ<EFBFBD><DAB5><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
|
uint8_t servicetype; // ҵ<><D2B5><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
|
int8_t level; // <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ŷȣ<C5B6> [0, 100]
|
|
|
|
|
|
uint16_t pad; // Ԥ<><D4A4><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>0ֵ
|
|
|
|
|
|
uint32_t cfgid; // <20><><EFBFBD>е<EFBFBD><D0B5><EFBFBD><EFBFBD><EFBFBD>ID<49><44>ֵΪ0<CEAA><30>ʾ<EFBFBD><CABE><EFBFBD><EFBFBD>δ֪<CEB4><D6AA><EFBFBD><EFBFBD>
|
|
|
|
|
|
char* logindex; //<2F><><EFBFBD><EFBFBD><EFBFBD>ֳ<EFBFBD><D6B3><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ļ<EFBFBD><C4BC>Ĵ洢·<E6B4A2><C2B7>URL<52><4C><EFBFBD><EFBFBD>"/0"<22><><EFBFBD><EFBFBD>
|
|
|
|
|
|
}msg_result_t;
|
|
|
|
|
|
|
|
|
|
|
|
#endif
|