<?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>bureX's blog &#187; Coding</title>
	<atom:link href="http://www.burex.net/category/coding/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.burex.net</link>
	<description>Digitalized scribbles</description>
	<lastBuildDate>Thu, 15 Sep 2011 00:29:37 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3</generator>
		<item>
		<title>TeamSpeak Extra &#8211; Finally</title>
		<link>http://www.burex.net/2009/01/18/teamspeak-extra-finally/</link>
		<comments>http://www.burex.net/2009/01/18/teamspeak-extra-finally/#comments</comments>
		<pubDate>Sun, 18 Jan 2009 03:37:33 +0000</pubDate>
		<dc:creator>bureX</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[Software]]></category>

		<guid isPermaLink="false">http://www.burex.net/2009/01/18/teamspeak-extra-finally/</guid>
		<description><![CDATA[After almost a full year of using this personal project as a neat TeamSpeak addon, I&#160; decided it was about time to tidy it up a bit and release it into the world. TeamSpeak Extra is an add-on written in Borland/CodeGear Delphi for the purpose of expanding the scope of features that TeamSpeak already has. [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.burex.net/wp-content/uploads/live/TeamSpeakExtraFinally_4103/1.jpg"><img title="1" style="border-right: 0px; border-top: 0px; display: inline; margin-left: 0px; border-left: 0px; margin-right: 0px; border-bottom: 0px" height="260" alt="1" src="http://www.burex.net/wp-content/uploads/live/TeamSpeakExtraFinally_4103/1_thumb.jpg" width="205" align="right" border="0" /></a>After almost a full year of using this personal project as a neat TeamSpeak addon, I&#160; decided it was about time to tidy it up a bit and release it into the world.</p>
<p>TeamSpeak Extra is an add-on written in Borland/CodeGear Delphi for the purpose of expanding the scope of features that TeamSpeak already has. It does that in a way that improves productivity and eliminates the needless hassle for frequent TeamSpeak users, and Administrators as well (such as myself) when public behavior needs to be moderated.</p>
<p>If anybody is interested, head on to <a href="http://ts.burex.net" target="_blank">ts.burex.net</a> and grab a copy.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.burex.net/2009/01/18/teamspeak-extra-finally/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>OOP and CSS</title>
		<link>http://www.burex.net/2008/05/04/oop-and-css/</link>
		<comments>http://www.burex.net/2008/05/04/oop-and-css/#comments</comments>
		<pubDate>Sun, 04 May 2008 02:27:31 +0000</pubDate>
		<dc:creator>bureX</dc:creator>
				<category><![CDATA[Coding]]></category>

		<guid isPermaLink="false">http://www.burex.net/?p=250</guid>
		<description><![CDATA[Since I'm working on a new PHP based project, I wanted to make a nice switch from the old methods I used to use... To cut the story short - it's OOP and CSS. "Object oriented programming" - not that high tech as one might imagine, but it doesn't let my PHP files turn into [...]]]></description>
			<content:encoded><![CDATA[<p>Since I'm working on a new PHP based project, I wanted to make a nice switch from the old methods I used to use... To cut the story short - it's OOP and CSS. "Object oriented programming" - not that high tech as one might imagine, but it doesn't let my PHP files turn into dusty code buckets, and it sure makes every piece of my hard written code reusable! In PHP - this basically means that you can create one class.php file that you will use to host your respectable code, and later on, you can call it on any page you find fit in a snap! Quite better than using plain libraries, since you can create multiple instances with your class and you don't have to worry about conflicting with any global variables or built-in PHP functions. Neat-o!</p>
<p>And as for CSS... Phew! It was a long way ahead! I'm glad it's over! For the first time CSS coder, the temptation to throw everything away and turn back to using plain old tables is very, very strong! And why wouldn't it be? Every WYSIWYG web design program let's you create tables in a jiffy, and organize them in any way you want, and with CSS, you have to ditch the GUI and work your way through &lt;div&gt;s and CSS properties. But, once you get past the first "position:absolute" line, you will see why this method of creating websites is really the most natural thing to do! You can position your DIV anywhere you want it to be! Tables are for data - that's it. They can't be moved properly and constrain your website to be nothing more than just plain flat, and once you start experiencing cross browser pains with tables (sure, they do exist for CSS, but in most cases, they are fairly resolvable) you will run back screaming. (trust me, the same table doesn't always look like it should in IE, Firefox or Opera, and there's nothing you can do about it)</p>
<p>Oh, and did I mention the feeling that most people get when they write something down in a PHP/HTML + CSS file and it works beautifully the way it should? Magical...</p>
<p>Well, there you have it... If I didn't make these switches, I'd be stuck with Cobol right now <img src='http://www.burex.net/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://www.burex.net/2008/05/04/oop-and-css/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>TeamSpeak flood protection</title>
		<link>http://www.burex.net/2008/04/04/teamspeak-flood-protection/</link>
		<comments>http://www.burex.net/2008/04/04/teamspeak-flood-protection/#comments</comments>
		<pubDate>Fri, 04 Apr 2008 00:37:22 +0000</pubDate>
		<dc:creator>bureX</dc:creator>
				<category><![CDATA[Coding]]></category>

		<guid isPermaLink="false">http://www.burex.net/?p=236</guid>
		<description><![CDATA[Since I am having a hard time controlling flood attacks on my TeamSpeak server, I decided that it would be a good idea to automate the protection of the server's integrity by upgrading an already great app - TS2PerlMod. If you don't have TS2PerlMod already installed, grab a free copy of ActivePerl and install it [...]]]></description>
			<content:encoded><![CDATA[<p>Since I am having a hard time controlling flood attacks on my TeamSpeak server, I decided that it would be a good idea to automate the protection of the server's integrity by upgrading an already great app - <a href="http://www.planetteamspeak.com/component/option,com_docman/task,doc_details/Itemid,69/gid,51/" target="_blank">TS2PerlMod</a>. If you don't have TS2PerlMod already installed, grab a free copy of <a href="http://www.activestate.com/Products/activeperl/" target="_blank">ActivePerl</a> and install it on your Windows machine (for *nix systems, I'm assuming perl is already present), then configure all the needed settings as you would usually do (see the ReadMe).</p>
<p>Now, here's the perl code snippet that I coded today (I am not very familiar with perl, but the C like syntax made it easy to write), it will enable you to ban every bot that tries to flood your server:</p>
<p><strong>ts2perlmod.pl</strong></p>
<p><em> <span style="color: #ffcc00;"> # update TeamSpeak2::TCPquery::Server object</span><br />
<span style="color: #33cccc;"> $server-&gt;getServerinfo();</span></em></p>
<p>Add this below the above code:</p>
<pre># bureX-ANTISPAM-MOD: making life a bit more easier on TeamSpeak...
    my @cplayerlist;
    my @iplayerlist;
    my $i;
    my $j;
    my $kicked;
		foreach my $player (@playerlist)
		{ 

      if ($player->{loginname} eq "")
      {
         $i=0;
         for ($j=0;$j<scalar(@cplayerlist);$j++)
         {
           if ($iplayerlist[$j] eq $player->{"ip"})
           {
             $cplayerlist[$j] = $cplayerlist[$j]+1;
             $i++;
           }
         }

         if ($i==0)
         {
           push(@cplayerlist, 1);
           push(@iplayerlist, $player->{"ip"});
         }
         $i=0;
      }
    }

    $kicked = 0;
    for ($i=0;$i<scalar(@cplayerlist);$i++)
    {
        if ($cplayerlist[$i] > 3) #number of allowed players to connect from the same IP address
        {
          $server->sendMessage("Spam Attack detected from ".$iplayerlist[$i]);
          $server->sendMessage("Initiating retaliation sequence for ".$cplayerlist[$i]." bots...");

          	foreach my $player (@playerlist)
            {
                if ($player->{ip} eq $iplayerlist[$i])
                {
                  $player->banIp(240); #ban spammers for 240 minutes
                  $player->kick("Spam protection");
                  $kicked = 1;
                }
            }

          $server->sendMessage("Retaliation sequence executed.");
          $server->sendMessage("Done... Have a nice day!");
          $server->sendMessage("TS defence system - crafted by bureX");
        }
    }

    if ($kicked == 1) {sleep(10);} #Let the TS Server rest for 10 seconds before updating the new list

    delete @cplayerlist[0..scalar(@cplayerlist)];
    delete @iplayerlist[0..scalar(@iplayerlist)];</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.burex.net/2008/04/04/teamspeak-flood-protection/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

