<?xml version="1.0" encoding="utf-8" ?>
<!DOCTYPE packagegui SYSTEM "./schema/packages.dtd">
<?xml-stylesheet type="text/xsl" href="./xsl/package.xsl"?>
<packagegui>
	<copyright>
	<![CDATA[
/* $Id$ */
/* ========================================================================== */
/*
    pfblocker.xml
    part of the pfblocker for pfSense
    Copyright (C) 2011 Marcello Coutinho

    All rights reserved.            
			                                                                  */
/* ========================================================================== */
/*
    Redistribution and use in source and binary forms, with or without
    modification, are permitted provided that the following conditions are met:

     1. Redistributions of source code must retain the above copyright notice,
        this list of conditions and the following disclaimer.

     2. Redistributions in binary form must reproduce the above copyright
        notice, this list of conditions and the following disclaimer in the
        documentation and/or other materials provided with the distribution.

    THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES,
    INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
    AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
    AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY,
    OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
    SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
    INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
    CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
    ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
    POSSIBILITY OF SUCH DAMAGE.
                                                                              */
/* ========================================================================== */
	]]>
	</copyright>
	<description>Describe your package here</description>
	<requirements>Describe your package requirements here</requirements>
	<faq>Currently there are no FAQ items provided.</faq>
	<name>pfblocker</name>
	<version>1.0</version>
	<title>Firewall: pfBlocker</title>
	<include_file>/usr/local/pkg/pfblocker.inc</include_file>
	<menu>
		<name>pfBlocker</name>
		<tooltiptext>Configure pfblocker</tooltiptext>
		<section>Firewall</section>
		<url>/pkg_edit.php?xml=pfblocker.xml</url>
	</menu>
	<additional_files_needed>
		<item>https://packages.pfsense.org/packages/config/pf-blocker/pfblocker.inc</item>
		<prefix>/usr/local/pkg/</prefix>
		<chmod>0755</chmod>
	</additional_files_needed>
	<additional_files_needed>
		<item>https://packages.pfsense.org/packages/config/pf-blocker/pfblocker.php</item>
		<prefix>/usr/local/www/</prefix>
		<chmod>0755</chmod>
	</additional_files_needed>
	<additional_files_needed>
		<item>https://packages.pfsense.org/packages/config/pf-blocker/pfBlocker.widget.php</item>
		<prefix>/usr/local/www/widgets/widgets/</prefix>
		<chmod>0755</chmod>
	</additional_files_needed>
	<additional_files_needed>
		<item>https://packages.pfsense.org/packages/config/pf-blocker/pfblocker_topspammers.xml</item>
		<prefix>/usr/local/pkg/</prefix>
		<chmod>0755</chmod>
	</additional_files_needed>
	<additional_files_needed>
		<item>https://packages.pfsense.org/packages/config/pf-blocker/pfblocker_lists.xml</item>
		<prefix>/usr/local/pkg/</prefix>
		<chmod>0755</chmod>
	</additional_files_needed>
	<additional_files_needed>
		<item>https://packages.pfsense.org/packages/config/pf-blocker/pfblocker_sync.xml</item>
		<prefix>/usr/local/pkg/</prefix>
		<chmod>0755</chmod>
	</additional_files_needed>
	<additional_files_needed>
		<item>https://packages.pfsense.org/packages/config/pf-blocker/lists/Africa_cidr.txt</item>
		<prefix>/usr/local/pkg/</prefix>
		<chmod>0555</chmod>
	</additional_files_needed>
	<additional_files_needed>
		<item>https://packages.pfsense.org/packages/config/pf-blocker/lists/Asia_cidr.txt</item>
		<prefix>/usr/local/pkg/</prefix>
		<chmod>0555</chmod>
	</additional_files_needed>
	<additional_files_needed>
		<item>https://packages.pfsense.org/packages/config/pf-blocker/lists/Europe_cidr.txt</item>
		<prefix>/usr/local/pkg/</prefix>
		<chmod>0555</chmod>
	</additional_files_needed>
	<additional_files_needed>
		<item>https://packages.pfsense.org/packages/config/pf-blocker/lists/North_America_cidr.txt</item>
		<prefix>/usr/local/pkg/</prefix>
		<chmod>0555</chmod>
	</additional_files_needed>
	<additional_files_needed>
		<item>https://packages.pfsense.org/packages/config/pf-blocker/lists/Oceania_cidr.txt</item>
		<prefix>/usr/local/pkg/</prefix>
		<chmod>0555</chmod>
	</additional_files_needed>
	<additional_files_needed>
		<item>https://packages.pfsense.org/packages/config/pf-blocker/lists/South_America_cidr.txt</item>
		<prefix>/usr/local/pkg/</prefix>
		<chmod>0555</chmod>
	</additional_files_needed>
