{"id":566,"date":"2012-12-19T11:10:48","date_gmt":"2012-12-19T10:10:48","guid":{"rendered":"http:\/\/elkano.org\/blog\/?p=566"},"modified":"2012-12-19T11:12:31","modified_gmt":"2012-12-19T10:12:31","slug":"550-message-does-not-pass-domainkeys-requirements-for-domain","status":"publish","type":"post","link":"https:\/\/elkano.org\/blog\/550-message-does-not-pass-domainkeys-requirements-for-domain\/","title":{"rendered":"550 Message does not pass DomainKeys requirements for domain"},"content":{"rendered":"<p>I got this error from my mail server log when attempting to send a mail to one of our clients: <\/p>\n<pre class=\"dontquote prettyprint lang-xml\">\r\n\/var\/log\/syslog.4.gz:Dec 14 18:13:01 XXXXXX postfix\/smtp[26150]: 01BA812B22C: to=&lt;xxxxx@yyyyy.com&gt;, \r\nrelay=smtp.xxxxxx.com[1.2.3.4]:25, delay=0.11, delays=0.03\/0.01\/0.02\/0.05, dsn=5.0.0,\r\nstatus=bounced (host smtp.xxxxxx.com[1.2.3.4] said: 550 Message does not pass DomainKeys requirements\r\n for domain zzzz.com (in reply to end of DATA command))\r\n<\/pre>\n<p>I&#8217;ve not implemented DomainKeys in my mail servers (but they was in the past), but I noticed that my DNS servers was wrong configured to support this protocol. DomainKeys needs two TXT records, one for the policy and one for the selector.<\/p>\n<p>The policy is set with a TXT record for _domainkey.yourdomain.com, &#8220;o=~;&#8221; means that some mails can be signed and &#8220;o=-;&#8221; means all mails must be signed for domain yourdomain.com. I my case I had to change &#8220;o=-;&#8221; to &#8220;o=~;&#8221; because now, I was not using Domainkeys in my MTAs.<\/p>\n<pre class=\"dontquote prettyprint xml-lang\">\r\n_domainkey                TXT    &quot;o=~;&quot;\r\n<\/pre>\n<p>The selector is implemented with other TXT record, in which you set your public key. According to <a href=\"http:\/\/www.ietf.org\/rfc\/rfc4870.txt\" title=\"rfc4870.txt\" target=\"_blank\">RFC<\/a>:<\/p>\n<blockquote><p> Selectors are arbitrary names below the &#8220;_domainkey.&#8221; namespace.  A selector value<br \/>\n   and length MUST be legal in the DNS namespace and in email headers<br \/>\n   with the additional provision that they cannot contain a semicolon.<\/p><\/blockquote>\n<pre class=\"dontquote prettyprint xml-lang\">\r\nbrisbane._domainkey IN TXT &quot;g=; k=rsa; p=MHww ... IDAQAB&quot;\r\n<\/pre>\n<p>The flags you can set are explained below: <\/p>\n<blockquote><p>g = granularity of the key.  If present with a non-zero length<br \/>\n          value, this value MUST exactly match the local part of the<br \/>\n          sending address.  This tag is optional.<\/p>\n<p>          The intent of this tag is to constrain which sending address<br \/>\n          can legitimately use this selector.  An email with a sending<br \/>\n          address that does not match the value of this tag constitutes<br \/>\n          a failed verification.<\/p>\n<p>      k = key type (rsa is the default).  Signers and verifiers MUST<br \/>\n          support the &#8216;rsa&#8217; key type.  This tag is optional.<\/p>\n<p>      n = Notes that may be of interest to a human.  No interpretation<br \/>\n          is made by any program.  This tag is optional.<\/p>\n<p>      p = public key data, encoded as a Base64 string.  An empty value<br \/>\n          means that this public key has been revoked.  This tag MUST be<br \/>\n          present.<\/p>\n<p>      t = a set of flags that define boolean attributes.  Valid<br \/>\n          attributes are as follows:<\/p>\n<p>          y = testing mode.  This domain is testing DomainKeys and<br \/>\n              unverified email MUST NOT be treated differently from<br \/>\n              verified email.  Recipient systems MAY wish to track<br \/>\n              testing mode results to assist the sender.<\/p>\n<p>          This tag is optional.\n<\/p><\/blockquote>\n<p>For example, valid entries for selectors can be:<\/p>\n<p>      &#8220;coolumbeach._domainkey.example.net&#8221;<br \/>\n      &#8220;sebastopol._domainkey.example.net&#8221;<br \/>\n      &#8220;reykjavik._domainkey.example.net&#8221;<br \/>\n      &#8220;default._domainkey.example.net&#8221;<\/p>\n<p>Here, you can use these links to test if your DNS records are well formed. the first one is to check your policy and the last one to check the selector:<\/p>\n<p><a href=\"http:\/\/domainkeys.sourceforge.net\/policycheck.html\" title=\"http:\/\/domainkeys.sourceforge.net\/policycheck.html\" target=\"_blank\">http:\/\/domainkeys.sourceforge.net\/policycheck.html<\/a><br \/>\n<a href=\"http:\/\/domainkeys.sourceforge.net\/selectorcheck.html\" title=\"http:\/\/domainkeys.sourceforge.net\/selectorcheck.html\" target=\"_blank\">http:\/\/domainkeys.sourceforge.net\/selectorcheck.html<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>I got this error from my mail server log when attempting to send a mail to one of our clients: \/var\/log\/syslog.4.gz:Dec 14 18:13:01 XXXXXX postfix\/smtp[26150]: 01BA812B22C: to=&lt;xxxxx@yyyyy.com&gt;, relay=smtp.xxxxxx.com[1.2.3.4]:25, delay=0.11, delays=0.03\/0.01\/0.02\/0.05, dsn=5.0.0, status=bounced (host smtp.xxxxxx.com[1.2.3.4] said: 550 Message does not pass DomainKeys requirements for domain zzzz.com (in reply to end of DATA command)) I&#8217;ve not implemented [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[3],"tags":[73,74,72],"_links":{"self":[{"href":"https:\/\/elkano.org\/blog\/wp-json\/wp\/v2\/posts\/566"}],"collection":[{"href":"https:\/\/elkano.org\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/elkano.org\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/elkano.org\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/elkano.org\/blog\/wp-json\/wp\/v2\/comments?post=566"}],"version-history":[{"count":20,"href":"https:\/\/elkano.org\/blog\/wp-json\/wp\/v2\/posts\/566\/revisions"}],"predecessor-version":[{"id":587,"href":"https:\/\/elkano.org\/blog\/wp-json\/wp\/v2\/posts\/566\/revisions\/587"}],"wp:attachment":[{"href":"https:\/\/elkano.org\/blog\/wp-json\/wp\/v2\/media?parent=566"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/elkano.org\/blog\/wp-json\/wp\/v2\/categories?post=566"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/elkano.org\/blog\/wp-json\/wp\/v2\/tags?post=566"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}