From: Andrew Lewis Date: Wed, 21 Sep 2016 12:55:08 +0000 (+0200) Subject: [Fix] Yield R_SPF_DNSFAIL if lookup of included record fails X-Git-Tag: 1.4.0~398^2~1 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=6c0e2ece642fdfd3dbbea5fa96c4e69e2f9831ec;p=rspamd.git [Fix] Yield R_SPF_DNSFAIL if lookup of included record fails --- diff --git a/src/libserver/spf.c b/src/libserver/spf.c index a4870f294..95bcc7628 100644 --- a/src/libserver/spf.c +++ b/src/libserver/spf.c @@ -729,6 +729,7 @@ spf_record_dns_callback (struct rdns_reply *reply, gpointer arg) cb->rec->sender_domain, cb->resolved->cur_domain); cb->addr->flags &= ~RSPAMD_SPF_FLAG_PARSED; + cb->addr->flags |= RSPAMD_SPF_FLAG_TEMPFAIL; break; case SPF_RESOLVE_EXP: break; diff --git a/src/plugins/spf.c b/src/plugins/spf.c index bc05cd9fe..6d5517db9 100644 --- a/src/plugins/spf.c +++ b/src/plugins/spf.c @@ -442,7 +442,7 @@ spf_plugin_callback (struct spf_resolved *record, struct rspamd_task *task, struct spf_resolved *l; struct rspamd_async_watcher *w = ud; - if (record && record->elts->len == 0) { + if (record && record->elts->len == 0 && !record->failed) { rspamd_task_insert_result (task, spf_module_ctx->symbol_na, 1,