<tabs>
		<tab>
			<text>General</text>
			<url>/pkg_edit.php?xml=pfblocker.xml&amp;id=0</url>
			<active/>
		</tab>
		<tab>
			<text>Lists</text>
			<url>/pkg.php?xml=pfblocker_lists.xml</url>
		</tab>

		<tab>
			<text>Top Spammers</text>
			<url>/pkg_edit.php?xml=pfblocker_topspammers.xml&amp;id=0</url>
		</tab>
	
		<tab>
			<text>Africa</text>
			<url>/pkg_edit.php?xml=pfblocker_Africa.xml&amp;id=0</url>
			
		</tab>
		<tab>
			<text>Asia</text>
			<url>/pkg_edit.php?xml=pfblocker_Asia.xml&amp;id=0</url>
			
		</tab>
		<tab>
			<text>Europe</text>
			<url>/pkg_edit.php?xml=pfblocker_Europe.xml&amp;id=0</url>
		</tab>
		<tab>
			<text>North America</text>
			<url>/pkg_edit.php?xml=pfblocker_NorthAmerica.xml&amp;id=0</url>
		</tab>
		<tab>
			<text>Oceania</text>
			<url>/pkg_edit.php?xml=pfblocker_Oceania.xml&amp;id=0</url>
		</tab>
		<tab>
			<text>South America</text>
			<url>/pkg_edit.php?xml=pfblocker_SouthAmerica.xml&amp;id=0</url>
		</tab>
		<tab>
			<text>XMLRPC Sync</text>
			<url>/pkg_edit.php?xml=pfblocker_sync.xml&amp;id=0</url>
		</tab>
</tabs>
	<fields>
		<field>
			<name>pfBlocker General Settings</name>
			<type>listtopic</type>
		</field>
		<field>
			<fielddescr>Enable pfBlocker</fielddescr>
			<fieldname>enable_cb</fieldname>
			<type>checkbox</type>
			<description></description>
		</field>
		<field>
			<fielddescr>Enable Logging</fielddescr>
			<fieldname>enable_log</fieldname>
			<type>checkbox</type>
			<description></description>
		</field>
		<field>
			<fielddescr>Inbound Interface(s)</fielddescr>
			<fieldname>inbound_interface</fieldname>
			<description><![CDATA[Default: <strong>WAN</strong><br>Select interface(s) that you want to block incoming traffic.]]></description>
			<type>interfaces_selection</type>
			<required/>
			<multiple/>
		</field>
		<field>
			<fielddescr>Inbound deny action</fielddescr>
			<fieldname>inbound_deny_action</fieldname>
			<description><![CDATA[Default:<strong>Block</strong><br>
							Select deny action for inbound rules]]></description>
	    	<type>select</type>
 				<options>
 				<option><name>Block</name><value>block</value></option>
				<option><name>Reject</name><value>reject</value></option>
				</options>
		</field>	
		<field>
			<fielddescr>Outbound Interface(s)</fielddescr>
			<fieldname>outbound_interface</fieldname>
			<description><![CDATA[Default:<strong>LAN</strong> or none.<br>Select interface(s) that you do not want to send outgoing traffic.]]></description>
			<type>interfaces_selection</type>
			<required/>
			<multiple/>
		</field>
			<field>
			<fielddescr>Outbound deny action</fielddescr>
			<fieldname>outbound_deny_action</fieldname>
			<description><![CDATA[Default:<strong>Reject</strong><br>
							Select deny action for outbound rules]]></description>
	    	<type>select</type>
 				<options>
				<option><name>Reject</name><value>reject</value></option>
				<option><name>Block</name><value>block</value></option>
				</options>
		</field>	
		<field>
			<name>About pfBlocker</name>
			<type>listtopic</type>
		</field>
		<field>
			<fielddescr>Credits</fielddescr>
			<fieldname>credits</fieldname>
			<type>checkbox</type>
			<description><![CDATA[Continent Lists are provided by <a target=_new href='http://www.countryipblocks.net/'>countryipblocks.net</a>.<br>
									Dynamic rules can be found in <a target=_new href='http://www.iblocklist.com/'>I-Blocklist.com</a>.</br>
									Created by <a target=_new href='https://forum.pfsense.org/index.php?action=profile;u=4710'>Marcello Coutinho</a> and <a target=_new href='http://www.tomschaefer.org/pfsense'>TomSchaefer</a>.<br>]]></description>
		</field>
		<field>
			<fielddescr>Donation</fielddescr>
			<fieldname>donation</fieldname>
			<type>checkbox</type>
			<description><![CDATA[If you like this package, please <a target=_new href='https://www.pfsense.org/index.php?option=com_content&task=view&id=47&Itemid=77'>donate to the pfSense project</a>.<br>
								 If you want your donation to go to these package developers, make a note on the donation forwarding it to us.<br>]]></description>
		</field>
	</fields>
	<custom_php_install_command>
		pfblocker_php_install_command();
	</custom_php_install_command>
	<custom_php_deinstall_command>
		pfblocker_php_deinstall_command();
	</custom_php_deinstall_command>
	<custom_php_validation_command>
		pfblocker_validate_input($_POST, &amp;$input_errors);
	</custom_php_validation_command>	
	<custom_php_resync_config_command>
		sync_package_pfblocker();
	</custom_php_resync_config_command>
</packagegui>