From: Vsevolod Stakhov Date: Sat, 18 Nov 2017 16:58:34 +0000 (+0000) Subject: [Fix] Fix processing of skip-hashes in fuzzy storage X-Git-Tag: 1.6.6~3^2~26 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=2a33adbe247f2870511803994acb273838b2dabe;p=rspamd.git [Fix] Fix processing of skip-hashes in fuzzy storage MFH: rspamd-1.6 --- diff --git a/src/fuzzy_storage.c b/src/fuzzy_storage.c index 6eed1d465..6992c2b85 100644 --- a/src/fuzzy_storage.c +++ b/src/fuzzy_storage.c @@ -876,8 +876,8 @@ rspamd_fuzzy_process_command (struct fuzzy_session *session) else { if (rspamd_fuzzy_check_client (session)) { /* Check whitelist */ - if (session->ctx->skip_hashes) { - rspamd_encode_hex_buf (cmd->digest, sizeof (cmd->cmd), + if (session->ctx->skip_hashes && cmd->cmd == FUZZY_WRITE) { + rspamd_encode_hex_buf (cmd->digest, sizeof (cmd->digest), hexbuf, sizeof (hexbuf) - 1); hexbuf[sizeof (hexbuf) - 1] = '\0';