Tomasz Kojm
0354e96264
fix maxpatlen
2009-10-13 22:45:58 +02:00
aCaB
63979bf21e
Merge remote branch 'origin/fmap4all'
2009-10-09 22:07:33 +02:00
aCaB
49cc1e3c35
s/struct F_MAP/fmap_t/
2009-10-02 18:09:31 +02:00
Tomasz Kojm
417b7509f6
libclamav/matcher-ac.c: fix matching of logical sigs (bb#1707)
2009-09-29 21:48:07 +02:00
Tomasz Kojm
04133ff998
libclamav: new signature blacklisting format (bb#1625)
...
libclamav: allow arbitrary names for .ign/.ign2 files (bb#1683)
2009-09-28 19:33:59 +02:00
Tomasz Kojm
723a44d54d
libclamav/matcher-ac.c: add support for line marker (L) (matches CR, CRLF and boundaries)
2009-09-25 10:38:10 +02:00
Tomasz Kojm
8c3c77b49c
libclamav/matcher-ac.c: implement word delimiter (B) as requested in bb#1631
2009-09-17 22:49:45 +02:00
aCaB
bad8ee8efd
merge master
2009-09-17 18:30:03 +02:00
Tomasz Kojm
a6d4c62ee5
libclamav/matcher-ac.c: initial limited support for word boundary (bb#1631)
2009-09-11 16:05:50 +02:00
Tomasz Kojm
95ac9effe4
libclamav/matcher-ac.c: alternatives can now be negated: !(aa|bb|cc)
2009-09-10 20:18:04 +02:00
Tomasz Kojm
8cd9e4da7a
fix copy&paste error
2009-09-09 23:14:07 +02:00
Tomasz Kojm
57e5af13c2
optimize alt handling
2009-09-09 22:50:24 +02:00
aCaB
10aa2df79b
Merge branch 'replace-mmap' into fmap4all
...
Conflicts:
libclamav/matcher-bm.c
libclamav/matcher-bm.h
libclamav/matcher.c
libclamav/pe.c
libclamav/phishcheck.c
libclamav/regex_list.c
2009-09-02 00:09:28 +02:00
aCaB
49ee0318fc
fix scanbuff callers
2009-09-01 19:15:57 +02:00
aCaB
048d76777f
scanners to fmap - hackish
...
peheader to fmap
lacks review + elf + macho
2009-09-01 13:49:36 +02:00
Tomasz Kojm
006f5fe642
libclamav: in bm_offmode only load sigs with non-floating absolute
...
and relative offsets into BM matcher (load other ones into AC) and
use per-file computed offset table to pick up best shifts (not
enabled by default, bb#1300)
2009-09-01 11:19:31 +02:00
Tomasz Kojm
a4d5efb4fe
fix fd check, thx aCaB
2009-08-31 11:19:53 +02:00
Tomasz Kojm
6bb841e896
libclamav/matcher-ac.c: improve handling of signature offsets
2009-08-26 23:39:35 +02:00
Tomasz Kojm
aca9ea82df
libclamav: handle relative offsets with cli_ac_data; fix offset logic
2009-08-21 15:55:10 +02:00
Tomasz Kojm
33872a43de
libclamav: improve handling of signature offsets
2009-08-14 14:38:13 +02:00
Tomasz Kojm
8df99a92aa
0.95.2
...
git-svn: trunk@5074
2009-06-10 20:50:49 +00:00
Tomasz Kojm
64b9b982c7
allow offsets for all buffer types
...
git-svn: trunk@5027
2009-04-06 20:17:25 +00:00
Tomasz Kojm
871177cdd9
return codes cleanup (bb#1159)
...
git-svn: trunk@4749
2009-02-12 13:53:23 +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
Tomasz Kojm
589d8d8e99
libclamav: add default.h
...
git-svn: trunk@4578
2008-12-29 17:55:30 +00:00
Tomasz Kojm
41486c4253
libclamav/matcher-ac.c: fix parsing of lsig modifiers
...
git-svn: trunk@4506
2008-12-01 18:48:39 +00:00
Tomasz Kojm
ab0d2f054d
libclamav, clamd, clamscan: use cl_engine_set() to control AC settings
...
git-svn: trunk@4404
2008-11-13 19:06:42 +00:00
Tomasz Kojm
724b2bf770
Move cl_engine from clamav.h to others.h; move cl_limits to cl_engine;
...
New API calls:
int cl_init(unsigned int options);
struct cl_engine *cl_engine_new(unsigned int options);
int cl_engine_compile(struct cl_engine *engine);
struct cl_engine *cl_engine_dup(struct cl_engine *engine);
int cl_engine_free(struct cl_engine *engine);
more to come..
WARNING: THE BRANCH IS CURRENTLY BROKEN AND SHOULD NOT BE USED
git-svn-id: file:///var/lib/svn/clamav-devel/branches/newapi@4370 77e5149b-7576-45b1-b177-96237e5ba77b
2008-11-10 17:39:58 +00:00
Török Edvin
fc0493d2ca
reduce memory usage of AC nodes
...
git-svn: trunk@4363
2008-11-10 10:46:24 +00:00
Török Edvin
6a21552ef2
have configure define NDEBUG unless we use --enable-debug, instead of having
...
to #ifndef CL_DEBUG #define NDEBUG #endif in each .c file that uses assert.
If you want assertions enabled you'll need to use --enable-debug to configure,
as until now, no change there.
git-svn: trunk@4343
2008-11-06 14:27:18 +00:00
aCaB
38e881e3c0
mpool cli_mp_hex2ui
...
git-svn: trunk@4337
2008-11-04 21:45:49 +00:00
Tomasz Kojm
a305a2616a
libclamav/matcher-ac.c: micro-optimization (bb#843), thanks to Edwin
...
git-svn: trunk@4334
2008-11-04 19:23:35 +00:00
aCaB
d6e1ef1611
mempool deuglification
...
git-svn: trunk@4333
2008-11-04 19:18:27 +00:00
Török Edvin
ad0fd7287a
* libclamav/matcher-ac.c (cli_ac_addsig): need to use mpool allocated memory for ->str
...
* libclamav/mpool.c (mp_malloc, cli_mp_hex2str, check_all): introduce hex2str wrapper
* libclamav/mpool.h (mp_t, cli_mp_hex2str): introduce hex2str wrapper
* libclamav/regex_list.c (add_hash): need to use mpool allocated memory for arg to bm_addpatt
git-svn: trunk@4330
2008-11-04 10:40:31 +00:00
Török Edvin
563582a1ec
fix unit tests when mpool is activated
...
git-svn: trunk@4323
2008-11-03 19:26:57 +00:00
aCaB
946bd26646
merge mempool branch
...
git-svn: trunk@4320
2008-11-01 02:39:00 +00:00
aCaB
e21657dfc9
a faster and more compact allocator
...
git-svn-id: file:///var/lib/svn/clamav-devel/branches/mpool@4286 77e5149b-7576-45b1-b177-96237e5ba77b
2008-10-21 23:55:11 +00:00
aCaB
0d9dbdef21
some leaks fixed
...
git-svn-id: file:///var/lib/svn/clamav-devel/branches/mpool@4280 77e5149b-7576-45b1-b177-96237e5ba77b
2008-10-19 16:16:49 +00:00
Török Edvin
29f241666f
fix hexnew allocation, mempool for regex_list
...
git-svn-id: file:///var/lib/svn/clamav-devel/branches/mpool@4276 77e5149b-7576-45b1-b177-96237e5ba77b
2008-10-19 12:13:24 +00:00
aCaB
a5746c2512
TODO:
...
- make regex* and hash* behave properly (either include or exclude from the pool entirely)
- cleanup the ifdefs and make a single macro
- fixup the proto for dconf (re-enables make check in mpool-mode)
- check the possibility to entirely wipe frees from error paths in mpool-mode
(this totally simplifies the code)
git-svn-id: file:///var/lib/svn/clamav-devel/branches/mpool@4271 77e5149b-7576-45b1-b177-96237e5ba77b
2008-10-18 12:03:08 +00:00
aCaB
885c2bf5b9
builds with and without mpools (#define USE_MPOOL) but it's still very broked
...
git-svn-id: file:///var/lib/svn/clamav-devel/branches/mpool@4269 77e5149b-7576-45b1-b177-96237e5ba77b
2008-10-18 01:04:14 +00:00
aCaB
0728972ea5
(hoepfully) completed db load, regexes and hashes missing
...
need to recheck strlen(hex2string) bugs, need to figure how to hangle regexes and hashes: edwiiiiiiin!!! :D
git-svn-id: file:///var/lib/svn/clamav-devel/branches/mpool@4268 77e5149b-7576-45b1-b177-96237e5ba77b
2008-10-18 00:16:23 +00:00
aCaB
b583d6ed27
small update
...
git-svn-id: file:///var/lib/svn/clamav-devel/branches/mpool@4267 77e5149b-7576-45b1-b177-96237e5ba77b
2008-10-17 20:33:15 +00:00
aCaB
b94e66c486
HIGLY EXPERIMENTAL memory pool for libclamav
...
The goal is to put an end to memory wasted due to stupid allocators and fragmentation
In the long run mpool libraries will be replaced with better code. For now there just good enough.
This branch is currently under development and totally broken.
If it will ever compile, it'll probably result in random crashes or at least (slightly) higher load times.
The code is also terrible, just don't look.
Do not use except for testing.
git-svn-id: file:///var/lib/svn/clamav-devel/branches/mpool@4266 77e5149b-7576-45b1-b177-96237e5ba77b
2008-10-17 17:00:13 +00:00
Tomasz Kojm
3b934d1e49
libclamav/matcher-ac.c: improve detection and reordering of zero-only subpatterns (bb#1188)
...
git-svn: trunk@4207
2008-09-25 11:05:21 +00:00
Tomasz Kojm
341faf6051
libclamav: drop obsolete code in matcher-ac
...
git-svn: trunk@4140
2008-08-25 14:07:18 +00:00
Tomasz Kojm
a45c7039c1
shut up some gcc warnings
...
git-svn: trunk@4092
2008-08-08 14:00:17 +00:00
Tomasz Kojm
710a22f179
libclamav/matcher-ac.c: add support for returning multiple matches in cli_ac_scanbuff()
...
git-svn: trunk@4017
2008-07-29 09:04:28 +00:00
Tomasz Kojm
ee8bd2fb14
libclamav: lsigs: handle extended block modifiers (bb#896)
...
git-svn: trunk@3998
2008-07-26 15:48:08 +00:00
Tomasz Kojm
c7aeeb46ef
evaluate lsigs in cli_scandesc
...
git-svn: trunk@3997
2008-07-25 23:11:23 +00:00