Commit Graph

176 Commits

Author SHA1 Message Date
Török Edvin
6870ebe176 mdprintf was also taking %f and %l, and they have different size than int.
Make the ARGLEN get the correct vaarg types, otherwise it was popping off the
stack an item of the wrong size!

git-svn: trunk@4784
2009-02-13 16:52:15 +00:00
Török Edvin
c5cfb0f96f add copyright header
git-svn: trunk@4782
2009-02-13 13:26:38 +00:00
Török Edvin
bfd89d7c84 fix Solaris build
git-svn: trunk@4776
2009-02-13 11:05:14 +00:00
Tomasz Kojm
086eab5c26 update old copyright headers
git-svn: trunk@4775
2009-02-13 10:55:45 +00:00
Török Edvin
40331c57f0 add missing include
git-svn: trunk@4772
2009-02-12 21:29:42 +00:00
Török Edvin
7a997ac950 move TCP socket creation to shared/
git-svn: trunk@4769
2009-02-12 21:14:51 +00:00
Török Edvin
08c9ac85c2 fix
git-svn: trunk@4767
2009-02-12 19:18:35 +00:00
Török Edvin
2a6bd14bc2 make prototype compatible with that declared in system headers. (bb #1383)
git-svn: trunk@4766
2009-02-12 19:06:29 +00:00
aCaB
ecbbc8c452 fix spam
git-svn: trunk@4762
2009-02-12 17:54:15 +00:00
aCaB
7609af89f2 merge from clamd-proto branch:
handle multiple %v parameters
    introduce poll_fds that also does the read into a buffer
    introduce thrmgr_group* commands for keeping track of groups of commands
    (multiscan, IDSESSION)
    introduce 2 queues in thrmgr, multiscan queues get lower priority. Commands
    are processed from both queues in a 4:1 ratio to avoid starvation.
    unify reply code: conn_reply*
    unify scanner code into scan_callback that is called from cli_ftw
    multiscan doesn't need stat() now if readdir() provides dt_type
    redesign clamd main loop: there is now an accept thread, and a
    recv()/dispatch thread, +MaxThreads worker (scanner) threads.
    introduce limiting on commands when worker threads are contended.
    introduce IDSESSION, a replacement for the old SESSION command, that allows
    asyncronous (scan) commands and scan replies
    introduce INSTREAM that allows sending the data to scan on same connection
    (vs STREAM that requires another port)
    introduce zCOMMANDS

git-svn: trunk@4756
2009-02-12 17:11:27 +00:00
Török Edvin
949c6fe54f merge from clamd-proto branch:
handle multiple %v parameters
    introduce poll_fds that also does the read into a buffer
    introduce thrmgr_group* commands for keeping track of groups of commands
    (multiscan, IDSESSION)
    introduce 2 queues in thrmgr, multiscan queues get lower priority. Commands
    are processed from both queues in a 4:1 ratio to avoid starvation.
    unify reply code: conn_reply*
    unify scanner code into scan_callback that is called from cli_ftw
    multiscan doesn't need stat() now if readdir() provides dt_type
    redesign clamd main loop: there is now an accept thread, and a
    recv()/dispatch thread, +MaxThreads worker (scanner) threads.
    introduce limiting on commands when worker threads are contended.
    introduce IDSESSION, a replacement for the old SESSION command, that allows
    asyncronous (scan) commands and scan replies
    introduce INSTREAM that allows sending the data to scan on same connection
    (vs STREAM that requires another port)
    introduce zCOMMANDS

git-svn: trunk@4755
2009-02-12 16:51:09 +00:00
aCaB
ee6702abf5 unify actions
git-svn-id: file:///var/lib/svn/clamav-devel/branches/clamd-proto@4751 77e5149b-7576-45b1-b177-96237e5ba77b
2009-02-12 15:14:12 +00:00
Török Edvin
e001f2838e Use 2 queues: one for single, one for bulk messages.
Also introduce MaxQueue, this will prevent clamdscan from flooding
clamd with too many FILDES requests.

git-svn-id: file:///var/lib/svn/clamav-devel/branches/clamd-proto@4710 77e5149b-7576-45b1-b177-96237e5ba77b
2009-02-08 21:06:59 +00:00
Tomasz Kojm
86c97e7e26 shared/optparser.c, clamconf: handle clamav-milter.conf in --generate-config
git-svn: trunk@4687
2009-02-06 14:43:30 +00:00
Tomasz Kojm
afff80efb9 libclamav, shared: minor cleanups; fix handling of long file names (bb#1349)
git-svn: trunk@4670
2009-02-03 18:47:18 +00:00
Tomasz Kojm
32390e3161 shared/optparser.c: improve handling of short switches (bb#1374)
git-svn: trunk@4665
2009-01-30 07:49:04 +00:00
Tomasz Kojm
1d8a56d491 shared/optparser.c, clamconf/clamconf.c: add --generate-config
git-svn: trunk@4664
2009-01-29 19:03:59 +00:00
Tomasz Kojm
47d40feb7a libclamav: use LibTomMath by Tom St Denis instead of libgmp for multiple precision integer arithmetic (bb#1366)
git-svn: trunk@4650
2009-01-26 19:47:02 +00:00
aCaB
056198f16d shared/optparser.c, clamconf: new clamconf (bb#1215, bb#1316)
git-svn-id: file:///var/lib/svn/clamav-devel/branches/clamd-proto@4632 77e5149b-7576-45b1-b177-96237e5ba77b
2009-01-22 17:29:53 +00:00
Tomasz Kojm
a128eb8063 clamconf: handle --version/-V
git-svn: trunk@4630
2009-01-22 14:38:16 +00:00
Tomasz Kojm
0d06ef19f8 shared/optparser.c, clamconf: new clamconf (bb#1215, bb#1316)
git-svn: trunk@4628
2009-01-22 14:19:47 +00:00
aCaB
59c2353664 shared/optparser.c: improve cmdline args handling
git-svn-id: file:///var/lib/svn/clamav-devel/branches/clamd-proto@4627 77e5149b-7576-45b1-b177-96237e5ba77b
2009-01-20 17:46:58 +00:00
Tomasz Kojm
19c17946cc shared/optparser.c: improve cmdline args handling
git-svn: trunk@4625
2009-01-19 19:41:27 +00:00
Tomasz Kojm
e247b45cc6 shared/misc.c: re-enable freshdbdir()
git-svn: trunk@4590
2009-01-02 21:45:46 +00:00
Tomasz Kojm
b61db429fc shared, clamconf: drop old stuff; replace getopt.[ch] with my_getopt
git-svn: trunk@4589
2009-01-02 17:04:11 +00:00
Tomasz Kojm
278dc6b3d9 shared/optparser.c, clamav-milter: use the new option parser (bb#1215)
git-svn: trunk@4588
2009-01-02 15:30:17 +00:00
Tomasz Kojm
d6af38e75e shared/optparser.c, sigtool: use the new option parser (bb#1215)
git-svn: trunk@4587
2009-01-02 11:54:08 +00:00
Tomasz Kojm
e8b54ef3fa shared/optparser.c: fix typo (bb#1336)
git-svn: trunk@4584
2008-12-31 14:28:02 +00:00
Tomasz Kojm
8392ae8070 shared/optparser.c: cosmetics; add FLAG_REQUIRED
git-svn: trunk@4583
2008-12-31 12:26:30 +00:00
Tomasz Kojm
a68d5e2fb2 shared/optparser.c, clamdscan: use the new option parser (bb#1215)
git-svn: trunk@4581
2008-12-30 21:16:02 +00:00
Tomasz Kojm
269d520dfb shared/optparser.c, clamscan: use the new option parser
git-svn: trunk@4580
2008-12-30 10:33:43 +00:00
Tomasz Kojm
7eca74fef9 shared/optparser.c: extend MATCH_BOOL regex (bb#1324)
git-svn: trunk@4576
2008-12-22 21:22:17 +00:00
Tomasz Kojm
229491b7b4 shared/optparser.c: handle --user/-u in freshclam (bb#1323)
git-svn: trunk@4575
2008-12-22 21:05:53 +00:00
Tomasz Kojm
1f95badf6a shared/optparser.c: fix small memleak
git-svn: trunk@4574
2008-12-22 15:01:59 +00:00
Tomasz Kojm
3f7802c93e shared/optparser.c, freshclam: use the new option parser (bb#1215)
git-svn: trunk@4573
2008-12-18 19:42:53 +00:00
Tomasz Kojm
e1c57af20c fix parentheses
git-svn: trunk@4571
2008-12-18 14:24:43 +00:00
Tomasz Kojm
064b4a0c99 initial version of the unified option parser (bb#1215)
git-svn: trunk@4565
2008-12-17 21:42:54 +00:00
aCaB
87620def4a add tempdir, some fixes
git-svn: trunk@4531
2008-12-04 16:27:16 +00:00
aCaB
66ded5b846 Whitelisting complete
git-svn: trunk@4530
2008-12-04 16:27:10 +00:00
aCaB
ce34c246e0 AddHeader
git-svn: trunk@4527
2008-12-04 16:26:52 +00:00
aCaB
e9747a42a2 Implenet actions
git-svn: trunk@4526
2008-12-04 16:26:47 +00:00
aCaB
f7f3b5913f cfg fix
git-svn: trunk@4525
2008-12-04 16:26:41 +00:00
aCaB
6840d862f5 LocalNet parser complete
git-svn: trunk@4523
2008-12-04 16:26:30 +00:00
aCaB
4c237bcfdd Squashed commit of the following:
commit 0ddbd1a7117e207b8aa87079568a056691d5eb32
Author: acab <acab@1337ness.(none)>
Date:   Thu Nov 27 17:18:04 2008 +0100

    to be committed

commit 51f8010a275717b8a56a3ab22d49755899819518
Author: acab <acab@1337ness.(none)>
Date:   Thu Nov 27 15:18:40 2008 +0100

    mangle body

commit cd38463f4739f4a7778b6bf294cfb2166024656e
Author: acab <acab@1337ness.(none)>
Date:   Thu Nov 27 14:43:39 2008 +0100

    parse clamd result

commit 7b8a39495e59ac745342455f8e9aab09951d1041
Author: acab <acab@1337ness.(none)>
Date:   Thu Nov 27 03:19:45 2008 +0100

    handle calloc shifts

commit a58b732af99f9e3f18d2327e977432f1117028ee
Author: acab <acab@1337ness.(none)>
Date:   Thu Nov 27 02:07:19 2008 +0100

    spam added, local is b0rked

commit 22604b4b037cfdbc92d6b29986652e2f004bd1f3
Author: acab <acab@albe.digitalfuture.it>
Date:   Wed Nov 26 19:44:59 2008 +0100

    free/close stuff

commit 33a02aed984981d3e80ca4930a482f702624f08f
Author: aCaB <acab@digitalfuture.it>
Date:   Wed Nov 26 03:11:29 2008 +0100

    skeleton ready

commit 4630d9902ee74b6137abf6526c6a9ad3e41fc597
Author: aCaB <acab@digitalfuture.it>
Date:   Tue Nov 25 22:59:41 2008 +0100

    need to rebase

commit 083f5f98aecfce2763870f20ae97643d5683613a
Author: aCaB <acab@digitalfuture.it>
Date:   Tue Nov 25 22:45:11 2008 +0100

    in body()

commit 08f040f67de1264810953415c0a47c95ec9acff0
Author: aCaB <acab@digitalfuture.it>
Date:   Tue Nov 25 19:51:15 2008 +0100

    clamfi

commit bc08fe8f72580b8be81791a7c03ec38952781af7
Author: aCaB <acab@digitalfuture.it>
Date:   Tue Nov 25 16:47:17 2008 +0100

    adding milter

commit 34dcebd9294a059f2c45ec9d1817bdb75f423cb3
Author: aCaB <acab@digitalfuture.it>
Date:   Tue Nov 25 00:35:11 2008 +0100

    netcode works, fix to cfgparser

commit 3cc0997d907e817954328c60e43cdcca0667d6f3
Author: aCaB <acab@digitalfuture.it>
Date:   Mon Nov 24 23:46:05 2008 +0100

    socket probe

commit 0c3bbd6d03f8df931cb114b07150cd0b7dcd0aff
Author: aCaB <acab@digitalfuture.it>
Date:   Mon Nov 24 19:02:06 2008 +0100

    nonblock started

commit a1193ff0de0d0a3d9212d833110236b1329c1f2e
Author: aCaB <acab@digitalfuture.it>
Date:   Mon Nov 24 11:17:41 2008 +0100

    legacy options

commit 90519c59ff8a4f44fceaf84e8c40116254c73045
Author: aCaB <acab@digitalfuture.it>
Date:   Sun Nov 23 19:41:26 2008 +0100

    sockets pool

commit 897b0c5f82503530ba3fbb2fcc3a9c007488e90a
Author: aCaB <acab@digitalfuture.it>
Date:   Sun Nov 23 01:02:59 2008 +0100

    Logging done

commit 4cf3a218756271c74782a1649f728e1c6e977ae5
Author: aCaB <acab@digitalfuture.it>
Date:   Sat Nov 22 23:31:34 2008 +0100

    Config done

commit 93b271579f680286c697476c00d8eec7effb2fc4
Author: aCaB <acab@digitalfuture.it>
Date:   Sat Nov 22 22:50:42 2008 +0100

    Sanitise config file options

commit bf5e81b8561b258daaef134894761fa80d44f5b1
Author: aCaB <acab@digitalfuture.it>
Date:   Sat Nov 22 20:25:06 2008 +0100

    cfgparser hacks to allow for milter own conf

commit 8924e93b2567a1f378c2177b4011b67631b49cc1
Author: aCaB <acab@digitalfuture.it>
Date:   Sat Nov 22 19:03:45 2008 +0100

    command line parser

commit d2180e370f75948b6ce12f89979bda9e92ccd5f8
Author: aCaB <acab@digitalfuture.it>
Date:   Sat Nov 22 16:36:37 2008 +0100

    restart from scratch

commit 249d6cdbddbea622c949753aafbf48e526e0ef4d
Author: aCaB <acab@digitalfuture.it>
Date:   Sun Nov 16 19:39:12 2008 +0100

    more diversion

commit b948990103867b59c749da88d6384128c1e5e6d3
Author: aCaB <acab@digitalfuture.it>
Date:   Sun Nov 16 17:31:42 2008 +0100

    milter separation (milter)

commit 6dc259a5d4f8f6e4428953055510382160ef8df4
Author: aCaB <acab@digitalfuture.it>
Date:   Sun Nov 16 17:23:14 2008 +0100

    milter separation

git-svn: trunk@4519
2008-12-04 16:26:04 +00:00
Tomasz Kojm
fa78cc4341 s/ArchiveMaxScanSize/ArchiveMaxFileSize in deprecated
git-svn: trunk@4505
2008-12-01 12:00:20 +00:00
aCaB
41cf3f0e48 typo in shared/cfgparser.c
git-svn: trunk@4490
2008-11-28 17:12:00 +00:00
aCaB
cd04ff0694 cfgparser hacks backported from branches/milter-v2.0
git-svn: trunk@4489
2008-11-28 16:57:15 +00:00
Tomasz Kojm
c6677c9418 LogFileUnlock was not working correctly (bb#1304)
git-svn: trunk@4471
2008-11-25 20:07:11 +00:00
Tomasz Kojm
33068e0973 libclamav: drop cl_settempdir(); use cl_engine_set() with CL_ENGINE_TMPDIR and CL_ENGINE_KEEPTMP instead
git-svn: trunk@4416
2008-11-14 22:23:39 +00:00
Tomasz Kojm
370892d044 clamscan, clamd: use the new API; drop the hardcoded default limits and use the ones set in cl_engine_new()
git-svn-id: file:///var/lib/svn/clamav-devel/branches/newapi@4384 77e5149b-7576-45b1-b177-96237e5ba77b
2008-11-12 16:19:43 +00:00