Re: RE: [Clamav-devel] why don't write portable code

2006-04-01 Thread BSCH
Brian A. Reiter
  If you could compile clamav at Win32, it maybe have little fix to src. So 
now, it has a module Clamav-win32. My mean, it has not must. You could 
maintenance ONE src. Not to have the module of Clamav-win32. If want to use in 
Win32. Only compile it. Now we have use in win32, we must patch the src, and 
compile. Though, we could compile it in Cygwin, but the execustive must have 
DLL with Cygwin.



=== 2006-04-01 08:07:53 您在来信中写道:===

X-Gmail-Received: 7fb57286f11b0f23703c9d0c4a2d27a4c38d3b00
Delivered-To: [EMAIL PROTECTED]
Received: by 10.36.39.5 with SMTP id m5cs36786nzm;
Fri, 31 Mar 2006 16:07:53 -0800 (PST)
Received: by 10.54.93.12 with SMTP id q12mr640685wrb;
Fri, 31 Mar 2006 16:07:53 -0800 (PST)
Return-Path: [EMAIL PROTECTED]
Received: from aj.catt.com (aj.catt.com [64.18.103.6])
by mx.gmail.com with ESMTP id 29si482937wrl.2006.03.31.16.07.49;
Fri, 31 Mar 2006 16:07:53 -0800 (PST)
Received-SPF: pass (gmail.com: domain of [EMAIL PROTECTED] designates 
64.18.103.6 as permitted sender)
Received: from aj.catt.com (localhost [127.0.0.1])
   by aj.catt.com (Postfix) with ESMTP id 4B82E156002;
   Fri, 31 Mar 2006 19:07:47 -0500 (EST)
Received: from rs19.luxsci.com (rs19.luxsci.com [65.61.136.23])
   by aj.catt.com (Postfix) with ESMTP id 90D6F10DA44
   for clamav-devel@lists.clamav.net;
   Fri, 31 Mar 2006 19:07:44 -0500 (EST)
Received: from prometheus (pool-72-75-60-71.washdc.east.verizon.net
   [72.75.60.71]) (authenticated bits=0)
   by rs19.luxsci.com (8.13.6/8.13.6) with ESMTP id k3107eZi018708
   (version=TLSv1/SSLv3 cipher=RC4-MD5 bits=128 verify=NOT)
   for clamav-devel@lists.clamav.net; Fri, 31 Mar 2006 18:07:41 -0600
From: Brian A. Reiter [EMAIL PROTECTED]
To: 'ClamAV Development' clamav-devel@lists.clamav.net
Subject: RE: [Clamav-devel] why don't write portable code
Date: Fri, 31 Mar 2006 19:07:32 -0500
Message-ID: [EMAIL PROTECTED]
MIME-Version: 1.0
X-Mailer: Microsoft Office Outlook 11
Thread-Index: AcZVFl8cPxgzSxkuRISADJDEue5QoQACR8zQ
In-Reply-To: [EMAIL PROTECTED]
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.1830
X-Content-Filtered-By: Mailman/MimeDel 2.1.5
X-BeenThere: clamav-devel@lists.clamav.net
X-Mailman-Version: 2.1.5
Precedence: list
Reply-To: ClamAV Development clamav-devel@lists.clamav.net
List-Id: ClamAV Development clamav-devel.lists.clamav.net
List-Unsubscribe: 
http://lists.clamav.net/cgi-bin/mailman/listinfo/clamav-devel,
   mailto:[EMAIL PROTECTED]
List-Post: mailto:clamav-devel@lists.clamav.net
List-Help: mailto:[EMAIL PROTECTED]
List-Subscribe: 
http://lists.clamav.net/cgi-bin/mailman/listinfo/clamav-devel,
   mailto:[EMAIL PROTECTED]
Content-Type: multipart/mixed; boundary2051393441==
Mime-version: 1.0
Sender: [EMAIL PROTECTED]
Errors-To: [EMAIL PROTECTED]

This is a multi-part message in MIME format.

--===2051393441==
Content-Type: multipart/signed; protocol=application/x-pkcs7-signature;
   micalg=SHA1; boundary==_NextPart_000_00C0_01C654F6.5CD55290

This is a multi-part message in MIME format.

--=_NextPart_000_00C0_01C654F6.5CD55290
Content-Type: text/plain;
   charset=us-ascii
