<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>#!/bin/blog &#187; postfix</title>
	<atom:link href="http://binblog.info/tag/postfix/feed/" rel="self" type="application/rss+xml" />
	<link>http://binblog.info</link>
	<description>&#34;It&#039;s hard to be humble when you&#039;re so fscking big!&#34;</description>
	<lastBuildDate>Wed, 01 Feb 2012 08:05:44 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='binblog.info' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://s2.wp.com/i/buttonw-com.png</url>
		<title>#!/bin/blog &#187; postfix</title>
		<link>http://binblog.info</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://binblog.info/osd.xml" title="#!/bin/blog" />
	<atom:link rel='hub' href='http://binblog.info/?pushpress=hub'/>
		<item>
		<title>Getting the Postfix MTA onto IPv6</title>
		<link>http://binblog.info/2010/09/02/getting-the-postfix-mta-onto-ipv6/</link>
		<comments>http://binblog.info/2010/09/02/getting-the-postfix-mta-onto-ipv6/#comments</comments>
		<pubDate>Thu, 02 Sep 2010 05:45:47 +0000</pubDate>
		<dc:creator>martin</dc:creator>
				<category><![CDATA[Internet]]></category>
		<category><![CDATA[ipv6]]></category>
		<category><![CDATA[postfix]]></category>

		<guid isPermaLink="false">http://binblog.info/?p=1695</guid>
		<description><![CDATA[This is simple. Postfix native IPv6 support was introduced in Version 2.2, which was released around the year 2005. So unless you are running an extremely outdated operating system, your Postfix MTA will be ready for IPv6. (Original Postfix IPv6 docs are here.) The changes required to the Postfix main.cf are extremely basic: # Tell [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=binblog.info&amp;blog=2416043&amp;post=1695&amp;subd=binblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>This is simple. <a href="http://www.postfix.org">Postfix</a> native IPv6 support was introduced in Version 2.2, which was released around the year 2005. So unless you are running an extremely outdated operating system, your Postfix MTA will be ready for IPv6. (Original Postfix IPv6 docs are <a href="http://www.postfix.org/IPV6_README.html">here</a>.)</p>
<p>The changes required to the Postfix <em>main.cf</em> are extremely basic:</p>
<p><code># Tell Postfix to use IPv6:<br />
inet_protocols = ipv4,ipv6<br />
# Add the equivalents to your existing IPv4 setup to mynetworks<br />
mynetworks = 127.0.0.1/32 1.2.3.0/24 [::1]/128 [2001:db8:dead:beef::]/64<br />
# This will be required if you need to override an autoconfed address<br />
# (for outbound connections):<br />
smtp_bind_address6=2001:db8:dead:beef::deca:fbad</code></p>
<p>After this, stop and start Postfix. A <em>postfix reload</em> alone will not bind to the new IPv6 interface.</p>
<p>After local testing, set up an additional <em>AAAA</em> record for your mailexchanger:</p>
<p><code>&nbsp;&nbsp; MX    10 mx.example.com.<br />
mx A     1.2.3.2<br />
; The new record:<br />
mx AAAA 2001:db8:dead:beef::deca:fbad</code></p>
<p><em>Don&#8217;t forget that you must, as always, set up proper forward and reverse DNS for your MX. Implement this at the same risk as if you were moving to a new IPv4 address.</em></p>
<p>Not long after the AAAA record is in place, you should see the spambots trying to deliver mail via IPv6, and Postfix will start to use IPv6 for outbound e-mail automatically if it can find a remote IPv6 MX. Which will be the case rather sooner than later. </p>
<p>See? You may still be an early adopter now, but you surely aren&#8217;t a pioneer living on the most remote corner of the net. I, for one, now have customers who use proper IPv6 e-mail without even knowing. <img src='http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/binblog.wordpress.com/1695/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/binblog.wordpress.com/1695/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/binblog.wordpress.com/1695/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/binblog.wordpress.com/1695/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/binblog.wordpress.com/1695/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/binblog.wordpress.com/1695/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/binblog.wordpress.com/1695/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/binblog.wordpress.com/1695/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/binblog.wordpress.com/1695/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/binblog.wordpress.com/1695/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/binblog.wordpress.com/1695/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/binblog.wordpress.com/1695/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/binblog.wordpress.com/1695/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/binblog.wordpress.com/1695/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=binblog.info&amp;blog=2416043&amp;post=1695&amp;subd=binblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://binblog.info/2010/09/02/getting-the-postfix-mta-onto-ipv6/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="" medium="image">
			<media:title type="html">martin</media:title>
		</media:content>
	</item>
		<item>
		<title>Debian VMware woes</title>
		<link>http://binblog.info/2009/05/16/debian-vmware-woes/</link>
		<comments>http://binblog.info/2009/05/16/debian-vmware-woes/#comments</comments>
		<pubDate>Sat, 16 May 2009 07:28:11 +0000</pubDate>
		<dc:creator>martin</dc:creator>
				<category><![CDATA[UNIX & Linux]]></category>
		<category><![CDATA[debian]]></category>
		<category><![CDATA[iowait]]></category>
		<category><![CDATA[postfix]]></category>
		<category><![CDATA[smtp]]></category>
		<category><![CDATA[vmware]]></category>

		<guid isPermaLink="false">http://binblog.wordpress.com/?p=617</guid>
		<description><![CDATA[Had some trouble with Debian in VMware Server 2.0: I/O was horribly slow, 100% IOwait when doing the simplest things, hdparm showing 11MB/s throughput. This was fixed by shutting down the VM, changing the SCSI adapter from Buslogic to LSI logic and booting up again. hdparm is at 63MB/s now. The machine, which will be [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=binblog.info&amp;blog=2416043&amp;post=617&amp;subd=binblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Had some trouble with Debian in VMware Server 2.0: I/O was horribly slow, 100% IOwait when doing the simplest things, hdparm showing 11MB/s throughput.</p>
<p>This was fixed by shutting down the VM, changing the SCSI adapter from Buslogic to LSI logic and booting up again. hdparm is at 63MB/s now. The machine, which will be an SMTP mail exchanger, now scans 8 mails per second (<a href="http://www.postfix.org/SMTPD_PROXY_README.html">Postfix before-queue filter</a> via amavisd-new+ClamAV) in 10 concurrent sessions. Not bad at all.</p>
<p>Debian is by far the simplest choice for an SMTP content filter because it&#8217;s not neccessary to bring in any dependencies by hand. Cool. <img src='http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/binblog.wordpress.com/617/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/binblog.wordpress.com/617/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/binblog.wordpress.com/617/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/binblog.wordpress.com/617/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/binblog.wordpress.com/617/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/binblog.wordpress.com/617/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/binblog.wordpress.com/617/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/binblog.wordpress.com/617/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/binblog.wordpress.com/617/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/binblog.wordpress.com/617/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/binblog.wordpress.com/617/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/binblog.wordpress.com/617/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/binblog.wordpress.com/617/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/binblog.wordpress.com/617/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=binblog.info&amp;blog=2416043&amp;post=617&amp;subd=binblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://binblog.info/2009/05/16/debian-vmware-woes/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="" medium="image">
			<media:title type="html">martin</media:title>
		</media:content>
	</item>
		<item>
		<title>&#8220;Attempted master login with no master passdbs&#8221;</title>
		<link>http://binblog.info/2008/02/10/attempted-master-login-with-no-master-passdbs/</link>
		<comments>http://binblog.info/2008/02/10/attempted-master-login-with-no-master-passdbs/#comments</comments>
		<pubDate>Sun, 10 Feb 2008 06:31:16 +0000</pubDate>
		<dc:creator>martin</dc:creator>
				<category><![CDATA[UNIX & Linux]]></category>
		<category><![CDATA[auth]]></category>
		<category><![CDATA[bug]]></category>
		<category><![CDATA[dovecot]]></category>
		<category><![CDATA[postfix]]></category>
		<category><![CDATA[sasl]]></category>

		<guid isPermaLink="false">http://binblog.wordpress.com/?p=44</guid>
		<description><![CDATA[If you get this under some conditions while using dovecot for SASL authentication from the Postfix MTA, you&#8217;re using an outdated pre-release version of dovecot, like e.g. 1.0.rc15. This specific version is still included not only in CentOS and RHEL 5 but also in Debian 4.0 (etch). The error is caused by a bug that [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=binblog.info&amp;blog=2416043&amp;post=44&amp;subd=binblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>If you get this under some conditions while using <a href="http://www.dovecot.org">dovecot</a> for SASL authentication from the Postfix MTA, you&#8217;re using an outdated pre-release version of dovecot, like e.g. 1.0.rc15. This specific version is still included not only in CentOS and RHEL 5 but also in Debian 4.0 (etch). The error is caused by a bug that was already <a href="http://www.mailinglistarchive.com/dovecot@dovecot.org/msg09688.html">fixed</a> in later pre-release versions.</p>
<p>I replaced the stock rpm from CentOS 5 with the current released <a href="http://www.atrpms.net/dist/el5/dovecot/">dovecot 1.0.10 rpm from atrpms.net</a>, which instantly fixed the problem. </p>
<p>Packages of dovecot 1.0.10 for Debian are <a href="http://packages.debian.org/search?lang=en&amp;suite=etch-backports&amp;searchon=names&amp;keywords=dovecot">available from backports.org</a>.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/binblog.wordpress.com/44/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/binblog.wordpress.com/44/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/binblog.wordpress.com/44/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/binblog.wordpress.com/44/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/binblog.wordpress.com/44/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/binblog.wordpress.com/44/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/binblog.wordpress.com/44/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/binblog.wordpress.com/44/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/binblog.wordpress.com/44/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/binblog.wordpress.com/44/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/binblog.wordpress.com/44/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/binblog.wordpress.com/44/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/binblog.wordpress.com/44/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/binblog.wordpress.com/44/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/binblog.wordpress.com/44/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/binblog.wordpress.com/44/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=binblog.info&amp;blog=2416043&amp;post=44&amp;subd=binblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://binblog.info/2008/02/10/attempted-master-login-with-no-master-passdbs/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="" medium="image">
			<media:title type="html">martin</media:title>
		</media:content>
	</item>
		<item>
		<title>Postfix 2.5.0</title>
		<link>http://binblog.info/2008/01/25/postfix-250/</link>
		<comments>http://binblog.info/2008/01/25/postfix-250/#comments</comments>
		<pubDate>Fri, 25 Jan 2008 06:22:17 +0000</pubDate>
		<dc:creator>martin</dc:creator>
				<category><![CDATA[Security]]></category>
		<category><![CDATA[mail]]></category>
		<category><![CDATA[postfix]]></category>
		<category><![CDATA[smtp]]></category>
		<category><![CDATA[tls]]></category>

		<guid isPermaLink="false">http://binblog.wordpress.com/?p=28</guid>
		<description><![CDATA[Seit heute ist die Version 2.5.0 des Postfix-MTA verfügbar. Das Feature, das mich am meisten interessiert, ist die Möglichkeit der Validierung von Serverzertifikaten anhand des Fingerprint. Aus dem Changelog: TLS (SSL) support was streamlined further, and provides a new security level based on certificate fingerprints instead of CA signatures. Wo man vorher bei der Mailauslieferung [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=binblog.info&amp;blog=2416043&amp;post=28&amp;subd=binblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Seit heute ist die Version 2.5.0 des <a href="http://www.postfix.org">Postfix-MTA</a> verfügbar. Das Feature, das mich am meisten interessiert, ist die Möglichkeit der <a href="http://www.postfix.org/TLS_README.html#client_tls_fprint">Validierung von Serverzertifikaten anhand des Fingerprint</a>.</p>
<p>Aus dem Changelog:</p>
<blockquote><p><i>TLS (SSL) support was streamlined further, and provides a new<br />
security level based on certificate fingerprints instead of CA<br />
signatures.</i></p></blockquote>
<p>Wo man vorher bei der Mailauslieferung über Einträge in <em>tls_policy_maps</em> geprüft hat, ob das gegnerische Zertifikat von einer bekannten CA signiert ist und auf einen Common Name aus einer bestimmten Domain ausgestellt ist:</p>
<p><code>example.com secure match=example.net</code></p>
<p>kann man nun auch selbstsignierte Zertifikate verwenden (oder Zertifikate, die von einer CA ausgestellt sind, mit deren Zertifizierungspolicy man nicht einverstanden ist) und den Fingerprint prüfen:</p>
<p><code>example.com fingerprint<br />
&nbsp;&nbsp;match=3D:95:34:51:24:66:33:B9:D2:40:99:C0:C1:17:0B:D1</code></p>
<p>Alle anderen Attribute des Zertifikats (insbesondere das Ablaufdatum) werden damit ignoriert.</p>
<p>Aus der Doku:</p>
<blockquote><p><i>If certificate fingerprints are exchanged securely, this is the strongest, and least scalable security level. [...] This may be feasible for an SMTP &#8220;VPN&#8221; connecting a small number of branch offices over the Internet, or for secure connections to a central mail hub. It works poorly if the remote SMTP server is managed by a third party, and its public certificate changes periodically without prior coordination with the verifying site.</i></p></blockquote>
<p>Ich finde es wirklich ulkig, daß hier von einem SMTP-VPN die Rede ist. Genau diesen treffenden Vergleich hat nämlich auch mal ein Kunde konstruiert, der im großen Maßstab <a href="http://www.postfix.org/TLS_README.html#client_tls_secure">Secure Channel TLS</a> einsetzt, um den Internet-Mailtraffic mit seinen Partnern abzusichern.</p>
<p>Für die Verwendung im &#8220;Enterprise-Bereich&#8221; sollte die Prüfung von Fingerprints aber in der Tat trotz des objektiv zu gewinnenden Sicherheitsvorteils genau auf den Prüfstand gestellt werden. Schlampig arbeitende Gegenstellen mit Snake-Oil-Zertifikaten werden damit nämlich möglicherweise erst recht zu weiterhin schlampiger Arbeit angehalten. </p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/binblog.wordpress.com/28/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/binblog.wordpress.com/28/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/binblog.wordpress.com/28/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/binblog.wordpress.com/28/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/binblog.wordpress.com/28/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/binblog.wordpress.com/28/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/binblog.wordpress.com/28/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/binblog.wordpress.com/28/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/binblog.wordpress.com/28/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/binblog.wordpress.com/28/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/binblog.wordpress.com/28/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/binblog.wordpress.com/28/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/binblog.wordpress.com/28/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/binblog.wordpress.com/28/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/binblog.wordpress.com/28/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/binblog.wordpress.com/28/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=binblog.info&amp;blog=2416043&amp;post=28&amp;subd=binblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://binblog.info/2008/01/25/postfix-250/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="" medium="image">
			<media:title type="html">martin</media:title>
		</media:content>
	</item>
		<item>
		<title>Postfix 2.3: Abgehend Server-Zertifikate prüfen</title>
		<link>http://binblog.info/2007/03/10/postfix-23-abgehend-server-zertifikate-prufen/</link>
		<comments>http://binblog.info/2007/03/10/postfix-23-abgehend-server-zertifikate-prufen/#comments</comments>
		<pubDate>Sat, 10 Mar 2007 21:59:15 +0000</pubDate>
		<dc:creator>martin</dc:creator>
				<category><![CDATA[Internet]]></category>
		<category><![CDATA[mail]]></category>
		<category><![CDATA[postfix]]></category>
		<category><![CDATA[smtp]]></category>
		<category><![CDATA[ssl]]></category>
		<category><![CDATA[tls]]></category>

		<guid isPermaLink="false">http://binblog.de/2007/03/10/postfix-23-abgehend-server-zertifikate-prufen/</guid>
		<description><![CDATA[Ausgangslage: Ein Internet-Mailgateway unter Postfix 2.3 soll ganz normal Mail an beliebige Gegenstellen im Internet ausliefern. Für bestimmte Zieldomains soll sichergestellt werden, daß Mails dorthin ausschließlich TLS-verschlüsselt übertragen werden. Hier die Basiskonfiguration für TLS, ein Auszug aus der main.cf: # TLS grundsätzlich deaktivieren, Aktivierung erfolgt dann fallweise. smtp_tls_security_level = none # Auch wenn wir selbst [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=binblog.info&amp;blog=2416043&amp;post=1451&amp;subd=binblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Ausgangslage: Ein Internet-Mailgateway unter Postfix 2.3 soll ganz normal Mail an beliebige Gegenstellen im Internet ausliefern. Für bestimmte Zieldomains soll sichergestellt werden, daß Mails dorthin ausschließlich TLS-verschlüsselt übertragen werden.</p>
<p>Hier die Basiskonfiguration für TLS, ein Auszug aus der <em>main.cf</em>:<br />
<code># TLS grundsätzlich deaktivieren, Aktivierung erfolgt dann fallweise.<br />
smtp_tls_security_level = none<br />
# Auch wenn wir selbst kein TLS machen, wollen wir loggen, wenn<br />
# Gegenstellen TLS anbieten.<br />
smtp_tls_note_starttls_offer = yes<br />
# Apropos Log; standardmäßig loggt Postfix überhaupt keine Infos zu<br />
# TLS-Transaktionen.<br />
smtp_tls_loglevel = 1<br />
# In dieser Map tragen wir die Gegenstellen ein, mit denen wir nur per<br />
# TLS kommunizieren wollen.<br />
smtp_tls_policy_maps = hash:/etc/postfix/tls_policy<br />
# Und in diesem Verzeichnis sind die Zertifikate enthalten, von denen<br />
# die Zertifikate der Gegenstellen signiert sein müssen, um als akzeptabel<br />
# zu gelten.<br />
smtp_tls_CApath = /etc/postfix/tls/cacerts.d</code></p>
<p>Zu beachten ist, daß die im <em>smtp_tls_CApath</em> hinterlegten Zertifikate vor Verwendung gehasht werden müssen. Dafür wird das Perl-Script <em>c_rehash</em> aus der OpenSSL-Distribution verwendet.</p>
<p><code>c_rehash `postconf -h smtp_tls_CApath`</code></p>
<p>(Falls der <em>smtp</em>-Client im chroot läuft, müssen die Zertifikate und die Links mit den Hashwerten dort ebenfalls vorhanden sein. Man kann das z.B. erreichen, indem man die Zertifikate in <em>/var/spool/postfix/etc/postfix/tls/cacerts.d/</em> ablegt und das Verzeichnis dann per Symlink aus <em>/etc/postfix/tls/</em> erreichbar macht. Oder man legt einen entsprechenden Kopierjob an. Der Fantasie des Lesers sind keine Grenzen gesetzt.)</p>
<p>Wie intensiv die Zertifikate bei abgehenden Verbindungen geprüft werden sollen, wird mittels <em>smtp_tls_security_level</em> festgelegt. Darüberhinaus können in der über <em>smtp_tls_policy_maps</em> referenzierten Datei <em>/etc/postfix/tls_policy</em> pro Zieldomain abweichende Policies definiert werden. Es lassen sich eine ganze Menge &#8220;Sicherheitsstufen&#8221; einstellen:</p>
<ul>
<li /><strong>none</strong>: Es wird generell nicht verschlüsselt. Wenn der gegnerische Mailserver seine Verschlüsselungsbereitschaft anzeigt (STARTTLS im ESMTP-Greeting), wird dies ignoriert.</p>
<li /><strong>may</strong>: Wenn der gegenerische Mailserver STARTTLS anbietet, wird verschlüsselt, wenn nicht, dann nicht.
<li /><strong>encrypt</strong>: Die Mail wird nur übertragen, wenn der gegnerische Mailserver STARTTLS anbietet und eine Verschlüsselung aufgebaut werden kann. Eine Prüfung des Server-Zertifikats findet nicht statt. Selbstsignierte Zertifikate werden akzeptiert.
<li /><strong>verify</strong>: Die Mail wird nur übertragen, wenn der gegnerische Server ein Zertifikat benutzt, das von einer CA ausgestellt wurde, deren Zertifikat im mit <em>smtp_tls_CApath</em> angegebenen Pfad enthalten ist.
<li /><strong>secure</strong>: Die Mail wird nur übertragen, wenn der gegnerische Server ein Zertifikat benutzt, das von einer CA ausgestellt wurde, deren Zertifikat im mit <em>smtp_tls_CApath</em> angegebenen Pfad enthalten ist und bei dem der im Zertifikat eingetragene Common Name mit der Zieldomain übereinstimmt.</ul>
<p>Als Default-Policy (<em>smtp_tls_security_level</em>) eignen sich ausschließlich <em>&#8220;none&#8221;</em> und <em>&#8220;may&#8221;</em>, denn mit <em>&#8220;encrypt&#8221;</em> und aufwärts wird man ein Gateway, das Mail ins Internet senden soll, nicht betreiben können. Ich habe mich im vorliegenden Fall für <em>&#8220;none&#8221;</em> entschieden, da ich in der von <em>&#8220;may&#8221;</em> gebotenen opportunistischen Verschlüsselung keinen Nutzen erkenne. Im Gegenteil: Opportunistische Verschlüsselung kostet mich nicht nur Rechenzeit, sondern es besteht potentiell die Gefahr, daß Probleme bei der Kommunikation mit MTAs auftreten, bei denen TLS fehlerhaft konfiguriert und/oder implementiert ist.</p>
<p>Nun zu den Zielen, mit denen wir verschlüsselt kommunizieren wollen. Wenn man davon ausgeht, daß keine Verschlüsselung besser ist als schlechte Verschlüsselung, kann man die Optionen <em>&#8220;may&#8221;</em> und <em>&#8220;encrypt&#8221;</em> in diesem Zusammenhang direkt vergessen:</p>
<ul>
<li />Die opportunistische Verschlüsselung <em>&#8220;may&#8221; </em>bringt keinerlei Sicherheitsgewinn.</p>
<li />Kaum etwas anderes gilt für <em>&#8220;encrypt&#8221;</em>: Für eine Gegenstelle Verschlüsselung zu erzwingen und dann jedes Zertifikat, egal ob abgelaufen oder selbstsigniert, zu akzeptieren, ist nur die Illusion von Sicherheit, gerade so, als würde man das routinemäßige Abklicken von SSL-Warnungen im WWW-Browser zum Standard erheben.</ul>
<p>Übrig bleiben also <em>&#8220;verify&#8221; </em>und <em>&#8220;secure&#8221;</em>, von denen die letztere natürlich ganz besonders verlockend klingt und es auch ist:</p>
<ul>
<li />Mit <em>&#8220;verify&#8221;</em> wird erzwungen, daß Mail an eine Gegenstelle nur dann ausgeliefert wird, wenn deren Zertifikat von einer bekannten CA signiert wurde.</p>
<li />Mit <em>&#8220;secure&#8221;</em> wird nicht nur, wie bei <em>&#8220;verify&#8221;</em>, das Zertifikat überprüft, sondern es wird auch noch verlangt, daß der Common Name des gegnerischen Zertifikats der Zieldomain entspricht. Alternativ kann auch eine Liste von Host- und Domainnamen angegeben werden, die als Common Names für die Zieldomain akzeptabel sind.</ul>
<p>Hier also ein paar Beispiele für Einträge in der <em>tls_policy</em>.</p>
<ul>
<li />Für die Domain <em>binblog.de</em> soll uns eine einfache Überprüfung des Zertifikats reichen:<br />
<code>binblog.de verify</code></p>
<li />Die Mailexchanger der Domain <em>example.com</em> liegen alle in <em>example.com</em> (<em>mx1.example.com</em> und <em>mx2.example.com</em>), und wir wollen nur Zertifikate akzeptieren, die auf einen Hostnamen (Common Name) unter <em>example.com</em> ausgestellt sind:<br />
<code>example.com secure</code></p>
<li />Der Mailexchanger der Domain <em>scsy.de</em> hat den Namen <em>vortex.f00.net</em>. In diesem Fall müssen wir, wenn wir den Common Name überprüfen wollen, extra dazusagen, in welcher Domain er liegen bzw. welchen Namen er haben soll:<br />
<code>scsy.de secure match=vortex.f00.net</code></ul>
<p>Mit der in den letzten beiden Beispielen genannten &#8220;sicheren&#8221; Überprüfung von Zertifikaten stellen wir so weit wie möglich sicher, daß wir gegen DNS-Angriffe geschützt sind: Wird uns ein gefälschter MX-Record untergeschoben, weigert sich Postfix, Mail an diesen auszuliefern. Wechselt die Domain den Besitzer und bekommt neue Mailexchanger, weigert sich Postfix ebenfalls, Mail dorthin auszuliefern, solange nicht entsprechende Konfigurationsänderungen in der TLS Policy vorgenommen werden.</p>
<p>Wenn Postfix aufgrund einer Umstellung auf einer der Gegenseiten keine Mail ausliefern kann, werden die Mails übrigens nicht gebounced, sondern im Rahmen der normalen Timeouts in der Queue behalten. Es bleibt also genügend Gelegenheit, auf Überwachungen oder Useranrufe zu reagieren.</p>
<p>Diese gesamte Konfigurationsmethodik wurde von Postfix 2.2 zu Postfix 2.3 komplett ausgetauscht. Leider ist 2.3 bisher nur zu den wenigsten Distributionen durchgedrungen. Die Implementation in 2.3 ist aber so gelungen ausgefallen, daß ich jedem, der sich auf diese Ebene begeben will, nur zum Upgrade raten kann.</p>
<p>Wer das alles viel zu überkandidelt findet: Die übernächste Postfix-Version, 2.5, wird voraussichtlich sogar die Möglichkeit haben, gezielt die Fingerprints von Zertifikaten pro Zieldomain anzugeben. Damit dürfte dann wirklich das allerletzte DNS-Schlupfloch gestopft sein, und gleichzeitig können selbstsignierte Zertifikate verwendet werden.</p>
<p><b>Update am 21.3.:</b> Hoffentlich werden hier jetzt keine Unwahrheiten mehr verbreitet. <img src='http://s1.wp.com/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' /> </p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/binblog.wordpress.com/1451/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/binblog.wordpress.com/1451/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/binblog.wordpress.com/1451/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/binblog.wordpress.com/1451/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/binblog.wordpress.com/1451/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/binblog.wordpress.com/1451/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/binblog.wordpress.com/1451/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/binblog.wordpress.com/1451/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/binblog.wordpress.com/1451/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/binblog.wordpress.com/1451/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/binblog.wordpress.com/1451/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/binblog.wordpress.com/1451/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/binblog.wordpress.com/1451/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/binblog.wordpress.com/1451/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/binblog.wordpress.com/1451/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/binblog.wordpress.com/1451/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=binblog.info&amp;blog=2416043&amp;post=1451&amp;subd=binblog&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://binblog.info/2007/03/10/postfix-23-abgehend-server-zertifikate-prufen/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="" medium="image">
			<media:title type="html">martin</media:title>
		</media:content>
	</item>
	</channel>
</rss>
