{"id":244,"date":"2017-03-09T15:08:06","date_gmt":"2017-03-09T07:08:06","guid":{"rendered":"http:\/\/matnet.my\/blog\/?p=244"},"modified":"2017-03-09T15:15:52","modified_gmt":"2017-03-09T07:15:52","slug":"dkim-issue-on-cpanel-server-with-cloudflare-dns","status":"publish","type":"post","link":"https:\/\/matnet.my\/blog\/2017\/03\/dkim-issue-on-cpanel-server-with-cloudflare-dns\/","title":{"rendered":"DKIM issue on Cpanel Server with Cloudflare DNS :("},"content":{"rendered":"<p>1. Last night, I got complaint from my customer said that their server can&#8217;t send email to some gov agencies.<\/p>\n<p>2. Usually if this happen, you should check your mail server blacklist or reputation.<\/p>\n<p>3. Done check, the server was in good reputation and doesn&#8217;t listed on any RBL (You may check at https:\/\/www.senderbase.org\/lookup\/ or https:\/\/mxtoolbox.com\/blacklists.aspx<\/p>\n<p>4. So why the recipient does not accept our email ? The error code was : 554 5.7.1 (You are not allowed to connect)<\/p>\n<p>5. From the error code, it&#8217;s doesn&#8217;t help you to troubleshoot since there are no details why we are not allowed to connect?<\/p>\n<p>6. I have take several options to mitigate this issue. But this is not confirm that you are always welcome to any mail server.<\/p>\n<p>7. Enable clamav scan for outgoing mail.<\/p>\n<p>8. Configure DKIM on local NS. Since i&#8217;m using cloudflare, i need to copy the DKIM into cloudflare DNS.<\/p>\n<p>9. DKIM record has been filled on the clouflare but the error still out there. I got error p= field must be base64 encoded (http:\/\/dkimcore.org\/c\/keycheck)<\/p>\n<p>10. I just copy and paste the value of TXT DKIM.<\/p>\n<p>12. I follow step by step how to setup DKIM on cloudflare, but error still there.<\/p>\n<p>13. Then i looked into the details of the p= value with other domain which is with a good DKIM record. After compared, there are<br \/>\n3\u00a0spot look suspicious after query(dig default._domainkey.domain.com TXT). This is the value from cpanel DNS :<\/p>\n<p><strong><span style=\"color: #ff0000;\">&#8220;v=DKIM<\/span><\/strong>1; k=rsa; p=MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAv+w6CJDDntA3Zwmk0p<br \/>\nf+5qCnmTE1NxA1zaVCZCtwWsuzPdbxdBpDb9R7lYB0V0zWzUAr8NGvnRsRJzYEZHRy6Gv5fplky15mJBppsy<br \/>\n6anSqU9V\/n8dEUY6kE0BbwTJL0WJqxwlu+CJ8RS1lGl99XacpWl4Dgf0mhDZlv4ViB+hW1Gv9ao\/0aQ+mWN<br \/>\nmWzYLYZD<strong><span style=\"color: #ff0000;\">&#8221; 29mx0OM<\/span><\/strong>+bwepI1vMyW87mU4i0yi2KMrJRnqOG+lGVJp5qd5ooVpfH0VcHb4HI6ho8phlNa7<br \/>\np\/s4uG4pNKCXGET5OAr0E+tWE36nAbWIYsUrjTakbc6bBATXnK80tJf7tIf7zxCfIjqPOIZtwNPklQIDA<strong><span style=\"color: #ff0000;\">QAB\\;<\/span><\/strong><\/p>\n<p>What do you need to do when paste it into Cloudflare Edit Record: TXT content is like this:<\/p>\n<p><strong><span style=\"color: #ff0000;\">v=DKIM<\/span><\/strong>1; k=rsa; p=MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAv+w6CJDDntA3Zwmk0pf+5q<br \/>\nCnmTE1NxA1zaVCZCtwWsuzPdbxdBpDb9R7lYB0V0zWzUAr8NGvnRsRJzYEZHRy6Gv5fplky15mJBppsy6anSq<br \/>\nU9V\/n8dEUY6kE0BbwTJL0WJqxwlu+CJ8RS1lGl99XacpWl4Dgf0mhDZlv4ViB+hW1Gv9ao\/0aQ+mWNmWzY<br \/>\nLYZ<strong><span style=\"color: #ff0000;\">D29mx0OM<\/span><\/strong>+bwepI1vMyW87mU4i0yi2KMrJRnqOG+lGVJp5qd5ooVpfH0VcHb4HI6ho8phlNa7p\/s4uG4p<br \/>\nNKCXGET5OAr0E+tWE36nAbWIYsUrjTakbc6bBATXnK80tJf7tIf7zxCfIjqPOIZtwNPklQIDA<strong><span style=\"color: #ff0000;\">QAB;<\/span><\/strong><\/p>\n<p>&#8211; Remove quotation mark &#8221; at &#8220;v=DKIM1<br \/>\n&#8211; Remove quotation mark &#8221; at &#8221; 29mx0OM+bwepI1 and should no space.<br \/>\n&#8211; Remove \\ before ; at the end.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>1. Last night, I got complaint from my customer said that their server can&#8217;t send email to some gov agencies. &hellip; <a href=\"https:\/\/matnet.my\/blog\/2017\/03\/dkim-issue-on-cpanel-server-with-cloudflare-dns\/\" class=\"more-link\">More <span class=\"screen-reader-text\">DKIM issue on Cpanel Server with Cloudflare DNS \ud83d\ude41<\/span> <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[6,12],"tags":[],"class_list":["post-244","post","type-post","status-publish","format-standard","hentry","category-bsd-nix","category-cpanel-whm","standard"],"_links":{"self":[{"href":"https:\/\/matnet.my\/blog\/wp-json\/wp\/v2\/posts\/244","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/matnet.my\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/matnet.my\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/matnet.my\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/matnet.my\/blog\/wp-json\/wp\/v2\/comments?post=244"}],"version-history":[{"count":4,"href":"https:\/\/matnet.my\/blog\/wp-json\/wp\/v2\/posts\/244\/revisions"}],"predecessor-version":[{"id":248,"href":"https:\/\/matnet.my\/blog\/wp-json\/wp\/v2\/posts\/244\/revisions\/248"}],"wp:attachment":[{"href":"https:\/\/matnet.my\/blog\/wp-json\/wp\/v2\/media?parent=244"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/matnet.my\/blog\/wp-json\/wp\/v2\/categories?post=244"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/matnet.my\/blog\/wp-json\/wp\/v2\/tags?post=244"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}