diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2015-12-10 15:38:34 +0000 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2015-12-10 15:38:34 +0000 |
commit | 576108c64c01901848010673efc53b46a24dbc92 (patch) | |
tree | 5df2355d81d48ed1534c62817398cea0e186c1a2 /src/libutil/regexp.h | |
parent | 1aed295e93e1153bff796f9c2472f7e318ae1e28 (diff) | |
download | rspamd-576108c64c01901848010673efc53b46a24dbc92.tar.gz rspamd-576108c64c01901848010673efc53b46a24dbc92.zip |
Add special flag to disable hyperscan for particular expressions
Diffstat (limited to 'src/libutil/regexp.h')
-rw-r--r-- | src/libutil/regexp.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/libutil/regexp.h b/src/libutil/regexp.h index 0b585ceec..bf88035e2 100644 --- a/src/libutil/regexp.h +++ b/src/libutil/regexp.h @@ -28,6 +28,10 @@ #include "config.h" #define RSPAMD_INVALID_ID ((guint64)-1LL) +#define RSPAMD_REGEXP_FLAG_RAW (1 << 1) +#define RSPAMD_REGEXP_FLAG_NOOPT (1 << 2) +#define RSPAMD_REGEXP_FLAG_FULL_MATCH (1 << 3) +#define RSPAMD_REGEXP_FLAG_PCRE_ONLY (1 << 4) typedef struct rspamd_regexp_s rspamd_regexp_t; struct rspamd_regexp_cache; @@ -122,6 +126,11 @@ guint rspamd_regexp_get_pcre_flags (rspamd_regexp_t *re); guint rspamd_regexp_get_flags (rspamd_regexp_t *re); /** + * Set rspamd flags for the regexp + */ +guint rspamd_regexp_set_flags (rspamd_regexp_t *re, guint new_flags); + +/** * Set regexp maximum hits */ guint rspamd_regexp_get_maxhits (rspamd_regexp_t *re); |