#define DEFAULT_SYMBOL "R_FUZZY_HASH"
#define RSPAMD_FUZZY_SYMBOL_FORBIDDEN "FUZZY_FORBIDDEN"
#define RSPAMD_FUZZY_SYMBOL_RATELIMITED "FUZZY_RATELIMITED"
+#define RSPAMD_FUZZY_SYMBOL_ENCRYPTION_REQUIRED "FUZZY_ENCRYPTION_REQUIRED"
#define DEFAULT_IO_TIMEOUT 1.0
#define DEFAULT_RETRANSMITS 3
0,
1,
1);
+ rspamd_symcache_add_symbol(cfg->cache,
+ RSPAMD_FUZZY_SYMBOL_ENCRYPTION_REQUIRED, 0, NULL, NULL,
+ SYMBOL_TYPE_VIRTUAL,
+ cb_id);
+ rspamd_config_add_symbol(cfg,
+ RSPAMD_FUZZY_SYMBOL_ENCRYPTION_REQUIRED,
+ 0.0,
+ "Fuzzy encryption is required by a server",
+ "fuzzy",
+ 0,
+ 1,
+ 1);
/*
* Here we can have 2 possibilities:
}
}
else if (rep->v1.value == 403) {
+ /* In fact, it should be 429, but we preserve compatibility */
rspamd_task_insert_result(task, RSPAMD_FUZZY_SYMBOL_RATELIMITED, 1.0,
session->rule->name);
}
rspamd_task_insert_result(task, RSPAMD_FUZZY_SYMBOL_FORBIDDEN, 1.0,
session->rule->name);
}
+ else if (rep->v1.value == 415) {
+ rspamd_task_insert_result(task, RSPAMD_FUZZY_SYMBOL_ENCRYPTION_REQUIRED, 1.0,
+ session->rule->name);
+ }
else if (rep->v1.value == 401) {
if (cmd->cmd != FUZZY_CHECK) {
msg_info_task(