aboutsummaryrefslogtreecommitdiffstats
path: root/src/util.c
Commit message (Collapse)AuthorAgeFilesLines
* Another debian license fix.Vsevolod Stakhov2012-09-101-1/+1
| | | | | Add apache license for regexp that were delivered from SpamAssassin project. Fix debian/copyright for src/dns.c.
* Update copyright (required by debian).Vsevolod Stakhov2012-09-041-3/+3
|
* * Rework thread pools locking logic to avoid global lua mutex usage.Vsevolod Stakhov2012-08-221-1/+18
| | | | | | Fixed several memory leaks with modern glib. Fixed memory leak in dkim code. Fixed a problem with static global variables in shared libraries.
* When inserting a url to the tree also check phishing status to avoid masking ↵Vsevolod Stakhov2012-08-061-0/+4
| | | | of phished urls by innocent urls.
* Fix build on FreeBSD 9.1 and Current. Thanks to Anton Yuzjaninov for testing.Vsevolod Stakhov2012-07-261-0/+4
|
* Strict prototypes.Vsevolod Stakhov2012-06-051-2/+2
|
* * Split rspamd build to several independent libraries to reduce overhead.Vsevolod Stakhov2012-06-051-21/+0
|
* Add portable api for locks and threads to handle Glib threads API change.Vsevolod Stakhov2012-04-131-0/+189
|
* Separate librspamdserver API from plugins and workers functions.Vsevolod Stakhov2012-03-011-2/+2
| | | | Make tests compileable again.
* * Introduce new system of worker's and modules initialization:Vsevolod Stakhov2012-01-161-51/+23
| | | | | | | | - Removed legacy limitation of worker's types; - Using GQuarks to identify workers and modules; - Remove modules.sh script; - Add a common system of workers and modules; - Write management and configuration for new architecture.
* Make compiler happy in several cases, remove warnings.Vsevolod Stakhov2011-12-201-1/+3
|
* Detect and use fallocate/posix_fallocate.Vsevolod Stakhov2011-12-141-0/+13
|
* Add another workaround for CentOS.Vsevolod Stakhov2011-12-141-0/+11
|
* Reorganize util.c as it should contain only common utilities.Vsevolod Stakhov2011-12-071-217/+2
| | | | Libkvstorage client is now deprecated as I plan to replace it with hiredis library.
* Add -i flag allowing to run workers as root.Vsevolod Stakhov2011-11-301-0/+5
|
* Check for SIGUSR1 by libevent to avoid signals collisions.Vsevolod Stakhov2011-11-301-5/+0
| | | | Remove greylist_storage as it was never used and is actually replaced with basic kvstorage.
* * Add incr and decr commands to kvstorage.Vsevolod Stakhov2011-11-101-0/+82
| | | | * Add integers detection inside kvstorage.
* * Fix threading in kvstorage.Vsevolod Stakhov2011-10-311-0/+2
| | | | Rspamd now can detect and work with libevent-2.
* * Initial implementation of threaded kvstorage worker.Vsevolod Stakhov2011-10-271-2/+2
|
* Fix siginfo detection code.Vsevolod Stakhov2011-10-241-1/+1
|
* Add universal utility function for creating stream sockets.Vsevolod Stakhov2011-10-181-1/+87
|
* Remove some warnings.Vsevolod Stakhov2011-10-141-3/+1
|
* Add make_socketpair utility function.Vsevolod Stakhov2011-10-131-0/+31
|
* Try to check spf domain before adding it to LRU hash.Vsevolod Stakhov2011-10-061-20/+20
| | | | Make libutil functions ported from BSD compatible with libbsd in linux.
* Fix signness in arithmetic operations.Vsevolod Stakhov2011-08-041-3/+3
|
* * First commit to implement multi-statfile filter system with new learning ↵Vsevolod Stakhov2011-07-121-0/+23
| | | | mechanizm (untested yet)
* * Fix error in raw headers parsingVsevolod Stakhov2011-05-241-0/+4
| | | | * Improve speed of raw headers access
* * Strip email addresses from bracesVsevolod Stakhov2011-05-131-0/+23
| | | | Ignore empty domains in settings
* * Rework build process:Vsevolod Stakhov2011-05-101-540/+181
| | | | | | | | | | - add librspamdserver - link this library to all daemons and utils of rspamd - use subdirectories more often * Rework global variables logic - move them to the main process * Fix logging to handle utf-8 correctly * Add statshow utility and make it working * Move printf functions to separate source file
* * Start new rspamd 0.3.4Vsevolod Stakhov2010-12-031-0/+54
| | | | * Add ability to manage per-module, per-worker and per-classifier options in XML parser
* Make own strlcpy that does not calculate remaining string length (faster and ↵Vsevolod Stakhov2010-11-161-6/+88
| | | | | | more safe) Allow only ASCII symbols in logs, escape control chars
* Urgent fixes.Vsevolod Stakhov2010-11-031-1/+1
|
* Add compatibility with glib < 2.2.22Vsevolod Stakhov2010-10-281-0/+7
| | | | Fix user in start script
* Fixes types (use glib ones) no functional change.Vsevolod Stakhov2010-10-061-172/+162
| | | | | Now all comments in commit logs beginning with '*' would be included in changelog, so important changes would be separated from small ones.
* * Fix detection of numeric urls (reported by citrin)Vsevolod Stakhov2010-07-051-13/+16
| | | | * Write real time of message's scan to log (not only virtual)
* * Use rspamd_snprintf instead of libc oneVsevolod Stakhov2010-06-241-2/+8
|
* * Fix compatibility issuesVsevolod Stakhov2010-06-231-2/+9
|
* * Rewrite buffered input for line policy (again)Vsevolod Stakhov2010-06-221-1/+17
| | | | | | | | * Fix issue with links that are ip addresses in numeric form in surbl * On Darwin use BSD style sendfile definition * Reorganize platform specific knobs in CMakeLists * Use gettimeofday on systems that have not clock_getres * Use ftime for dns trans id generation on systems without clock_getres
* * New logic of SURBL module:Vsevolod Stakhov2010-06-181-0/+28
| | | | | | | | | | | | | - remove completely 2tld - add option "exception" - for domains from exception list check (level + 1) parts of url: If we have url mail.some.com.ru and have com.ru in exception list then we would check some.com.ru. If we have some.com.ru in exceptions list them mail.some.com.ru would be checked and so on. - optimized parsing of surbl requests * Use system mkstemp(3) on systems where it is available as glib implementation has poor security and generate rather predictable temporary file names.
* * Convert statistic sums to use long double for countersVsevolod Stakhov2010-05-271-7/+71
| | | | * Use hyperbolic tangent for internal normalizer
* * Fix unix socket creation under FreeBSD (reported by Andrey Zverev)cebka@lenovo-laptop2010-02-151-7/+5
|
* * Introduce new logging system:Vsevolod Stakhov2009-12-221-190/+21
| | | | | | | | | - independent and customizeable buffering - line buffering - errors handling support - custom (ip based) debug - append function name automaticaly (based on __FUNCTION__) - add some logic to logs system
* * Add ability to specify pid file from command line (for rc scripts)Vsevolod Stakhov2009-12-211-2/+6
| | | | * Do not use flock directly in pidfile handling
* * Fix symbols cache (init lua filters before symbols cache initialization)Vsevolod Stakhov2009-12-141-2/+2
| | | | | | | * Remove LRU expiration logic from statfiles and replace it with random/lowerest value expiration logic: expire random block or block with lowerest value ! statfiles are incompatible again
* * Many major fixes to statfiles:Vsevolod Stakhov2009-12-031-0/+5
| | | | | | | | | | - fix bug with mmapping files: new addresses must NOT be allocated in shared memory by themselves - fix bug with winnow classifier that totally brokes it down - fix bug with too much grow of values * Use double precission values in statistics * Add statistics for statfiles * Add more informative data to output of LEARN command (weight of incoming message) * Add weight to output of classifier as well
* * Some fixes to syncVsevolod Stakhov2009-12-021-0/+3
|
* * Adopt printf function from nginx for comfortable printing of some data ↵Vsevolod Stakhov2009-11-301-4/+418
| | | | | | | types (fixed strings, pids etc) * Fix work of http maps (they were broken in some places before) * Fix sync of statfiles (not fully tested yet)
* * Write revision and revision time to statfileVsevolod Stakhov2009-11-121-2/+45
| | | | * Make some improvements to API (trying to make it more clear)
* * Fix addrlen of sockaddr_un (previous was a mistake)Vsevolod Stakhov2009-11-111-2/+2
|
* * Add logging urls as it was required by rambler searchVsevolod Stakhov2009-11-061-2/+0
|