From 648dc171910113e897d77424c5f264763a285142 Mon Sep 17 00:00:00 2001 From: Vsevolod Stakhov Date: Wed, 30 Sep 2015 18:39:48 +0100 Subject: [PATCH] Set the correct epoch for encrypted requests. --- src/fuzzy_storage.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/fuzzy_storage.c b/src/fuzzy_storage.c index 82af1c282..c60046a5b 100644 --- a/src/fuzzy_storage.c +++ b/src/fuzzy_storage.c @@ -336,7 +336,8 @@ rspamd_fuzzy_cmd_from_wire (guchar *buf, guint buflen, struct fuzzy_session *s) msg_debug ("invalid fuzzy command of size %d received", buflen); return FALSE; } - s->epoch = epoch; + /* Encrypted is epoch 10 at least */ + s->epoch = RSPAMD_FUZZY_EPOCH10; break; case sizeof (struct rspamd_fuzzy_encrypted_shingle_cmd): s->cmd_type = CMD_ENCRYPTED_SHINGLE; @@ -352,7 +353,8 @@ rspamd_fuzzy_cmd_from_wire (guchar *buf, guint buflen, struct fuzzy_session *s) msg_debug ("invalid fuzzy command of size %d received", buflen); return FALSE; } - s->epoch = epoch; + + s->epoch = RSPAMD_FUZZY_EPOCH10; break; default: msg_debug ("invalid fuzzy command of size %d received", buflen); -- 2.39.5