From 1d32119e301d0507050d28e232669832715a75c6 Mon Sep 17 00:00:00 2001 From: Vsevolod Stakhov Date: Fri, 15 Apr 2022 21:02:22 +0100 Subject: [PATCH] [Test] Add a test with DKIM key with spaces in base64 Issue: #4149 --- test/rspamd_cxx_unit_dkim.hxx | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/test/rspamd_cxx_unit_dkim.hxx b/test/rspamd_cxx_unit_dkim.hxx index 87e244b3d..29facba8a 100644 --- a/test/rspamd_cxx_unit_dkim.hxx +++ b/test/rspamd_cxx_unit_dkim.hxx @@ -111,6 +111,15 @@ TEST_CASE("rspamd_dkim_parse_key") "lnNaq5pWei/B8pG6teV+y3t4yay5ZGktALJjlylKHVo2USkVYQTFQ9Ji25m2jupdCd" "kn1FTuYNqh0Nzg3KPQHNVp7mlE7lfwIDAQAB ", true, "e40cc5c40ee29cb4f21d95c7f0dc9989"}, + // Spaces within base64 + {"p=MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCA" + " QEA5CeQZpoPbsS8lG41UI1rxTtOSqPrfgZzhrZsk0t9dIbFTvaoql/FLuYcbdUARc" + " 5zuyXsDj1eSprOgcPT9PY9RoSUsY8i/ jnD49DHXtMfXoBk0J6epNzbZqqWU+" + " TG02HwWNy/kf1h+OlAGQKJLgakivZ3nMMnUIPHkUjwvhbkaMXCI046XoqsEQ7KW" + " VKRoF3cK1cFXLo+bgO3sEJgGtvwzPodG0CqVu+gjehrjwdLnPhqyEspfI1IbL" + " lnNaq5pWei/B8pG6teV+y3t4yay5ZGktALJjlylKHVo2USkVYQTFQ9Ji25m2jupdCd" + " kn1FTuYNqh0Nzg3KPQHNVp7mlE7lfwIDAQAB", + true, "e40cc5c40ee29cb4f21d95c7f0dc9989"}, // Invalid RSA {"ololo=trololo; k=rsa; t=s; " "p = BADMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCA" -- 2.39.5