Content-Transfer-Encoding: 7bit


  i know it maybe use some time to write it, but i think it 
 valuealbe. 
  ONE ENGINE IS A CORE OF SOFTWARE. and why don't you design 
 it indepent 
  platform? if possible, the directory maybe plot clearly, the same
 
 The engine is POSIX compliant.

And, in fact, Microsoft has made a POSIX-compliant executive sub-system
derived from OpenBSD and System V available for Windows NT 5+. It is called
Interix aka Services for UNIX and Subsystem for UNIX-based Applications
(SUA). Clamd and clamscan run fine under Interix.

Download SFU 3.5 here:
http://www.microsoft.com/technet/interopmigration/unix/sfu/default.mspx

Subsystem for Unix-based Applications (SUA/Interix 5.2):
http://www.microsoft.com/windowsserver2003/r2/unixinterop/default.mspx

POSIX should be portable enough.

--=_NextPart_000_00C0_01C654F6.5CD55290--


--===2051393441==
Content-Type: text/plain; charset=us-ascii
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

___
http://lurker.clamav.net/list/clamav-devel.html

--===2051393441==--


= = = = = = = = = = = = = = = = = = = =


致
礼!
 
 
BSCH
[EMAIL PROTECTED]
  2006-04-01

___
http://lurker.clamav.net/list/clamav-devel.html


Re: RE: [Clamav-devel] why don't write portable code

2006-04-01 Thread BSCH
Brian A. Reiter!

  if engine design pure. the others could use the clamav engine to write 
anti-virus software. the software not to write by us. ALL could use the engine 
convenience.



=== 2006-04-01 08:07:53 您在来信中写道:===

X-Gmail-Received: 7fb57286f11b0f23703c9d0c4a2d27a4c38d3b00
Delivered-To: [EMAIL PROTECTED]
Received: by 10.36.39.5 with SMTP id m5cs36786nzm;
Fri, 31 Mar 2006 16:07:53 -0800 (PST)
Received: by 10.54.93.12 with SMTP id q12mr640685wrb;
Fri, 31 Mar 2006 16:07:53 -0800 (PST)
Return-Path: [EMAIL PROTECTED]
Received: from aj.catt.com (aj.catt.com [64.18.103.6])
by mx.gmail.com with ESMTP id 29si482937wrl.2006.03.31.16.07.49;
Fri, 31 Mar 2006 16:07:53 -0800 (PST)
Received-SPF: pass (gmail.com: domain of [EMAIL PROTECTED] designates 
64.18.103.6 as permitted sender)
Received: from aj.catt.com (localhost [127.0.0.1])
   by aj.catt.com (Postfix) with ESMTP id 4B82E156002;
   Fri, 31 Mar 2006 19:07:47 -0500 (EST)
Received: from rs19.luxsci.com (rs19.luxsci.com [65.61.136.23])
   by aj.catt.com (Postfix) with ESMTP id 90D6F10DA44
   for clamav-devel@lists.clamav.net;
   Fri, 31 Mar 2006 19:07:44 -0500 (EST)
Received: from prometheus (pool-72-75-60-71.washdc.east.verizon.net
   [72.75.60.71]) (authenticated bits=0)
   by rs19.luxsci.com (8.13.6/8.13.6) with ESMTP id k3107eZi018708
   (version=TLSv1/SSLv3 cipher=RC4-MD5 bits=128 verify=NOT)
   for clamav-devel@lists.clamav.net; Fri, 31 Mar 2006 18:07:41 -0600
From: Brian A. Reiter [EMAIL PROTECTED]
To: 'ClamAV Development' clamav-devel@lists.clamav.net
Subject: RE: [Clamav-devel] why don't write portable code
Date: Fri, 31 Mar 2006 19:07:32 -0500
Message-ID: [EMAIL PROTECTED]
MIME-Version: 1.0
X-Mailer: Microsoft Office Outlook 11
Thread-Index: AcZVFl8cPxgzSxkuRISADJDEue5QoQACR8zQ
In-Reply-To: [EMAIL PROTECTED]
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.1830
X-Content-Filtered-By: Mailman/MimeDel 2.1.5
X-BeenThere: clamav-devel@lists.clamav.net
X-Mailman-Version: 2.1.5
Precedence: list
Reply-To: ClamAV Development clamav-devel@lists.clamav.net
List-Id: ClamAV Development clamav-devel.lists.clamav.net
List-Unsubscribe: 
http://lists.clamav.net/cgi-bin/mailman/listinfo/clamav-devel,
   mailto:[EMAIL PROTECTED]
