git-svn: trunk@3172
Török Edvin authored on 2007/08/15 06:21:49... | ... |
@@ -1,3 +1,8 @@ |
1 |
+Tue Aug 14 23:23:00 EEST 2007 (edwin) |
|
2 |
+---------------------------------- |
|
3 |
+ * libclamav/phishcheck.c, regex_list.c, phish_whitelist.c: make debug output |
|
4 |
+ look better (patch from Sven) |
|
5 |
+ |
|
1 | 6 |
Tue Aug 14 23:11:00 EEST 2007 (edwin) |
2 | 7 |
---------------------------------- |
3 | 8 |
* libclamav/phishcheck.c: Don't report phishing on broken urls containing > |
... | ... |
@@ -47,7 +47,7 @@ |
47 | 47 |
int whitelist_match(const struct cl_engine* engine,const char* real_url,const char* display_url,int hostOnly) |
48 | 48 |
{ |
49 | 49 |
const char* info;/*unused*/ |
50 |
- cli_dbgmsg("Phishing: looking up in whitelist:%s:%s; host-only:%d\n",real_url,display_url,hostOnly); |
|
50 |
+ cli_dbgmsg("Phishing: looking up in whitelist: %s:%s; host-only:%d\n",real_url,display_url,hostOnly); |
|
51 | 51 |
return engine->whitelist_matcher ? regex_list_match(engine->whitelist_matcher,real_url,display_url,hostOnly,&info,1) : 0; |
52 | 52 |
} |
53 | 53 |
|
... | ... |
@@ -352,7 +352,7 @@ static void free_if_needed(struct url_check* url) |
352 | 352 |
static int build_regex(regex_t* preg,const char* regex,int nosub) |
353 | 353 |
{ |
354 | 354 |
int rc; |
355 |
- cli_dbgmsg("Phishcheck: Compiling regex:%s\n",regex); |
|
355 |
+ cli_dbgmsg("Phishcheck: Compiling regex: %s\n",regex); |
|
356 | 356 |
rc = regcomp(preg,regex,REG_EXTENDED|REG_ICASE|(nosub ? REG_NOSUB :0)); |
357 | 357 |
if(rc) { |
358 | 358 |
|
... | ... |
@@ -401,7 +401,7 @@ static int get_host(const struct phishcheck* s,struct string* dest,const char* U |
401 | 401 |
else { |
402 | 402 |
start=URL;/*URL without protocol*/ |
403 | 403 |
if(isReal) |
404 |
- cli_dbgmsg("Phishcheck: Real URL without protocol:%s\n",URL); |
|
404 |
+ cli_dbgmsg("Phishcheck: Real URL without protocol: %s\n",URL); |
|
405 | 405 |
else ismailto=2;/*no-protocol, might be mailto, @ is no problem*/ |
406 | 406 |
} |
407 | 407 |
} |
... | ... |
@@ -805,7 +805,7 @@ int phishingScan(message* m,const char* dir,cli_ctx* ctx,tag_arguments_t* hrefs) |
805 | 805 |
if(pchk->is_disabled) |
806 | 806 |
return CL_CLEAN; |
807 | 807 |
free_if_needed(&urls); |
808 |
- cli_dbgmsg("Phishcheck: Phishing scan result:%s\n",phishing_ret_toString(rc)); |
|
808 |
+ cli_dbgmsg("Phishcheck: Phishing scan result: %s\n",phishing_ret_toString(rc)); |
|
809 | 809 |
switch(rc)/*TODO: support flags from ctx->options,*/ |
810 | 810 |
{ |
811 | 811 |
case CL_PHISH_CLEAN: |
... | ... |
@@ -284,10 +284,10 @@ int regex_list_match(struct regex_matcher* matcher,const char* real_url,const ch |
284 | 284 |
buffer[buffer_len-match_len-1]=='.') |
285 | 285 |
/* subdomain matched*/) { |
286 | 286 |
|
287 |
- cli_dbgmsg("Got a match:%s with %s\n",buffer,*info); |
|
287 |
+ cli_dbgmsg("Got a match: %s with %s\n",buffer,*info); |
|
288 | 288 |
break; |
289 | 289 |
} |
290 |
- cli_dbgmsg("Ignoring false match:%s with %s\n",buffer,*info); |
|
290 |
+ cli_dbgmsg("Ignoring false match: %s with %s\n",buffer,*info); |
|
291 | 291 |
rc=0; |
292 | 292 |
} |
293 | 293 |
} |