aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2018-05-16 14:34:04 +0100
committerVsevolod Stakhov <vsevolod@highsecure.ru>2018-05-16 14:34:04 +0100
commit57ae7eea2e0db52f6fd2fbb8e0fcfdf333655953 (patch)
tree842c6cc702b6b4d386bc6ec65c26739ce368a622 /src
parent21be6e229918aa90d26db549dd41ce7cc4338bb0 (diff)
downloadrspamd-57ae7eea2e0db52f6fd2fbb8e0fcfdf333655953.tar.gz
rspamd-57ae7eea2e0db52f6fd2fbb8e0fcfdf333655953.zip
[Minor] Fix "invalid key algorithm" warning
Diffstat (limited to 'src')
-rw-r--r--src/libserver/dkim.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/libserver/dkim.c b/src/libserver/dkim.c
index a51399a31..5af61daf7 100644
--- a/src/libserver/dkim.c
+++ b/src/libserver/dkim.c
@@ -1430,6 +1430,7 @@ rspamd_dkim_parse_key (rspamd_dkim_context_t *ctx, const gchar *txt,
if (alglen == 0 || alg == NULL) {
alg = "rsa"; /* Implicit */
+ alglen = 3;
}
if (alglen == 8 && rspamd_lc_cmp (alg, "ecdsa256", alglen) == 0) {
@@ -1445,6 +1446,7 @@ rspamd_dkim_parse_key (rspamd_dkim_context_t *ctx, const gchar *txt,
if (alglen != 3 || rspamd_lc_cmp (alg, "rsa", alglen) != 0) {
msg_info_dkim ("invalid key algorithm: %*s", (gint)alglen, alg);
}
+
return rspamd_dkim_make_key (ctx, c, klen,
RSPAMD_DKIM_KEY_RSA, err);
}