#ifndef __LIBCOMMTOUCH_H
#define __LIBCOMMTOUCH_H

#define BNAME_LEN	80

typedef struct {
    char blockname[BNAME_LEN];                  /* data */
    unsigned long ipmax;
    int hits;
} recType;   

char *COMMTOUCH_SERVER = "ctwsd1.ctmail.com";
char *COMMTOUCH_SERVER_IP = "116.92.1.87";
int commtouch_socket;
int		sta = -1;

int commtouch_comid = 1;
char *commtouch_pver = "1.0";
char *commtouch_key= "0001I001Q1061K177I08";

short	psCode;

#define COMMTOUCH_GATEGORY_LIST_FILE "/etc/config/category_list"
#define URL_HASH_SIZE 1024
#define CACHE_ENTRY_LENGTH 2

typedef struct {
	char url_addr[64];
	short category;
}url_cache;
url_cache url_cache_table[URL_HASH_SIZE][CACHE_ENTRY_LENGTH];

typedef struct {
	char category[128];
	char pscode[4];
}CATEGORY;

CATEGORY category_list[256];

short cache_index[URL_HASH_SIZE];

char *BK_EXEFILE[] = {".exe", ".com", ".scr", ".pif", ".bas", ".bat", ".inf", ".reg"};	//8 items
char *BK_ZIPFILE[] = {".zip", ".rar", ".arj", ".ace", ".cab", ".sit"}; //6 items 
char *BK_MMSFILE[] = {".mov", ".mp3", ".rm", ".ra", ".au", ".wmv", ".wav", ".asf", ".mpg", ".mpeg", ".avi", ".ram"}; //12 items
char *BK_JAVA[] = {".class", ".jad", ".jar", ".jav", ".java", ".jcm", ".jsp", ".jse", ".js", ".jtk"};	//10 items
char *BK_OLE[] = {".ocx", ".cab", ".olb", ".apb", ".ole", ".tlb", ".alx", ".axs", ".viv", ".vrm"};  //10 items
	 

#endif