List-Post: mailto:clamav-devel@lists.clamav.net
List-Help: mailto:[EMAIL PROTECTED]
List-Subscribe: 
http://lists.clamav.net/cgi-bin/mailman/listinfo/clamav-devel,
   mailto:[EMAIL PROTECTED]
Content-Type: multipart/mixed; boundary2051393441==
Mime-version: 1.0
Sender: [EMAIL PROTECTED]
Errors-To: [EMAIL PROTECTED]

This is a multi-part message in MIME format.

--===2051393441==
Content-Type: multipart/signed; protocol=application/x-pkcs7-signature;
   micalg=SHA1; boundary==_NextPart_000_00C0_01C654F6.5CD55290

This is a multi-part message in MIME format.

--=_NextPart_000_00C0_01C654F6.5CD55290
Content-Type: text/plain;
   charset=us-ascii
Content-Transfer-Encoding: 7bit


  i know it maybe use some time to write it, but i think it 
 valuealbe. 
  ONE ENGINE IS A CORE OF SOFTWARE. and why don't you design 
 it indepent 
  platform? if possible, the directory maybe plot clearly, the same
 
 The engine is POSIX compliant.

And, in fact, Microsoft has made a POSIX-compliant executive sub-system
derived from OpenBSD and System V available for Windows NT 5+. It is called
Interix aka Services for UNIX and Subsystem for UNIX-based Applications
(SUA). Clamd and clamscan run fine under Interix.

Download SFU 3.5 here:
http://www.microsoft.com/technet/interopmigration/unix/sfu/default.mspx

Subsystem for Unix-based Applications (SUA/Interix 5.2):
http://www.microsoft.com/windowsserver2003/r2/unixinterop/default.mspx

POSIX should be portable enough.

--=_NextPart_000_00C0_01C654F6.5CD55290--


--===2051393441==
Content-Type: text/plain; charset=us-ascii
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

___
http://lurker.clamav.net/list/clamav-devel.html

--===2051393441==--


= = = = = = = = = = = = = = = = = = = =


致
礼!
 
 
BSCH
[EMAIL PROTECTED]
  2006-04-01

___
http://lurker.clamav.net/list/clamav-devel.html


Re: RE: [Clamav-devel] why don't write portable code

2006-04-01 Thread GiM
BSCH in message 'Re: [Clamav-devel] why don't write portable code' wrote:
 Brian A. Reiter!
 
   if engine design pure. the others could use the clamav engine to write
 anti-virus software. the software not to write by us. ALL could use the
 engine convenience.
 
   

I don't think you understand the differences between UNIX and Windows
platforms. Programming in these environments is totaly different, and
creating one universal engine wouldn't be reasonable.

And what problems do you see for others writing anti-virus software
on ClamAV basis?

btw: 1) I'm not a native english speaker, but it's quite hard o understand
 what you're trying to say (this and previous posts)
 2) stop top-posting, this is really annoying.

 main(int a[puts(Michał 'GiM' Spadliński)]){}
-- 
144722 lcamtuf I've found bug in sendmail
144724 lcamtuf what a suprise

___
http://lurker.clamav.net/list/clamav-devel.html


Re: Re: RE: [Clamav-devel] why don't write portable code

2006-04-01 Thread BSCH
GiM,您好!

I think you not to understand my mean.
your said Programming in these environments is totaly different, and
creating one universal engine wouldn't be reasonable. YOU COULD NOT PROOF 
IT.
The engine is pure! It only match signature one a file! match signature could 
use standar c or c++.

=== 2006-04-01 23:10:09 您在来信中写道:===

BSCH in message 'Re: [Clamav-devel] why don't write portable code' wrote:
 Brian A. Reiter!
 
   if engine design pure. the others could use the clamav engine to write
 anti-virus software. the software not to write by us. ALL could use the
 engine convenience.
 
  

I don't think you understand the differences between UNIX and Windows
platforms. Programming in these environments is totaly different, and
creating one universal engine wouldn't be reasonable.

And what problems do you see for others writing anti-virus software
on ClamAV basis?

btw: 1) I'm not a native english speaker, but it's quite hard o understand
 what you're trying to say (this and previous posts)
 2) stop top-posting, this is really annoying.

 main(int a[puts(Michał 'GiM' Spadliński)]){}
-- 
144722 lcamtuf I've found bug in sendmail
144724 lcamtuf what a suprise

___
http://lurker.clamav.net/list/clamav-devel.html

