<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[iRedMail — DKIM signing for multiple virtual domains?]]></title>
		<link>http://www.iredmail.org/forum/topic130-dkim-signing-for-multiple-virtual-domains.html</link>
		<atom:link href="http://www.iredmail.org/forum/feed-rss-topic130.xml" rel="self" type="application/rss+xml" />
		<description><![CDATA[The most recent posts in DKIM signing for multiple virtual domains?.]]></description>
		<lastBuildDate>Sat, 18 Jul 2009 03:38:34 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Re: DKIM signing for multiple virtual domains?]]></title>
			<link>http://www.iredmail.org/forum/post691.html#p691</link>
			<description><![CDATA[<p>hmm, Why not just give it a try?</p>]]></description>
			<author><![CDATA[null@example.com (ZhangHuangbin)]]></author>
			<pubDate>Sat, 18 Jul 2009 03:38:34 +0000</pubDate>
			<guid>http://www.iredmail.org/forum/post691.html#p691</guid>
		</item>
		<item>
			<title><![CDATA[Re: DKIM signing for multiple virtual domains?]]></title>
			<link>http://www.iredmail.org/forum/post688.html#p688</link>
			<description><![CDATA[<div class="codebox"><pre><code># setfacl -m u:amavis:r-- mydefaultdomain.net.pem</code></pre></div><p>Sweet, that worked great.</p><div class="quotebox"><blockquote><p>Just make sure you have one &#039;dkim_key()&#039;, and it will use it as default DKIM pem.</p></blockquote></div><p>So was I right about the following code?</p><div class="codebox"><pre><code>&#039;dkim_key(&quot;.&quot;, &quot;dkim&quot;, &quot;/var/lib/dkim/mydefaultdomain.net.pem&quot;);&#039;</code></pre></div><p>As long as I replace a specific signing domain with &quot;.&quot; it will sign all emails from all domains?</p><p>Thanks again for all your help.</p>]]></description>
			<author><![CDATA[null@example.com (Steve)]]></author>
			<pubDate>Fri, 17 Jul 2009 18:32:04 +0000</pubDate>
			<guid>http://www.iredmail.org/forum/post688.html#p688</guid>
		</item>
		<item>
			<title><![CDATA[Re: DKIM signing for multiple virtual domains?]]></title>
			<link>http://www.iredmail.org/forum/post682.html#p682</link>
			<description><![CDATA[<div class="quotebox"><cite>Steve wrote:</cite><blockquote><p>&#039;-rw-r-----+&nbsp; 1 root&nbsp; &nbsp;root&nbsp; &nbsp; 887 Jul 14 16:43 mydefaultdomain.net.pem&#039;</p></blockquote></div><p>Please use &#039;getfacl&#039; command to check advance access control:<br /></p><div class="codebox"><pre><code># getfacl mydefaultdomain.net.pem</code></pre></div><div class="quotebox"><blockquote><p>So I am looking for THE magic chmod command to fix permissions for any sites I add and still have a secure file.</p></blockquote></div><p>For security reason, it&#039;s not a good idea to make it world-readable, so we restrict it like this:<br /></p><div class="codebox"><pre><code># setfacl -m u:amavis:r-- mydefaultdomain.net.pem</code></pre></div><p>You can search &#039;setfacl&#039; in iRedMail-x.y.z/functions/amavisd.sh.</p><div class="quotebox"><blockquote><p>In regards to the catchall signing of every outgoing email by default I assume you are referring the last line in the &#039;/etc/amavisd.conf&#039; file that says the following?</p><p>&#039;&nbsp; &nbsp; # catchall defaults<br />&nbsp; &nbsp; &#039;.&#039; =&gt; { a =&gt; &#039;rsa-sha256&#039;, c =&gt; &#039;relaxed/simple&#039;, ttl =&gt; 30*24*3600 },&#039;</p><p>This line doesn&#039;t seem to be pointing to a key file like the &#039;dkim_key&#039; line does. So would I still need to add a line similar to the following?</p><p>&#039;dkim_key(&quot;.&quot;, &quot;dkim&quot;, &quot;/var/lib/dkim/mydefaultdomain.net.pem&quot;);&#039;</p><p>Then comment out the one that was created by the install script?</p><p>&#039;dkim_key(&quot;mydefaultdomain.net&quot;, &quot;dkim&quot;, &quot;/var/lib/dkim/mydefaultdomain.net.pem&quot;);&#039;</p><p>Thank you for you assistance with these issues.</p></blockquote></div><p>Just make sure you have one &#039;dkim_key()&#039;, and it will use it as default DKIM pem.</p>]]></description>
			<author><![CDATA[null@example.com (ZhangHuangbin)]]></author>
			<pubDate>Fri, 17 Jul 2009 07:08:07 +0000</pubDate>
			<guid>http://www.iredmail.org/forum/post682.html#p682</guid>
		</item>
		<item>
			<title><![CDATA[Re: DKIM signing for multiple virtual domains?]]></title>
			<link>http://www.iredmail.org/forum/post676.html#p676</link>
			<description><![CDATA[<p>Ok, I got everything to work after adding separate &#039;dkim_key&#039; lines to the &#039;/etc/amavisd.conf&#039; file and creating my own keys by running the following command:</p><p>&#039;amavisd genrsa /var/lib/dkim/mydomain1.com.pem&#039;</p><p>I had issues with the default permissions though.</p><p>This first site is the default site that the install script asked for when setting up this box initially. I can&#039;t seem to find any documentation on how to duplicate these permission. The plus sign throws me off here.</p><p>&#039;-rw-r-----+&nbsp; 1 root&nbsp; &nbsp;root&nbsp; &nbsp; 887 Jul 14 16:43 mydefaultdomain.net.pem&#039;</p><p>When I run the &#039;amavisd genrsa&#039; command I get the following permission set and when I add the appropriate lines in the &#039;/etc/amavisd.conf&#039; file and restart the amavisd service, it will not come back up complaining about permissions.</p><p>&#039;-rw-------&nbsp; &nbsp;1 root&nbsp; &nbsp;root&nbsp; &nbsp; 891 Jul 16 00:56 mydomain1.com.pem&#039;</p><p>A third site I have set up on the system works after doing a:</p><p>&#039;chmod 777 mydomain2.com.pem&#039; </p><p>resulting in the following:</p><p>&#039;-rwxrwxrwx&nbsp; &nbsp;1 root&nbsp; &nbsp;root&nbsp; &nbsp; 887 Jul 15 15:06 mydomain2.com.pem&#039;</p><p>So I am looking for THE magic chmod command to fix permissions for any sites I add and still have a secure file.</p><br /><p>In regards to the catchall signing of every outgoing email by default I assume you are referring the last line in the &#039;/etc/amavisd.conf&#039; file that says the following?</p><p>&#039;&nbsp; &nbsp; # catchall defaults<br />&nbsp; &nbsp; &#039;.&#039; =&gt; { a =&gt; &#039;rsa-sha256&#039;, c =&gt; &#039;relaxed/simple&#039;, ttl =&gt; 30*24*3600 },&#039;</p><p>This line doesn&#039;t seem to be pointing to a key file like the &#039;dkim_key&#039; line does. So would I still need to add a line similar to the following?</p><p>&#039;dkim_key(&quot;.&quot;, &quot;dkim&quot;, &quot;/var/lib/dkim/mydefaultdomain.net.pem&quot;);&#039;</p><p>Then comment out the one that was created by the install script?</p><p>&#039;dkim_key(&quot;mydefaultdomain.net&quot;, &quot;dkim&quot;, &quot;/var/lib/dkim/mydefaultdomain.net.pem&quot;);&#039;</p><p>Thank you for you assistance with these issues.</p>]]></description>
			<author><![CDATA[null@example.com (Steve)]]></author>
			<pubDate>Thu, 16 Jul 2009 15:20:33 +0000</pubDate>
			<guid>http://www.iredmail.org/forum/post676.html#p676</guid>
		</item>
		<item>
			<title><![CDATA[Re: DKIM signing for multiple virtual domains?]]></title>
			<link>http://www.iredmail.org/forum/post669.html#p669</link>
			<description><![CDATA[<div class="quotebox"><cite>Steve wrote:</cite><blockquote><p>DKIM signing works great for my default domain. I&#039;m sure I&#039;ve missed something but what is the &quot;correct&quot; way of signing emails from multiple virtual domains?</p></blockquote></div><p>You can use a catchall or a per-domain signing, both are &#039;correct&#039;.</p><div class="quotebox"><blockquote><p>So far it doesn&#039;t seem obvious how to do this. The two parts to the equation that I can see so far are that I need new key files in /var/lib/dkim/ and the /etc/amavisd.conf file needs to be modified.</p></blockquote></div><p>It uses catchall signing by default, and you must add all your domains in &#039;local_domains_maps&#039; (/etc/amavisd.conf).</p><div class="quotebox"><blockquote><p>Is there a simple command that I can run to add other keys and that adds the new config lines to the appropriate files?</p></blockquote></div><p>No.</p>]]></description>
			<author><![CDATA[null@example.com (ZhangHuangbin)]]></author>
			<pubDate>Thu, 16 Jul 2009 02:07:30 +0000</pubDate>
			<guid>http://www.iredmail.org/forum/post669.html#p669</guid>
		</item>
		<item>
			<title><![CDATA[DKIM signing for multiple virtual domains?]]></title>
			<link>http://www.iredmail.org/forum/post664.html#p664</link>
			<description><![CDATA[<p>DKIM signing works great for my default domain. I&#039;m sure I&#039;ve missed something but what is the &quot;correct&quot; way of signing emails from multiple virtual domains? It appears I can use the same key or use a catchall in the amavisd.conf file to sign ALL outgoing emails. But what are the best practices for DKIM signing in this situation? </p><p>So far it doesn&#039;t seem obvious how to do this. The two parts to the equation that I can see so far are that I need new key files in /var/lib/dkim/ and the /etc/amavisd.conf file needs to be modified. Is there a simple command that I can run to add other keys and that adds the new config lines to the appropriate files? </p><p>Or was there a different way to set up the box initially that would have done all this for me for multiple domains?</p>]]></description>
			<author><![CDATA[null@example.com (Steve)]]></author>
			<pubDate>Wed, 15 Jul 2009 17:12:17 +0000</pubDate>
			<guid>http://www.iredmail.org/forum/post664.html#p664</guid>
		</item>
	</channel>
</rss>
