diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2016-08-13 16:44:48 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2016-08-13 16:44:48 +0100 |
commit | b4b779222a899f5a09475f56afaa61bc1cd168fc (patch) | |
tree | 49b026cf1e58663d031c9ae1bdf0df3932fc9c4b | |
parent | 3aeb60bd65509099f83eb3b5b79aba8676ace8ac (diff) | |
download | rspamd-b4b779222a899f5a09475f56afaa61bc1cd168fc.tar.gz rspamd-b4b779222a899f5a09475f56afaa61bc1cd168fc.zip |
[CritFix] Fix setting of fuzzy keys (completely breaks fuzzy storage)
-rw-r--r-- | src/plugins/fuzzy_check.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/plugins/fuzzy_check.c b/src/plugins/fuzzy_check.c index 429360e1c..1542c3d71 100644 --- a/src/plugins/fuzzy_check.c +++ b/src/plugins/fuzzy_check.c @@ -532,6 +532,7 @@ fuzzy_parse_rule (struct rspamd_config *cfg, const ucl_object_t *obj, } } + k = NULL; if ((value = ucl_object_lookup (obj, "fuzzy_key")) != NULL) { /* Create key from user's input */ k = ucl_object_tostring (value); @@ -547,6 +548,7 @@ fuzzy_parse_rule (struct rspamd_config *cfg, const ucl_object_t *obj, rspamd_cryptobox_hash (rule->hash_key->str, k, strlen (k), NULL, 0); rule->hash_key->len = rspamd_cryptobox_HASHKEYBYTES; + k = NULL; if ((value = ucl_object_lookup (obj, "fuzzy_shingles_key")) != NULL) { k = ucl_object_tostring (value); } |