<?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>PRESOON.COM &#187; APF</title>
	<atom:link href="http://presoon.com/blog/category/apf/feed/" rel="self" type="application/rss+xml" />
	<link>http://presoon.com/blog</link>
	<description></description>
	<lastBuildDate>Wed, 01 Jun 2011 09:19:34 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.1.4</generator>
		<item>
		<title>LWP perl module (libwww-perl) cPanel csf issue.</title>
		<link>http://presoon.com/blog/2009/09/24/lwp-perl-module-libwww-perl-cpanel-csf-issue/</link>
		<comments>http://presoon.com/blog/2009/09/24/lwp-perl-module-libwww-perl-cpanel-csf-issue/#comments</comments>
		<pubDate>Thu, 24 Sep 2009 09:46:59 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[APF]]></category>
		<category><![CDATA[Cpanel]]></category>
		<category><![CDATA[libwww-perl]]></category>
		<category><![CDATA[LWP]]></category>
		<category><![CDATA[perl module]]></category>

		<guid isPermaLink="false">http://presoon.com/blog/?p=125</guid>
		<description><![CDATA[You may face issue with the perl module LWP libwww-perl . Just do the following check whether the following file exist ls -alh /root/.gnupg cd /usr/local/src/ wget http://perlmirror.indialinks.com/authors/id/G/GA/GAAS/libwww-perl-5.806.tar.gz or download the available version from http://perlmirror.indialinks.com/authors/id/G/GA/GAAS/ tar zxvf libwww-perl-5.806.tar.gz cd libwww-perl-5.806 perl Makefile.PL make make install cd ../ Also do the following wget http://perlmirror.indialinks.com/authors/id/A/AN/ANDK/CPAN-1.93.tar.gz tar zxvf [...]]]></description>
			<content:encoded><![CDATA[<p>You may face issue with the perl module LWP libwww-perl .<br />
Just do the following</p>
<p>check whether the following file exist</p>
<pre>
<code>ls -alh /root/.gnupg</code>
</pre>
<pre>
<code>cd /usr/local/src/
wget 

http://perlmirror.indialinks.com/authors/id/G/GA/GAAS/libwww-perl-5.806.tar.gz

or download the available version from http://perlmirror.indialinks.com/authors/id/G/GA/GAAS/
tar zxvf libwww-perl-5.806.tar.gz
cd libwww-perl-5.806
perl Makefile.PL
make
make install
cd ../</code>
</pre>
<p>Also do the following</p>
<pre>
<code>wget  http://perlmirror.indialinks.com/authors/id/A/AN/ANDK/CPAN-1.93.tar.gz
tar zxvf CPAN-1.93.tar.gz
Or download the latest from http://perlmirror.indialinks.com/authors/id/A/AN/ANDK/
cd CPAN-1.93
perl Makefile.PL
make
make install

/usr/local/cpanel/bin/checkperlmodules
/scripts/rrdtoolinstall</code>
</pre>
<p>Now try installing csf.<br />
It should work fine.</p>
]]></content:encoded>
			<wfw:commentRss>http://presoon.com/blog/2009/09/24/lwp-perl-module-libwww-perl-cpanel-csf-issue/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to install BFD</title>
		<link>http://presoon.com/blog/2008/10/11/how-to-install-bfd/</link>
		<comments>http://presoon.com/blog/2008/10/11/how-to-install-bfd/#comments</comments>
		<pubDate>Sat, 11 Oct 2008 04:06:44 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[APF]]></category>
		<category><![CDATA[Centos]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Attacks]]></category>
		<category><![CDATA[BFD]]></category>

		<guid isPermaLink="false">http://presoon.com/blog/?p=68</guid>
		<description><![CDATA[What is BFD (Brute Force Detection)? BFD is a modular shell script for parsing applicable logs and checking for authentication failures. There is not much complexity or detail to BFD yet and likewise it is very straight-forward in its installation, configuration and usage. The reason behind BFD is very simple; the fact there is little [...]]]></description>
			<content:encoded><![CDATA[<p><strong>What is BFD (Brute Force Detection)?</strong></p>
<p><strong><br />
</strong>BFD is a modular shell script for parsing applicable logs and checking for authentication failures. There is not much complexity or detail to BFD yet and likewise it is very straight-forward in its installation, configuration and usage. The reason behind BFD is very simple; the fact there is little to no authentication and brute force auditing programs in the linux community that work in conjunction with a firewall or real-time facility to place bans. BFD is available at: <a href="http://www.rfxnetworks.com/bfd.php" target="_blank">http://www.rfxnetworks.com/bfd.php</a></p>
<p>This guide will show you how to install and configure BFD to protect your system from brute force hack attempts.</p>
<p><strong>Requirements:</strong><br />
- You MUST have APF Firewall Installed before installing BFD &#8211; it works with APF and requires some APF files to operate.<br />
- Root SSH access to your server</p>
<p><strong></strong><strong><br />
</strong>Login to your server through SSH and su to the root user.</p>
<p><strong>1. </strong><em>cd /usr/local/src/</em>.</p>
<p><!-- COPYRIGHT MIDDLE ART --></p>
<div class="whitetext">Article provided by WebHostGear.com</div>
<div id="beacon_53" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">&lt;a href=&#8217;http://a.wavepointmedia.net/adclick.php?n=a263378f&#8217; target=&#8217;_blank&#8217;&gt;&lt;img src=&#8217;http://a.wavepointmedia.net/adview.php?what=zone:14&amp;amp;n=a263378f&#8217; border=&#8217;0&#8242; alt=&#8221;&gt;&lt;/a&gt;</div>
<p><noscript></noscript><strong>2.</strong> <em>wget </em><a href="http://www.rfxnetworks.com/downloads/bfd-current.tar.gz"><em>http://www.rfxnetworks.com/downloads/bfd-current.tar.gz</em></a></p>
<p><strong>3. </strong><span style="color: #003366;"><em>tar -xvzf bfd-current.tar.gz</em></p>
<p><strong>4.</strong> <em>cd bfd-*</p>
<p></em><strong>5. </strong>Run the install file: <em>./install.sh<br />
</em>You will receive a message saying it has been installed</p>
<p>.: BFD installed<br />
Install path:    /usr/local/bfd<br />
Config path:     /usr/local/bfd/conf.bfd<br />
Executable path: /usr/local/sbin/bfd</p>
<p><strong>6.</strong> Edit the configuration file: <em>vi /usr/local/bfd/conf.bfd</em></p>
<p><strong>7. </strong>Enable brute force hack attempt alerts:</p>
<p>Find: <em>EMAIL_USR=&#8221;root&#8221;</em> CHANGE TO: <em>EMAIL_USR=&#8221;your@yourdomain.com&#8221; </em></p>
<p>Save the changes<em></em></p>
<p><strong>8. </strong>Prevent locking yourself out!<br />
<em>vi /usr/local/bfd/ignore.hosts</em> and add your own trusted IPs</span><span style="color: #003366;"><em><br />
</em>Save the changes<em></em></p>
<p><strong>9.</strong> Run the program!<br />
<em>/usr/local/sbin/bfd -s</em></p>
<p><strong>10.</strong> Customize your applicatoins brute force configuration<br />
Check out the <strong>rules</strong> directory in your <em>/usr/local/bfd</em></p>
<p>Here you&#8217;ll find all kinds of pre-made rules for popular services such as Apache, and ProFTPD w00t!<br />
If you have any clue about shell scripting you can customize them or create new rules for enhanced brute force detection and prevent attacks.</p>
<p></span></p>
]]></content:encoded>
			<wfw:commentRss>http://presoon.com/blog/2008/10/11/how-to-install-bfd/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Uninstall APF</title>
		<link>http://presoon.com/blog/2008/05/14/uninstall-apf/</link>
		<comments>http://presoon.com/blog/2008/05/14/uninstall-apf/#comments</comments>
		<pubDate>Tue, 13 May 2008 20:41:59 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[APF]]></category>

		<guid isPermaLink="false">http://presoon.com/blog/?p=52</guid>
		<description><![CDATA[rm -rf /etc/apf rm -f /etc/cron.daily/fw rm -f /etc/init.d/apf rm -f /usr/local/sbin/apf]]></description>
			<content:encoded><![CDATA[<p>rm -rf /etc/apf<br />
rm -f /etc/cron.daily/fw<br />
rm -f /etc/init.d/apf<br />
rm -f /usr/local/sbin/apf</p>
]]></content:encoded>
			<wfw:commentRss>http://presoon.com/blog/2008/05/14/uninstall-apf/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Unable to load iptables module (ipt_state), aborting. APF Error</title>
		<link>http://presoon.com/blog/2008/04/24/unable-to-load-iptables-module-ipt_state-aborting-apf-error/</link>
		<comments>http://presoon.com/blog/2008/04/24/unable-to-load-iptables-module-ipt_state-aborting-apf-error/#comments</comments>
		<pubDate>Thu, 24 Apr 2008 07:39:04 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[APF]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Apf Error]]></category>

		<guid isPermaLink="false">http://presoon.com/blog/?p=29</guid>
		<description><![CDATA[root@server[/etc/apf]# apf -s Unable to load iptables module (ipt_state), aborting. root@server[/etc/apf]# Here is the fix Edit /etc/apf/internals/functions.apf vi /etc/apf/internals/functions.apf Replace the lines ==================== ml ipt_state 1 ml ipt_multiport 1 ==================== With ==================== ml xt_state ml xt_multiport ==================== Restart apf.]]></description>
			<content:encoded><![CDATA[<p>root@server[/etc/apf]# apf -s<br />
Unable to load iptables module (ipt_state), aborting.<br />
root@server[/etc/apf]#</p>
<p>Here is the fix</p>
<p>Edit  /etc/apf/internals/functions.apf</p>
<p>vi /etc/apf/internals/functions.apf</p>
<p>Replace the lines </p>
<p>====================<br />
ml ipt_state 1<br />
ml ipt_multiport 1<br />
====================</p>
<p>With</p>
<p>====================<br />
ml xt_state<br />
ml xt_multiport<br />
====================</p>
<p>Restart apf.</p>
]]></content:encoded>
			<wfw:commentRss>http://presoon.com/blog/2008/04/24/unable-to-load-iptables-module-ipt_state-aborting-apf-error/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>APF Installation and configuration</title>
		<link>http://presoon.com/blog/2008/04/09/apf-installation-and-configuration/</link>
		<comments>http://presoon.com/blog/2008/04/09/apf-installation-and-configuration/#comments</comments>
		<pubDate>Wed, 09 Apr 2008 21:06:09 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[APF]]></category>
		<category><![CDATA[Advanced policy firewall]]></category>
		<category><![CDATA[Install APF]]></category>

		<guid isPermaLink="false">http://presoon.com/blog/?p=6</guid>
		<description><![CDATA[1. cd /usr/local/src or another temporary folder where you store your files. 2. wget http://www.rfxnetworks.com/downloads/apf-current.tar.gz 3. tar -xvzf apf-current.tar.gz 4. cd apf-0.9.5-1/ or whatever the latest version is. 5. Run the install file: ./install.sh You will receive a message saying it has been installed Installing APF 0.9.5-1: Completed. Other Details: Listening TCP ports: 1,21,22,25,53,80,110,111,143,443,465,993,995,2082, 2083,2086,2087,2095,2096,3306 [...]]]></description>
			<content:encoded><![CDATA[<p>1. cd /usr/local/src or another temporary folder where you store your files.</p>
<p>2. wget http://www.rfxnetworks.com/downloads/apf-current.tar.gz</p>
<p>3. tar -xvzf apf-current.tar.gz</p>
<p>4. cd apf-0.9.5-1/ or whatever the latest version is.</p>
<p>5. Run the install file: ./install.sh<br />
You will receive a message saying it has been installed</p>
<p>Installing APF 0.9.5-1: Completed.</p>
<p>Other Details:<br />
Listening TCP ports: 1,21,22,25,53,80,110,111,143,443,465,993,995,2082, 2083,2086,2087,2095,2096,3306<br />
Listening UDP ports: 53,55880<br />
Note: These ports are not auto-configured; they are simply presented for information purposes. You must manually configure all port options.</p>
<p>6. Configure the firewall: pico /etc/apf/conf.apf<br />
We will go over the general configuration to get your firewall running. This isn’t a complete detailed guide of every feature the firewall has. Look through the README and the configuration for an explanation of each feature.</p>
<p>We like to use DShield.org’s “block” list of top networks that have exhibited<br />
suspicious activity.<br />
FIND: USE_DS=”0?<br />
CHANGE TO: USE_DS=”1?</p>
<p>7. Configuring Firewall Ports:</p>
<p>Cpanel Servers<br />
We like to use the following on our Cpanel Servers</p>
<p>Common ingress (inbound) ports<br />
# Common ingress (inbound) TCP ports -3000_3500 = passive port range for Pure FTPD<br />
IG_TCP_CPORTS=”21,22,25,53,80,110,143,443,2082,208 3, 2086,2087, 2095, 2096,3000_3500?<br />
#<br />
# Common ingress (inbound) UDP ports<br />
IG_UDP_CPORTS=”53?</p>
<p>Common egress (outbound) ports<br />
# Egress filtering [0 = Disabled / 1 = Enabled]<br />
EGF=”1?</p>
<p># Common egress (outbound) TCP ports<br />
EG_TCP_CPORTS=”21,25,80,443,43,2089?<br />
#<br />
# Common egress (outbound) UDP ports<br />
EG_UDP_CPORTS=”20,21,53?</p>
<p>8. Starting the firewall<br />
/usr/local/sbin/apf -s</p>
<p>9. After everything is fine, change the DEV option<br />
Stop the firewall from automatically clearing itself every 5 minutes from cron.<br />
We recommend changing this back to “0? after you’ve had a chance to ensure everything is working well and tested the server out.</p>
<p>pico /etc/apf/conf.apf</p>
<p>FIND: DEVM=”1?<br />
CHANGE TO: DEVM=”0?</p>
<p>10. Configure AntiDOS for APF<br />
Relatively new to APF is the new AntiDOS feature which can be found in: /etc/apf/ad<br />
The log file will be located at /var/log/apfados_log so you might want to make note of it and watch it!</p>
<p>pico /etc/apf/ad/conf.antidos</p>
<p>11. Checking the APF Log</p>
<p>tail -f /var/log/apf_log</p>
<p>12. New &#8211; Make APF Start automatically at boot time</p>
<p>chkconfig –level 2345 apf on</p>
<p>To remove it from autostart, run this:</p>
<p>chkconfig –del apf</p>
<p>13. Denying IPs with APF Firewall (Blocking)</p>
<p>Pico /etc/apf/deny_hosts.rules</p>
<p>You can then just add a new line and enter the IP you wish to block. Before this becomes active though you’ll need to reload the APF ruleset.</p>
<p>/etc/apf/apf -r</p>
<p>14. Allowing IPs with APF Firewall (Unblocking)</p>
<p>I know I know, you added an IP now you need it removed right away! You need to manually remove IPs that are blocked from deny_hosts.rules.</p>
<p>pico /etc/apf/deny_hosts.rules</p>
<p>Find where the IP is listed and remove the line that has the IP.<br />
After this is done save the file and reload apf to make the new changes active.</p>
<p>/etc/apf/apf -r</p>
<p>pico /etc/apf/allow_hosts.rules</p>
<p># added 185.14.157.123 on 08/23/05 01:39:43<br />
# UNBLOCKING<br />
185.14.157.123</p>
]]></content:encoded>
			<wfw:commentRss>http://presoon.com/blog/2008/04/09/apf-installation-and-configuration/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>What is APF (Advanced Policy Firewall)? APF Firewall</title>
		<link>http://presoon.com/blog/2008/04/09/what-is-apf-advanced-policy-firewall-apf-firewall/</link>
		<comments>http://presoon.com/blog/2008/04/09/what-is-apf-advanced-policy-firewall-apf-firewall/#comments</comments>
		<pubDate>Wed, 09 Apr 2008 21:04:31 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[APF]]></category>
		<category><![CDATA[Advanced policy firewalls]]></category>

		<guid isPermaLink="false">http://presoon.com/blog/?p=5</guid>
		<description><![CDATA[APF is a policy based iptables firewall system designed for ease of use and configuration. It employs a subset of features to satisfy the veteran Linux user and the novice alike. Packaged in tar.gz format and RPM formats, make APF ideal for deployment in many server environments based on Linux. APF is developed and maintained [...]]]></description>
			<content:encoded><![CDATA[<p>APF is a policy based iptables firewall system designed for ease of use and configuration. It employs a subset of features to satisfy the veteran Linux user and the novice alike. Packaged in tar.gz format and RPM formats, make APF ideal for deployment in many server environments based on Linux. APF is developed and maintained by R-fx Networks: http://www.rfxnetworks.com/apf.php</p>
]]></content:encoded>
			<wfw:commentRss>http://presoon.com/blog/2008/04/09/what-is-apf-advanced-policy-firewall-apf-firewall/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