= = = = = = = = = = = = = = = = = = = =


致
礼!
 
 
BSCH
[EMAIL PROTECTED]
  2006-04-02

___
http://lurker.clamav.net/list/clamav-devel.html


RE: Re: RE: [Clamav-devel] why don't write portable code

2006-04-01 Thread Nigel Horne
 GiM,您好!
 
 your said Programming in these environments is totaly different, and
 creating one universal engine wouldn't be reasonable. YOU COULD 
 NOT PROOF IT.
 The engine is pure! It only match signature one a file! match 
 signature could use standar c or c++.

I strongly suggest that we all stop feeding the troll.
 
 BSCH
 [EMAIL PROTECTED]
   2006-04-02

-Nigel

___
http://lurker.clamav.net/list/clamav-devel.html


[Clamav-devel] more scanners.c issues (html and one typo)

2006-04-01 Thread Alch

Hi,

The latest scanners.c, rev1.175 in anonymous CVS includes a patch for 
if() parentheses  for RAR-SFX and ZIP-SFX however 2 other entries in 
cli_magic_scandesc() were omitted. I noticed sf.net CVS has been down 
lately so it may be attributed to that.


However after applying the full if((ret = cli_scandesc(desc, ctx, 0, 0, 
NULL)) == CL_VIRUS)  patch I started noticing a lot of Unknown Error 
entires in the logs which I think are caused by this code omitting ret 
assignement in cli_scanraw():

   case CL_TYPE_HTML:
   if(SCAN_HTML  type == CL_TYPE_UNKNOWN_TEXT)
   if(cli_scanhtml(desc, ctx) == CL_VIRUS)
   return CL_VIRUS;

ret is a filetype before a call to cli_scanhtml and type is returned 
instead of the cli_scanhtml code if there is no virus.


Patch with incorrect  if() parentheses fix in cli_magic_scandesc() and 
ret assignment in cli_scanraw() attached.


Regards,
Alch



--- scanners.c  2006-04-02 10:51:12.567512000 +1000
+++ scanners.new2006-04-02 11:06:04.059414400 +1000
@@ -1538,15 +1538,15 @@ static int cli_scanraw(int desc, cli_ctx
ret == CL_TYPE_MAIL ? ctx-mrec++ : ctx-arec++;
switch(ret) {
case CL_TYPE_HTML:
-   if(SCAN_HTML  type == CL_TYPE_UNKNOWN_TEXT)
-   if(cli_scanhtml(desc, ctx) == CL_VIRUS)
-   return CL_VIRUS;
-   break;
-
-   case CL_TYPE_MAIL:
-   if(SCAN_MAIL  type == CL_TYPE_UNKNOWN_TEXT)
-   if(cli_scanmail(desc, ctx) == CL_VIRUS)
-   return CL_VIRUS;
+   if(SCAN_HTML  type == CL_TYPE_UNKNOWN_TEXT)
+   if((ret = cli_scanhtml(desc, ctx)) == CL_VIRUS)
+   return CL_VIRUS;
+   break;
+
+   case CL_TYPE_MAIL:
+   if(SCAN_MAIL  type == CL_TYPE_UNKNOWN_TEXT)
+   if((ret = cli_scanmail(desc, ctx)) == CL_VIRUS)
+   return CL_VIRUS;
break;
 
case CL_TYPE_RARSFX:
@@ -1614,7 +1614,7 @@ int cli_magic_scandesc(int desc, cli_ctx
 
 if(!ctx-options) { /* raw mode (stdin, etc.) */
cli_dbgmsg(Raw mode: No support for special files\n);
-   if((ret = cli_scandesc(desc, ctx, 0, 0, NULL) == CL_VIRUS))
+   if((ret = cli_scandesc(desc, ctx, 0, 0, NULL)) == CL_VIRUS)
cli_dbgmsg(%s found in descriptor %d\n, *ctx-virname, desc);
return ret;
 }
@@ -1641,7 +1641,7 @@ int cli_magic_scandesc(int desc, cli_ctx
 lseek(desc, 0, SEEK_SET);
 
 if(type != CL_TYPE_DATA  ctx-engine-sdb) {
-   if((ret = cli_scanraw(desc, ctx, type) == CL_VIRUS))
+   if((ret = cli_scanraw(desc, ctx, type)) == CL_VIRUS)
return CL_VIRUS;
lseek(desc, 0, SEEK_SET);
 }
___
http://lurker.clamav.net/list/clamav-devel.html