]> source.dussan.org Git - rspamd.git/commitdiff
[Fix] Fix dependencies for DNS_SIGNED symbol
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Wed, 3 Oct 2018 12:25:31 +0000 (13:25 +0100)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Wed, 3 Oct 2018 12:30:04 +0000 (13:30 +0100)
src/plugins/dkim_check.c
src/plugins/lua/dkim_signing.lua

index f728fb5ec4e1165162b084e0770d89d44650125a..1784612f0e44f1353bc67ad086cabedb1016c372 100644 (file)
@@ -499,36 +499,43 @@ dkim_module_config (struct rspamd_config *cfg)
                }
 
                cb_id = rspamd_symbols_cache_add_symbol (cfg->cache,
-                       dkim_module_ctx->symbol_reject,
-                       0,
-                       dkim_symbol_callback,
-                       NULL,
-                       SYMBOL_TYPE_NORMAL|SYMBOL_TYPE_FINE,
-                       -1);
+                               "DKIM_CHECK",
+                               0,
+                               dkim_symbol_callback,
+                               NULL,
+                               SYMBOL_TYPE_CALLBACK,
+                               -1);
                rspamd_symbols_cache_add_symbol (cfg->cache,
-                       dkim_module_ctx->symbol_na,
-                       0,
-                       NULL, NULL,
-                       SYMBOL_TYPE_VIRTUAL|SYMBOL_TYPE_FINE,
-                       cb_id);
+                               dkim_module_ctx->symbol_reject,
+                               0,
+                               NULL,
+                               NULL,
+                               SYMBOL_TYPE_VIRTUAL|SYMBOL_TYPE_FINE,
+                               cb_id);
                rspamd_symbols_cache_add_symbol (cfg->cache,
-                       dkim_module_ctx->symbol_permfail,
-                       0,
-                       NULL, NULL,
-                       SYMBOL_TYPE_VIRTUAL|SYMBOL_TYPE_FINE,
-                       cb_id);
+                               dkim_module_ctx->symbol_na,
+                               0,
+                               NULL, NULL,
+                               SYMBOL_TYPE_VIRTUAL|SYMBOL_TYPE_FINE,
+                               cb_id);
                rspamd_symbols_cache_add_symbol (cfg->cache,
-                       dkim_module_ctx->symbol_tempfail,
-                       0,
-                       NULL, NULL,
-                       SYMBOL_TYPE_VIRTUAL|SYMBOL_TYPE_FINE,
-                       cb_id);
+                               dkim_module_ctx->symbol_permfail,
+                               0,
+                               NULL, NULL,
+                               SYMBOL_TYPE_VIRTUAL|SYMBOL_TYPE_FINE,
+                               cb_id);
                rspamd_symbols_cache_add_symbol (cfg->cache,
-                       dkim_module_ctx->symbol_allow,
-                       0,
-                       NULL, NULL,
-                       SYMBOL_TYPE_VIRTUAL|SYMBOL_TYPE_FINE,
-                       cb_id);
+                               dkim_module_ctx->symbol_tempfail,
+                               0,
+                               NULL, NULL,
+                               SYMBOL_TYPE_VIRTUAL|SYMBOL_TYPE_FINE,
+                               cb_id);
+               rspamd_symbols_cache_add_symbol (cfg->cache,
+                               dkim_module_ctx->symbol_allow,
+                               0,
+                               NULL, NULL,
+                               SYMBOL_TYPE_VIRTUAL|SYMBOL_TYPE_FINE,
+                               cb_id);
 
                rspamd_symbols_cache_add_symbol (cfg->cache,
                                "DKIM_TRACE",
index f15816afd5ec6ce09d5c718cee5032732acd8be4..8d621bbb203ed6da60fb82635a32bcbd1745a4c4 100644 (file)
@@ -221,3 +221,6 @@ rspamd_config:register_symbol({
   groups = {"policies", "dkim"},
   score = 0.0,
 })
+
+-- Add dependency on DKIM checks
+rspamd_config:register_dependency(settings['symbol'], 'DKIM_CHECK')
\ No newline at end of file