<?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/"
	>

<channel>
	<title>ra23.net</title>
	<atom:link href="http://ra23.net/wop/feed/" rel="self" type="application/rss+xml" />
	<link>http://ra23.net/wop</link>
	<description>Just another WordPress weblog</description>
	<lastBuildDate>Mon, 08 Mar 2010 18:14:22 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Mumble Online User anzeigen</title>
		<link>http://ra23.net/wop/2010/03/mumble-online-user-anzeigen/</link>
		<comments>http://ra23.net/wop/2010/03/mumble-online-user-anzeigen/#comments</comments>
		<pubDate>Mon, 08 Mar 2010 18:07:45 +0000</pubDate>
		<dc:creator>Andre Rein</dc:creator>
				<category><![CDATA[mumble]]></category>
		<category><![CDATA[baum]]></category>
		<category><![CDATA[grid]]></category>
		<category><![CDATA[tree]]></category>

		<guid isPermaLink="false">http://ra23.net/wop/?p=33</guid>
		<description><![CDATA[Die Ausgabe von Kanälen in Mumble ist Anfangs leicht verwirrend, da ich im Netz keine Anleitung gefunden habe, wie man so eine Anzeige generiert,
hier eine kleine Einstiegshilfe. Dazu sollte ich noch sagen, das es um die Darstellung der Kanäle/Benutzer in einer Baumstruktur geht.
Die Kanäle/Benutzer einfach in einer Anzeige-Ebene als HTML ausgeben, stellt kein Problem dar. [...]]]></description>
			<content:encoded><![CDATA[<p>Die Ausgabe von Kanälen in Mumble ist Anfangs leicht verwirrend, da ich im Netz keine Anleitung gefunden habe, wie man so eine Anzeige generiert,<br />
hier eine kleine Einstiegshilfe. Dazu sollte ich noch sagen, das es um die Darstellung der Kanäle/Benutzer in einer Baumstruktur geht.<br />
Die Kanäle/Benutzer einfach in einer Anzeige-Ebene als HTML ausgeben, stellt kein Problem dar. Dafür sind Funktionen vorhanden.</p>
<p>Es geht hier explizit um die Darstellung, die die Tiefe der Kanäle und der Benutzer beachtet und demnach ausgibt:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #666666; font-style: italic;">#root-channel
</span>  <span style="color: #339933;">-</span>subchannel1
  <span style="color: #339933;">-</span>subchannel2
    <span style="color: #339933;">-</span> subsubchannel21
      o User1
      o User2
  <span style="color: #339933;">-</span>subchannel3</pre></div></div>

<p>Mumble verwendet eine Schnittstelle mit dem Namen Ice, die in PHP registriert sein muss.</p>
<p>Unter Debian benötigt man das Paket &#8220;php-zeroc-ice&#8221;<br />
Aktiviert wird das ganze unter: /etc/php5/conf.d/IcePHP.ini</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;">extension <span style="color: #339933;">=</span> IcePHP<span style="color: #339933;">.</span>so</pre></div></div>

<p>In der Konfigurationsdatei von php, gibt man den Link zu Murmur.ice ein. (Ist im Serverdownload enthalten)</p>
<p>php.ini</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;">ice<span style="color: #339933;">.</span>slice<span style="color: #339933;">=/</span>pfad<span style="color: #339933;">/</span>zu<span style="color: #339933;">/</span>Murmur<span style="color: #339933;">.</span>ice</pre></div></div>

<p>Nun stellt man noch sicher, das in der Konfigurationsdatei von Murmur folgendes enthalten ist:<br />
Murmur.ini</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;">ice<span style="color: #339933;">=</span><span style="color: #0000ff;">&quot;tcp -h 127.0.0.1 -p 6502&quot;</span></pre></div></div>

<p>Wenn man nun den Murmur Server startet, sollte die ICE-Schnittstelle auf dem angegebenen Port zur Verfügung stehen, mit der wir jetzt agieren können.</p>
<p>Achtet darauf, das die Variable $ICE global sein muss, ansonsten funktioniert es leider nicht.<br />
Aufgerufen wird das ganze folgendermaßen:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?</span>
  <span style="color: #000000; font-weight: bold;">global</span> <span style="color: #000088;">$ICE</span><span style="color: #339933;">;</span>
  <span style="color: #000088;">$output</span><span style="color: #339933;">=</span><span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">;</span>
  try<span style="color: #009900;">&#123;</span>
    Ice_loadProfile<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
    <span style="color: #000088;">$base</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$ICE</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">stringToProxy</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;Meta:tcp -h 127.0.0.1 -p 6502&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
    <span style="color: #000088;">$meta</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$base</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">ice_checkedCast</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;::Murmur::Meta&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
    <span style="color: #666666; font-style: italic;">//paste in your serverid!</span>
    <span style="color: #000088;">$server</span><span style="color: #339933;">=</span> <span style="color: #000088;">$meta</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">getServer</span><span style="color: #009900;">&#40;</span><span style="color: #cc66cc;">1</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
    <span style="color: #000088;">$myoutput</span><span style="color: #339933;">=</span>plotTreePlainTest<span style="color: #009900;">&#40;</span><span style="color: #000088;">$server</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">getTree</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
  <span style="color: #009900;">&#125;</span>
  catch <span style="color: #009900;">&#40;</span>Ice_Exception <span style="color: #000088;">$ex</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
    <span style="color: #990000;">print_r</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$ex</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
  <span style="color: #009900;">&#125;</span>
<span style="color: #b1b100;">echo</span> <span style="color: #000088;">$myoutput</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>Auch hier findet wieder eine globale Variable Verwendung. Die Variable kann natürlich auch als Referenz übergeben werden.</p>
<p>Hier die Funktion, die uns die HTML-Ausgabe macht:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;">&nbsp;
<span style="color: #000000; font-weight: bold;">function</span> plotTreePlainTest<span style="color: #009900;">&#40;</span><span style="color: #000088;">$tree</span><span style="color: #339933;">,</span><span style="color: #000088;">$indent</span><span style="color: #339933;">=</span><span style="color: #cc66cc;">0</span><span style="color: #339933;">,</span> <span style="color: #000088;">$first_run</span><span style="color: #339933;">=</span><span style="color: #009900; font-weight: bold;">true</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>
  <span style="color: #000000; font-weight: bold;">global</span> <span style="color: #000088;">$output</span><span style="color: #339933;">;</span>
  <span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span><span style="color: #990000;">is_object</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$tree</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>
    <span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span><span style="color: #990000;">is_array</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$tree</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">children</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>
      <span style="color: #000088;">$output</span><span style="color: #339933;">.=</span> <span style="color: #0000ff;">'&lt;div '</span><span style="color: #339933;">;</span>
      <span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #339933;">!</span><span style="color: #000088;">$first_run</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>
        <span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #990000;">is_object</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$tree</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">children</span><span style="color: #009900;">&#91;</span><span style="color: #cc66cc;">0</span><span style="color: #009900;">&#93;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>
          <span style="color: #000088;">$output</span><span style="color: #339933;">.=</span> <span style="color: #0000ff;">'&gt;'</span><span style="color: #339933;">.</span><span style="color: #990000;">str_repeat</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;&amp;nbsp;&quot;</span><span style="color: #339933;">,</span> <span style="color: #000088;">$indent</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">'+ '</span><span style="color: #339933;">;</span>
        <span style="color: #009900;">&#125;</span>
        <span style="color: #b1b100;">else</span> <span style="color: #009900;">&#123;</span>
          <span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #990000;">is_null</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$tree</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">users</span><span style="color: #009900;">&#91;</span><span style="color: #cc66cc;">0</span><span style="color: #009900;">&#93;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>
            <span style="color: #000088;">$display</span><span style="color: #339933;">=</span><span style="color: #0000ff;">'style=&quot;display: none;&quot; '</span><span style="color: #339933;">;</span>
          <span style="color: #009900;">&#125;</span>
          <span style="color: #000088;">$output</span><span style="color: #339933;">.=</span> <span style="color: #000088;">$display</span><span style="color: #339933;">.</span><span style="color: #0000ff;">'&gt;'</span><span style="color: #339933;">.</span><span style="color: #990000;">str_repeat</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;&amp;nbsp;&quot;</span><span style="color: #339933;">,</span> <span style="color: #000088;">$indent</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">'- '</span><span style="color: #339933;">;</span>
        <span style="color: #009900;">&#125;</span>
      <span style="color: #009900;">&#125;</span>
      <span style="color: #b1b100;">else</span> <span style="color: #009900;">&#123;</span>
        <span style="color: #000088;">$output</span><span style="color: #339933;">.=</span> <span style="color: #0000ff;">&quot;&gt;o &quot;</span><span style="color: #339933;">;</span>
      <span style="color: #009900;">&#125;</span>
      <span style="color: #000088;">$channelname</span><span style="color: #339933;">=</span><span style="color: #990000;">str_replace</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;=&quot;</span><span style="color: #339933;">,</span><span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">,</span><span style="color: #000088;">$tree</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">c</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">name</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
      <span style="color: #000088;">$channelname</span><span style="color: #339933;">=</span><span style="color: #990000;">str_replace</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;|&quot;</span><span style="color: #339933;">,</span><span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">,</span><span style="color: #000088;">$channelname</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
      <span style="color: #000088;">$channelname</span><span style="color: #339933;">=</span><span style="color: #990000;">str_replace</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;-&quot;</span><span style="color: #339933;">,</span><span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">,</span><span style="color: #000088;">$channelname</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
      <span style="color: #000088;">$channelname</span><span style="color: #339933;">=</span><span style="color: #990000;">preg_replace</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;/^[0-9]\ (.*)/&quot;</span><span style="color: #339933;">,</span><span style="color: #0000ff;">&quot;<span style="color: #006699; font-weight: bold;">$1</span>&quot;</span><span style="color: #339933;">,</span><span style="color: #000088;">$channelname</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
      <span style="color: #000088;">$output</span><span style="color: #339933;">.=</span> <span style="color: #000088;">$channelname</span><span style="color: #339933;">.</span><span style="color: #0000ff;">&quot;&lt;/div&gt;&quot;</span><span style="color: #339933;">;</span>
      <span style="color: #b1b100;">foreach</span> <span style="color: #009900;">&#40;</span><span style="color: #000088;">$tree</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">users</span> <span style="color: #b1b100;">as</span> <span style="color: #000088;">$k</span><span style="color: #339933;">=&gt;</span><span style="color: #000088;">$v</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>
        <span style="color: #000088;">$output</span><span style="color: #339933;">.=</span> <span style="color: #990000;">str_repeat</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;&amp;nbsp;&quot;</span><span style="color: #339933;">,</span> <span style="color: #000088;">$indent</span><span style="color: #339933;">+</span><span style="color: #cc66cc;">2</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        <span style="color: #000088;">$output</span><span style="color: #339933;">.=</span> <span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">'&lt;span style=&quot;color: green;&quot;&gt;&lt;b&gt;'</span><span style="color: #339933;">.</span><span style="color: #000088;">$v</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">name</span><span style="color: #339933;">.</span><span style="color: #0000ff;">&quot;&lt;/b&gt;&lt;/span&gt;&lt;br/&gt;&quot;</span><span style="color: #339933;">;</span>
      <span style="color: #009900;">&#125;</span>
      <span style="color: #b1b100;">foreach</span> <span style="color: #009900;">&#40;</span><span style="color: #000088;">$tree</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">children</span> <span style="color: #b1b100;">as</span> <span style="color: #000088;">$k</span><span style="color: #339933;">=&gt;</span><span style="color: #000088;">$v</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>
        <span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #990000;">is_object</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$tree</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">children</span><span style="color: #009900;">&#91;</span><span style="color: #000088;">$k</span><span style="color: #009900;">&#93;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span>
        plotTreePlainTest<span style="color: #009900;">&#40;</span><span style="color: #000088;">$tree</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">children</span><span style="color: #009900;">&#91;</span><span style="color: #000088;">$k</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">,</span><span style="color: #000088;">$indent</span><span style="color: #339933;">+</span><span style="color: #cc66cc;">2</span><span style="color: #339933;">,</span><span style="color: #009900; font-weight: bold;">false</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
      <span style="color: #009900;">&#125;</span>
    <span style="color: #009900;">&#125;</span>
&nbsp;
  <span style="color: #009900;">&#125;</span>
  <span style="color: #b1b100;">return</span> <span style="color: #000088;">$output</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span></pre></div></div>

<p>Das alles soll nur eine kleine Hilfestellung zur Anzeige der Channel und Benutzer unter Mumble geben.<br />
Ggf. erweitere ich den Code noch ein wenig, bzw. erläutere noch etwas mehr dazu, falls dies erwünscht ist.</p>
]]></content:encoded>
			<wfw:commentRss>http://ra23.net/wop/2010/03/mumble-online-user-anzeigen/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>SMF-SPAMD ein wenig aufgebohrt</title>
		<link>http://ra23.net/wop/2009/08/smf-spamd-ein-wenig-aufgebohrt/</link>
		<comments>http://ra23.net/wop/2009/08/smf-spamd-ein-wenig-aufgebohrt/#comments</comments>
		<pubDate>Sat, 08 Aug 2009 02:02:40 +0000</pubDate>
		<dc:creator>Andre Rein</dc:creator>
				<category><![CDATA[milter-smf-spamd]]></category>
		<category><![CDATA[sendmail]]></category>
		<category><![CDATA[milter]]></category>
		<category><![CDATA[patch]]></category>
		<category><![CDATA[smf-spamd]]></category>
		<category><![CDATA[Spam]]></category>

		<guid isPermaLink="false">http://ra23.net/wop/?p=20</guid>
		<description><![CDATA[Ich benutze schon eine ganze Weile die  Milter smf-* von Eugene Kurmanin
für Sendmail und bin sehr zufrieden damit.
Das Programm smf-spamd dient dazu Emails an SpamAssassin weiter zu reichen.
Wenn ein bestimmer einstellbarer Grenzwert bei der Überprüfung überschritten wird (in meinem Fall 15 Punkte), wird die Email mit einer Fehlermeldung abgelehnt.
Da ich unter anderem Emails von [...]]]></description>
			<content:encoded><![CDATA[<p>Ich benutze schon eine ganze Weile die <a href="http://smfs.sourceforge.net/index.html"> Milter smf-*</a> von Eugene Kurmanin<br />
für <a href="http://www.sendmail.org">Sendmail</a> und bin sehr zufrieden damit.<br />
Das Programm smf-spamd dient dazu Emails an <a href="http://spamassassin.apache.org/">SpamAssassin</a> weiter zu reichen.<br />
Wenn ein bestimmer einstellbarer Grenzwert bei der Überprüfung überschritten wird (in meinem Fall 15 Punkte), wird die Email mit einer Fehlermeldung abgelehnt.</p>
<p>Da ich unter anderem Emails von einem Server empfange der keinen Spamfilter verwendet, in dem speziellen Fall ist es eine Weiterleitung, werden auch sämtliche Mails abgelehnt die in diesem Fall über 15 Punkten liegen.<br />
Dies resultiert dann auf dem externen Mailserver in einem Mailer Error der an mich gerichtet ist und die Spam Mail ist im Anhang der Error Mail.</p>
<p>Damit ist natürlich nicht viel gewonnen und bedeutet nur Mehrarbeit.<br />
Eine Möglichkeit wäre den Host in die generelle Whitelist zu packen, dann wird die Mail aber schon beim eigentlichen Connect direkt durchgelassen ohne das eine Prüfung auf Spam erfolgt. </p>
<p>Der hier aufgeführte Patch führt eine zusätzliche Whitelist ein, die dieses Verhalten ändert.<br />
Kommt eine Mail von einem Host dessen IP in der extra Whitelist steht, wird sie vom Server nie abgelehnt, sondern sie durchläuft die Prüfung durch SpamAssassin. Es spielt keine Rolle ob sie als EXTRA SPAM identifiziert wurde, sie wird ganz normal weitergeleitet, jedoch wird wie gewünscht das Subject richtig umgeschrieben und kann somit lokal direkt in den Spamordner geschoben werden.</p>
<p><a href="http://ra23.net/wop/?attachment_id=19">Patch für smf-spamd -&gt; Download</a></p>

<div class="wp_syntax"><div class="code"><pre class="diff" style="font-family:monospace;">diff -up -r smf-spamd-1.3.1/smf-config.h smf-spamd-1.3.1-modded/smf-config.h
<span style="color: #888822;">--- smf-spamd-1.3.1/smf-config.h	<span style="">2007</span>-01-<span style="">18</span> <span style="">15</span>:<span style="">35</span>:<span style="">08.000000000</span> +0100</span>
<span style="color: #888822;">+++ smf-spamd-1.3.1-modded/smf-config.h	<span style="">2009</span>-08-08 03:<span style="">51</span>:<span style="">05.000000000</span> +0200</span>
<span style="color: #440088;">@@ -<span style="">5</span>,<span style="">10</span> +<span style="">5</span>,<span style="">13</span> @@</span>
  */
&nbsp;
 /* Hosts/Networks whitelist <span style="">&#40;</span>extended regex format<span style="">&#41;</span> */
<span style="color: #991111;">-#define WHITE_LIST	&quot;<span style="">&#40;</span>^<span style="">127</span>\\.|^<span style="">192</span>\\.168\\.|^<span style="">10</span>\\.<span style="">&#41;</span>&quot;</span>
<span style="color: #00b000;">+#define WHITE_LIST     &quot;<span style="">&#40;</span>^<span style="">127</span>\\.|^<span style="">192</span>\\.168\\.|^<span style="">10</span>\\.<span style="">&#41;</span>&quot;</span>
<span style="color: #00b000;">+</span>
<span style="color: #00b000;">+/* Hosts/Networks which probably send EXTRA SPAM and should not be blocked*/</span>
<span style="color: #00b000;">+#define WHITE_LIST_EXTRA   &quot;<span style="">&#40;</span>^<span style="">1</span>\\.2\\.3\\.<span style="">&#41;</span>&quot;</span>
&nbsp;
 /* Maximal message size */
<span style="color: #991111;">-#define MAX_SIZE	<span style="">131072</span> /* bytes */</span>
<span style="color: #00b000;">+#define MAX_SIZE	<span style="">5131072</span> /* bytes */</span>
&nbsp;
 /* Probable SPAM e-Mail messages Subject tagging */
 #define TAG_SUBJECT	<span style="">1</span> /* set <span style="">0</span> to disable */
diff -up -r smf-spamd-1.3.1/smf-spamd.c smf-spamd-1.3.1-modded/smf-spamd.c
<span style="color: #888822;">--- smf-spamd-1.3.1/smf-spamd.c	<span style="">2007</span>-01-<span style="">18</span> <span style="">15</span>:<span style="">35</span>:<span style="">08.000000000</span> +0100</span>
<span style="color: #888822;">+++ smf-spamd-1.3.1-modded/smf-spamd.c	<span style="">2009</span>-08-08 02:<span style="">43</span>:<span style="">33.000000000</span> +0200</span>
<span style="color: #440088;">@@ -<span style="">91</span>,<span style="">6</span> +<span style="">91</span>,<span style="">10</span> @@ int daemon<span style="">&#40;</span>int nochdir, int noclose<span style="">&#41;</span> <span style="">&#123;</span></span>
 static const char *ignore_connect = WHITE_LIST;
 static regex_t re_ignore_connect;
&nbsp;
<span style="color: #00b000;">+static const char *no_ignore_connect = WHITE_LIST_EXTRA;</span>
<span style="color: #00b000;">+static regex_t no_re_ignore_connect;</span>
<span style="color: #00b000;">+</span>
<span style="color: #00b000;">+</span>
 struct context <span style="">&#123;</span>
     char addr<span style="">&#91;</span><span style="">64</span><span style="">&#93;</span>;
     char fqdn<span style="">&#91;</span>MAXLINE<span style="">&#93;</span>;
<span style="color: #440088;">@@ -<span style="">470</span>,<span style="">12</span> +<span style="">474</span>,<span style="">18</span> @@ static sfsistat smf_eom<span style="">&#40;</span>SMFICTX *ctx<span style="">&#41;</span> <span style="">&#123;</span></span>
     elapsed = context-&gt;tend.tv_sec - context-&gt;tstart.tv_sec + <span style="">&#40;</span>context-&gt;tend.tv_usec - context-&gt;tstart.tv_usec<span style="">&#41;</span> / 1.0e6;
     if <span style="">&#40;</span>ret == <span style="">1</span><span style="">&#41;</span> <span style="">&#123;</span>
 	if <span style="">&#40;</span>context-&gt;score &gt;= EXTRA_SPAM<span style="">&#41;</span> <span style="">&#123;</span>
<span style="color: #00b000;">+	  // if there is an entry in WHITELIST_EXTRA do not reject the message;</span>
<span style="color: #00b000;">+	  if <span style="">&#40;</span>no_ignore_connect<span style="">&#91;</span><span style="">0</span><span style="">&#93;</span> &amp;&amp; regexec<span style="">&#40;</span>&amp;no_re_ignore_connect, context-&gt;addr, <span style="">0</span>, NULL, <span style="">0</span><span style="">&#41;</span><span style="">&#41;</span><span style="">&#123;</span></span>
 	    char reject<span style="">&#91;</span>MAXLINE<span style="">&#93;</span>;
&nbsp;
 	    syslog<span style="">&#40;</span>LOG_NOTICE, &quot;EXTRA SPAM <span style="">&#40;</span>%.1f/%.1f<span style="">&#41;</span>, %.3fsec, %s, %s -&gt; %s&quot;, context-&gt;score, context-&gt;threshold, elapsed, context-&gt;fqdn, context-&gt;from, context-&gt;rcpt<span style="">&#41;</span>;
 	    snprintf<span style="">&#40;</span>reject, sizeof<span style="">&#40;</span>reject<span style="">&#41;</span>, &quot;Sorry, looks like spam. Contact %s to resolve this issue&quot;, CONTACT_ADDRESS<span style="">&#41;</span>;
 	    smfi_setreply<span style="">&#40;</span>ctx, &quot;<span style="">554</span>&quot;, &quot;5.7.1&quot;, reject<span style="">&#41;</span>;
 	    return SMFIS_REJECT;
<span style="color: #00b000;">+          <span style="">&#125;</span></span>
<span style="color: #00b000;">+          else<span style="">&#123;</span></span>
<span style="color: #00b000;">+            syslog<span style="">&#40;</span>LOG_NOTICE, &quot;EXTRA SPAM WHITELISTED <span style="">&#40;</span>%.1f/%.1f<span style="">&#41;</span>, %.3fsec, %s, %s -&gt; %s&quot;, context-&gt;score, context-&gt;threshold, elapsed, context-&gt;fqdn, context-&gt;from, context-&gt;rcpt<span style="">&#41;</span>;</span>
<span style="color: #00b000;">+          <span style="">&#125;</span></span>
 	<span style="">&#125;</span>
 	if <span style="">&#40;</span>REDIRECT_SPAM<span style="">&#41;</span> <span style="">&#123;</span>
 	    if <span style="">&#40;</span>context-&gt;rcpts<span style="">&#41;</span> <span style="">&#123;</span>
<span style="color: #440088;">@@ -<span style="">572</span>,<span style="">6</span> +<span style="">582</span>,<span style="">7</span> @@ int main<span style="">&#40;</span>int argc, char **argv<span style="">&#41;</span> <span style="">&#123;</span></span>
     int ret = <span style="">0</span>;
&nbsp;
     regcomp<span style="">&#40;</span>&amp;re_ignore_connect, ignore_connect, REG_EXTENDED|REG_ICASE<span style="">&#41;</span>;
<span style="color: #00b000;">+    regcomp<span style="">&#40;</span>&amp;no_re_ignore_connect, no_ignore_connect, REG_EXTENDED|REG_ICASE<span style="">&#41;</span>;</span>
     tzset<span style="">&#40;</span><span style="">&#41;</span>;
     openlog<span style="">&#40;</span>&quot;smf-spamd&quot;, LOG_PID|LOG_NDELAY, SYSLOG_FACILITY<span style="">&#41;</span>;
     if <span style="">&#40;</span>!strncmp<span style="">&#40;</span>oconn, &quot;unix:&quot;, <span style="">5</span><span style="">&#41;</span><span style="">&#41;</span></pre></div></div>

<p>Alles weitere zu smf-spamd kann man auf der Seite des Entwicklers nachschaun.</p>
<p>gruss<br />
Andre</p>
]]></content:encoded>
			<wfw:commentRss>http://ra23.net/wop/2009/08/smf-spamd-ein-wenig-aufgebohrt/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Hello world!</title>
		<link>http://ra23.net/wop/2009/08/hello-world/</link>
		<comments>http://ra23.net/wop/2009/08/hello-world/#comments</comments>
		<pubDate>Wed, 05 Aug 2009 19:27:18 +0000</pubDate>
		<dc:creator>Andre Rein</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[hello]]></category>
		<category><![CDATA[test]]></category>

		<guid isPermaLink="false">http://ra23.net/wop/?p=1</guid>
		<description><![CDATA[
#include
int main&#40;void&#41;&#123;
  printf&#40;&#34;Hello World!&#34;&#41;;
&#125;

asdsadasd
]]></description>
			<content:encoded><![CDATA[
<div class="wp_syntax"><div class="code"><pre class="c" style="font-family:monospace;"><span style="color: #339933;">#include</span>
<span style="color: #993333;">int</span> main<span style="color: #009900;">&#40;</span><span style="color: #993333;">void</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>
  <span style="color: #000066;">printf</span><span style="color: #009900;">&#40;</span><span style="color: #ff0000;">&quot;Hello World!&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span></pre></div></div>

<p>asdsadasd</p>
]]></content:encoded>
			<wfw:commentRss>http://ra23.net/wop/2009/08/hello-world/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
