<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.tetrain.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Manojsemwal</id>
	<title>TetraWiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.tetrain.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Manojsemwal"/>
	<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=Special:Contributions/Manojsemwal"/>
	<updated>2026-07-25T07:20:39Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.43.9</generator>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=Pfsense_Carp&amp;diff=2031</id>
		<title>Pfsense Carp</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=Pfsense_Carp&amp;diff=2031"/>
		<updated>2015-07-29T13:49:49Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:Tetra Clients]]&lt;br /&gt;
[[category:GSPC]]&lt;br /&gt;
&lt;br /&gt;
                                                     &#039;&#039;&#039;CARP-SETUP-GIPL&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[File:Gipl_cluster.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
(Before CARP Setup Layer 2 Switching Loop needs to be eliminated by making changes in the system files , configuration changes is located at bottom of this Doc &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
As we have already configured pfsense firewall, now we need to make another pfsense with exact same configurations, which will serve as backup server, in case of primary pfsense goes down or failure.&lt;br /&gt;
&lt;br /&gt;
In order to build backup pfsense, we are going to first download whole Configuration Backup from primary pfsense &lt;br /&gt;
&lt;br /&gt;
Reference :- https://doc.pfsense.org/index.php/Configuration_Backup_and_Restore&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Diagnostics &amp;gt; Backup/Restore, and clicking Download Configuration.&lt;br /&gt;
&lt;br /&gt;
Now keep this file in safe place in your local system.&lt;br /&gt;
&lt;br /&gt;
Now we are going to create backup server, just install the pfsense on backup server (already described in previous document)&lt;br /&gt;
&lt;br /&gt;
After Installation Connect one machine directly to LAN port of backup server and assign IP 192.168.1.2/24 (so that we can use GUI to restore backup)&lt;br /&gt;
&lt;br /&gt;
Because by default pfsense will assign LAN IP as 192.168.1.1/24 to its LAN interface&lt;br /&gt;
&lt;br /&gt;
Now from your Local Machine which is connected directly to pfsense LAN interface open this link:-&lt;br /&gt;
https://192.168.1.1&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
It will load configuration panel of pfsense just skip it by clicking at the TOP of pfsense Picture on left side.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now restoring a configuration is just as easy,&lt;br /&gt;
&lt;br /&gt;
Diagnostics &amp;gt; Backup/Restore&lt;br /&gt;
&lt;br /&gt;
 Click Browse, locate the backup configuration file, and then click Restore Configuration.&lt;br /&gt;
&lt;br /&gt;
Configuration files can be restored to a completely different piece of hardware without issue. If the new target hardware has different NICs&lt;br /&gt;
 &lt;br /&gt;
than the system where the backup was taken, a prompt will appear to re-assign the NICs after restoring the configuration&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now Wait For around 5 hours, this process will install all the packages with configurations.&lt;br /&gt;
&lt;br /&gt;
Once the task is completed Change the IP’s as described in the Diagram, for wan, bridge and lan.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now we have Two Machines Ready running Pfsense with same configurations (make sure you change the WAN, bridge, LAN IP’s on Backup Server)&lt;br /&gt;
We are now going to Setup CARP:-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Reference:- https://doc.pfsense.org/index.php/Configuring_pfSense_Hardware_Redundancy_%28CARP%29&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
One real IP address is required for every CARP cluster node. To have 2 cluster nodes, 2 IP addresses are needed for the real interfaces and then an additional IP for each CARP type virtual IP address&lt;br /&gt;
&lt;br /&gt;
On the primary cluster node, add a virtual IP addresses of the CARP type in Firewall &amp;gt; Virtual IPs. The virtual IP addresses must fall within the same subnet of an IP address defined on a real interface&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:virtual_ip.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
A unique VHID must be used for each shared virtual IP address on a given interface (It is assigned automatically)&lt;br /&gt;
Setup a Dedicated Sync Interface&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Set up each cluster Sync interface; give it an IP address in the same subnet.  on the primary cluster node enter 10.0.0.1 and on the secondary cluster node enter 10.0.0.2 for the IP address. Use a /24 subnet.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Add Firewall Rules for Synchronization&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Before configuring synchronization, add firewall rules to the Sync interface that will pass traffic between the nodes. &lt;br /&gt;
•	Navigate to Firewall &amp;gt; Rules on the Sync interface tab &lt;br /&gt;
&lt;br /&gt;
•	Add a rule to pass traffic from the Sync Net to any destination. &lt;br /&gt;
&lt;br /&gt;
Enable State Synchronization (pfsync)&lt;br /&gt;
&lt;br /&gt;
State synchronization should be enabled on all cluster nodes. &lt;br /&gt;
&lt;br /&gt;
•	Navigate to System &amp;gt; High Avail. Sync &lt;br /&gt;
&lt;br /&gt;
•	Check Synchronize States &lt;br /&gt;
&lt;br /&gt;
•	Choose the correct Synchronize Interface for state synchronization &lt;br /&gt;
&lt;br /&gt;
•	If using two cluster nodes, enter the sync interface IP address for the opposing node in pfsync Synchronize Peer IP. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
   the primary cluster node would have 10.0.0.2 set. The secondary node would have 10.0.0.1 set.&lt;br /&gt;
&lt;br /&gt;
    Click Save &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Sync_settings.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Enable Configuration Synchronization (XMLRPC Sync)&lt;br /&gt;
&lt;br /&gt;
Before proceeding, set the same admin user password and webConfigurator protocol (e.g. HTTPS) on each cluster node. &lt;br /&gt;
&lt;br /&gt;
The configuration synchronization settings should only be enabled on the primary cluster node. &lt;br /&gt;
&lt;br /&gt;
•	Navigate to System &amp;gt; High Avail. Sync &lt;br /&gt;
&lt;br /&gt;
•	Enter the IP address of the secondary in Synchronize Config to IP 10.0.0.2&lt;br /&gt;
&lt;br /&gt;
•	Enter admin for the Remote System Username (other usernames will not work) &lt;br /&gt;
&lt;br /&gt;
•	Enter the Remote System Password (the password should be the same on all nodes) &lt;br /&gt;
&lt;br /&gt;
•	Check boxes for the desired configuration areas to sync&lt;br /&gt;
&lt;br /&gt;
•	Click Save &lt;br /&gt;
The chosen areas will synchronize to the secondary node once the settings have been saved. &lt;br /&gt;
&lt;br /&gt;
Now reboot both the machines 1 by 1 &lt;br /&gt;
&lt;br /&gt;
Verify CARP Status&lt;br /&gt;
&lt;br /&gt;
On both nodes, check Status &amp;gt; CARP (failover). If either system shows a button labeled Enable CARP, click it. &lt;br /&gt;
On that page, verify that the VIPs show the proper status. On the primary node, each VIP should show MASTER. On the secondary node, each VIP should show BACKUP. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Layer 2 Switching Loop Workaround:-&lt;br /&gt;
The editor is available here:&lt;br /&gt;
Diagnostics&amp;gt;Edit File. The Load/Save path is “/conf/config.xml”.&lt;br /&gt;
&lt;br /&gt;
Look for these lines :- &lt;br /&gt;
# CARP notify hooks. This will call carpup/carpdown with the&lt;br /&gt;
# interface (carp0, carp1) as the first parameter.&lt;br /&gt;
notify 100 {&lt;br /&gt;
 match &amp;quot;system&amp;quot;          &amp;quot;CARP&amp;quot;;&lt;br /&gt;
   match &amp;quot;type&amp;quot;            &amp;quot;MASTER&amp;quot;;&lt;br /&gt;
   action &amp;quot;/usr/local/sbin/pfSctl -c &#039;interface carpmaster $subsystem&#039;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
notify 100 {&lt;br /&gt;
    match &amp;quot;system&amp;quot;          &amp;quot;CARP&amp;quot;;&lt;br /&gt;
    match &amp;quot;type&amp;quot;            &amp;quot;BACKUP&amp;quot;;&lt;br /&gt;
    action &amp;quot;/usr/local/sbin/pfSctl -c &#039;interface carpbackup $subsystem&#039;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
Modify As:-&lt;br /&gt;
notify 100 {&lt;br /&gt;
    match &amp;quot;system&amp;quot;          &amp;quot;CARP&amp;quot;;&lt;br /&gt;
    match &amp;quot;type&amp;quot;            &amp;quot;MASTER&amp;quot;;&lt;br /&gt;
    action &amp;quot;&#039;&#039;&#039;ifconfig bridge0 up &amp;amp;&amp;amp;&#039;&#039;&#039; /usr/local/sbin/pfSctl -c &#039;interface carpmaster $subsystem&#039;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
notify 100 {&lt;br /&gt;
    match &amp;quot;system&amp;quot;          &amp;quot;CARP&amp;quot;;&lt;br /&gt;
    match &amp;quot;type&amp;quot;            &amp;quot;BACKUP&amp;quot;;&lt;br /&gt;
    action &amp;quot;&#039;&#039;&#039;ifconfig bridge0 down &amp;amp;&amp;amp;&#039;&#039;&#039; /usr/local/sbin/pfSctl -c &#039;interface carpbackup $subsystem&#039;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
Save this file and reboot both servers 1 by 1. Make these changes before CARPSETUP.&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=Pfsense_Carp&amp;diff=2030</id>
		<title>Pfsense Carp</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=Pfsense_Carp&amp;diff=2030"/>
		<updated>2015-07-29T13:48:05Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:Tetra Clients]]&lt;br /&gt;
[[category:GSPC]]&lt;br /&gt;
&lt;br /&gt;
                                                     &#039;&#039;&#039;CARP-SETUP-GIPL&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[File:Gipl_cluster.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
(Before CARP Setup Layer 2 Switching Loop needs to be eliminated by making changes in the system files , configuration changes is located at bottom of this Doc &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
As we have already configured pfsense firewall, now we need to make another pfsense with exact same configurations, which will serve as backup server, in case of primary pfsense goes down or failure.&lt;br /&gt;
&lt;br /&gt;
In order to build backup pfsense, we are going to first download whole Configuration Backup from primary pfsense &lt;br /&gt;
&lt;br /&gt;
Reference :- https://doc.pfsense.org/index.php/Configuration_Backup_and_Restore&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Diagnostics &amp;gt; Backup/Restore, and clicking Download Configuration.&lt;br /&gt;
&lt;br /&gt;
Now keep this file in safe place in your local system.&lt;br /&gt;
&lt;br /&gt;
Now we are going to create backup server, just install the pfsense on backup server (already described in previous document)&lt;br /&gt;
&lt;br /&gt;
After Installation Connect one machine directly to LAN port of backup server and assign IP 192.168.1.2/24 (so that we can use GUI to restore backup)&lt;br /&gt;
&lt;br /&gt;
Because by default pfsense will assign LAN IP as 192.168.1.1/24 to its LAN interface&lt;br /&gt;
&lt;br /&gt;
Now from your Local Machine which is connected directly to pfsense LAN interface open this link:-&lt;br /&gt;
https://192.168.1.1&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
It will load configuration panel of pfsense just skip it by clicking at the TOP of pfsense Picture on left side.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now restoring a configuration is just as easy,&lt;br /&gt;
&lt;br /&gt;
Diagnostics &amp;gt; Backup/Restore&lt;br /&gt;
&lt;br /&gt;
 Click Browse, locate the backup configuration file, and then click Restore Configuration.&lt;br /&gt;
&lt;br /&gt;
Configuration files can be restored to a completely different piece of hardware without issue. If the new target hardware has different NICs&lt;br /&gt;
 &lt;br /&gt;
than the system where the backup was taken, a prompt will appear to re-assign the NICs after restoring the configuration&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now Wait For around 5 hours, this process will install all the packages with configurations.&lt;br /&gt;
&lt;br /&gt;
Once the task is completed Change the IP’s as described in the Diagram, for wan, bridge and lan.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now we have Two Machines Ready running Pfsense with same configurations (make sure you change the WAN, bridge, LAN IP’s on Backup Server)&lt;br /&gt;
We are now going to Setup CARP:-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Reference:- https://doc.pfsense.org/index.php/Configuring_pfSense_Hardware_Redundancy_%28CARP%29&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
One real IP address is required for every CARP cluster node. To have 2 cluster nodes, 2 IP addresses are needed for the real interfaces and then an additional IP for each CARP type virtual IP address&lt;br /&gt;
&lt;br /&gt;
On the primary cluster node, add a virtual IP addresses of the CARP type in Firewall &amp;gt; Virtual IPs. The virtual IP addresses must fall within the same subnet of an IP address defined on a real interface&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:virtual_ip.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
A unique VHID must be used for each shared virtual IP address on a given interface (It is assigned automatically)&lt;br /&gt;
Setup a Dedicated Sync Interface&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Set up each cluster Sync interface; give it an IP address in the same subnet.  on the primary cluster node enter 10.0.0.1 and on the secondary cluster node enter 10.0.0.2 for the IP address. Use a /24 subnet.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Add Firewall Rules for Synchronization&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Before configuring synchronization, add firewall rules to the Sync interface that will pass traffic between the nodes. &lt;br /&gt;
•	Navigate to Firewall &amp;gt; Rules on the Sync interface tab &lt;br /&gt;
&lt;br /&gt;
•	Add a rule to pass traffic from the Sync Net to any destination. &lt;br /&gt;
&lt;br /&gt;
Enable State Synchronization (pfsync)&lt;br /&gt;
&lt;br /&gt;
State synchronization should be enabled on all cluster nodes. &lt;br /&gt;
&lt;br /&gt;
•	Navigate to System &amp;gt; High Avail. Sync &lt;br /&gt;
&lt;br /&gt;
•	Check Synchronize States &lt;br /&gt;
&lt;br /&gt;
•	Choose the correct Synchronize Interface for state synchronization &lt;br /&gt;
&lt;br /&gt;
•	If using two cluster nodes, enter the sync interface IP address for the opposing node in pfsync Synchronize Peer IP. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
   the primary cluster node would have 10.0.0.2 set. The secondary node would have 10.0.0.1 set.&lt;br /&gt;
&lt;br /&gt;
    Click Save &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Sync_settings.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Enable Configuration Synchronization (XMLRPC Sync)&lt;br /&gt;
&lt;br /&gt;
Before proceeding, set the same admin user password and webConfigurator protocol (e.g. HTTPS) on each cluster node. &lt;br /&gt;
&lt;br /&gt;
The configuration synchronization settings should only be enabled on the primary cluster node. &lt;br /&gt;
&lt;br /&gt;
•	Navigate to System &amp;gt; High Avail. Sync &lt;br /&gt;
&lt;br /&gt;
•	Enter the IP address of the secondary in Synchronize Config to IP 10.0.0.2&lt;br /&gt;
&lt;br /&gt;
•	Enter admin for the Remote System Username (other usernames will not work) &lt;br /&gt;
&lt;br /&gt;
•	Enter the Remote System Password (the password should be the same on all nodes) &lt;br /&gt;
&lt;br /&gt;
•	Check boxes for the desired configuration areas to sync&lt;br /&gt;
&lt;br /&gt;
•	Click Save &lt;br /&gt;
The chosen areas will synchronize to the secondary node once the settings have been saved. &lt;br /&gt;
&lt;br /&gt;
Now reboot both the machines 1 by 1 &lt;br /&gt;
&lt;br /&gt;
Verify CARP Status&lt;br /&gt;
&lt;br /&gt;
On both nodes, check Status &amp;gt; CARP (failover). If either system shows a button labeled Enable CARP, click it. &lt;br /&gt;
On that page, verify that the VIPs show the proper status. On the primary node, each VIP should show MASTER. On the secondary node, each VIP should show BACKUP. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Layer 2 Switching Loop Workaround:-&lt;br /&gt;
The editor is available here:&lt;br /&gt;
Diagnostics&amp;gt;Edit File. The Load/Save path is “/conf/config.xml”.&lt;br /&gt;
&lt;br /&gt;
Look for these lines :- &lt;br /&gt;
# CARP notify hooks. This will call carpup/carpdown with the&lt;br /&gt;
# interface (carp0, carp1) as the first parameter.&lt;br /&gt;
notify 100 {&lt;br /&gt;
 match &amp;quot;system&amp;quot;          &amp;quot;CARP&amp;quot;;&lt;br /&gt;
   match &amp;quot;type&amp;quot;            &amp;quot;MASTER&amp;quot;;&lt;br /&gt;
   action &amp;quot;/usr/local/sbin/pfSctl -c &#039;interface carpmaster $subsystem&#039;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
notify 100 {&lt;br /&gt;
    match &amp;quot;system&amp;quot;          &amp;quot;CARP&amp;quot;;&lt;br /&gt;
    match &amp;quot;type&amp;quot;            &amp;quot;BACKUP&amp;quot;;&lt;br /&gt;
    action &amp;quot;/usr/local/sbin/pfSctl -c &#039;interface carpbackup $subsystem&#039;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
Modify As:-&lt;br /&gt;
notify 100 {&lt;br /&gt;
    match &amp;quot;system&amp;quot;          &amp;quot;CARP&amp;quot;;&lt;br /&gt;
    match &amp;quot;type&amp;quot;            &amp;quot;MASTER&amp;quot;;&lt;br /&gt;
    action &amp;quot;ifconfig bridge0 up &amp;amp;&amp;amp; /usr/local/sbin/pfSctl -c &#039;interface carpmaster $subsystem&#039;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
notify 100 {&lt;br /&gt;
    match &amp;quot;system&amp;quot;          &amp;quot;CARP&amp;quot;;&lt;br /&gt;
    match &amp;quot;type&amp;quot;            &amp;quot;BACKUP&amp;quot;;&lt;br /&gt;
    action &amp;quot;ifconfig bridge0 down &amp;amp;&amp;amp; /usr/local/sbin/pfSctl -c &#039;interface carpbackup $subsystem&#039;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
Save this file and reboot both servers 1 by 1. Make these changes before CARPSETUP.&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=Pfsense_Carp&amp;diff=2029</id>
		<title>Pfsense Carp</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=Pfsense_Carp&amp;diff=2029"/>
		<updated>2015-07-29T13:45:17Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: Created page with &amp;quot;category:Tetra Clients category:GSPC                                                       &amp;#039;&amp;#039;&amp;#039;CARP-SETUP-GIPL&amp;#039;&amp;#039;&amp;#039;  File:Gipl_cluster.jpg   (Before CARP Setup Layer ...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:Tetra Clients]]&lt;br /&gt;
[[category:GSPC]]&lt;br /&gt;
&lt;br /&gt;
                                                     &#039;&#039;&#039;CARP-SETUP-GIPL&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[File:Gipl_cluster.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
(Before CARP Setup Layer 2 Switching Loop needs to be eliminated by making changes in the system files , configuration changes is located at bottom of this Doc .)&lt;br /&gt;
As we have already configured pfsense firewall, now we need to make another pfsense with exact same configurations, which will serve as backup server, in case of primary pfsense goes down or failure.&lt;br /&gt;
In order to build backup pfsense, we are going to first download whole Configuration Backup from primary pfsense &lt;br /&gt;
Reference :- https://doc.pfsense.org/index.php/Configuration_Backup_and_Restore&lt;br /&gt;
&lt;br /&gt;
Diagnostics &amp;gt; Backup/Restore, and clicking Download Configuration.&lt;br /&gt;
Now keep this file in safe place in your local system.&lt;br /&gt;
Now we are going to create backup server, just install the pfsense on backup server (already described in previous document)&lt;br /&gt;
After Installation Connect one machine directly to LAN port of backup server and assign IP 192.168.1.2/24 (so that we can use GUI to restore backup)&lt;br /&gt;
Because by default pfsense will assign LAN IP as 192.168.1.1/24 to its LAN interface&lt;br /&gt;
&lt;br /&gt;
Now from your Local Machine which is connected directly to pfsense LAN interface open this link:-&lt;br /&gt;
https://192.168.1.1&lt;br /&gt;
It will load configuration panel of pfsense just skip it by clicking at the TOP of pfsense Picture on left side.&lt;br /&gt;
Now restoring a configuration is just as easy,&lt;br /&gt;
Diagnostics &amp;gt; Backup/Restore&lt;br /&gt;
 Click Browse, locate the backup configuration file, and then click Restore Configuration.&lt;br /&gt;
Configuration files can be restored to a completely different piece of hardware without issue. If the new target hardware has different NICs than the system where the backup was taken, a prompt will appear to re-assign the NICs after restoring the configuration&lt;br /&gt;
Now Wait For around 5 hours, this process will install all the packages with configurations.&lt;br /&gt;
Once the task is completed Change the IP’s as described in the Diagram, for wan, bridge and lan.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now we have Two Machines Ready running Pfsense with same configurations (make sure you change the WAN, bridge, LAN IP’s on Backup Server)&lt;br /&gt;
We are now going to Setup CARP:-&lt;br /&gt;
Reference:- https://doc.pfsense.org/index.php/Configuring_pfSense_Hardware_Redundancy_%28CARP%29&lt;br /&gt;
One real IP address is required for every CARP cluster node. To have 2 cluster nodes, 2 IP addresses are needed for the real interfaces and then an additional IP for each CARP type virtual IP address&lt;br /&gt;
On the primary cluster node, add a virtual IP addresses of the CARP type in Firewall &amp;gt; Virtual IPs. The virtual IP addresses must fall within the same subnet of an IP address defined on a real interface&lt;br /&gt;
&lt;br /&gt;
[[File:virtual_ip.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
A unique VHID must be used for each shared virtual IP address on a given interface (It is assigned automatically)&lt;br /&gt;
Setup a Dedicated Sync Interface&lt;br /&gt;
Set up each cluster Sync interface; give it an IP address in the same subnet. Example: on the primary cluster node enter 10.0.0.1 and on the secondary cluster node enter 10.0.0.2 for the IP address. Use a /24 subnet.&lt;br /&gt;
&lt;br /&gt;
Add Firewall Rules for Synchronization&lt;br /&gt;
Before configuring synchronization, add firewall rules to the Sync interface that will pass traffic between the nodes. &lt;br /&gt;
•	Navigate to Firewall &amp;gt; Rules on the Sync interface tab &lt;br /&gt;
•	Add a rule to pass traffic from the Sync Net to any destination. &lt;br /&gt;
Enable State Synchronization (pfsync)&lt;br /&gt;
State synchronization should be enabled on all cluster nodes. &lt;br /&gt;
•	Navigate to System &amp;gt; High Avail. Sync &lt;br /&gt;
•	Check Synchronize States &lt;br /&gt;
•	Choose the correct Synchronize Interface for state synchronization &lt;br /&gt;
•	If using two cluster nodes, enter the sync interface IP address for the opposing node in pfsync Synchronize Peer IP. &lt;br /&gt;
Using the above example, the primary cluster node would have 10.0.0.2 set. The secondary node would have 10.0.0.1 set. Click Save &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:Sync_settings.jpg]]&lt;br /&gt;
&lt;br /&gt;
Enable Configuration Synchronization (XMLRPC Sync)&lt;br /&gt;
Before proceeding, set the same admin user password and webConfigurator protocol (e.g. HTTPS) on each cluster node. &lt;br /&gt;
The configuration synchronization settings should only be enabled on the primary cluster node. &lt;br /&gt;
•	Navigate to System &amp;gt; High Avail. Sync &lt;br /&gt;
•	Enter the IP address of the secondary in Synchronize Config to IP 10.0.0.2&lt;br /&gt;
•	Enter admin for the Remote System Username (other usernames will not work) &lt;br /&gt;
•	Enter the Remote System Password (the password should be the same on all nodes) &lt;br /&gt;
•	Check boxes for the desired configuration areas to sync&lt;br /&gt;
•	Click Save &lt;br /&gt;
The chosen areas will synchronize to the secondary node once the settings have been saved. &lt;br /&gt;
Now reboot both the machines 1 by 1 &lt;br /&gt;
Verify CARP Status&lt;br /&gt;
On both nodes, check Status &amp;gt; CARP (failover). If either system shows a button labeled Enable CARP, click it. &lt;br /&gt;
On that page, verify that the VIPs show the proper status. On the primary node, each VIP should show MASTER. On the secondary node, each VIP should show BACKUP. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Layer 2 Switching Loop Workaround:-&lt;br /&gt;
The editor is available here:&lt;br /&gt;
Diagnostics&amp;gt;Edit File. The Load/Save path is “/conf/config.xml”.&lt;br /&gt;
&lt;br /&gt;
Look for these lines :- &lt;br /&gt;
# CARP notify hooks. This will call carpup/carpdown with the&lt;br /&gt;
# interface (carp0, carp1) as the first parameter.&lt;br /&gt;
notify 100 {&lt;br /&gt;
 match &amp;quot;system&amp;quot;          &amp;quot;CARP&amp;quot;;&lt;br /&gt;
   match &amp;quot;type&amp;quot;            &amp;quot;MASTER&amp;quot;;&lt;br /&gt;
   action &amp;quot;/usr/local/sbin/pfSctl -c &#039;interface carpmaster $subsystem&#039;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
notify 100 {&lt;br /&gt;
    match &amp;quot;system&amp;quot;          &amp;quot;CARP&amp;quot;;&lt;br /&gt;
    match &amp;quot;type&amp;quot;            &amp;quot;BACKUP&amp;quot;;&lt;br /&gt;
    action &amp;quot;/usr/local/sbin/pfSctl -c &#039;interface carpbackup $subsystem&#039;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
Modify As:-&lt;br /&gt;
notify 100 {&lt;br /&gt;
    match &amp;quot;system&amp;quot;          &amp;quot;CARP&amp;quot;;&lt;br /&gt;
    match &amp;quot;type&amp;quot;            &amp;quot;MASTER&amp;quot;;&lt;br /&gt;
    action &amp;quot;ifconfig bridge0 up &amp;amp;&amp;amp; /usr/local/sbin/pfSctl -c &#039;interface carpmaster $subsystem&#039;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
notify 100 {&lt;br /&gt;
    match &amp;quot;system&amp;quot;          &amp;quot;CARP&amp;quot;;&lt;br /&gt;
    match &amp;quot;type&amp;quot;            &amp;quot;BACKUP&amp;quot;;&lt;br /&gt;
    action &amp;quot;ifconfig bridge0 down &amp;amp;&amp;amp; /usr/local/sbin/pfSctl -c &#039;interface carpbackup $subsystem&#039;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
Save this file and reboot both servers 1 by 1. Make these changes before CARPSETUP.&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=File:Sync_settings.jpg&amp;diff=2028</id>
		<title>File:Sync settings.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=File:Sync_settings.jpg&amp;diff=2028"/>
		<updated>2015-07-29T13:02:32Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=File:Virtual_ip.jpg&amp;diff=2027</id>
		<title>File:Virtual ip.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=File:Virtual_ip.jpg&amp;diff=2027"/>
		<updated>2015-07-29T13:02:11Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=File:Gipl_cluster.jpg&amp;diff=2026</id>
		<title>File:Gipl cluster.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=File:Gipl_cluster.jpg&amp;diff=2026"/>
		<updated>2015-07-29T13:01:20Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=Pahwa_Bryair_Zimbra&amp;diff=2025</id>
		<title>Pahwa Bryair Zimbra</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=Pahwa_Bryair_Zimbra&amp;diff=2025"/>
		<updated>2015-07-29T12:49:35Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:Pahwa Group]]&lt;br /&gt;
                                                    &#039;&#039;&#039;Pahwa New Architecture&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
[[File:Pahwa 01.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Installation :-&lt;br /&gt;
&lt;br /&gt;
On IMSS server :-&lt;br /&gt;
//Install Postfix &lt;br /&gt;
Yum install postfix &lt;br /&gt;
&lt;br /&gt;
// Install Trend IMSS&lt;br /&gt;
Download   IMSS_v7.1_Linux_1224_r2.tar.gz  for &lt;br /&gt;
Untar the file and run the installation script :-&lt;br /&gt;
./ isinst.sh  &lt;br /&gt;
Press y when ask for installation and confirm .&lt;br /&gt;
It will ask for database server to install locally , press y and proceed .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Postfix Configuration.&lt;br /&gt;
cd /etc/postfix&lt;br /&gt;
&lt;br /&gt;
#vim main.cf&lt;br /&gt;
&lt;br /&gt;
//insert following entry &lt;br /&gt;
&lt;br /&gt;
mydomain = pahwa.com&lt;br /&gt;
myhostname = imss.pahwa.com&lt;br /&gt;
mydestination = $myhostname, localhost.$mydomain, $mydomain&lt;br /&gt;
default_process_limit=200&lt;br /&gt;
imss_timeout=10m&lt;br /&gt;
imss_connect_timeout=1s&lt;br /&gt;
content_filter = imss:localhost:10025&lt;br /&gt;
imss_destination_recipient_limit=200&lt;br /&gt;
imss_destination_concurrency_limit=200&lt;br /&gt;
&lt;br /&gt;
smtpd_client_restrictions =&lt;br /&gt;
  permit_mynetworks,&lt;br /&gt;
  reject_rbl_client bl.spamcop.net,&lt;br /&gt;
  reject_rbl_client b.barracudacentral.org,&lt;br /&gt;
  reject_rbl_client cbl.abuseat.org,&lt;br /&gt;
  reject_rbl_client dnsbl.sorbs.net,&lt;br /&gt;
  permit&lt;br /&gt;
&lt;br /&gt;
disable_vrfy_command = yes&lt;br /&gt;
smtpd_recipient_restrictions =&lt;br /&gt;
  check_recipient_access hash:/etc/postfix/recipient_domains, permit_mynetworks, permit_sasl_authenticated,&lt;br /&gt;
  reject_unverified_recipient,&lt;br /&gt;
  reject_non_fqdn_sender,&lt;br /&gt;
  reject_non_fqdn_recipient,&lt;br /&gt;
  reject_unauth_destination,&lt;br /&gt;
  reject_unauth_pipelining,&lt;br /&gt;
  reject&lt;br /&gt;
&lt;br /&gt;
smtpd_sender_restrictions =&lt;br /&gt;
  permit_mynetworks,&lt;br /&gt;
  permit_sasl_authenticated,&lt;br /&gt;
  check_sender_access hash:/etc/postfix/sender_access&lt;br /&gt;
  reject_unknown_sender_domain&lt;br /&gt;
&lt;br /&gt;
mynetworks = 127.0.0.1, 192.168.0.5, 192.168.0.254, 192.168.0.2&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
//For recipent restriction&lt;br /&gt;
&lt;br /&gt;
#vim recipient_domains  &lt;br /&gt;
//Make Entry :-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
pahwa.com OK&lt;br /&gt;
&lt;br /&gt;
//Now Postmap command to make db&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
#postmap recipient_domains&lt;br /&gt;
&lt;br /&gt;
//For Sender restriction&lt;br /&gt;
#vim /etc/postfix/sender_access&lt;br /&gt;
&lt;br /&gt;
pahwa.com REJECT&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
postmaster@imss.pahwa.com REJECT&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
#postmap sender_access&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
//Also Edit master.cf &lt;br /&gt;
&lt;br /&gt;
#vim master.cf&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
//IMSS: content filter smtp transport imss for IMSS&lt;br /&gt;
imss unix - - n - - smtp&lt;br /&gt;
         -o disable_dns_lookups=yes&lt;br /&gt;
         -o smtp_connect_timeout=$imss_connect_timeout&lt;br /&gt;
         -o smtp_data_done_timeout=$imss_timeout&lt;br /&gt;
//IMSS: content filter loop back smtpd&lt;br /&gt;
localhost:10026 inet n - n - 200 smtpd&lt;br /&gt;
         -o content_filter=&lt;br /&gt;
         -o smtpd_timeout=$imss_timeout&lt;br /&gt;
         -o local_recipient_maps=&lt;br /&gt;
         -o myhostname=postfix.imss71&lt;br /&gt;
         -o smtpd_client_restrictions=&lt;br /&gt;
         -o smtpd_enforce_tls=no&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
//IMSS Configuration Via Graphical Panel :-&lt;br /&gt;
All the configurations are done by IT team of Pahwa like filters and rules for AV/AS .&lt;br /&gt;
we have defined :-&lt;br /&gt;
&lt;br /&gt;
IMSS configuration -&amp;gt; SMTP Routing -&amp;gt; Domain-based delivery &lt;br /&gt;
&lt;br /&gt;
Domain             IP                         Port&lt;br /&gt;
pahwa.com     192.168.0.2         25&lt;br /&gt;
&lt;br /&gt;
Fetch mail is also configured on this server, to download mails from mx2 in case of failure of mx1 &lt;br /&gt;
http://192.168.1.15/wiki/index.php/Fetchmail&lt;br /&gt;
Configuration of fetch mail was downloaded from old server &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
DRBD and HEARTBEAT configuration:-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Step :1 Download EPEL and ELRepo (epel is for heartbeat and elrepo is for DRBD) &lt;br /&gt;
# rpm -Uvh http://elrepo.org/elrepo-release-6-4.el6.elrepo.noarch.rpm &lt;br /&gt;
vi /etc/yum.repos.d/elrepo.repo &lt;br /&gt;
enabled=0 &lt;br /&gt;
# yum --enablerepo=elrepo install drbd83-utils kmod-drbd83 &lt;br /&gt;
rpm -Uvh http://download.fedora.redhat.com/pub/epel/6/x86_64/epel-release-6-5.noarch.rpm &lt;br /&gt;
# vi /etc/yum.repos.d/epel.repo &lt;br /&gt;
enabled=0 &lt;br /&gt;
# yum --enablerepo=epel install heartbeat &lt;br /&gt;
&lt;br /&gt;
Same configyration in Node1 and Node2 &lt;br /&gt;
&lt;br /&gt;
vim /etc/hosts&lt;br /&gt;
192.168.0.5     node1.pahwa.com node1&lt;br /&gt;
192.168.0.2     mail21c.pahwa.com       mail21c&lt;br /&gt;
node2.pahwa.com need to be added later &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
#mv /etc/drbd.d/global_common.conf /etc/drbd.d/global_common.sample  &lt;br /&gt;
and create a new file: &lt;br /&gt;
&lt;br /&gt;
# vi /etc/drbd.d/global_common.conf&lt;br /&gt;
global { usage-count no; } &lt;br /&gt;
common { &lt;br /&gt;
syncer { rate 100M; } &lt;br /&gt;
} &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Create a new resource file that I called “main”, on both servers they have to be equal: &lt;br /&gt;
# vi /etc/drbd.d/main.res&lt;br /&gt;
resource main {&lt;br /&gt;
protocol C;&lt;br /&gt;
startup { wfc-timeout 0; degr-wfc-timeout 120; }&lt;br /&gt;
disk { on-io-error detach; }&lt;br /&gt;
on node1.pahwa.com {&lt;br /&gt;
device /dev/drbd0;&lt;br /&gt;
disk /dev/vg_pahwa/LogVol01;&lt;br /&gt;
meta-disk internal;&lt;br /&gt;
address 10.0.0.1:7788;&lt;br /&gt;
on node2.pahwa.com {&lt;br /&gt;
device /dev/drbd0;&lt;br /&gt;
disk /dev/vg_pahwa/LogVol01;&lt;br /&gt;
meta-disk internal;&lt;br /&gt;
address 10.0.0.2:7788;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now we have to create the metadata on both servers: &lt;br /&gt;
 #dd if=/dev/zero of= /dev/vg_home1 bs=1M count=50 &lt;br /&gt;
drbdadm create-md main (run on node1) &lt;br /&gt;
drbdadm create-md main (run on node2) &lt;br /&gt;
node 2 is not configured yet and need to be configured.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[root@node1 drbd.d]# service drbd start &lt;br /&gt;
Starting DRBD resources: [ d(main) s(main) n(main) ]. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We will tell DRBD that server1 is the Primary server: &lt;br /&gt;
On node1: &lt;br /&gt;
# drbdsetup /dev/drbd0 primary -o&lt;br /&gt;
&lt;br /&gt;
On node1: &lt;br /&gt;
# mkfs.ext4 /dev/drbd0 &lt;br /&gt;
Now DRBD is configured , now you ready to mount your /dev/drbd0 to /opt &lt;br /&gt;
On Node1 &lt;br /&gt;
# mount –t ext4 /dev/drbd0 /opt &lt;br /&gt;
&lt;br /&gt;
We will install heartbeat from the EPEL repository: &lt;br /&gt;
# rpm -Uvh http://download.fedora.redhat.com/pub/epel/6/x86_64/epel-release-6-5.noarch.rpm &lt;br /&gt;
# vi /etc/yum.repos.d/epel.repo &lt;br /&gt;
       enabled=0 &lt;br /&gt;
# yum --enablerepo=epel install heartbeat &lt;br /&gt;
  &lt;br /&gt;
Create the following file on both servers with the exact same content: &lt;br /&gt;
# vi /etc/ha.d/ha.cf &lt;br /&gt;
keepalive 2 &lt;br /&gt;
deadtime 30 &lt;br /&gt;
bcast eth0 &lt;br /&gt;
node node1.pahwa.com node2.pahwa.com &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The next setp is to create the resource file for heartbeat on both servers with exact same content again: &lt;br /&gt;
# vi /etc/ha.d/haresources &lt;br /&gt;
node1.pahwa.com IPaddr::192.168.0.2/24/eth0 drbddisk::main Filesystem::/dev/drbd0::/opt::ext4 zimbra&lt;br /&gt;
&lt;br /&gt;
# first word is the hostname of the primary server then the IP 192.168.0.2 is the one I choose to be the virtual IP to be moved to the slave in case of a failure. &lt;br /&gt;
The last thing is to create the authentication file on both servers again with the same content: &lt;br /&gt;
# vi /etc/ha.d/authkeys &lt;br /&gt;
auth 3 &lt;br /&gt;
&lt;br /&gt;
3 md5 asd1234f &lt;br /&gt;
&lt;br /&gt;
This password file should only be readable by the root user: &lt;br /&gt;
# chmod 600 /etc/ha.d/authkeys &lt;br /&gt;
&lt;br /&gt;
Need To Configure Same settings on node2.pahwa.com which will be provided later by Client.&lt;br /&gt;
Currently IP Alias is Added Directly on eth0 for node1.pahwa.com&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Zimbra Installation On node1.pahwa.com:-&lt;br /&gt;
&lt;br /&gt;
Download zcs-8.6.0_GA_1153.RHEL6_64.20141215151155.tgz and untar the compressed file .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
#cd zcs-8.6.0_GA_1153.RHEL6_64.20141215151155&lt;br /&gt;
&lt;br /&gt;
now inside this directory run install.sh&lt;br /&gt;
&lt;br /&gt;
./install.sh --platform-override &lt;br /&gt;
&lt;br /&gt;
now follow the onscreen instructions and install zimbra .&lt;br /&gt;
&lt;br /&gt;
Do not install zimbra-proxy and zimbra-memcahce , Just press [N] while setup prompts for install .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
After Successful Installation we need to create users which was provided by IT team of pahwa with passwords .&lt;br /&gt;
&lt;br /&gt;
//script location /root/Desktop/scripts &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
zmprov &amp;lt; /PATH_of_script  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now we want all external mails to go via IMSS server so we have Defined External Relay IP under Global Config via&lt;br /&gt;
Admin Panel as 192.168.0.10:25&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=Pahwa_Bryair_Zimbra&amp;diff=2024</id>
		<title>Pahwa Bryair Zimbra</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=Pahwa_Bryair_Zimbra&amp;diff=2024"/>
		<updated>2015-07-29T12:47:42Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: Created page with &amp;quot;                                                     &amp;#039;&amp;#039;&amp;#039;Pahwa New Architecture&amp;#039;&amp;#039;&amp;#039;   File:Pahwa 01.jpg     Installation :-  On IMSS server :- //Install Postfix  Yum install...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
                                                    &#039;&#039;&#039;Pahwa New Architecture&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
[[File:Pahwa 01.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Installation :-&lt;br /&gt;
&lt;br /&gt;
On IMSS server :-&lt;br /&gt;
//Install Postfix &lt;br /&gt;
Yum install postfix &lt;br /&gt;
&lt;br /&gt;
// Install Trend IMSS&lt;br /&gt;
Download   IMSS_v7.1_Linux_1224_r2.tar.gz  for &lt;br /&gt;
Untar the file and run the installation script :-&lt;br /&gt;
./ isinst.sh  &lt;br /&gt;
Press y when ask for installation and confirm .&lt;br /&gt;
It will ask for database server to install locally , press y and proceed .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Postfix Configuration.&lt;br /&gt;
cd /etc/postfix&lt;br /&gt;
&lt;br /&gt;
#vim main.cf&lt;br /&gt;
&lt;br /&gt;
//insert following entry &lt;br /&gt;
&lt;br /&gt;
mydomain = pahwa.com&lt;br /&gt;
myhostname = imss.pahwa.com&lt;br /&gt;
mydestination = $myhostname, localhost.$mydomain, $mydomain&lt;br /&gt;
default_process_limit=200&lt;br /&gt;
imss_timeout=10m&lt;br /&gt;
imss_connect_timeout=1s&lt;br /&gt;
content_filter = imss:localhost:10025&lt;br /&gt;
imss_destination_recipient_limit=200&lt;br /&gt;
imss_destination_concurrency_limit=200&lt;br /&gt;
&lt;br /&gt;
smtpd_client_restrictions =&lt;br /&gt;
  permit_mynetworks,&lt;br /&gt;
  reject_rbl_client bl.spamcop.net,&lt;br /&gt;
  reject_rbl_client b.barracudacentral.org,&lt;br /&gt;
  reject_rbl_client cbl.abuseat.org,&lt;br /&gt;
  reject_rbl_client dnsbl.sorbs.net,&lt;br /&gt;
  permit&lt;br /&gt;
&lt;br /&gt;
disable_vrfy_command = yes&lt;br /&gt;
smtpd_recipient_restrictions =&lt;br /&gt;
  check_recipient_access hash:/etc/postfix/recipient_domains, permit_mynetworks, permit_sasl_authenticated,&lt;br /&gt;
  reject_unverified_recipient,&lt;br /&gt;
  reject_non_fqdn_sender,&lt;br /&gt;
  reject_non_fqdn_recipient,&lt;br /&gt;
  reject_unauth_destination,&lt;br /&gt;
  reject_unauth_pipelining,&lt;br /&gt;
  reject&lt;br /&gt;
&lt;br /&gt;
smtpd_sender_restrictions =&lt;br /&gt;
  permit_mynetworks,&lt;br /&gt;
  permit_sasl_authenticated,&lt;br /&gt;
  check_sender_access hash:/etc/postfix/sender_access&lt;br /&gt;
  reject_unknown_sender_domain&lt;br /&gt;
&lt;br /&gt;
mynetworks = 127.0.0.1, 192.168.0.5, 192.168.0.254, 192.168.0.2&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
//For recipent restriction&lt;br /&gt;
&lt;br /&gt;
#vim recipient_domains  &lt;br /&gt;
//Make Entry :-&lt;br /&gt;
pahwa.com OK&lt;br /&gt;
&lt;br /&gt;
//Now Postmap command to make db&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
#postmap recipient_domains&lt;br /&gt;
&lt;br /&gt;
//For Sender restriction&lt;br /&gt;
#vim /etc/postfix/sender_access&lt;br /&gt;
&lt;br /&gt;
pahwa.com REJECT&lt;br /&gt;
postmaster@imss.pahwa.com REJECT&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
#postmap sender_access&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
//Also Edit master.cf &lt;br /&gt;
&lt;br /&gt;
#vim master.cf&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
//IMSS: content filter smtp transport imss for IMSS&lt;br /&gt;
imss unix - - n - - smtp&lt;br /&gt;
         -o disable_dns_lookups=yes&lt;br /&gt;
         -o smtp_connect_timeout=$imss_connect_timeout&lt;br /&gt;
         -o smtp_data_done_timeout=$imss_timeout&lt;br /&gt;
//IMSS: content filter loop back smtpd&lt;br /&gt;
localhost:10026 inet n - n - 200 smtpd&lt;br /&gt;
         -o content_filter=&lt;br /&gt;
         -o smtpd_timeout=$imss_timeout&lt;br /&gt;
         -o local_recipient_maps=&lt;br /&gt;
         -o myhostname=postfix.imss71&lt;br /&gt;
         -o smtpd_client_restrictions=&lt;br /&gt;
         -o smtpd_enforce_tls=no&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
//IMSS Configuration Via Graphical Panel :-&lt;br /&gt;
All the configurations are done by IT team of Pahwa like filters and rules for AV/AS .&lt;br /&gt;
we have defined :-&lt;br /&gt;
&lt;br /&gt;
IMSS configuration -&amp;gt; SMTP Routing -&amp;gt; Domain-based delivery &lt;br /&gt;
&lt;br /&gt;
Domain             IP                         Port&lt;br /&gt;
pahwa.com     192.168.0.2         25&lt;br /&gt;
&lt;br /&gt;
Fetch mail is also configured on this server, to download mails from mx2 in case of failure of mx1 &lt;br /&gt;
http://192.168.1.15/wiki/index.php/Fetchmail&lt;br /&gt;
Configuration of fetch mail was downloaded from old server &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
DRBD and HEARTBEAT configuration:-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Step :1 Download EPEL and ELRepo (epel is for heartbeat and elrepo is for DRBD) &lt;br /&gt;
# rpm -Uvh http://elrepo.org/elrepo-release-6-4.el6.elrepo.noarch.rpm &lt;br /&gt;
vi /etc/yum.repos.d/elrepo.repo &lt;br /&gt;
enabled=0 &lt;br /&gt;
# yum --enablerepo=elrepo install drbd83-utils kmod-drbd83 &lt;br /&gt;
rpm -Uvh http://download.fedora.redhat.com/pub/epel/6/x86_64/epel-release-6-5.noarch.rpm &lt;br /&gt;
# vi /etc/yum.repos.d/epel.repo &lt;br /&gt;
enabled=0 &lt;br /&gt;
# yum --enablerepo=epel install heartbeat &lt;br /&gt;
&lt;br /&gt;
Same configyration in Node1 and Node2 &lt;br /&gt;
&lt;br /&gt;
vim /etc/hosts&lt;br /&gt;
192.168.0.5     node1.pahwa.com node1&lt;br /&gt;
192.168.0.2     mail21c.pahwa.com       mail21c&lt;br /&gt;
node2.pahwa.com need to be added later &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
#mv /etc/drbd.d/global_common.conf /etc/drbd.d/global_common.sample  &lt;br /&gt;
and create a new file: &lt;br /&gt;
&lt;br /&gt;
# vi /etc/drbd.d/global_common.conf&lt;br /&gt;
global { usage-count no; } &lt;br /&gt;
common { &lt;br /&gt;
syncer { rate 100M; } &lt;br /&gt;
} &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Create a new resource file that I called “main”, on both servers they have to be equal: &lt;br /&gt;
# vi /etc/drbd.d/main.res&lt;br /&gt;
resource main {&lt;br /&gt;
protocol C;&lt;br /&gt;
startup { wfc-timeout 0; degr-wfc-timeout 120; }&lt;br /&gt;
disk { on-io-error detach; }&lt;br /&gt;
on node1.pahwa.com {&lt;br /&gt;
device /dev/drbd0;&lt;br /&gt;
disk /dev/vg_pahwa/LogVol01;&lt;br /&gt;
meta-disk internal;&lt;br /&gt;
address 10.0.0.1:7788;&lt;br /&gt;
on node2.pahwa.com {&lt;br /&gt;
device /dev/drbd0;&lt;br /&gt;
disk /dev/vg_pahwa/LogVol01;&lt;br /&gt;
meta-disk internal;&lt;br /&gt;
address 10.0.0.2:7788;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now we have to create the metadata on both servers: &lt;br /&gt;
 #dd if=/dev/zero of= /dev/vg_home1 bs=1M count=50 &lt;br /&gt;
drbdadm create-md main (run on node1) &lt;br /&gt;
drbdadm create-md main (run on node2) &lt;br /&gt;
node 2 is not configured yet and need to be configured.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[root@node1 drbd.d]# service drbd start &lt;br /&gt;
Starting DRBD resources: [ d(main) s(main) n(main) ]. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We will tell DRBD that server1 is the Primary server: &lt;br /&gt;
On node1: &lt;br /&gt;
# drbdsetup /dev/drbd0 primary -o&lt;br /&gt;
&lt;br /&gt;
On node1: &lt;br /&gt;
# mkfs.ext4 /dev/drbd0 &lt;br /&gt;
Now DRBD is configured , now you ready to mount your /dev/drbd0 to /opt &lt;br /&gt;
On Node1 &lt;br /&gt;
# mount –t ext4 /dev/drbd0 /opt &lt;br /&gt;
&lt;br /&gt;
We will install heartbeat from the EPEL repository: &lt;br /&gt;
# rpm -Uvh http://download.fedora.redhat.com/pub/epel/6/x86_64/epel-release-6-5.noarch.rpm &lt;br /&gt;
# vi /etc/yum.repos.d/epel.repo &lt;br /&gt;
       enabled=0 &lt;br /&gt;
# yum --enablerepo=epel install heartbeat &lt;br /&gt;
  &lt;br /&gt;
Create the following file on both servers with the exact same content: &lt;br /&gt;
# vi /etc/ha.d/ha.cf &lt;br /&gt;
keepalive 2 &lt;br /&gt;
deadtime 30 &lt;br /&gt;
bcast eth0 &lt;br /&gt;
node node1.pahwa.com node2.pahwa.com &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The next setp is to create the resource file for heartbeat on both servers with exact same content again: &lt;br /&gt;
# vi /etc/ha.d/haresources &lt;br /&gt;
node1.pahwa.com IPaddr::192.168.0.2/24/eth0 drbddisk::main Filesystem::/dev/drbd0::/opt::ext4 zimbra&lt;br /&gt;
&lt;br /&gt;
# first word is the hostname of the primary server then the IP 192.168.0.2 is the one I choose to be the virtual IP to be moved to the slave in case of a failure. &lt;br /&gt;
The last thing is to create the authentication file on both servers again with the same content: &lt;br /&gt;
# vi /etc/ha.d/authkeys &lt;br /&gt;
auth 3 &lt;br /&gt;
&lt;br /&gt;
3 md5 asd1234f &lt;br /&gt;
&lt;br /&gt;
This password file should only be readable by the root user: &lt;br /&gt;
# chmod 600 /etc/ha.d/authkeys &lt;br /&gt;
&lt;br /&gt;
Need To Configure Same settings on node2.pahwa.com which will be provided later by Client.&lt;br /&gt;
Currently IP Alias is Added Directly on eth0 for node1.pahwa.com&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Zimbra Installation On node1.pahwa.com:-&lt;br /&gt;
&lt;br /&gt;
Download zcs-8.6.0_GA_1153.RHEL6_64.20141215151155.tgz and untar the compressed file .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
#cd zcs-8.6.0_GA_1153.RHEL6_64.20141215151155&lt;br /&gt;
&lt;br /&gt;
now inside this directory run install.sh&lt;br /&gt;
&lt;br /&gt;
./install.sh --platform-override &lt;br /&gt;
&lt;br /&gt;
now follow the onscreen instructions and install zimbra .&lt;br /&gt;
&lt;br /&gt;
Do not install zimbra-proxy and zimbra-memcahce , Just press [N] while setup prompts for install .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
After Successful Installation we need to create users which was provided by IT team of pahwa with passwords .&lt;br /&gt;
&lt;br /&gt;
//script location /root/Desktop/scripts &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
zmprov &amp;lt; /PATH_of_script  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now we want all external mails to go via IMSS server so we have Defined External Relay IP under Global Config via&lt;br /&gt;
Admin Panel as 192.168.0.10:25&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=File:Pahwa_01.jpg&amp;diff=2023</id>
		<title>File:Pahwa 01.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=File:Pahwa_01.jpg&amp;diff=2023"/>
		<updated>2015-07-29T12:40:28Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=Zimbra_OSE_with_Active_sync_with_mobile_and_outlook13/window8_mail&amp;diff=2017</id>
		<title>Zimbra OSE with Active sync with mobile and outlook13/window8 mail</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=Zimbra_OSE_with_Active_sync_with_mobile_and_outlook13/window8_mail&amp;diff=2017"/>
		<updated>2015-07-17T10:58:54Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:Zimbra]]&lt;br /&gt;
&lt;br /&gt;
 &lt;br /&gt;
&#039;&#039;&#039;Zimbra OSE with Active sync with mobile and outlook13/window8 mail&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Implementation Reference== &lt;br /&gt;
http://imanudin.net/2014/11/11/how-to-enable-mode-activesync-on-zimbra-ose/&lt;br /&gt;
&lt;br /&gt;
http://vwiki.co.uk/Z-Push_v2_with_Zimbra&lt;br /&gt;
&lt;br /&gt;
==Test Environment==&lt;br /&gt;
Test Zimbra Server - mail.sysnetglobal.net &lt;br /&gt;
&lt;br /&gt;
Test z-push server - 182.50.129.154 ( earlier securitrans server ) on Centos 6x &lt;br /&gt;
&lt;br /&gt;
test account - biswajit.banerjee@sysnetglobal.net - pass Sysop_0603&lt;br /&gt;
&lt;br /&gt;
domain mapping - mobile.tetrain.com for ip  182.50.129.154&lt;br /&gt;
&lt;br /&gt;
=Implementation on the activesync server (182.50.129.154)=&lt;br /&gt;
&lt;br /&gt;
Install packages needed by Z-Push&lt;br /&gt;
&lt;br /&gt;
 yum install php-cli php-soap php-process php httpd&lt;br /&gt;
&lt;br /&gt;
Download and install Z-Push. When this article written, Z-Push final release is 2.1.3-1892 version&lt;br /&gt;
&lt;br /&gt;
 wget -c http://download.z-push.org/final/2.1/z-push-2.1.3-1892.tar.gz&lt;br /&gt;
 tar -zxvf z-push-2.1.3-1892.tar.gz&lt;br /&gt;
 mv z-push-2.1.3-1892 /var/www/html/z-push&lt;br /&gt;
&lt;br /&gt;
Make log directory and data&lt;br /&gt;
&lt;br /&gt;
 mkdir /var/lib/z-push /var/log/z-push&lt;br /&gt;
 chmod 755 /var/lib/z-push /var/log/z-push&lt;br /&gt;
 chown apache:apache /var/lib/z-push /var/log/z-push&lt;br /&gt;
&lt;br /&gt;
Make document root for Z-Push on Apache&lt;br /&gt;
 &lt;br /&gt;
vi /etc/httpd/conf.d/z-push.conf&lt;br /&gt;
&lt;br /&gt;
Fill with information like below&lt;br /&gt;
&lt;br /&gt;
 Alias /Microsoft-Server-ActiveSync /var/www/html/z-push/index.php&lt;br /&gt;
 php_flag magic_quotes_gpc off&lt;br /&gt;
 php_flag register_globals off&lt;br /&gt;
 php_flag magic_quotes_runtime off&lt;br /&gt;
 php_flag short_open_tag on&lt;br /&gt;
&lt;br /&gt;
Also make sure memory_limit = 128M on /etc/php.ini. Download Z-Push Zimbra Backend&lt;br /&gt;
 &lt;br /&gt;
wget -c http://downloads.sourceforge.net/project/zimbrabackend/Release61/zimbra61.tgz&lt;br /&gt;
 tar -zxvf zimbra61.tgz&lt;br /&gt;
 mv zimbra61/z-push-2/ /var/www/html/z-push/backend/zimbra&lt;br /&gt;
&lt;br /&gt;
Configure Z-Push for using Zimbra Backend&lt;br /&gt;
&lt;br /&gt;
 vi /var/www/html/z-push/config.php&lt;br /&gt;
&lt;br /&gt;
change and adjust with your region&lt;br /&gt;
&lt;br /&gt;
 define(&#039;PROVISIONING&#039;, false);&lt;br /&gt;
 define(&#039;LOOSE_PROVISIONING&#039;, true);&lt;br /&gt;
 define(&#039;TIMEZONE&#039;, &#039;Asia/Kolkata&#039;);&lt;br /&gt;
 define(&#039;BACKEND_PROVIDER&#039;, &#039;BackendZimbra&#039;);&lt;br /&gt;
&lt;br /&gt;
Configure Zimbra Backend and define Zimbra URL to localhost or hostname of Zimbra&lt;br /&gt;
&lt;br /&gt;
 vi /var/www/html/z-push/backend/zimbra/config.php&lt;br /&gt;
&lt;br /&gt;
 define(&#039;ZIMBRA_URL&#039;, &#039;http://mail.sysnetglobal.net&#039;);&lt;br /&gt;
&lt;br /&gt;
Restart service httpd&lt;br /&gt;
 &lt;br /&gt;
 service httpd restart&lt;br /&gt;
&lt;br /&gt;
== Issue on Z-push Side ==&lt;br /&gt;
Some additional steps are sometimes required due to bugs etc, see the INSTALL file included with the backend for more info.&lt;br /&gt;
&lt;br /&gt;
If running Zimbra backend 59 onwards fix Z-Push&#039;s RowCmp() function&lt;br /&gt;
Within z-push/lib/default/diffbackend/diffstate.php, replace existing contents of RowCmp() with&lt;br /&gt;
 return strcmp( $b[&amp;quot;id&amp;quot;], $a[&amp;quot;id&amp;quot;] ) ;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Changes on Zimbra Server ( mail.sysnetglobal.net ) side ==&lt;br /&gt;
&lt;br /&gt;
If running Zimbra 7.2 onwards and have clients with multiple devices you need to allow them to connect simultaneously, on your Zimbra server allow an appropriate number of sessions (default is 5)&lt;br /&gt;
 zmlocalconfig -e zimbra_session_limit_soap=7&lt;br /&gt;
 zmconfigdctl reload&lt;br /&gt;
&lt;br /&gt;
If running Zimbra 8 onwards you need to whitelist your Z-Push server otherwise its likely to get blocked by Zimbra, on your Zimbra server allow your Z-Push server&#039;s IP address&lt;br /&gt;
 zmprov mcf zimbraHttpThrottleSafeIPs 182.50.129.154&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=Basic Testing =&lt;br /&gt;
&lt;br /&gt;
check ActiveSync with browser : http://182.50.129.154/Microsoft-Server-ActiveSync. If asking username and password, fill with username and password accounts your Zimbra Mail Server. If appear information like below, configuration Z-Push and Z-Push Zimbra Backend has been success and could be used with mobile devices&lt;br /&gt;
&lt;br /&gt;
[[image:Z-push.png]]&lt;br /&gt;
&lt;br /&gt;
=Outlook Configuration =&lt;br /&gt;
&lt;br /&gt;
# Make sure you use the server name ( in our case mobile.tetrain.com ) ,use of IP will not work &lt;br /&gt;
# Please ensure the use of Outlook 13 only as other lower version will not work . Only Outlook 13 supports Active sync .&lt;br /&gt;
# It only supports SSL based configuration , non SSL based z-push configuration will not be supported . That means we need to have Authosized SSL certificate for mobile.tetrain.com ( in our example ) and https is enabled on the Z-push server .  &lt;br /&gt;
# while configuration choose manual and then  Outlook.com or Exchange Activesync service&lt;br /&gt;
# select as shown in picture (only example)&lt;br /&gt;
[[image:Thumb.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Outlook connecting issue - resolution ==&lt;br /&gt;
&lt;br /&gt;
Reference : http://www.vionblog.com/connect-zimbra-community-with-outlook-2013/&lt;br /&gt;
&lt;br /&gt;
First time the connectivity with the Server will fail &lt;br /&gt;
&lt;br /&gt;
so &lt;br /&gt;
&lt;br /&gt;
First time Open your task manager by holding “Ctrl + Shift + Esc” or right click on your task bar and select “Task Manager”&lt;br /&gt;
At the Windows Task Manager, navigate to “Processes” tab (Windows 7) / “Details” tab (Windows 8) Taskmanager&lt;br /&gt;
&lt;br /&gt;
Look for outlook.exe process and click “End Process”, if any confirmation dialog appear, simply click&lt;br /&gt;
&lt;br /&gt;
Resolution Of This Outlook Error :-&lt;br /&gt;
 You can edit z-push core files so you don’t have to kill the Outlook process.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
vi /var/www/z-push/lib/core/zpush.php&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  static private $supportedASVersions = array(&lt;br /&gt;
 //self::ASV_1,&lt;br /&gt;
 //self::ASV_2,&lt;br /&gt;
 //self::ASV_21,&lt;br /&gt;
 self::ASV_25,&lt;br /&gt;
 self::ASV_12,&lt;br /&gt;
 self::ASV_121,&lt;br /&gt;
 self::ASV_14&lt;br /&gt;
 );&lt;br /&gt;
&lt;br /&gt;
Comment first 3 lines as shown&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Mobile Configuration =&lt;br /&gt;
&lt;br /&gt;
Almost All mobiles with Microsoft OS , Android OS , Nokia Smart Phone , IOS (  Apple Phone ) will support Activesync.&lt;br /&gt;
&lt;br /&gt;
Blackberry 10 onward will support Activesync. &lt;br /&gt;
&lt;br /&gt;
You can use Activesync or Exchange Account to configure the mobile . &lt;br /&gt;
&lt;br /&gt;
The mobile compatibility list is available at http://z-push.org/compatibility/&lt;br /&gt;
&lt;br /&gt;
Configuration will be like &lt;br /&gt;
 Username - Full username (biswajit.banerjee@sysnetglobal.net)&lt;br /&gt;
 Password - email account&#039;s password &lt;br /&gt;
 Port - 80 ( in our case )&lt;br /&gt;
 ssl - no ( as our implementation is without ssl so we are making it no , if implentation is with ssl (required in production environment ) then make it yes )&lt;br /&gt;
&lt;br /&gt;
== Thunderbird Configurations ==&lt;br /&gt;
Thunderbird does not have active sync capabilities yet . But all feature of email , contact , calander and task can be synced directly from Zimbra open source . &lt;br /&gt;
&lt;br /&gt;
For email sync use IMAP &lt;br /&gt;
&lt;br /&gt;
for GAL ( Global Address book list ) please follow - http://blog.darioef.com/2014/07/zimbra-gal-thunderbird-24.html&lt;br /&gt;
&lt;br /&gt;
for Calander sync , follow - http://community.zimbra.com/collaboration/f/1897/t/1136947&lt;br /&gt;
 &lt;br /&gt;
 Thunderbird with Lightning actually configure for CalDAV in a slightly unusual way in that you have to configure each calendar  individually instead of just specifying the account. You will need to specify a URL like:&lt;br /&gt;
 https://mail.example.com/dav/me@example.com/Calendar&lt;br /&gt;
 The last part of the URL is the name of your calendar.&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=Zimbra_OSE_with_Active_sync_with_mobile_and_outlook13/window8_mail&amp;diff=2016</id>
		<title>Zimbra OSE with Active sync with mobile and outlook13/window8 mail</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=Zimbra_OSE_with_Active_sync_with_mobile_and_outlook13/window8_mail&amp;diff=2016"/>
		<updated>2015-07-17T10:57:34Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:Zimbra]]&lt;br /&gt;
&lt;br /&gt;
 &lt;br /&gt;
&#039;&#039;&#039;Zimbra OSE with Active sync with mobile and outlook13/window8 mail&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Implementation Reference== &lt;br /&gt;
http://imanudin.net/2014/11/11/how-to-enable-mode-activesync-on-zimbra-ose/&lt;br /&gt;
&lt;br /&gt;
http://vwiki.co.uk/Z-Push_v2_with_Zimbra&lt;br /&gt;
&lt;br /&gt;
==Test Environment==&lt;br /&gt;
Test Zimbra Server - mail.sysnetglobal.net &lt;br /&gt;
&lt;br /&gt;
Test z-push server - 182.50.129.154 ( earlier securitrans server ) on Centos 6x &lt;br /&gt;
&lt;br /&gt;
test account - biswajit.banerjee@sysnetglobal.net - pass Sysop_0603&lt;br /&gt;
&lt;br /&gt;
domain mapping - mobile.tetrain.com for ip  182.50.129.154&lt;br /&gt;
&lt;br /&gt;
=Implementation on the activesync server (182.50.129.154)=&lt;br /&gt;
&lt;br /&gt;
Install packages needed by Z-Push&lt;br /&gt;
&lt;br /&gt;
 yum install php-cli php-soap php-process php httpd&lt;br /&gt;
&lt;br /&gt;
Download and install Z-Push. When this article written, Z-Push final release is 2.1.3-1892 version&lt;br /&gt;
&lt;br /&gt;
 wget -c http://download.z-push.org/final/2.1/z-push-2.1.3-1892.tar.gz&lt;br /&gt;
 tar -zxvf z-push-2.1.3-1892.tar.gz&lt;br /&gt;
 mv z-push-2.1.3-1892 /var/www/html/z-push&lt;br /&gt;
&lt;br /&gt;
Make log directory and data&lt;br /&gt;
&lt;br /&gt;
 mkdir /var/lib/z-push /var/log/z-push&lt;br /&gt;
 chmod 755 /var/lib/z-push /var/log/z-push&lt;br /&gt;
 chown apache:apache /var/lib/z-push /var/log/z-push&lt;br /&gt;
&lt;br /&gt;
Make document root for Z-Push on Apache&lt;br /&gt;
 &lt;br /&gt;
vi /etc/httpd/conf.d/z-push.conf&lt;br /&gt;
&lt;br /&gt;
Fill with information like below&lt;br /&gt;
&lt;br /&gt;
 Alias /Microsoft-Server-ActiveSync /var/www/html/z-push/index.php&lt;br /&gt;
 php_flag magic_quotes_gpc off&lt;br /&gt;
 php_flag register_globals off&lt;br /&gt;
 php_flag magic_quotes_runtime off&lt;br /&gt;
 php_flag short_open_tag on&lt;br /&gt;
&lt;br /&gt;
Also make sure memory_limit = 128M on /etc/php.ini. Download Z-Push Zimbra Backend&lt;br /&gt;
 &lt;br /&gt;
wget -c http://downloads.sourceforge.net/project/zimbrabackend/Release61/zimbra61.tgz&lt;br /&gt;
 tar -zxvf zimbra61.tgz&lt;br /&gt;
 mv zimbra61/z-push-2/ /var/www/html/z-push/backend/zimbra&lt;br /&gt;
&lt;br /&gt;
Configure Z-Push for using Zimbra Backend&lt;br /&gt;
&lt;br /&gt;
 vi /var/www/html/z-push/config.php&lt;br /&gt;
&lt;br /&gt;
change and adjust with your region&lt;br /&gt;
&lt;br /&gt;
 define(&#039;PROVISIONING&#039;, false);&lt;br /&gt;
 define(&#039;LOOSE_PROVISIONING&#039;, true);&lt;br /&gt;
 define(&#039;TIMEZONE&#039;, &#039;Asia/Kolkata&#039;);&lt;br /&gt;
 define(&#039;BACKEND_PROVIDER&#039;, &#039;BackendZimbra&#039;);&lt;br /&gt;
&lt;br /&gt;
Configure Zimbra Backend and define Zimbra URL to localhost or hostname of Zimbra&lt;br /&gt;
&lt;br /&gt;
 vi /var/www/html/z-push/backend/zimbra/config.php&lt;br /&gt;
&lt;br /&gt;
 define(&#039;ZIMBRA_URL&#039;, &#039;http://mail.sysnetglobal.net&#039;);&lt;br /&gt;
&lt;br /&gt;
Restart service httpd&lt;br /&gt;
 &lt;br /&gt;
 service httpd restart&lt;br /&gt;
&lt;br /&gt;
== Issue on Z-push Side ==&lt;br /&gt;
Some additional steps are sometimes required due to bugs etc, see the INSTALL file included with the backend for more info.&lt;br /&gt;
&lt;br /&gt;
If running Zimbra backend 59 onwards fix Z-Push&#039;s RowCmp() function&lt;br /&gt;
Within z-push/lib/default/diffbackend/diffstate.php, replace existing contents of RowCmp() with&lt;br /&gt;
 return strcmp( $b[&amp;quot;id&amp;quot;], $a[&amp;quot;id&amp;quot;] ) ;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Changes on Zimbra Server ( mail.sysnetglobal.net ) side ==&lt;br /&gt;
&lt;br /&gt;
If running Zimbra 7.2 onwards and have clients with multiple devices you need to allow them to connect simultaneously, on your Zimbra server allow an appropriate number of sessions (default is 5)&lt;br /&gt;
 zmlocalconfig -e zimbra_session_limit_soap=7&lt;br /&gt;
 zmconfigdctl reload&lt;br /&gt;
&lt;br /&gt;
If running Zimbra 8 onwards you need to whitelist your Z-Push server otherwise its likely to get blocked by Zimbra, on your Zimbra server allow your Z-Push server&#039;s IP address&lt;br /&gt;
 zmprov mcf zimbraHttpThrottleSafeIPs 182.50.129.154&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=Basic Testing =&lt;br /&gt;
&lt;br /&gt;
check ActiveSync with browser : http://182.50.129.154/Microsoft-Server-ActiveSync. If asking username and password, fill with username and password accounts your Zimbra Mail Server. If appear information like below, configuration Z-Push and Z-Push Zimbra Backend has been success and could be used with mobile devices&lt;br /&gt;
&lt;br /&gt;
[[image:Z-push.png]]&lt;br /&gt;
&lt;br /&gt;
=Outlook Configuration =&lt;br /&gt;
&lt;br /&gt;
# Make sure you use the server name ( in our case mobile.tetrain.com ) ,use of IP will not work &lt;br /&gt;
# Please ensure the use of Outlook 13 only as other lower version will not work . Only Outlook 13 supports Active sync .&lt;br /&gt;
# It only supports SSL based configuration , non SSL based z-push configuration will not be supported . That means we need to have Authosized SSL certificate for mobile.tetrain.com ( in our example ) and https is enabled on the Z-push server .  &lt;br /&gt;
# while configuration choose manual and then  Outlook.com or Exchange Activesync service&lt;br /&gt;
# select as shown in picture (only example)&lt;br /&gt;
[[image:Thumb.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Outlook connecting issue - resolution ==&lt;br /&gt;
&lt;br /&gt;
Reference : http://www.vionblog.com/connect-zimbra-community-with-outlook-2013/&lt;br /&gt;
&lt;br /&gt;
First time the connectivity with the Server will fail &lt;br /&gt;
&lt;br /&gt;
so &lt;br /&gt;
&lt;br /&gt;
First time Open your task manager by holding “Ctrl + Shift + Esc” or right click on your task bar and select “Task Manager”&lt;br /&gt;
At the Windows Task Manager, navigate to “Processes” tab (Windows 7) / “Details” tab (Windows 8) Taskmanager&lt;br /&gt;
&lt;br /&gt;
Look for outlook.exe process and click “End Process”, if any confirmation dialog appear, simply click&lt;br /&gt;
&lt;br /&gt;
Resolution Of This Outlook Error :-&lt;br /&gt;
 You can edit z-push core files so you don’t have to kill the Outlook process.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
vi /var/www/z-push/lib/core/zpush.php&lt;br /&gt;
&lt;br /&gt;
static private $supportedASVersions = array(&lt;br /&gt;
 //self::ASV_1,&lt;br /&gt;
 //self::ASV_2,&lt;br /&gt;
 //self::ASV_21,&lt;br /&gt;
 self::ASV_25,&lt;br /&gt;
 self::ASV_12,&lt;br /&gt;
 self::ASV_121,&lt;br /&gt;
 self::ASV_14&lt;br /&gt;
 );&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Mobile Configuration =&lt;br /&gt;
&lt;br /&gt;
Almost All mobiles with Microsoft OS , Android OS , Nokia Smart Phone , IOS (  Apple Phone ) will support Activesync.&lt;br /&gt;
&lt;br /&gt;
Blackberry 10 onward will support Activesync. &lt;br /&gt;
&lt;br /&gt;
You can use Activesync or Exchange Account to configure the mobile . &lt;br /&gt;
&lt;br /&gt;
The mobile compatibility list is available at http://z-push.org/compatibility/&lt;br /&gt;
&lt;br /&gt;
Configuration will be like &lt;br /&gt;
 Username - Full username (biswajit.banerjee@sysnetglobal.net)&lt;br /&gt;
 Password - email account&#039;s password &lt;br /&gt;
 Port - 80 ( in our case )&lt;br /&gt;
 ssl - no ( as our implementation is without ssl so we are making it no , if implentation is with ssl (required in production environment ) then make it yes )&lt;br /&gt;
&lt;br /&gt;
== Thunderbird Configurations ==&lt;br /&gt;
Thunderbird does not have active sync capabilities yet . But all feature of email , contact , calander and task can be synced directly from Zimbra open source . &lt;br /&gt;
&lt;br /&gt;
For email sync use IMAP &lt;br /&gt;
&lt;br /&gt;
for GAL ( Global Address book list ) please follow - http://blog.darioef.com/2014/07/zimbra-gal-thunderbird-24.html&lt;br /&gt;
&lt;br /&gt;
for Calander sync , follow - http://community.zimbra.com/collaboration/f/1897/t/1136947&lt;br /&gt;
 &lt;br /&gt;
 Thunderbird with Lightning actually configure for CalDAV in a slightly unusual way in that you have to configure each calendar  individually instead of just specifying the account. You will need to specify a URL like:&lt;br /&gt;
 https://mail.example.com/dav/me@example.com/Calendar&lt;br /&gt;
 The last part of the URL is the name of your calendar.&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=Kloxo_large_database_upload_workaround&amp;diff=1981</id>
		<title>Kloxo large database upload workaround</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=Kloxo_large_database_upload_workaround&amp;diff=1981"/>
		<updated>2015-06-06T11:07:03Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:Mobilepedia]]&lt;br /&gt;
[[category:KLOXO]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;ISSUE&#039;&#039;&#039;:- There is an Issue with Kloxo that it hangs/freezes whenever client uploads File larger than 100mb .&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Resolution&#039;&#039;&#039; :-  As there is limition with kloxo , we are going to edit phpMyAdmin configuration .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Step 1 :-   Let us first go to configuration directory of PhpMyAdmin &lt;br /&gt;
            &#039;&#039;&#039;cd  /usr/local/lxlabs/kloxo/httpdocs/thirdparty/phpMyAdmin&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Step 2 :-   now we have configuration file  inside this location &lt;br /&gt;
            &#039;&#039;&#039;config.inc.php&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
open this file with and look for these parameters :-&lt;br /&gt;
&lt;br /&gt;
$cfg[&#039;UploadDir&#039;] = &#039;&#039;;  &lt;br /&gt;
&lt;br /&gt;
      &lt;br /&gt;
$cfg[&#039;SaveDir&#039;] = &#039;&#039;;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now we have to change the path for UploadDir and SaveDir  //please note UploadDir will be used while Import and SaveDir will be used while Export //&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Let us take one example of configuration done for 107.167.181.187 server , here username for FTP user is iwmp_mobi with home directory /home/iwmp_mobi/&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
$cfg[&#039;UploadDir&#039;] = &#039;/home/iwmp_mobi/&#039;;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
$cfg[&#039;SaveDir&#039;] = &#039;/home/iwmp_mobi/&#039;;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
After doing this entry save the file and restart httpd .&lt;br /&gt;
&lt;br /&gt;
This will enable PhpMyAdmin to Look inside /home/iwmp_mobi for .sql files while Import .&lt;br /&gt;
&lt;br /&gt;
while importing we just have to select &amp;quot;Select from the web server upload directory &amp;quot;&lt;br /&gt;
&lt;br /&gt;
[[Image:import_kloxo.png]]&lt;br /&gt;
&lt;br /&gt;
Client is Using Core-FTP to transfer database file directly to /home/iwmp_mobi/ directory .&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=Kloxo_large_database_upload_workaround&amp;diff=1980</id>
		<title>Kloxo large database upload workaround</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=Kloxo_large_database_upload_workaround&amp;diff=1980"/>
		<updated>2015-06-06T11:06:30Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:Mobilepedia]]&lt;br /&gt;
[[category:KLOXO]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;ISSUE&#039;&#039;&#039;:- There is an Issue with Kloxo that it hangs/freezes whenever client uploads File larger than 100mb .&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Resolution&#039;&#039;&#039; :-  As there is limition with kloxo , we are going to edit phpMyAdmin configuration .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Step 1 :-   Let us first go to configuration directory of PhpMyAdmin &lt;br /&gt;
            &#039;&#039;&#039;cd  /usr/local/lxlabs/kloxo/httpdocs/thirdparty/phpMyAdmin&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Step 2 :-   now we have configuration file  inside this location &lt;br /&gt;
            &#039;&#039;&#039;config.inc.php&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
open this file with and look for these parameters :-&lt;br /&gt;
&lt;br /&gt;
$cfg[&#039;UploadDir&#039;] = &#039;&#039;;  &lt;br /&gt;
&lt;br /&gt;
      &lt;br /&gt;
$cfg[&#039;SaveDir&#039;] = &#039;&#039;;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now we have to change the path for UploadDir and SaveDir  //please note UploadDir will be used while Import and SaveDir will be used while Export //&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Let us take one example of configuration done for 107.167.181.187 server , here username for FTP user is iwmp_mobi with home directory /home/iwmp_mobi/&lt;br /&gt;
$cfg[&#039;UploadDir&#039;] = &#039;/home/iwmp_mobi/&#039;;&lt;br /&gt;
$cfg[&#039;SaveDir&#039;] = &#039;/home/iwmp_mobi/&#039;;&lt;br /&gt;
&lt;br /&gt;
After doing this entry save the file and restart httpd .&lt;br /&gt;
&lt;br /&gt;
This will enable PhpMyAdmin to Look inside /home/iwmp_mobi for .sql files while Import .&lt;br /&gt;
&lt;br /&gt;
while importing we just have to select &amp;quot;Select from the web server upload directory &amp;quot;&lt;br /&gt;
&lt;br /&gt;
[[Image:import_kloxo.png]]&lt;br /&gt;
&lt;br /&gt;
Client is Using Core-FTP to transfer database file directly to /home/iwmp_mobi/ directory .&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=Kloxo_large_database_upload_workaround&amp;diff=1979</id>
		<title>Kloxo large database upload workaround</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=Kloxo_large_database_upload_workaround&amp;diff=1979"/>
		<updated>2015-06-06T11:05:59Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:Mobilepedia]]&lt;br /&gt;
[[category:KLOXO]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;ISSUE&#039;&#039;&#039;:- There is an Issue with Kloxo that it hangs/freezes whenever client uploads File larger than 100mb .&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Resolution&#039;&#039;&#039; :-  As there is limition with kloxo , we are going to edit phpMyAdmin configuration .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Step 1 :-   Let us first go to configuration directory of PhpMyAdmin &lt;br /&gt;
            &#039;&#039;&#039;cd  /usr/local/lxlabs/kloxo/httpdocs/thirdparty/phpMyAdmin&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Step 2 :-   now we have configuration file  inside this location &lt;br /&gt;
            &#039;&#039;&#039;config.inc.php&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
open this file with and look for these parameters :-&lt;br /&gt;
&lt;br /&gt;
$cfg[&#039;UploadDir&#039;] = &#039;&#039;;        &lt;br /&gt;
$cfg[&#039;SaveDir&#039;] = &#039;&#039;;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now we have to change the path for UploadDir and SaveDir  //please note UploadDir will be used while Import and SaveDir will be used while Export //&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Let us take one example of configuration done for 107.167.181.187 server , here username for FTP user is iwmp_mobi with home directory /home/iwmp_mobi/&lt;br /&gt;
$cfg[&#039;UploadDir&#039;] = &#039;/home/iwmp_mobi/&#039;;&lt;br /&gt;
$cfg[&#039;SaveDir&#039;] = &#039;/home/iwmp_mobi/&#039;;&lt;br /&gt;
&lt;br /&gt;
After doing this entry save the file and restart httpd .&lt;br /&gt;
&lt;br /&gt;
This will enable PhpMyAdmin to Look inside /home/iwmp_mobi for .sql files while Import .&lt;br /&gt;
&lt;br /&gt;
while importing we just have to select &amp;quot;Select from the web server upload directory &amp;quot;&lt;br /&gt;
&lt;br /&gt;
[[Image:import_kloxo.png]]&lt;br /&gt;
&lt;br /&gt;
Client is Using Core-FTP to transfer database file directly to /home/iwmp_mobi/ directory .&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=Kloxo_large_database_upload_workaround&amp;diff=1978</id>
		<title>Kloxo large database upload workaround</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=Kloxo_large_database_upload_workaround&amp;diff=1978"/>
		<updated>2015-06-06T10:52:15Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:Mobilepedia]]&lt;br /&gt;
[[category:KLOXO]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;ISSUE&#039;&#039;&#039;:- There is an Issue with Kloxo that it hangs/freezes whenever client uploads File larger than 100mb .&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Resolution&#039;&#039;&#039; :-  As there is limition with kloxo , we are going to edit phpMyAdmin configuration .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Step 1 :-   Let us first go to configuration directory of PhpMyAdmin &lt;br /&gt;
            &#039;&#039;&#039;cd  /usr/local/lxlabs/kloxo/httpdocs/thirdparty/phpMyAdmin&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Step 2 :-   now we have configuration file  inside this location &lt;br /&gt;
            &#039;&#039;&#039;config.inc.php&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
open this file with and look for these parameters :-&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;$cfg[&#039;UploadDir&#039;] = &#039;&#039;;&#039;&#039;&#039;         &lt;br /&gt;
&#039;&#039;&#039;$cfg[&#039;SaveDir&#039;] = &#039;&#039;;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now we have to change the path for UploadDir and SaveDir  //please note UploadDir will be used while Import and SaveDir will be used while Export //&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Let us take one example of configuration done for 107.167.181.187 server , here username for FTP user is iwmp_mobi with home directory /home/iwmp_mobi/&lt;br /&gt;
&#039;&#039;&#039;$cfg[&#039;UploadDir&#039;] = &#039;/home/iwmp_mobi/&#039;;&#039;&#039;&#039;&lt;br /&gt;
&#039;&#039;&#039;$cfg[&#039;SaveDir&#039;] = &#039;/home/iwmp_mobi/&#039;;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
After doing this entry save the file and restart httpd .&lt;br /&gt;
&lt;br /&gt;
This will enable PhpMyAdmin to Look inside /home/iwmp_mobi for .sql files while Import .&lt;br /&gt;
&lt;br /&gt;
while importing we just have to select &amp;quot;Select from the web server upload directory &amp;quot;&lt;br /&gt;
&lt;br /&gt;
[[Image:import_kloxo.png]]&lt;br /&gt;
&lt;br /&gt;
Client is Using Core-FTP to transfer database file directly to /home/iwmp_mobi/ directory .&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=Kloxo_large_database_upload_workaround&amp;diff=1977</id>
		<title>Kloxo large database upload workaround</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=Kloxo_large_database_upload_workaround&amp;diff=1977"/>
		<updated>2015-06-06T10:51:44Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: Created page with &amp;quot;category:Mobilepedia category:KLOXO  &amp;#039;&amp;#039;&amp;#039;ISSUE&amp;#039;&amp;#039;&amp;#039;:- There is an Issue with Kloxo that it hangs/freezes whenever client uploads File larger than 100mb .  &amp;#039;&amp;#039;&amp;#039;Resolution&amp;#039;&amp;#039;...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:Mobilepedia]]&lt;br /&gt;
[[category:KLOXO]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;ISSUE&#039;&#039;&#039;:- There is an Issue with Kloxo that it hangs/freezes whenever client uploads File larger than 100mb .&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Resolution&#039;&#039;&#039; :-  As there is limition with kloxo , we are going to edit phpMyAdmin configuration .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Step 1 :-   Let us first go to configuration directory of PhpMyAdmin &lt;br /&gt;
            &#039;&#039;&#039;cd  /usr/local/lxlabs/kloxo/httpdocs/thirdparty/phpMyAdmin&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Step 2 :-   now we have configuration file  inside this location &lt;br /&gt;
            &#039;&#039;&#039;config.inc.php&#039;&#039;&#039;&lt;br /&gt;
[[category:Tetra Clients]]&lt;br /&gt;
[[category:kloxo]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
open this file with and look for these parameters :-&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;$cfg[&#039;UploadDir&#039;] = &#039;&#039;;&#039;&#039;&#039;         &lt;br /&gt;
&#039;&#039;&#039;$cfg[&#039;SaveDir&#039;] = &#039;&#039;;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now we have to change the path for UploadDir and SaveDir  //please note UploadDir will be used while Import and SaveDir will be used while Export //&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Let us take one example of configuration done for 107.167.181.187 server , here username for FTP user is iwmp_mobi with home directory /home/iwmp_mobi/&lt;br /&gt;
&#039;&#039;&#039;$cfg[&#039;UploadDir&#039;] = &#039;/home/iwmp_mobi/&#039;;&#039;&#039;&#039;&lt;br /&gt;
&#039;&#039;&#039;$cfg[&#039;SaveDir&#039;] = &#039;/home/iwmp_mobi/&#039;;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
After doing this entry save the file and restart httpd .&lt;br /&gt;
&lt;br /&gt;
This will enable PhpMyAdmin to Look inside /home/iwmp_mobi for .sql files while Import .&lt;br /&gt;
&lt;br /&gt;
while importing we just have to select &amp;quot;Select from the web server upload directory &amp;quot;&lt;br /&gt;
&lt;br /&gt;
[[Image:import_kloxo.png]]&lt;br /&gt;
&lt;br /&gt;
Client is Using Core-FTP to transfer database file directly to /home/iwmp_mobi/ directory .&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=File:Import_kloxo.png&amp;diff=1976</id>
		<title>File:Import kloxo.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=File:Import_kloxo.png&amp;diff=1976"/>
		<updated>2015-06-06T10:48:32Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1914</id>
		<title>PF Sense Firewall Implementation at GIPL</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1914"/>
		<updated>2015-04-16T11:23:27Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:Tetra Clients]]&lt;br /&gt;
[[category:GSPC]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;center&amp;gt;&amp;lt;u&amp;gt;&#039;&#039;&#039;PF Sense Firewall Implementation at GIPL , GandhiNagar &#039;&#039;&#039;&amp;lt;/u&amp;gt;&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-000.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Performing a Full Install (LiveCD) ==&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Installation&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;pfSense&#039;&#039;&#039; is an open source firewall/router computer software distribution based on FreeBSD. It is installed on a computer to make a dedicated firewall/router for a network and is noted for its reliability[1] and offering features often only found in expensive commercial firewalls&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Download pfSense&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Visit https://www.pfsense.org/download/mirror.php?section=downloads&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Step 1 :- &#039;&#039;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Power on the target system and connect the install media: Place the CD into the drive or plug the Memstick into a USB port. If the BIOS is set to boot from CD/USB, pfSense will start. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-001.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
As the operating system boots and pfSense starts, a prompt is presented with some choices and a countdown timer. At this prompt, press &#039;&#039;i&#039;&#039; to invoke the installer now.&lt;br /&gt;
&lt;br /&gt;
When the installer detects multiple disks in the system the first screen available provides the option &#039;&#039;&#039;Setup GEOM Mirror&#039;&#039;&#039;. Choose that option, pick the primary disk, the disk to use for the mirror copy, and then proceed with the installation as normal. &lt;br /&gt;
&lt;br /&gt;
The Quick/Easy install choice will target the GEOM mirror automatically&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-002.jpeg]]&lt;br /&gt;
&lt;br /&gt;
At the &#039;&#039;&#039;Select Task&#039;&#039;&#039; prompt, choose &#039;&#039;Quick/Easy Install&#039;&#039;. [[Image:Gpil-003.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-004.jpeg]]&lt;br /&gt;
&lt;br /&gt;
The install will proceed, wiping the target disk and installing pfSense. Copying files may take some time to finish. &lt;br /&gt;
&lt;br /&gt;
After the files have been copied to the target disk, a choice is presented to select the console type. &#039;&#039;Standard&#039;&#039; defaults to the VGA console. &#039;&#039;Embedded&#039;&#039; defaults to serial console&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-005.jpeg]]&lt;br /&gt;
&lt;br /&gt;
Now the system must reboot so that pfSense may start from the target disk. Select &#039;&#039;Reboot&#039;&#039; and then press &#039;&#039;&#039;Enter (remove CD from Drive)&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-006.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After the system reboots, pfSense will be running from the target disk. The next step is to Assign Interfaces on the Console below.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-007.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After installation and assignment, a shell menu is presented on the console with a number of options. pfSense now is ready to be accessed via the network, LAN interface IP 192.168.1.1 is assigned by default.&lt;br /&gt;
&lt;br /&gt;
Open a web browser and navigate to https://192.168.1.1/, using the default username admin and password pfsense to login.&lt;br /&gt;
&lt;br /&gt;
The first visit to the WebGUI will be redirected to the setup wizard.&lt;br /&gt;
&lt;br /&gt;
== GUI Configuration Setup ==&lt;br /&gt;
Once The Setup is launched, Fill the details are follows:-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-008.jpg]]&lt;br /&gt;
&lt;br /&gt;
We have defined FQDN as gipl.firewall&lt;br /&gt;
&lt;br /&gt;
DNS servers:- 8.8.8.8 and 4.4.2.2 Global DNS&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click NEXT&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-009.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select The Time-Zone as Asia/Kolkata .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
And Click NEXT&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-010.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Here we have Set WAN as Static Interface&lt;br /&gt;
&lt;br /&gt;
With IP address :- 203.77.200.91/25&lt;br /&gt;
&lt;br /&gt;
Gateway :- 203.77.200.1&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-011.jpg]]&lt;br /&gt;
&lt;br /&gt;
Here we have Configured LAN interface with IP address 192.168.45.101/24&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
( note:-As per the client Network Topology , Lan interface have multiple Subnets configured , so we will be configuring Virtual IP’s from GUI )&lt;br /&gt;
&lt;br /&gt;
After Setting Admin Password, Page will be redirected to Pfsense-Dashboard.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We Have Changed Default Port from 443 to 8080 Via :-&lt;br /&gt;
[[Image:Gpil-012.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;System &amp;gt; Advanced&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-013.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Change TCP Port from Default 443 to 8080 .&lt;br /&gt;
&lt;br /&gt;
Save .&lt;br /&gt;
&lt;br /&gt;
Now pfsense Can be accessed via [https://IP:8080 https://IP:8080]&lt;br /&gt;
&lt;br /&gt;
IP Address of Firewall is 203.77.200.91 on WAN interface.&lt;br /&gt;
&lt;br /&gt;
Go to :- interface &amp;gt; assign , and edit Opt1 as DMZ , do not assign IP address to This interface , because we will be creating bridge interface .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bridge Interface ==&lt;br /&gt;
Now we have to configure &#039;&#039;&#039;Interface Bridges&#039;&#039;&#039; in order to Setup Pfsense in &lt;br /&gt;
&lt;br /&gt;
Transparent mode.&lt;br /&gt;
&lt;br /&gt;
Reference:- &amp;lt;u&amp;gt;https://doc.pfsense.org/index.php/Interface_Bridges&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Navigate To :- Interfaces &amp;gt; (assign) &lt;br /&gt;
&lt;br /&gt;
on the Bridges tab Click “ +” symbol to add a new bridge .&lt;br /&gt;
[[Image:Gpil-014.jpg]] &lt;br /&gt;
&lt;br /&gt;
Ctrl-Click to select the Member interfaces from the list of available interfaces and type a Description , we have selected WAN + DMZ as bridge0 and create new Interface BRIDGEINTERFACE using bridge0 .&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-015.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
By default, traffic is filtered on the member interfaces and not on the bridge interface itself. This behavior may be changed by toggling the values of &#039;&#039;&#039;net.link.bridge.pfil_member&#039;&#039;&#039; and net.link.bridge.pfil&#039;&#039;&#039;_bridge &#039;&#039;&#039;under System&#039;&#039;&#039; &amp;gt; Advanced &#039;&#039;&#039;on the &#039;&#039;&#039;System Tunables&#039;&#039;&#039; tab. With them set at &#039;&#039;0&#039;&#039; and &#039;&#039;1&#039;&#039;, respectively, then filtering would be performed on the bridge only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-016.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Pfsense is Configured In Bridge Mode with &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;WAN interface: - 203.77.200.91/25 gateway :- 203.77.200.1&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface:- 192.168.45.101/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;DMZ: - no ip &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;BRIDGEINTERFACE:- 203.77.200.92/25&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-017.jpg]]&lt;br /&gt;
&lt;br /&gt;
== Assign Virtual IP’s To LAN interface:- ==&lt;br /&gt;
[[Image:Gpil-018.jpg]]&lt;br /&gt;
Now as LAN environment have multiple Subnet configured, we will be assigning Virtual IP address to LAN interface.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-019.jpg]]&lt;br /&gt;
&lt;br /&gt;
Clients on LAN Environment have their Gateway Set from These Virtual IP’s.&lt;br /&gt;
&lt;br /&gt;
203.77.196.230 is added for outside access of Local Servers 203.77.192.49/28.&lt;br /&gt;
&lt;br /&gt;
(203.77.196.230) is configured in 203.77.192.2 switch which will receive any packet for 203.77.192.49/28 from Outside and send it to 203.77.196.230.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SNORT  ==&lt;br /&gt;
&amp;lt;u&amp;gt;&#039;&#039;&#039;Reference&#039;&#039;&#039;&amp;lt;/u&amp;gt; :- &amp;lt;u&amp;gt;&#039;&#039;&#039;https://doc.pfsense.org/index.php/Setup_Snort_Package&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Go to the &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab under the &#039;&#039;&#039;System&#039;&#039;&#039; menu and install the snort package.&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;When the installation completes, click on &#039;&#039;&#039;Snort&#039;&#039;&#039; under the &#039;&#039;&#039;Services&#039;&#039;&#039; menu. &amp;amp;nbsp;This will open the Snort main setup page.&lt;br /&gt;
&lt;br /&gt;
Click the &#039;&#039;&#039;Global Settings&#039;&#039;&#039; tab and perform the following At the top of the page you have three choices for Rule Sets to activate.&lt;br /&gt;
&lt;br /&gt;
Put Check mark on :-Install &#039;&#039;&#039;Snort Community&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Emerging Threats&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Snort VRT&#039;&#039;&#039; rules. And save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Updates&#039;&#039;&#039; tab is used to check the status of downloaded rules packages and to download new updates. The table shows the available rule packages and their current status [[Image:Gpil-020.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Update Button to Update the rules.&lt;br /&gt;
[[Image:Gpil-021.jpg]]&lt;br /&gt;
&lt;br /&gt;
== Add Snort to an interface ==&lt;br /&gt;
Click the Snort Interfaces tab and then the &amp;quot;+&amp;quot; icon to add a new Snort interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;On the &#039;&#039;&#039;WAN Settings&#039;&#039;&#039; tab, click the &#039;&#039;Enable&#039;&#039; checkbox.In the drop-down, choose the interface. &amp;amp;nbsp;The WAN interface is the default and is a good first choice.In the &#039;&#039;Description&#039;&#039; textbox, enter a name (WAN again, is fine here).Click the checkbox to &amp;quot;&#039;&#039;Send alerts to the main System logs&#039;&#039;&amp;quot;.leave the other settings at their defaults&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-022.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After saving, the browser will be returned to the Snort Interfaces tab. Note the warning icons in the image below showing no rules have been selected for the new Snort interface. Those rules will be configured next. Click the &amp;quot;e&amp;quot; icon to edit the new Snort interface again&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-023.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Select which types of rules will protect the network ==&lt;br /&gt;
Click the &#039;&#039;&#039;Categories&#039;&#039;&#039; tab for the new interface&lt;br /&gt;
&lt;br /&gt;
Check [https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=GPLv2_community.rules Snort GPLv2 Community Rules (VRT certified)] Box .&lt;br /&gt;
&lt;br /&gt;
And Manual Rules :-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-botcc.rules emerging-botcc.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_blacklist.rules snort_blacklist.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.so.rules snort_exploit-kit.so.rules] &lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_ddos.rules snort_ddos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_dos.rules snort_dos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.rules snort_exploit-kit.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-malware.rules emerging-malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-mobile_malware.rules emerging-mobile_malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-tor.rules emerging-tor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-trojan.rules emerging-trojan.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_malware-backdoor.rules snort_malware-backdoor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_virus.rules snort_virus.rules]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-024.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click SAVE when finished to save the selection and build the rules &lt;br /&gt;
&lt;br /&gt;
After that restart the service &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-025.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Managing Pass lists:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Pass Lists are lists of IP addresses that Snort should never block. These may be created and managed on the Pass Lists tab. When an IP address is listed on a Pass List, Snort will never insert a block on that address even when malicious traffic is detected.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;To create a new Pass List, click &amp;quot;+&amp;quot;. To edit an existing Pass List, click the &amp;quot;e&amp;quot;. To delete a Pass List, click &amp;quot;x&amp;quot;. Note that a Pass List may not be deleted if it is currently assigned to one or more Snort interfaces.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We have added GIPL IP’s in Pass list . i.e&#039;&#039;&#039; &amp;lt;u&amp;gt;203.77.192.0/20&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-026.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== IP Alias and Port Alias ==&lt;br /&gt;
IP aliases allow you to create a group of IP addresses that you can assign by group name instead of specifying each IP address individually. This can be great for specifying a group of servers that need ssh access and then in the firewall rules you can create a rule that allows ssh traffic for the ssh servers group.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Along the top menu hover over Firewall and click on Aliases.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-027.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The next tab is for setting up Port Aliases. &amp;amp;nbsp;Similar to the IP Aliases you can setup groups but on this tab you are creating groups of ports instead of IP addresses.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-028.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
IP Aliases Created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-029.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
PORT ALIAS CREATED&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-030.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Firewall Rules :- ==&lt;br /&gt;
Reference:- [https://doc.pfsense.org/index.php/Firewall_Rule_Basics https://doc.pfsense.org/index.php/Firewall_Rule_Basics]&lt;br /&gt;
&lt;br /&gt;
Firewall rules control what traffic is allowed to enter an interface on the firewall. Once traffic is passed on the interface it enters an entry in the state table is created. A state table entry allows through subsequent packets that are part of that connection.&lt;br /&gt;
&lt;br /&gt;
Firewall rules are managed at Firewall &amp;gt; Rules. Multiple rules may be selected for some actions by clicking on their row or checking the box at the start of their row. Rules may be deleted or reordered in bulk in this way. See Managing Lists of Items on pfSense for more information on the meaning of the icons when manipulating rules.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;any&#039;&#039;&#039; - &#039;&#039;0.0.0.0&#039;&#039; to &#039;&#039;255.255.255.255&#039;&#039;, or all IPv6 addresses &lt;br /&gt;
* &#039;&#039;&#039;Single host or alias&#039;&#039;&#039; - Select this and enter one IP address (&#039;&#039;1.2.3.4&#039;&#039;, &#039;&#039;aa:bb:cc:dd::1&#039;&#039;) or type the name of an Alias that has already been configured (&#039;&#039;&#039;Firewall &amp;gt; Aliases&#039;&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Network&#039;&#039;&#039; - Select this and enter a network and mask (&#039;&#039;10.99.0.0/16&#039;&#039;, &#039;&#039;aa:bb:cc:dd::0/64&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;LAN net&#039;&#039;&#039; - The subnet configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039;. On pfSense 2.2+, this also includes static route networks on that interface. &lt;br /&gt;
* &#039;&#039;&#039;LAN address&#039;&#039;&#039; - The IP address configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039; &lt;br /&gt;
* &#039;&#039;&#039;zzz Net&#039;&#039;&#039; / &#039;&#039;&#039;zzz address&#039;&#039;&#039; - Works the same as LAN above but for other interfaces (WAN, OPT1, OPT2, etc.) &lt;br /&gt;
* &#039;&#039;&#039;PPTP clients&#039;&#039;&#039; - Automatically locate and use the addresses of PPTP clients &lt;br /&gt;
* &#039;&#039;&#039;L2TP clients&#039;&#039;&#039; - Automatically locate and use the addresses of L2TP clients &lt;br /&gt;
* &#039;&#039;&#039;This Firewall (self)&#039;&#039;&#039; - Any IP address assigned to any interface on this firewall (pfSense 2.2+) &lt;br /&gt;
&lt;br /&gt;
Firewall rules are generally processed starting with Floating Rules, then Interface Group rules, then Interface tab rules&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Rules Created on bridge interface, for DMZ access&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-031.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-032.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface Rules Created:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-033.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Squid and Squidguard:- ==&lt;br /&gt;
&#039;&#039;&#039;Reference - &#039;&#039;&#039;[https://doc.pfsense.org/index.php/SquidGuard_package https://doc.pfsense.org/index.php/SquidGuard_package]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Login to your pfsense&#039;s Web Administrator, and click on &amp;quot;Server -&amp;gt; Packages&amp;quot;, scroll down the list and find squid and click on &amp;quot;+&amp;quot; button to install, wait for the process to finish then return to the packages section and look for squidguard and install that package as well.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-034.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now go to &amp;quot;Services&amp;quot; menu and look for Proxy Server &amp;amp; Proxy Filter &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-035.jpg]]&lt;br /&gt;
&lt;br /&gt;
(We are setting up the proxy server as a transparent proxy)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on Services -&amp;gt; Proxy Server.&lt;br /&gt;
&lt;br /&gt;
On the General Tab, you want to set the following settings, the Proxy Interface Option should be set to &amp;quot;LAN&amp;quot;, to set up transparent proxy server, tick the &amp;quot;Transparent Proxy&amp;quot; check box.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-036.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Tick the &amp;quot;Enabled Logging&amp;quot; Checkbox, set the log store to the default location &amp;quot; /var/squid/logs &amp;quot; rotate your logs every 30 days, set your proxy port to port number 3128 We have By-passed Proxy for 203.77.192.49/28, These are the Local Servers.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next click on the &amp;quot;Cache Mgmt.&amp;quot; tab, by default the Hard Disk Cache Size is set to 100mb, we have allocated 100GB , Memory Cache Size 3072 .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-037.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click on Save.&lt;br /&gt;
&lt;br /&gt;
Click on the Access Control Tab next, in the allowed subnets field type in your required subnets. As we have multiple Subnets, so we are going to define all.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-038.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.129/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.1.224.1/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.192.49/28&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.57/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.17/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.137/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.33.50.1/27&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click On Save &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that’s is the proxy server configured, next we are going to configure SquidGuard, click on the Services menu and select the Proxy Filter button, tick the following 3 check boxes &amp;quot;Enable&amp;quot;, &amp;quot;Enable GUI Log&amp;quot; and &amp;quot;Enable Log&amp;quot; then click the Save button, once the page has reloaded click on apply and then confirm that the Squidguard service is running by making sure the SquidGuard status is set to STARTED.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-039.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on the Black list tab and add URL &#039;&#039;&#039;http://www.shallalist.de/Downloads/shallalist.tar.gz&#039;&#039;&#039; to the Update Address and click on Download. Wait for the process to complete.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-040.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-041.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now we can set up common ACL’s&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-042.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-043.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Click on Save and restart the Squid and SquidGuard from Services. &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SARG:- ==&lt;br /&gt;
After Installing SARG package, we can configure SARG from Status &amp;gt; Sarg Reports&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-044.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select Proxy Servers as SQUID proxy . And leave Rest of Field set to Default&lt;br /&gt;
&lt;br /&gt;
And Save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Go to Next Tab Schedule&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click “+” Symbol to create new schedule &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-045.jpg]] &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Reports can be viewed From “View Reports”&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-046.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bandwidthd:- ==&lt;br /&gt;
After Installing Package &#039;&#039;&#039;bandwidthd&#039;&#039;&#039; , Configuration can be done via&lt;br /&gt;
&lt;br /&gt;
Services &amp;gt; bandwidthd&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-047.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-048.jpg]]&lt;br /&gt;
&lt;br /&gt;
Enable Bandwidthd by checking the BOX.&lt;br /&gt;
&lt;br /&gt;
Now Select the Interface: - LAN.&lt;br /&gt;
&lt;br /&gt;
Enter The Subnets from LAN interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Save and Restart bandwidthd service from Services.&lt;br /&gt;
&lt;br /&gt;
Now Bandwidthd can be accessed:-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/bandwidthd/index.html https://203.77.200.91:8080/bandwidthd/index.html]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of ntopng:- ==&lt;br /&gt;
After installing ntopng package, it appears under Diagnostics &amp;gt; ntopng. It will even track where connections were made by local PCs, and how much bandwidth was used on individual connections.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-049.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
First we have to configure ntopng settings. Via Diagnostics &amp;gt; ntopng settings.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-050.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Setup Admin Password &amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Select the Interfaces on Which ntopng will be monitoring traffic.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We have selected LAN, DMZ and BRIDGEINTERFACE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To save the changes Click “Change”&lt;br /&gt;
&lt;br /&gt;
Ntopng can be accessed via [http://203.77.200.91:3000/login.html http://203.77.200.91:3000/login.html]&lt;br /&gt;
&lt;br /&gt;
With username admin and password assigned in previous step.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Configuring OpenVPN  =&lt;br /&gt;
A VPN (virtual private network) allows us to connect directly to our home private network over the internet&lt;br /&gt;
&lt;br /&gt;
The certificate authority or CA will sign the certificates that we will be creating for the server and client side when we configure OpenVPN. You can access the certificate configuration by going over to System–&amp;gt;Cert Manager.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-051.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Under the CAs tab you might already have a CA created if you followed one of my previous articles as we needed to created one in order to sign an internal certificate to be used for securing the pfSense web interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Certificate Authority ===&lt;br /&gt;
Fill in the fields to &#039;&#039;&#039;create a new Certificate Authority&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Descriptive Name&#039;&#039;&#039; - Used as the Common Name (CN) for the CA. Do not spaces, punctuation or special characters (ex: &#039;&#039;VPN Server CA&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Key Length&#039;&#039;&#039; - Default is OK, the higher the better but will use more CPU. &lt;br /&gt;
* &#039;&#039;&#039;Lifetime&#039;&#039;&#039; - Default is OK, but can be lowered if it must be changed out more often. &lt;br /&gt;
* &#039;&#039;&#039;Country Code&#039;&#039;&#039;, &#039;&#039;&#039;State/Province&#039;&#039;&#039;, &#039;&#039;&#039;City&#039;&#039;&#039;, &#039;&#039;&#039;Organization&#039;&#039;&#039; - Enter values for this location/company. &lt;br /&gt;
* &#039;&#039;&#039;E-mail&#039;&#039;&#039; - Used as a reference on the certificate, does not receive any mail from the system. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Add New CA&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-052.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
After you finished setting up the CA the next step is to create some certificates that the recently created CA will sign for us. Since these are self-signed certificates most browsers will give you a warning&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Server Certificate ===&lt;br /&gt;
Fill in the fields to create a new &#039;&#039;&#039;Server Certificate&#039;&#039;&#039;. Similar Fields as CA entry, most of the fields carry over and do not need changed. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Create new Certificate&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-053.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that we have all the components in place we can configure OpenVPN. Head over to VPN–&amp;gt;OpenVPN.&lt;br /&gt;
&lt;br /&gt;
.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-054.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select “Wizards” from the tab at the top which will guide us step by step to configure OpenVPN&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-055.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-056.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We will select the local user access database provided by pfSense&lt;br /&gt;
&lt;br /&gt;
In the next step we will be selecting the CA that we created at the beginning of this article.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-057.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Following is the Server Certificate that we will be using which is the Certificate that we recently created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-058.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;OpenVPN Server Configuration&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;TLS Authentication&#039;&#039;&#039; -- Leave this checked, along with the box underneath to generate a new key. Using a TLS key is technically optional, but &#039;&#039;highly&#039;&#039; recommended&lt;br /&gt;
* &#039;&#039;&#039;Tunnel Network&#039;&#039;&#039; -- Should be a new, unique network that does not exist anywhere in the current network or routing table. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-059.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-060.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-061.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== Firewall Rules ===&lt;br /&gt;
The next screen offers the choice to add firewall rules automatically. For convenience, check both unless the rules will be managed manually. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== End of the Wizard ===&lt;br /&gt;
Click &#039;&#039;&#039;Finish&#039;&#039;&#039; to exit the wizard and the new settings will be saved and applied automatically. &lt;br /&gt;
&lt;br /&gt;
== Adding a User with a Certificate ==&lt;br /&gt;
Navigate to &#039;&#039;&#039;System &amp;gt; User Manager&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click &amp;quot;+&amp;quot; To add a &#039;&#039;&#039;user&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Username&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Password / Confirm password&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Check Click to create a &#039;&#039;&#039;user certificate.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in the Descriptive Name as the username&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-062.jpeg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-063.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The OpenVPN Client Export Package allows exporting configurations formatted for a wide variety of platforms. It also allows exporting a pre-packaged Windows installer executable which includes the configuration bundled inside for a painly client installation. &lt;br /&gt;
&lt;br /&gt;
=== Installing the OpenVPN Client Export Package ===&lt;br /&gt;
To Install the OpenVPN Client Export Package &lt;br /&gt;
&lt;br /&gt;
* Navigate to &#039;&#039;&#039;System &amp;gt; Packages&#039;&#039;&#039;, &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab &lt;br /&gt;
* Find &#039;&#039;&#039;OpenVPN Client Export Package&#039;&#039;&#039; in the list &lt;br /&gt;
&lt;br /&gt;
=== Exporting a Configuration ===&lt;br /&gt;
* Navigate to &#039;&#039;&#039;VPN &amp;gt; OpenVPN&#039;&#039;&#039; on the &#039;&#039;&#039;Client Export&#039;&#039;&#039; tab &lt;br /&gt;
* Choose the VPN from the &#039;&#039;&#039;Remote Access Server&#039;&#039;&#039; drop-down list &lt;br /&gt;
* Find the user in the list at the bottom of the page and select the appropriate configuration type to export. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-064.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-065.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Multiple instance of VPN server can be created with different tunnel network &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-066.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Firewall Rules are applied as per the requirement on tunnel network .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-067.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Firewall Logs =&lt;br /&gt;
The Firewall logs at &#039;&#039;&#039;Status &amp;gt; System Logs&#039;&#039;&#039; on the &#039;&#039;&#039;Firewall&#039;&#039;&#039; tab show all events logged by the firewall.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Each entry is displayed with the action ( pass or block, reject is only logged as block), time, interface, source, destination, and protocol.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Configuration Of rsyslog Server for Logs Storage:-&lt;br /&gt;
&lt;br /&gt;
Status: &amp;gt;System logs &amp;gt; Settings&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-068.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Configuration of rsyslog on Centos :-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Setup Log File Location =====&lt;br /&gt;
Now edit Rsyslog configuration file and configure the location’s to generate log files in system.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# vim /etc/rsyslog.conf&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
and add following lines as the end of file.&lt;br /&gt;
&lt;br /&gt;
$template TmplAuth, &amp;quot;/var/log/%HOSTNAME%/%PROGRAMNAME%.log&amp;quot; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
authpriv.* ?TmplAuth&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;*.info,mail.none,authpriv.none,cron.none &amp;lt;/nowiki&amp;gt;?TmplMsg&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Enable Module and UDP Protocol =====&lt;br /&gt;
Also remove comment from following lines ( remove starting # ) in rsyslog configuration file to enable UDP.&lt;br /&gt;
&lt;br /&gt;
$ModLoad imudp&lt;br /&gt;
&lt;br /&gt;
$UDPServerRun 514&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Restart Rsyslog  =====&lt;br /&gt;
After making above changes in Rsyslog central server, restart service using following command.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# service rsyslog restart&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Logrotation:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Create file&#039;&#039;&#039; :- &#039;&#039;&#039;/etc/logrotate.d/pfsense&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;And enter:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/var/log/pfsense/filterlog.log&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;{&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;daily&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;missingok&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;rotate 60&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;compress&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;notifempty&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;create 640 root root&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;postrotate&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/etc/init.d/rsyslog restart &amp;gt;/dev/null&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;endscript&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;}&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Save and Quit.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;RRD Graphs:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
These are located under &#039;&#039;&#039;Status &amp;gt; RRD Graphs&#039;&#039;&#039;. Several graphs are presented for each monitored item, with varying time intervals and averages. &lt;br /&gt;
&lt;br /&gt;
These graphs measure things such as CPU usage, memory usage, state table usage, throughput (in bytes as well as packets), link quality, traffic shaping queue usage, and so on. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-069.jpg]]&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1913</id>
		<title>PF Sense Firewall Implementation at GIPL</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1913"/>
		<updated>2015-04-16T11:22:15Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:Tetra Clients]]&lt;br /&gt;
[[category:GSPC]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;center&amp;gt;&amp;lt;u&amp;gt;&#039;&#039;&#039;PF Sense Firewall Implementation at GIPL , GandhiNagar &#039;&#039;&#039;&amp;lt;/u&amp;gt;&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-000.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Performing a Full Install (LiveCD) ==&lt;br /&gt;
Power on the target system and connect the install media: Place the CD into the drive or plug the Memstick into a USB port. If the BIOS is set to boot from CD/USB, pfSense will start. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-001.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
As the operating system boots and pfSense starts, a prompt is presented with some choices and a countdown timer. At this prompt, press &#039;&#039;i&#039;&#039; to invoke the installer now.&lt;br /&gt;
&lt;br /&gt;
When the installer detects multiple disks in the system the first screen available provides the option &#039;&#039;&#039;Setup GEOM Mirror&#039;&#039;&#039;. Choose that option, pick the primary disk, the disk to use for the mirror copy, and then proceed with the installation as normal. &lt;br /&gt;
&lt;br /&gt;
The Quick/Easy install choice will target the GEOM mirror automatically&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-002.jpeg]]&lt;br /&gt;
&lt;br /&gt;
At the &#039;&#039;&#039;Select Task&#039;&#039;&#039; prompt, choose &#039;&#039;Quick/Easy Install&#039;&#039;. [[Image:Gpil-003.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-004.jpeg]]&lt;br /&gt;
&lt;br /&gt;
The install will proceed, wiping the target disk and installing pfSense. Copying files may take some time to finish. &lt;br /&gt;
&lt;br /&gt;
After the files have been copied to the target disk, a choice is presented to select the console type. &#039;&#039;Standard&#039;&#039; defaults to the VGA console. &#039;&#039;Embedded&#039;&#039; defaults to serial console&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-005.jpeg]]&lt;br /&gt;
&lt;br /&gt;
Now the system must reboot so that pfSense may start from the target disk. Select &#039;&#039;Reboot&#039;&#039; and then press &#039;&#039;&#039;Enter (remove CD from Drive)&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-006.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After the system reboots, pfSense will be running from the target disk. The next step is to Assign Interfaces on the Console below.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-007.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After installation and assignment, a shell menu is presented on the console with a number of options. pfSense now is ready to be accessed via the network, LAN interface IP 192.168.1.1 is assigned by default.&lt;br /&gt;
&lt;br /&gt;
Open a web browser and navigate to https://192.168.1.1/, using the default username admin and password pfsense to login.&lt;br /&gt;
&lt;br /&gt;
The first visit to the WebGUI will be redirected to the setup wizard.&lt;br /&gt;
&lt;br /&gt;
== GUI Configuration Setup ==&lt;br /&gt;
Once The Setup is launched, Fill the details are follows:-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-008.jpg]]&lt;br /&gt;
&lt;br /&gt;
We have defined FQDN as gipl.firewall&lt;br /&gt;
&lt;br /&gt;
DNS servers:- 8.8.8.8 and 4.4.2.2 Global DNS&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click NEXT&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-009.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select The Time-Zone as Asia/Kolkata .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
And Click NEXT&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-010.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Here we have Set WAN as Static Interface&lt;br /&gt;
&lt;br /&gt;
With IP address :- 203.77.200.91/25&lt;br /&gt;
&lt;br /&gt;
Gateway :- 203.77.200.1&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-011.jpg]]&lt;br /&gt;
&lt;br /&gt;
Here we have Configured LAN interface with IP address 192.168.45.101/24&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
( note:-As per the client Network Topology , Lan interface have multiple Subnets configured , so we will be configuring Virtual IP’s from GUI )&lt;br /&gt;
&lt;br /&gt;
After Setting Admin Password, Page will be redirected to Pfsense-Dashboard.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We Have Changed Default Port from 443 to 8080 Via :-&lt;br /&gt;
[[Image:Gpil-012.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;System &amp;gt; Advanced&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-013.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Change TCP Port from Default 443 to 8080 .&lt;br /&gt;
&lt;br /&gt;
Save .&lt;br /&gt;
&lt;br /&gt;
Now pfsense Can be accessed via [https://IP:8080 https://IP:8080]&lt;br /&gt;
&lt;br /&gt;
IP Address of Firewall is 203.77.200.91 on WAN interface.&lt;br /&gt;
&lt;br /&gt;
Go to :- interface &amp;gt; assign , and edit Opt1 as DMZ , do not assign IP address to This interface , because we will be creating bridge interface .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bridge Interface ==&lt;br /&gt;
Now we have to configure &#039;&#039;&#039;Interface Bridges&#039;&#039;&#039; in order to Setup Pfsense in &lt;br /&gt;
&lt;br /&gt;
Transparent mode.&lt;br /&gt;
&lt;br /&gt;
Reference:- &amp;lt;u&amp;gt;https://doc.pfsense.org/index.php/Interface_Bridges&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Navigate To :- Interfaces &amp;gt; (assign) &lt;br /&gt;
&lt;br /&gt;
on the Bridges tab Click “ +” symbol to add a new bridge .&lt;br /&gt;
[[Image:Gpil-014.jpg]] &lt;br /&gt;
&lt;br /&gt;
Ctrl-Click to select the Member interfaces from the list of available interfaces and type a Description , we have selected WAN + DMZ as bridge0 and create new Interface BRIDGEINTERFACE using bridge0 .&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-015.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
By default, traffic is filtered on the member interfaces and not on the bridge interface itself. This behavior may be changed by toggling the values of &#039;&#039;&#039;net.link.bridge.pfil_member&#039;&#039;&#039; and net.link.bridge.pfil&#039;&#039;&#039;_bridge &#039;&#039;&#039;under System&#039;&#039;&#039; &amp;gt; Advanced &#039;&#039;&#039;on the &#039;&#039;&#039;System Tunables&#039;&#039;&#039; tab. With them set at &#039;&#039;0&#039;&#039; and &#039;&#039;1&#039;&#039;, respectively, then filtering would be performed on the bridge only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-016.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Pfsense is Configured In Bridge Mode with &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;WAN interface: - 203.77.200.91/25 gateway :- 203.77.200.1&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface:- 192.168.45.101/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;DMZ: - no ip &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;BRIDGEINTERFACE:- 203.77.200.92/25&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-017.jpg]]&lt;br /&gt;
&lt;br /&gt;
== Assign Virtual IP’s To LAN interface:- ==&lt;br /&gt;
[[Image:Gpil-018.jpg]]&lt;br /&gt;
Now as LAN environment have multiple Subnet configured, we will be assigning Virtual IP address to LAN interface.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-019.jpg]]&lt;br /&gt;
&lt;br /&gt;
Clients on LAN Environment have their Gateway Set from These Virtual IP’s.&lt;br /&gt;
&lt;br /&gt;
203.77.196.230 is added for outside access of Local Servers 203.77.192.49/28.&lt;br /&gt;
&lt;br /&gt;
(203.77.196.230) is configured in 203.77.192.2 switch which will receive any packet for 203.77.192.49/28 from Outside and send it to 203.77.196.230.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SNORT  ==&lt;br /&gt;
&amp;lt;u&amp;gt;&#039;&#039;&#039;Reference&#039;&#039;&#039;&amp;lt;/u&amp;gt; :- &amp;lt;u&amp;gt;&#039;&#039;&#039;https://doc.pfsense.org/index.php/Setup_Snort_Package&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Go to the &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab under the &#039;&#039;&#039;System&#039;&#039;&#039; menu and install the snort package.&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;When the installation completes, click on &#039;&#039;&#039;Snort&#039;&#039;&#039; under the &#039;&#039;&#039;Services&#039;&#039;&#039; menu. &amp;amp;nbsp;This will open the Snort main setup page.&lt;br /&gt;
&lt;br /&gt;
Click the &#039;&#039;&#039;Global Settings&#039;&#039;&#039; tab and perform the following At the top of the page you have three choices for Rule Sets to activate.&lt;br /&gt;
&lt;br /&gt;
Put Check mark on :-Install &#039;&#039;&#039;Snort Community&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Emerging Threats&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Snort VRT&#039;&#039;&#039; rules. And save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Updates&#039;&#039;&#039; tab is used to check the status of downloaded rules packages and to download new updates. The table shows the available rule packages and their current status [[Image:Gpil-020.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Update Button to Update the rules.&lt;br /&gt;
[[Image:Gpil-021.jpg]]&lt;br /&gt;
&lt;br /&gt;
== Add Snort to an interface ==&lt;br /&gt;
Click the Snort Interfaces tab and then the &amp;quot;+&amp;quot; icon to add a new Snort interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;On the &#039;&#039;&#039;WAN Settings&#039;&#039;&#039; tab, click the &#039;&#039;Enable&#039;&#039; checkbox.In the drop-down, choose the interface. &amp;amp;nbsp;The WAN interface is the default and is a good first choice.In the &#039;&#039;Description&#039;&#039; textbox, enter a name (WAN again, is fine here).Click the checkbox to &amp;quot;&#039;&#039;Send alerts to the main System logs&#039;&#039;&amp;quot;.leave the other settings at their defaults&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-022.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After saving, the browser will be returned to the Snort Interfaces tab. Note the warning icons in the image below showing no rules have been selected for the new Snort interface. Those rules will be configured next. Click the &amp;quot;e&amp;quot; icon to edit the new Snort interface again&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-023.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Select which types of rules will protect the network ==&lt;br /&gt;
Click the &#039;&#039;&#039;Categories&#039;&#039;&#039; tab for the new interface&lt;br /&gt;
&lt;br /&gt;
Check [https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=GPLv2_community.rules Snort GPLv2 Community Rules (VRT certified)] Box .&lt;br /&gt;
&lt;br /&gt;
And Manual Rules :-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-botcc.rules emerging-botcc.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_blacklist.rules snort_blacklist.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.so.rules snort_exploit-kit.so.rules] &lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_ddos.rules snort_ddos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_dos.rules snort_dos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.rules snort_exploit-kit.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-malware.rules emerging-malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-mobile_malware.rules emerging-mobile_malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-tor.rules emerging-tor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-trojan.rules emerging-trojan.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_malware-backdoor.rules snort_malware-backdoor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_virus.rules snort_virus.rules]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-024.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click SAVE when finished to save the selection and build the rules &lt;br /&gt;
&lt;br /&gt;
After that restart the service &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-025.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Managing Pass lists:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Pass Lists are lists of IP addresses that Snort should never block. These may be created and managed on the Pass Lists tab. When an IP address is listed on a Pass List, Snort will never insert a block on that address even when malicious traffic is detected.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;To create a new Pass List, click &amp;quot;+&amp;quot;. To edit an existing Pass List, click the &amp;quot;e&amp;quot;. To delete a Pass List, click &amp;quot;x&amp;quot;. Note that a Pass List may not be deleted if it is currently assigned to one or more Snort interfaces.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We have added GIPL IP’s in Pass list . i.e&#039;&#039;&#039; &amp;lt;u&amp;gt;203.77.192.0/20&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-026.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== IP Alias and Port Alias ==&lt;br /&gt;
IP aliases allow you to create a group of IP addresses that you can assign by group name instead of specifying each IP address individually. This can be great for specifying a group of servers that need ssh access and then in the firewall rules you can create a rule that allows ssh traffic for the ssh servers group.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Along the top menu hover over Firewall and click on Aliases.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-027.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The next tab is for setting up Port Aliases. &amp;amp;nbsp;Similar to the IP Aliases you can setup groups but on this tab you are creating groups of ports instead of IP addresses.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-028.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
IP Aliases Created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-029.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
PORT ALIAS CREATED&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-030.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Firewall Rules :- ==&lt;br /&gt;
Reference:- [https://doc.pfsense.org/index.php/Firewall_Rule_Basics https://doc.pfsense.org/index.php/Firewall_Rule_Basics]&lt;br /&gt;
&lt;br /&gt;
Firewall rules control what traffic is allowed to enter an interface on the firewall. Once traffic is passed on the interface it enters an entry in the state table is created. A state table entry allows through subsequent packets that are part of that connection.&lt;br /&gt;
&lt;br /&gt;
Firewall rules are managed at Firewall &amp;gt; Rules. Multiple rules may be selected for some actions by clicking on their row or checking the box at the start of their row. Rules may be deleted or reordered in bulk in this way. See Managing Lists of Items on pfSense for more information on the meaning of the icons when manipulating rules.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;any&#039;&#039;&#039; - &#039;&#039;0.0.0.0&#039;&#039; to &#039;&#039;255.255.255.255&#039;&#039;, or all IPv6 addresses &lt;br /&gt;
* &#039;&#039;&#039;Single host or alias&#039;&#039;&#039; - Select this and enter one IP address (&#039;&#039;1.2.3.4&#039;&#039;, &#039;&#039;aa:bb:cc:dd::1&#039;&#039;) or type the name of an Alias that has already been configured (&#039;&#039;&#039;Firewall &amp;gt; Aliases&#039;&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Network&#039;&#039;&#039; - Select this and enter a network and mask (&#039;&#039;10.99.0.0/16&#039;&#039;, &#039;&#039;aa:bb:cc:dd::0/64&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;LAN net&#039;&#039;&#039; - The subnet configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039;. On pfSense 2.2+, this also includes static route networks on that interface. &lt;br /&gt;
* &#039;&#039;&#039;LAN address&#039;&#039;&#039; - The IP address configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039; &lt;br /&gt;
* &#039;&#039;&#039;zzz Net&#039;&#039;&#039; / &#039;&#039;&#039;zzz address&#039;&#039;&#039; - Works the same as LAN above but for other interfaces (WAN, OPT1, OPT2, etc.) &lt;br /&gt;
* &#039;&#039;&#039;PPTP clients&#039;&#039;&#039; - Automatically locate and use the addresses of PPTP clients &lt;br /&gt;
* &#039;&#039;&#039;L2TP clients&#039;&#039;&#039; - Automatically locate and use the addresses of L2TP clients &lt;br /&gt;
* &#039;&#039;&#039;This Firewall (self)&#039;&#039;&#039; - Any IP address assigned to any interface on this firewall (pfSense 2.2+) &lt;br /&gt;
&lt;br /&gt;
Firewall rules are generally processed starting with Floating Rules, then Interface Group rules, then Interface tab rules&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Rules Created on bridge interface, for DMZ access&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-031.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-032.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface Rules Created:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-033.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Squid and Squidguard:- ==&lt;br /&gt;
&#039;&#039;&#039;Reference - &#039;&#039;&#039;[https://doc.pfsense.org/index.php/SquidGuard_package https://doc.pfsense.org/index.php/SquidGuard_package]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Login to your pfsense&#039;s Web Administrator, and click on &amp;quot;Server -&amp;gt; Packages&amp;quot;, scroll down the list and find squid and click on &amp;quot;+&amp;quot; button to install, wait for the process to finish then return to the packages section and look for squidguard and install that package as well.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-034.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now go to &amp;quot;Services&amp;quot; menu and look for Proxy Server &amp;amp; Proxy Filter &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-035.jpg]]&lt;br /&gt;
&lt;br /&gt;
(We are setting up the proxy server as a transparent proxy)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on Services -&amp;gt; Proxy Server.&lt;br /&gt;
&lt;br /&gt;
On the General Tab, you want to set the following settings, the Proxy Interface Option should be set to &amp;quot;LAN&amp;quot;, to set up transparent proxy server, tick the &amp;quot;Transparent Proxy&amp;quot; check box.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-036.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Tick the &amp;quot;Enabled Logging&amp;quot; Checkbox, set the log store to the default location &amp;quot; /var/squid/logs &amp;quot; rotate your logs every 30 days, set your proxy port to port number 3128 We have By-passed Proxy for 203.77.192.49/28, These are the Local Servers.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next click on the &amp;quot;Cache Mgmt.&amp;quot; tab, by default the Hard Disk Cache Size is set to 100mb, we have allocated 100GB , Memory Cache Size 3072 .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-037.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click on Save.&lt;br /&gt;
&lt;br /&gt;
Click on the Access Control Tab next, in the allowed subnets field type in your required subnets. As we have multiple Subnets, so we are going to define all.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-038.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.129/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.1.224.1/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.192.49/28&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.57/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.17/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.137/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.33.50.1/27&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click On Save &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that’s is the proxy server configured, next we are going to configure SquidGuard, click on the Services menu and select the Proxy Filter button, tick the following 3 check boxes &amp;quot;Enable&amp;quot;, &amp;quot;Enable GUI Log&amp;quot; and &amp;quot;Enable Log&amp;quot; then click the Save button, once the page has reloaded click on apply and then confirm that the Squidguard service is running by making sure the SquidGuard status is set to STARTED.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-039.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on the Black list tab and add URL &#039;&#039;&#039;http://www.shallalist.de/Downloads/shallalist.tar.gz&#039;&#039;&#039; to the Update Address and click on Download. Wait for the process to complete.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-040.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-041.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now we can set up common ACL’s&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-042.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-043.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Click on Save and restart the Squid and SquidGuard from Services. &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SARG:- ==&lt;br /&gt;
After Installing SARG package, we can configure SARG from Status &amp;gt; Sarg Reports&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-044.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select Proxy Servers as SQUID proxy . And leave Rest of Field set to Default&lt;br /&gt;
&lt;br /&gt;
And Save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Go to Next Tab Schedule&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click “+” Symbol to create new schedule &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-045.jpg]] &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Reports can be viewed From “View Reports”&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-046.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bandwidthd:- ==&lt;br /&gt;
After Installing Package &#039;&#039;&#039;bandwidthd&#039;&#039;&#039; , Configuration can be done via&lt;br /&gt;
&lt;br /&gt;
Services &amp;gt; bandwidthd&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-047.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-048.jpg]]&lt;br /&gt;
&lt;br /&gt;
Enable Bandwidthd by checking the BOX.&lt;br /&gt;
&lt;br /&gt;
Now Select the Interface: - LAN.&lt;br /&gt;
&lt;br /&gt;
Enter The Subnets from LAN interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Save and Restart bandwidthd service from Services.&lt;br /&gt;
&lt;br /&gt;
Now Bandwidthd can be accessed:-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/bandwidthd/index.html https://203.77.200.91:8080/bandwidthd/index.html]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of ntopng:- ==&lt;br /&gt;
After installing ntopng package, it appears under Diagnostics &amp;gt; ntopng. It will even track where connections were made by local PCs, and how much bandwidth was used on individual connections.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-049.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
First we have to configure ntopng settings. Via Diagnostics &amp;gt; ntopng settings.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-050.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Setup Admin Password &amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Select the Interfaces on Which ntopng will be monitoring traffic.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We have selected LAN, DMZ and BRIDGEINTERFACE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To save the changes Click “Change”&lt;br /&gt;
&lt;br /&gt;
Ntopng can be accessed via [http://203.77.200.91:3000/login.html http://203.77.200.91:3000/login.html]&lt;br /&gt;
&lt;br /&gt;
With username admin and password assigned in previous step.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Configuring OpenVPN  =&lt;br /&gt;
A VPN (virtual private network) allows us to connect directly to our home private network over the internet&lt;br /&gt;
&lt;br /&gt;
The certificate authority or CA will sign the certificates that we will be creating for the server and client side when we configure OpenVPN. You can access the certificate configuration by going over to System–&amp;gt;Cert Manager.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-051.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Under the CAs tab you might already have a CA created if you followed one of my previous articles as we needed to created one in order to sign an internal certificate to be used for securing the pfSense web interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Certificate Authority ===&lt;br /&gt;
Fill in the fields to &#039;&#039;&#039;create a new Certificate Authority&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Descriptive Name&#039;&#039;&#039; - Used as the Common Name (CN) for the CA. Do not spaces, punctuation or special characters (ex: &#039;&#039;VPN Server CA&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Key Length&#039;&#039;&#039; - Default is OK, the higher the better but will use more CPU. &lt;br /&gt;
* &#039;&#039;&#039;Lifetime&#039;&#039;&#039; - Default is OK, but can be lowered if it must be changed out more often. &lt;br /&gt;
* &#039;&#039;&#039;Country Code&#039;&#039;&#039;, &#039;&#039;&#039;State/Province&#039;&#039;&#039;, &#039;&#039;&#039;City&#039;&#039;&#039;, &#039;&#039;&#039;Organization&#039;&#039;&#039; - Enter values for this location/company. &lt;br /&gt;
* &#039;&#039;&#039;E-mail&#039;&#039;&#039; - Used as a reference on the certificate, does not receive any mail from the system. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Add New CA&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-052.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
After you finished setting up the CA the next step is to create some certificates that the recently created CA will sign for us. Since these are self-signed certificates most browsers will give you a warning&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Server Certificate ===&lt;br /&gt;
Fill in the fields to create a new &#039;&#039;&#039;Server Certificate&#039;&#039;&#039;. Similar Fields as CA entry, most of the fields carry over and do not need changed. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Create new Certificate&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-053.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that we have all the components in place we can configure OpenVPN. Head over to VPN–&amp;gt;OpenVPN.&lt;br /&gt;
&lt;br /&gt;
.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-054.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select “Wizards” from the tab at the top which will guide us step by step to configure OpenVPN&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-055.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-056.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We will select the local user access database provided by pfSense&lt;br /&gt;
&lt;br /&gt;
In the next step we will be selecting the CA that we created at the beginning of this article.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-057.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Following is the Server Certificate that we will be using which is the Certificate that we recently created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-058.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;OpenVPN Server Configuration&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;TLS Authentication&#039;&#039;&#039; -- Leave this checked, along with the box underneath to generate a new key. Using a TLS key is technically optional, but &#039;&#039;highly&#039;&#039; recommended&lt;br /&gt;
* &#039;&#039;&#039;Tunnel Network&#039;&#039;&#039; -- Should be a new, unique network that does not exist anywhere in the current network or routing table. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-059.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-060.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-061.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== Firewall Rules ===&lt;br /&gt;
The next screen offers the choice to add firewall rules automatically. For convenience, check both unless the rules will be managed manually. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== End of the Wizard ===&lt;br /&gt;
Click &#039;&#039;&#039;Finish&#039;&#039;&#039; to exit the wizard and the new settings will be saved and applied automatically. &lt;br /&gt;
&lt;br /&gt;
== Adding a User with a Certificate ==&lt;br /&gt;
Navigate to &#039;&#039;&#039;System &amp;gt; User Manager&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click &amp;quot;+&amp;quot; To add a &#039;&#039;&#039;user&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Username&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Password / Confirm password&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Check Click to create a &#039;&#039;&#039;user certificate.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in the Descriptive Name as the username&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-062.jpeg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-063.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The OpenVPN Client Export Package allows exporting configurations formatted for a wide variety of platforms. It also allows exporting a pre-packaged Windows installer executable which includes the configuration bundled inside for a painly client installation. &lt;br /&gt;
&lt;br /&gt;
=== Installing the OpenVPN Client Export Package ===&lt;br /&gt;
To Install the OpenVPN Client Export Package &lt;br /&gt;
&lt;br /&gt;
* Navigate to &#039;&#039;&#039;System &amp;gt; Packages&#039;&#039;&#039;, &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab &lt;br /&gt;
* Find &#039;&#039;&#039;OpenVPN Client Export Package&#039;&#039;&#039; in the list &lt;br /&gt;
&lt;br /&gt;
=== Exporting a Configuration ===&lt;br /&gt;
* Navigate to &#039;&#039;&#039;VPN &amp;gt; OpenVPN&#039;&#039;&#039; on the &#039;&#039;&#039;Client Export&#039;&#039;&#039; tab &lt;br /&gt;
* Choose the VPN from the &#039;&#039;&#039;Remote Access Server&#039;&#039;&#039; drop-down list &lt;br /&gt;
* Find the user in the list at the bottom of the page and select the appropriate configuration type to export. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-064.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-065.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Multiple instance of VPN server can be created with different tunnel network &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-066.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Firewall Rules are applied as per the requirement on tunnel network .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-067.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Firewall Logs =&lt;br /&gt;
The Firewall logs at &#039;&#039;&#039;Status &amp;gt; System Logs&#039;&#039;&#039; on the &#039;&#039;&#039;Firewall&#039;&#039;&#039; tab show all events logged by the firewall.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Each entry is displayed with the action ( pass or block, reject is only logged as block), time, interface, source, destination, and protocol.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Configuration Of rsyslog Server for Logs Storage:-&lt;br /&gt;
&lt;br /&gt;
Status: &amp;gt;System logs &amp;gt; Settings&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-068.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Configuration of rsyslog on Centos :-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Setup Log File Location =====&lt;br /&gt;
Now edit Rsyslog configuration file and configure the location’s to generate log files in system.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# vim /etc/rsyslog.conf&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
and add following lines as the end of file.&lt;br /&gt;
&lt;br /&gt;
$template TmplAuth, &amp;quot;/var/log/%HOSTNAME%/%PROGRAMNAME%.log&amp;quot; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
authpriv.* ?TmplAuth&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;*.info,mail.none,authpriv.none,cron.none &amp;lt;/nowiki&amp;gt;?TmplMsg&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Enable Module and UDP Protocol =====&lt;br /&gt;
Also remove comment from following lines ( remove starting # ) in rsyslog configuration file to enable UDP.&lt;br /&gt;
&lt;br /&gt;
$ModLoad imudp&lt;br /&gt;
&lt;br /&gt;
$UDPServerRun 514&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Restart Rsyslog  =====&lt;br /&gt;
After making above changes in Rsyslog central server, restart service using following command.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# service rsyslog restart&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Logrotation:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Create file&#039;&#039;&#039; :- &#039;&#039;&#039;/etc/logrotate.d/pfsense&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;And enter:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/var/log/pfsense/filterlog.log&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;{&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;daily&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;missingok&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;rotate 60&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;compress&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;notifempty&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;create 640 root root&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;postrotate&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/etc/init.d/rsyslog restart &amp;gt;/dev/null&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;endscript&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;}&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Save and Quit.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;RRD Graphs:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
These are located under &#039;&#039;&#039;Status &amp;gt; RRD Graphs&#039;&#039;&#039;. Several graphs are presented for each monitored item, with varying time intervals and averages. &lt;br /&gt;
&lt;br /&gt;
These graphs measure things such as CPU usage, memory usage, state table usage, throughput (in bytes as well as packets), link quality, traffic shaping queue usage, and so on. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-069.jpg]]&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1912</id>
		<title>PF Sense Firewall Implementation at GIPL</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1912"/>
		<updated>2015-04-16T11:20:47Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:Tetra Clients]]&lt;br /&gt;
[[category:GSPC]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;center&amp;gt;&amp;lt;u&amp;gt;&#039;&#039;&#039;PF Sense Firewall Implementation at GIPL , GandhiNagar &#039;&#039;&#039;&amp;lt;/u&amp;gt;&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-000.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Installation&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;pfSense&#039;&#039;&#039; is an open source firewall/router computer software distribution based on FreeBSD. It is installed on a computer to make a dedicated firewall/router for a network and is noted for its reliability[1] and offering features often only found in expensive commercial firewalls&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Download pfSense&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Visit https://www.pfsense.org/download/mirror.php?section=downloads&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Step 1 :- &#039;&#039;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Performing a Full Install (LiveCD) ==&lt;br /&gt;
Power on the target system and connect the install media: Place the CD into the drive or plug the Memstick into a USB port. If the BIOS is set to boot from CD/USB, pfSense will start. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-001.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
As the operating system boots and pfSense starts, a prompt is presented with some choices and a countdown timer. At this prompt, press &#039;&#039;i&#039;&#039; to invoke the installer now.&lt;br /&gt;
&lt;br /&gt;
When the installer detects multiple disks in the system the first screen available provides the option &#039;&#039;&#039;Setup GEOM Mirror&#039;&#039;&#039;. Choose that option, pick the primary disk, the disk to use for the mirror copy, and then proceed with the installation as normal. &lt;br /&gt;
&lt;br /&gt;
The Quick/Easy install choice will target the GEOM mirror automatically&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-002.jpeg]]&lt;br /&gt;
&lt;br /&gt;
At the &#039;&#039;&#039;Select Task&#039;&#039;&#039; prompt, choose &#039;&#039;Quick/Easy Install&#039;&#039;. [[Image:Gpil-003.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-004.jpeg]]&lt;br /&gt;
&lt;br /&gt;
The install will proceed, wiping the target disk and installing pfSense. Copying files may take some time to finish. &lt;br /&gt;
&lt;br /&gt;
After the files have been copied to the target disk, a choice is presented to select the console type. &#039;&#039;Standard&#039;&#039; defaults to the VGA console. &#039;&#039;Embedded&#039;&#039; defaults to serial console&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-005.jpeg]]&lt;br /&gt;
&lt;br /&gt;
Now the system must reboot so that pfSense may start from the target disk. Select &#039;&#039;Reboot&#039;&#039; and then press &#039;&#039;&#039;Enter (remove CD from Drive)&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-006.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After the system reboots, pfSense will be running from the target disk. The next step is to Assign Interfaces on the Console below.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-007.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After installation and assignment, a shell menu is presented on the console with a number of options. pfSense now is ready to be accessed via the network, LAN interface IP 192.168.1.1 is assigned by default.&lt;br /&gt;
&lt;br /&gt;
Open a web browser and navigate to https://192.168.1.1/, using the default username admin and password pfsense to login.&lt;br /&gt;
&lt;br /&gt;
The first visit to the WebGUI will be redirected to the setup wizard.&lt;br /&gt;
&lt;br /&gt;
== GUI Configuration Setup ==&lt;br /&gt;
Once The Setup is launched, Fill the details are follows:-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-008.jpg]]&lt;br /&gt;
&lt;br /&gt;
We have defined FQDN as gipl.firewall&lt;br /&gt;
&lt;br /&gt;
DNS servers:- 8.8.8.8 and 4.4.2.2 Global DNS&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click NEXT&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-009.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select The Time-Zone as Asia/Kolkata .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
And Click NEXT&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-010.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Here we have Set WAN as Static Interface&lt;br /&gt;
&lt;br /&gt;
With IP address :- 203.77.200.91/25&lt;br /&gt;
&lt;br /&gt;
Gateway :- 203.77.200.1&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-011.jpg]]&lt;br /&gt;
&lt;br /&gt;
Here we have Configured LAN interface with IP address 192.168.45.101/24&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
( note:-As per the client Network Topology , Lan interface have multiple Subnets configured , so we will be configuring Virtual IP’s from GUI )&lt;br /&gt;
&lt;br /&gt;
After Setting Admin Password, Page will be redirected to Pfsense-Dashboard.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We Have Changed Default Port from 443 to 8080 Via :-&lt;br /&gt;
[[Image:Gpil-012.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;System &amp;gt; Advanced&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-013.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Change TCP Port from Default 443 to 8080 .&lt;br /&gt;
&lt;br /&gt;
Save .&lt;br /&gt;
&lt;br /&gt;
Now pfsense Can be accessed via [https://IP:8080 https://IP:8080]&lt;br /&gt;
&lt;br /&gt;
IP Address of Firewall is 203.77.200.91 on WAN interface.&lt;br /&gt;
&lt;br /&gt;
Go to :- interface &amp;gt; assign , and edit Opt1 as DMZ , do not assign IP address to This interface , because we will be creating bridge interface .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bridge Interface ==&lt;br /&gt;
Now we have to configure &#039;&#039;&#039;Interface Bridges&#039;&#039;&#039; in order to Setup Pfsense in &lt;br /&gt;
&lt;br /&gt;
Transparent mode.&lt;br /&gt;
&lt;br /&gt;
Reference:- &amp;lt;u&amp;gt;https://doc.pfsense.org/index.php/Interface_Bridges&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Navigate To :- Interfaces &amp;gt; (assign) &lt;br /&gt;
&lt;br /&gt;
on the Bridges tab Click “ +” symbol to add a new bridge .&lt;br /&gt;
[[Image:Gpil-014.jpg]] &lt;br /&gt;
&lt;br /&gt;
Ctrl-Click to select the Member interfaces from the list of available interfaces and type a Description , we have selected WAN + DMZ as bridge0 and create new Interface BRIDGEINTERFACE using bridge0 .&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-015.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
By default, traffic is filtered on the member interfaces and not on the bridge interface itself. This behavior may be changed by toggling the values of &#039;&#039;&#039;net.link.bridge.pfil_member&#039;&#039;&#039; and net.link.bridge.pfil&#039;&#039;&#039;_bridge &#039;&#039;&#039;under System&#039;&#039;&#039; &amp;gt; Advanced &#039;&#039;&#039;on the &#039;&#039;&#039;System Tunables&#039;&#039;&#039; tab. With them set at &#039;&#039;0&#039;&#039; and &#039;&#039;1&#039;&#039;, respectively, then filtering would be performed on the bridge only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-016.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Pfsense is Configured In Bridge Mode with &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;WAN interface: - 203.77.200.91/25 gateway :- 203.77.200.1&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface:- 192.168.45.101/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;DMZ: - no ip &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;BRIDGEINTERFACE:- 203.77.200.92/25&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-017.jpg]]&lt;br /&gt;
&lt;br /&gt;
== Assign Virtual IP’s To LAN interface:- ==&lt;br /&gt;
[[Image:Gpil-018.jpg]]&lt;br /&gt;
Now as LAN environment have multiple Subnet configured, we will be assigning Virtual IP address to LAN interface.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-019.jpg]]&lt;br /&gt;
&lt;br /&gt;
Clients on LAN Environment have their Gateway Set from These Virtual IP’s.&lt;br /&gt;
&lt;br /&gt;
203.77.196.230 is added for outside access of Local Servers 203.77.192.49/28.&lt;br /&gt;
&lt;br /&gt;
(203.77.196.230) is configured in 203.77.192.2 switch which will receive any packet for 203.77.192.49/28 from Outside and send it to 203.77.196.230.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SNORT  ==&lt;br /&gt;
&amp;lt;u&amp;gt;&#039;&#039;&#039;Reference&#039;&#039;&#039;&amp;lt;/u&amp;gt; :- &amp;lt;u&amp;gt;&#039;&#039;&#039;https://doc.pfsense.org/index.php/Setup_Snort_Package&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Go to the &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab under the &#039;&#039;&#039;System&#039;&#039;&#039; menu and install the snort package.&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;When the installation completes, click on &#039;&#039;&#039;Snort&#039;&#039;&#039; under the &#039;&#039;&#039;Services&#039;&#039;&#039; menu. &amp;amp;nbsp;This will open the Snort main setup page.&lt;br /&gt;
&lt;br /&gt;
Click the &#039;&#039;&#039;Global Settings&#039;&#039;&#039; tab and perform the following At the top of the page you have three choices for Rule Sets to activate.&lt;br /&gt;
&lt;br /&gt;
Put Check mark on :-Install &#039;&#039;&#039;Snort Community&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Emerging Threats&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Snort VRT&#039;&#039;&#039; rules. And save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Updates&#039;&#039;&#039; tab is used to check the status of downloaded rules packages and to download new updates. The table shows the available rule packages and their current status [[Image:Gpil-020.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Update Button to Update the rules.&lt;br /&gt;
[[Image:Gpil-021.jpg]]&lt;br /&gt;
&lt;br /&gt;
== Add Snort to an interface ==&lt;br /&gt;
Click the Snort Interfaces tab and then the &amp;quot;+&amp;quot; icon to add a new Snort interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;On the &#039;&#039;&#039;WAN Settings&#039;&#039;&#039; tab, click the &#039;&#039;Enable&#039;&#039; checkbox.In the drop-down, choose the interface. &amp;amp;nbsp;The WAN interface is the default and is a good first choice.In the &#039;&#039;Description&#039;&#039; textbox, enter a name (WAN again, is fine here).Click the checkbox to &amp;quot;&#039;&#039;Send alerts to the main System logs&#039;&#039;&amp;quot;.leave the other settings at their defaults&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-022.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After saving, the browser will be returned to the Snort Interfaces tab. Note the warning icons in the image below showing no rules have been selected for the new Snort interface. Those rules will be configured next. Click the &amp;quot;e&amp;quot; icon to edit the new Snort interface again&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-023.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Select which types of rules will protect the network ==&lt;br /&gt;
Click the &#039;&#039;&#039;Categories&#039;&#039;&#039; tab for the new interface&lt;br /&gt;
&lt;br /&gt;
Check [https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=GPLv2_community.rules Snort GPLv2 Community Rules (VRT certified)] Box .&lt;br /&gt;
&lt;br /&gt;
And Manual Rules :-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-botcc.rules emerging-botcc.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_blacklist.rules snort_blacklist.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.so.rules snort_exploit-kit.so.rules] &lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_ddos.rules snort_ddos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_dos.rules snort_dos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.rules snort_exploit-kit.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-malware.rules emerging-malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-mobile_malware.rules emerging-mobile_malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-tor.rules emerging-tor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-trojan.rules emerging-trojan.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_malware-backdoor.rules snort_malware-backdoor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_virus.rules snort_virus.rules]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-024.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click SAVE when finished to save the selection and build the rules &lt;br /&gt;
&lt;br /&gt;
After that restart the service &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-025.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Managing Pass lists:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Pass Lists are lists of IP addresses that Snort should never block. These may be created and managed on the Pass Lists tab. When an IP address is listed on a Pass List, Snort will never insert a block on that address even when malicious traffic is detected.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;To create a new Pass List, click &amp;quot;+&amp;quot;. To edit an existing Pass List, click the &amp;quot;e&amp;quot;. To delete a Pass List, click &amp;quot;x&amp;quot;. Note that a Pass List may not be deleted if it is currently assigned to one or more Snort interfaces.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We have added GIPL IP’s in Pass list . i.e&#039;&#039;&#039; &amp;lt;u&amp;gt;203.77.192.0/20&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-026.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== IP Alias and Port Alias ==&lt;br /&gt;
IP aliases allow you to create a group of IP addresses that you can assign by group name instead of specifying each IP address individually. This can be great for specifying a group of servers that need ssh access and then in the firewall rules you can create a rule that allows ssh traffic for the ssh servers group.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Along the top menu hover over Firewall and click on Aliases.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-027.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The next tab is for setting up Port Aliases. &amp;amp;nbsp;Similar to the IP Aliases you can setup groups but on this tab you are creating groups of ports instead of IP addresses.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-028.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
IP Aliases Created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-029.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
PORT ALIAS CREATED&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-030.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Firewall Rules :- ==&lt;br /&gt;
Reference:- [https://doc.pfsense.org/index.php/Firewall_Rule_Basics https://doc.pfsense.org/index.php/Firewall_Rule_Basics]&lt;br /&gt;
&lt;br /&gt;
Firewall rules control what traffic is allowed to enter an interface on the firewall. Once traffic is passed on the interface it enters an entry in the state table is created. A state table entry allows through subsequent packets that are part of that connection.&lt;br /&gt;
&lt;br /&gt;
Firewall rules are managed at Firewall &amp;gt; Rules. Multiple rules may be selected for some actions by clicking on their row or checking the box at the start of their row. Rules may be deleted or reordered in bulk in this way. See Managing Lists of Items on pfSense for more information on the meaning of the icons when manipulating rules.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;any&#039;&#039;&#039; - &#039;&#039;0.0.0.0&#039;&#039; to &#039;&#039;255.255.255.255&#039;&#039;, or all IPv6 addresses &lt;br /&gt;
* &#039;&#039;&#039;Single host or alias&#039;&#039;&#039; - Select this and enter one IP address (&#039;&#039;1.2.3.4&#039;&#039;, &#039;&#039;aa:bb:cc:dd::1&#039;&#039;) or type the name of an Alias that has already been configured (&#039;&#039;&#039;Firewall &amp;gt; Aliases&#039;&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Network&#039;&#039;&#039; - Select this and enter a network and mask (&#039;&#039;10.99.0.0/16&#039;&#039;, &#039;&#039;aa:bb:cc:dd::0/64&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;LAN net&#039;&#039;&#039; - The subnet configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039;. On pfSense 2.2+, this also includes static route networks on that interface. &lt;br /&gt;
* &#039;&#039;&#039;LAN address&#039;&#039;&#039; - The IP address configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039; &lt;br /&gt;
* &#039;&#039;&#039;zzz Net&#039;&#039;&#039; / &#039;&#039;&#039;zzz address&#039;&#039;&#039; - Works the same as LAN above but for other interfaces (WAN, OPT1, OPT2, etc.) &lt;br /&gt;
* &#039;&#039;&#039;PPTP clients&#039;&#039;&#039; - Automatically locate and use the addresses of PPTP clients &lt;br /&gt;
* &#039;&#039;&#039;L2TP clients&#039;&#039;&#039; - Automatically locate and use the addresses of L2TP clients &lt;br /&gt;
* &#039;&#039;&#039;This Firewall (self)&#039;&#039;&#039; - Any IP address assigned to any interface on this firewall (pfSense 2.2+) &lt;br /&gt;
&lt;br /&gt;
Firewall rules are generally processed starting with Floating Rules, then Interface Group rules, then Interface tab rules&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Rules Created on bridge interface, for DMZ access&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-031.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-032.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface Rules Created:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-033.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Squid and Squidguard:- ==&lt;br /&gt;
&#039;&#039;&#039;Reference - &#039;&#039;&#039;[https://doc.pfsense.org/index.php/SquidGuard_package https://doc.pfsense.org/index.php/SquidGuard_package]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Login to your pfsense&#039;s Web Administrator, and click on &amp;quot;Server -&amp;gt; Packages&amp;quot;, scroll down the list and find squid and click on &amp;quot;+&amp;quot; button to install, wait for the process to finish then return to the packages section and look for squidguard and install that package as well.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-034.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now go to &amp;quot;Services&amp;quot; menu and look for Proxy Server &amp;amp; Proxy Filter &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-035.jpg]]&lt;br /&gt;
&lt;br /&gt;
(We are setting up the proxy server as a transparent proxy)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on Services -&amp;gt; Proxy Server.&lt;br /&gt;
&lt;br /&gt;
On the General Tab, you want to set the following settings, the Proxy Interface Option should be set to &amp;quot;LAN&amp;quot;, to set up transparent proxy server, tick the &amp;quot;Transparent Proxy&amp;quot; check box.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-036.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Tick the &amp;quot;Enabled Logging&amp;quot; Checkbox, set the log store to the default location &amp;quot; /var/squid/logs &amp;quot; rotate your logs every 30 days, set your proxy port to port number 3128 We have By-passed Proxy for 203.77.192.49/28, These are the Local Servers.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next click on the &amp;quot;Cache Mgmt.&amp;quot; tab, by default the Hard Disk Cache Size is set to 100mb, we have allocated 100GB , Memory Cache Size 3072 .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-037.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click on Save.&lt;br /&gt;
&lt;br /&gt;
Click on the Access Control Tab next, in the allowed subnets field type in your required subnets. As we have multiple Subnets, so we are going to define all.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-038.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.129/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.1.224.1/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.192.49/28&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.57/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.17/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.137/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.33.50.1/27&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click On Save &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that’s is the proxy server configured, next we are going to configure SquidGuard, click on the Services menu and select the Proxy Filter button, tick the following 3 check boxes &amp;quot;Enable&amp;quot;, &amp;quot;Enable GUI Log&amp;quot; and &amp;quot;Enable Log&amp;quot; then click the Save button, once the page has reloaded click on apply and then confirm that the Squidguard service is running by making sure the SquidGuard status is set to STARTED.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-039.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on the Black list tab and add URL &#039;&#039;&#039;http://www.shallalist.de/Downloads/shallalist.tar.gz&#039;&#039;&#039; to the Update Address and click on Download. Wait for the process to complete.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-040.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-041.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now we can set up common ACL’s&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-042.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-043.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Click on Save and restart the Squid and SquidGuard from Services. &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SARG:- ==&lt;br /&gt;
After Installing SARG package, we can configure SARG from Status &amp;gt; Sarg Reports&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-044.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select Proxy Servers as SQUID proxy . And leave Rest of Field set to Default&lt;br /&gt;
&lt;br /&gt;
And Save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Go to Next Tab Schedule&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click “+” Symbol to create new schedule &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-045.jpg]] &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Reports can be viewed From “View Reports”&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-046.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bandwidthd:- ==&lt;br /&gt;
After Installing Package &#039;&#039;&#039;bandwidthd&#039;&#039;&#039; , Configuration can be done via&lt;br /&gt;
&lt;br /&gt;
Services &amp;gt; bandwidthd&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-047.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-048.jpg]]&lt;br /&gt;
&lt;br /&gt;
Enable Bandwidthd by checking the BOX.&lt;br /&gt;
&lt;br /&gt;
Now Select the Interface: - LAN.&lt;br /&gt;
&lt;br /&gt;
Enter The Subnets from LAN interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Save and Restart bandwidthd service from Services.&lt;br /&gt;
&lt;br /&gt;
Now Bandwidthd can be accessed:-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/bandwidthd/index.html https://203.77.200.91:8080/bandwidthd/index.html]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of ntopng:- ==&lt;br /&gt;
After installing ntopng package, it appears under Diagnostics &amp;gt; ntopng. It will even track where connections were made by local PCs, and how much bandwidth was used on individual connections.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-049.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
First we have to configure ntopng settings. Via Diagnostics &amp;gt; ntopng settings.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-050.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Setup Admin Password &amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Select the Interfaces on Which ntopng will be monitoring traffic.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We have selected LAN, DMZ and BRIDGEINTERFACE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To save the changes Click “Change”&lt;br /&gt;
&lt;br /&gt;
Ntopng can be accessed via [http://203.77.200.91:3000/login.html http://203.77.200.91:3000/login.html]&lt;br /&gt;
&lt;br /&gt;
With username admin and password assigned in previous step.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Configuring OpenVPN  =&lt;br /&gt;
A VPN (virtual private network) allows us to connect directly to our home private network over the internet&lt;br /&gt;
&lt;br /&gt;
The certificate authority or CA will sign the certificates that we will be creating for the server and client side when we configure OpenVPN. You can access the certificate configuration by going over to System–&amp;gt;Cert Manager.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-051.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Under the CAs tab you might already have a CA created if you followed one of my previous articles as we needed to created one in order to sign an internal certificate to be used for securing the pfSense web interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Certificate Authority ===&lt;br /&gt;
Fill in the fields to &#039;&#039;&#039;create a new Certificate Authority&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Descriptive Name&#039;&#039;&#039; - Used as the Common Name (CN) for the CA. Do not spaces, punctuation or special characters (ex: &#039;&#039;VPN Server CA&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Key Length&#039;&#039;&#039; - Default is OK, the higher the better but will use more CPU. &lt;br /&gt;
* &#039;&#039;&#039;Lifetime&#039;&#039;&#039; - Default is OK, but can be lowered if it must be changed out more often. &lt;br /&gt;
* &#039;&#039;&#039;Country Code&#039;&#039;&#039;, &#039;&#039;&#039;State/Province&#039;&#039;&#039;, &#039;&#039;&#039;City&#039;&#039;&#039;, &#039;&#039;&#039;Organization&#039;&#039;&#039; - Enter values for this location/company. &lt;br /&gt;
* &#039;&#039;&#039;E-mail&#039;&#039;&#039; - Used as a reference on the certificate, does not receive any mail from the system. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Add New CA&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-052.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
After you finished setting up the CA the next step is to create some certificates that the recently created CA will sign for us. Since these are self-signed certificates most browsers will give you a warning&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Server Certificate ===&lt;br /&gt;
Fill in the fields to create a new &#039;&#039;&#039;Server Certificate&#039;&#039;&#039;. Similar Fields as CA entry, most of the fields carry over and do not need changed. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Create new Certificate&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-053.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that we have all the components in place we can configure OpenVPN. Head over to VPN–&amp;gt;OpenVPN.&lt;br /&gt;
&lt;br /&gt;
.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-054.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select “Wizards” from the tab at the top which will guide us step by step to configure OpenVPN&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-055.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-056.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We will select the local user access database provided by pfSense&lt;br /&gt;
&lt;br /&gt;
In the next step we will be selecting the CA that we created at the beginning of this article.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-057.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Following is the Server Certificate that we will be using which is the Certificate that we recently created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-058.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;OpenVPN Server Configuration&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;TLS Authentication&#039;&#039;&#039; -- Leave this checked, along with the box underneath to generate a new key. Using a TLS key is technically optional, but &#039;&#039;highly&#039;&#039; recommended&lt;br /&gt;
* &#039;&#039;&#039;Tunnel Network&#039;&#039;&#039; -- Should be a new, unique network that does not exist anywhere in the current network or routing table. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-059.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-060.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-061.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== Firewall Rules ===&lt;br /&gt;
The next screen offers the choice to add firewall rules automatically. For convenience, check both unless the rules will be managed manually. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== End of the Wizard ===&lt;br /&gt;
Click &#039;&#039;&#039;Finish&#039;&#039;&#039; to exit the wizard and the new settings will be saved and applied automatically. &lt;br /&gt;
&lt;br /&gt;
== Adding a User with a Certificate ==&lt;br /&gt;
Navigate to &#039;&#039;&#039;System &amp;gt; User Manager&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click &amp;quot;+&amp;quot; To add a &#039;&#039;&#039;user&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Username&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Password / Confirm password&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Check Click to create a &#039;&#039;&#039;user certificate.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in the Descriptive Name as the username&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-062.jpeg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-063.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The OpenVPN Client Export Package allows exporting configurations formatted for a wide variety of platforms. It also allows exporting a pre-packaged Windows installer executable which includes the configuration bundled inside for a painly client installation. &lt;br /&gt;
&lt;br /&gt;
=== Installing the OpenVPN Client Export Package ===&lt;br /&gt;
To Install the OpenVPN Client Export Package &lt;br /&gt;
&lt;br /&gt;
* Navigate to &#039;&#039;&#039;System &amp;gt; Packages&#039;&#039;&#039;, &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab &lt;br /&gt;
* Find &#039;&#039;&#039;OpenVPN Client Export Package&#039;&#039;&#039; in the list &lt;br /&gt;
&lt;br /&gt;
=== Exporting a Configuration ===&lt;br /&gt;
* Navigate to &#039;&#039;&#039;VPN &amp;gt; OpenVPN&#039;&#039;&#039; on the &#039;&#039;&#039;Client Export&#039;&#039;&#039; tab &lt;br /&gt;
* Choose the VPN from the &#039;&#039;&#039;Remote Access Server&#039;&#039;&#039; drop-down list &lt;br /&gt;
* Find the user in the list at the bottom of the page and select the appropriate configuration type to export. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-064.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-065.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Multiple instance of VPN server can be created with different tunnel network &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-066.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Firewall Rules are applied as per the requirement on tunnel network .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-067.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Firewall Logs =&lt;br /&gt;
The Firewall logs at &#039;&#039;&#039;Status &amp;gt; System Logs&#039;&#039;&#039; on the &#039;&#039;&#039;Firewall&#039;&#039;&#039; tab show all events logged by the firewall.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Each entry is displayed with the action ( pass or block, reject is only logged as block), time, interface, source, destination, and protocol.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Configuration Of rsyslog Server for Logs Storage:-&lt;br /&gt;
&lt;br /&gt;
Status: &amp;gt;System logs &amp;gt; Settings&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-068.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Configuration of rsyslog on Centos :-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Setup Log File Location =====&lt;br /&gt;
Now edit Rsyslog configuration file and configure the location’s to generate log files in system.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# vim /etc/rsyslog.conf&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
and add following lines as the end of file.&lt;br /&gt;
&lt;br /&gt;
$template TmplAuth, &amp;quot;/var/log/%HOSTNAME%/%PROGRAMNAME%.log&amp;quot; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
authpriv.* ?TmplAuth&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;*.info,mail.none,authpriv.none,cron.none &amp;lt;/nowiki&amp;gt;?TmplMsg&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Enable Module and UDP Protocol =====&lt;br /&gt;
Also remove comment from following lines ( remove starting # ) in rsyslog configuration file to enable UDP.&lt;br /&gt;
&lt;br /&gt;
$ModLoad imudp&lt;br /&gt;
&lt;br /&gt;
$UDPServerRun 514&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Restart Rsyslog  =====&lt;br /&gt;
After making above changes in Rsyslog central server, restart service using following command.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# service rsyslog restart&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Logrotation:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Create file&#039;&#039;&#039; :- &#039;&#039;&#039;/etc/logrotate.d/pfsense&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;And enter:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/var/log/pfsense/filterlog.log&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;{&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;daily&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;missingok&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;rotate 60&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;compress&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;notifempty&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;create 640 root root&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;postrotate&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/etc/init.d/rsyslog restart &amp;gt;/dev/null&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;endscript&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;}&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Save and Quit.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;RRD Graphs:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
These are located under &#039;&#039;&#039;Status &amp;gt; RRD Graphs&#039;&#039;&#039;. Several graphs are presented for each monitored item, with varying time intervals and averages. &lt;br /&gt;
&lt;br /&gt;
These graphs measure things such as CPU usage, memory usage, state table usage, throughput (in bytes as well as packets), link quality, traffic shaping queue usage, and so on. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-069.jpg]]&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1911</id>
		<title>PF Sense Firewall Implementation at GIPL</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1911"/>
		<updated>2015-04-16T11:18:30Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:Tetra Clients]]&lt;br /&gt;
[[category:GSPC]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;center&amp;gt;&amp;lt;u&amp;gt;&#039;&#039;&#039;PF Sense Firewall Implementation at GIPL , GandhiNagar &#039;&#039;&#039;&amp;lt;/u&amp;gt;&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-000.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Installation&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;pfSense&#039;&#039;&#039; is an open source firewall/router computer software distribution based on FreeBSD. It is installed on a computer to make a dedicated firewall/router for a network and is noted for its reliability[1] and offering features often only found in expensive commercial firewalls&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Download pfSense&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Visit https://www.pfsense.org/download/mirror.php?section=downloads&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Step 1 :- &#039;&#039;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Performing a Full Install (LiveCD) ==&lt;br /&gt;
Power on the target system and connect the install media: Place the CD into the drive or plug the Memstick into a USB port. If the BIOS is set to boot from CD/USB, pfSense will start. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-001.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
As the operating system boots and pfSense starts, a prompt is presented with some choices and a countdown timer. At this prompt, press &#039;&#039;i&#039;&#039; to invoke the installer now.&lt;br /&gt;
&lt;br /&gt;
When the installer detects multiple disks in the system the first screen available provides the option &#039;&#039;&#039;Setup GEOM Mirror&#039;&#039;&#039;. Choose that option, pick the primary disk, the disk to use for the mirror copy, and then proceed with the installation as normal. &lt;br /&gt;
&lt;br /&gt;
The Quick/Easy install choice will target the GEOM mirror automatically&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-002.jpeg]]&lt;br /&gt;
&lt;br /&gt;
At the &#039;&#039;&#039;Select Task&#039;&#039;&#039; prompt, choose &#039;&#039;Quick/Easy Install&#039;&#039;. [[Image:Gpil-003.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-004.jpeg]]&lt;br /&gt;
&lt;br /&gt;
The install will proceed, wiping the target disk and installing pfSense. Copying files may take some time to finish. &lt;br /&gt;
&lt;br /&gt;
After the files have been copied to the target disk, a choice is presented to select the console type. &#039;&#039;Standard&#039;&#039; defaults to the VGA console. &#039;&#039;Embedded&#039;&#039; defaults to serial console&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-005.jpeg]]&lt;br /&gt;
&lt;br /&gt;
Now the system must reboot so that pfSense may start from the target disk. Select &#039;&#039;Reboot&#039;&#039; and then press &#039;&#039;&#039;Enter (remove CD from Drive)&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-006.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After the system reboots, pfSense will be running from the target disk. The next step is to Assign Interfaces on the Console below.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-007.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After installation and assignment, a shell menu is presented on the console with a number of options. pfSense now is ready to be accessed via the network, LAN interface IP 192.168.1.1 is assigned by default.&lt;br /&gt;
&lt;br /&gt;
Open a web browser and navigate to https://192.168.1.1/, using the default username admin and password pfsense to login.&lt;br /&gt;
&lt;br /&gt;
The first visit to the WebGUI will be redirected to the setup wizard.&lt;br /&gt;
&lt;br /&gt;
== GUI Configuration Setup ==&lt;br /&gt;
Once The Setup is launched, Fill the details are follows:-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-008.jpg]]&lt;br /&gt;
&lt;br /&gt;
We have defined FQDN as gipl.firewall&lt;br /&gt;
&lt;br /&gt;
DNS servers:- 8.8.8.8 and 4.4.2.2 Global DNS&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click NEXT&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-009.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select The Time-Zone as Asia/Kolkata .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
And Click NEXT&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-010.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Here we have Set WAN as Static Interface&lt;br /&gt;
&lt;br /&gt;
With IP address :- 203.77.200.91/25&lt;br /&gt;
&lt;br /&gt;
Gateway :- 203.77.200.1&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-011.jpg]]&lt;br /&gt;
&lt;br /&gt;
Here we have Configured LAN interface with IP address 192.168.45.101/24&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
( note:-As per the client Network Topology , Lan interface have multiple Subnets configured , so we will be configuring Virtual IP’s from GUI )&lt;br /&gt;
&lt;br /&gt;
After Setting Admin Password, Page will be redirected to Pfsense-Dashboard.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We Have Changed Default Port from 443 to 8080 Via :-&lt;br /&gt;
[[Image:Gpil-012.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;System &amp;gt; Advanced&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-013.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Change TCP Port from Default 443 to 8080 .&lt;br /&gt;
&lt;br /&gt;
Save .&lt;br /&gt;
&lt;br /&gt;
Now pfsense Can be accessed via [https://IP:8080 https://IP:8080]&lt;br /&gt;
&lt;br /&gt;
IP Address of Firewall is 203.77.200.91 on WAN interface.&lt;br /&gt;
&lt;br /&gt;
Go to :- interface &amp;gt; assign , and edit Opt1 as DMZ , do not assign IP address to This interface , because we will be creating bridge interface .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bridge Interface ==&lt;br /&gt;
Now we have to configure &#039;&#039;&#039;Interface Bridges&#039;&#039;&#039; in order to Setup Pfsense in &lt;br /&gt;
&lt;br /&gt;
Transparent mode.&lt;br /&gt;
&lt;br /&gt;
Reference:- &amp;lt;u&amp;gt;https://doc.pfsense.org/index.php/Interface_Bridges&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Navigate To :- Interfaces &amp;gt; (assign) &lt;br /&gt;
&lt;br /&gt;
on the Bridges tab Click “ +” symbol to add a new bridge .&lt;br /&gt;
[[Image:Gpil-014.jpg]] &lt;br /&gt;
&lt;br /&gt;
Ctrl-Click to select the Member interfaces from the list of available interfaces and type a Description , we have selected WAN + DMZ as bridge0 and create new Interface BRIDGEINTERFACE using bridge0 .&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-015.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
By default, traffic is filtered on the member interfaces and not on the bridge interface itself. This behavior may be changed by toggling the values of &#039;&#039;&#039;net.link.bridge.pfil_member&#039;&#039;&#039; and net.link.bridge.pfil&#039;&#039;&#039;_bridge &#039;&#039;&#039;under System&#039;&#039;&#039; &amp;gt; Advanced &#039;&#039;&#039;on the &#039;&#039;&#039;System Tunables&#039;&#039;&#039; tab. With them set at &#039;&#039;0&#039;&#039; and &#039;&#039;1&#039;&#039;, respectively, then filtering would be performed on the bridge only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-016.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Pfsense is Configured In Bridge Mode with &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;WAN interface: - 203.77.200.91/25 gateway :- 203.77.200.1&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface:- 192.168.45.101/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;DMZ: - no ip &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;BRIDGEINTERFACE:- 203.77.200.92/25&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-017.jpg]]&lt;br /&gt;
&lt;br /&gt;
== Assign Virtual IP’s To LAN interface:- ==&lt;br /&gt;
[[Image:Gpil-018.jpg]]&lt;br /&gt;
Now as LAN environment have multiple Subnet configured, we will be assigning Virtual IP address to LAN interface.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-019.jpg]]&lt;br /&gt;
&lt;br /&gt;
Clients on LAN Environment have their Gateway Set from These Virtual IP’s.&lt;br /&gt;
&lt;br /&gt;
203.77.196.230 is added for outside access of Local Servers 203.77.192.49/28.&lt;br /&gt;
&lt;br /&gt;
(203.77.196.230) is configured in 203.77.192.2 switch which will receive any packet for 203.77.192.49/28 from Outside and send it to 203.77.196.230.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SNORT  ==&lt;br /&gt;
&amp;lt;u&amp;gt;&#039;&#039;&#039;Reference&#039;&#039;&#039;&amp;lt;/u&amp;gt; :- &amp;lt;u&amp;gt;&#039;&#039;&#039;https://doc.pfsense.org/index.php/Setup_Snort_Package&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Go to the &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab under the &#039;&#039;&#039;System&#039;&#039;&#039; menu and install the snort package.&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;When the installation completes, click on &#039;&#039;&#039;Snort&#039;&#039;&#039; under the &#039;&#039;&#039;Services&#039;&#039;&#039; menu. &amp;amp;nbsp;This will open the Snort main setup page.&lt;br /&gt;
&lt;br /&gt;
Click the &#039;&#039;&#039;Global Settings&#039;&#039;&#039; tab and perform the following At the top of the page you have three choices for Rule Sets to activate.&lt;br /&gt;
&lt;br /&gt;
Put Check mark on :-Install &#039;&#039;&#039;Snort Community&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Emerging Threats&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Snort VRT&#039;&#039;&#039; rules. And save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Updates&#039;&#039;&#039; tab is used to check the status of downloaded rules packages and to download new updates. The table shows the available rule packages and their current status [[Image:Gpil-020.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Update Button to Update the rules.&lt;br /&gt;
[[Image:Gpil-021.jpg]]&lt;br /&gt;
&lt;br /&gt;
== Add Snort to an interface ==&lt;br /&gt;
Click the Snort Interfaces tab and then the &amp;quot;+&amp;quot; icon to add a new Snort interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;On the &#039;&#039;&#039;WAN Settings&#039;&#039;&#039; tab, click the &#039;&#039;Enable&#039;&#039; checkbox.In the drop-down, choose the interface. &amp;amp;nbsp;The WAN interface is the default and is a good first choice.In the &#039;&#039;Description&#039;&#039; textbox, enter a name (WAN again, is fine here).Click the checkbox to &amp;quot;&#039;&#039;Send alerts to the main System logs&#039;&#039;&amp;quot;.leave the other settings at their defaults&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-022.jpg]]&lt;br /&gt;
&lt;br /&gt;
After saving, the browser will be returned to the Snort Interfaces tab. Note the warning icons in the image below showing no rules have been selected for the new Snort interface. Those rules will be configured next. Click the &amp;quot;e&amp;quot; icon to edit the new Snort interface again&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-023.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Select which types of rules will protect the network ==&lt;br /&gt;
Click the &#039;&#039;&#039;Categories&#039;&#039;&#039; tab for the new interface&lt;br /&gt;
&lt;br /&gt;
Check [https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=GPLv2_community.rules Snort GPLv2 Community Rules (VRT certified)] Box .&lt;br /&gt;
&lt;br /&gt;
And Manual Rules :-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-botcc.rules emerging-botcc.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_blacklist.rules snort_blacklist.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.so.rules snort_exploit-kit.so.rules] &lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_ddos.rules snort_ddos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_dos.rules snort_dos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.rules snort_exploit-kit.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-malware.rules emerging-malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-mobile_malware.rules emerging-mobile_malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-tor.rules emerging-tor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-trojan.rules emerging-trojan.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_malware-backdoor.rules snort_malware-backdoor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_virus.rules snort_virus.rules]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-024.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click SAVE when finished to save the selection and build the rules &lt;br /&gt;
&lt;br /&gt;
After that restart the service &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-025.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Managing Pass lists:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Pass Lists are lists of IP addresses that Snort should never block. These may be created and managed on the Pass Lists tab. When an IP address is listed on a Pass List, Snort will never insert a block on that address even when malicious traffic is detected.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;To create a new Pass List, click &amp;quot;+&amp;quot;. To edit an existing Pass List, click the &amp;quot;e&amp;quot;. To delete a Pass List, click &amp;quot;x&amp;quot;. Note that a Pass List may not be deleted if it is currently assigned to one or more Snort interfaces.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We have added GIPL IP’s in Pass list . i.e&#039;&#039;&#039; &amp;lt;u&amp;gt;203.77.192.0/20&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-026.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== IP Alias and Port Alias ==&lt;br /&gt;
IP aliases allow you to create a group of IP addresses that you can assign by group name instead of specifying each IP address individually. This can be great for specifying a group of servers that need ssh access and then in the firewall rules you can create a rule that allows ssh traffic for the ssh servers group.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Along the top menu hover over Firewall and click on Aliases.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-027.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The next tab is for setting up Port Aliases. &amp;amp;nbsp;Similar to the IP Aliases you can setup groups but on this tab you are creating groups of ports instead of IP addresses.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-028.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
IP Aliases Created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-029.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
PORT ALIAS CREATED&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-030.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Firewall Rules :- ==&lt;br /&gt;
Reference:- [https://doc.pfsense.org/index.php/Firewall_Rule_Basics https://doc.pfsense.org/index.php/Firewall_Rule_Basics]&lt;br /&gt;
&lt;br /&gt;
Firewall rules control what traffic is allowed to enter an interface on the firewall. Once traffic is passed on the interface it enters an entry in the state table is created. A state table entry allows through subsequent packets that are part of that connection.&lt;br /&gt;
&lt;br /&gt;
Firewall rules are managed at Firewall &amp;gt; Rules. Multiple rules may be selected for some actions by clicking on their row or checking the box at the start of their row. Rules may be deleted or reordered in bulk in this way. See Managing Lists of Items on pfSense for more information on the meaning of the icons when manipulating rules.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;any&#039;&#039;&#039; - &#039;&#039;0.0.0.0&#039;&#039; to &#039;&#039;255.255.255.255&#039;&#039;, or all IPv6 addresses &lt;br /&gt;
* &#039;&#039;&#039;Single host or alias&#039;&#039;&#039; - Select this and enter one IP address (&#039;&#039;1.2.3.4&#039;&#039;, &#039;&#039;aa:bb:cc:dd::1&#039;&#039;) or type the name of an Alias that has already been configured (&#039;&#039;&#039;Firewall &amp;gt; Aliases&#039;&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Network&#039;&#039;&#039; - Select this and enter a network and mask (&#039;&#039;10.99.0.0/16&#039;&#039;, &#039;&#039;aa:bb:cc:dd::0/64&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;LAN net&#039;&#039;&#039; - The subnet configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039;. On pfSense 2.2+, this also includes static route networks on that interface. &lt;br /&gt;
* &#039;&#039;&#039;LAN address&#039;&#039;&#039; - The IP address configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039; &lt;br /&gt;
* &#039;&#039;&#039;zzz Net&#039;&#039;&#039; / &#039;&#039;&#039;zzz address&#039;&#039;&#039; - Works the same as LAN above but for other interfaces (WAN, OPT1, OPT2, etc.) &lt;br /&gt;
* &#039;&#039;&#039;PPTP clients&#039;&#039;&#039; - Automatically locate and use the addresses of PPTP clients &lt;br /&gt;
* &#039;&#039;&#039;L2TP clients&#039;&#039;&#039; - Automatically locate and use the addresses of L2TP clients &lt;br /&gt;
* &#039;&#039;&#039;This Firewall (self)&#039;&#039;&#039; - Any IP address assigned to any interface on this firewall (pfSense 2.2+) &lt;br /&gt;
&lt;br /&gt;
Firewall rules are generally processed starting with Floating Rules, then Interface Group rules, then Interface tab rules&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Rules Created on bridge interface, for DMZ access&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-031.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-032.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface Rules Created:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-033.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Squid and Squidguard:- ==&lt;br /&gt;
&#039;&#039;&#039;Reference - &#039;&#039;&#039;[https://doc.pfsense.org/index.php/SquidGuard_package https://doc.pfsense.org/index.php/SquidGuard_package]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Login to your pfsense&#039;s Web Administrator, and click on &amp;quot;Server -&amp;gt; Packages&amp;quot;, scroll down the list and find squid and click on &amp;quot;+&amp;quot; button to install, wait for the process to finish then return to the packages section and look for squidguard and install that package as well.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-034.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now go to &amp;quot;Services&amp;quot; menu and look for Proxy Server &amp;amp; Proxy Filter &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-035.jpg]]&lt;br /&gt;
&lt;br /&gt;
(We are setting up the proxy server as a transparent proxy)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on Services -&amp;gt; Proxy Server.&lt;br /&gt;
&lt;br /&gt;
On the General Tab, you want to set the following settings, the Proxy Interface Option should be set to &amp;quot;LAN&amp;quot;, to set up transparent proxy server, tick the &amp;quot;Transparent Proxy&amp;quot; check box.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-036.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Tick the &amp;quot;Enabled Logging&amp;quot; Checkbox, set the log store to the default location &amp;quot; /var/squid/logs &amp;quot; rotate your logs every 30 days, set your proxy port to port number 3128 We have By-passed Proxy for 203.77.192.49/28, These are the Local Servers.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next click on the &amp;quot;Cache Mgmt.&amp;quot; tab, by default the Hard Disk Cache Size is set to 100mb, we have allocated 100GB , Memory Cache Size 3072 .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-037.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click on Save.&lt;br /&gt;
&lt;br /&gt;
Click on the Access Control Tab next, in the allowed subnets field type in your required subnets. As we have multiple Subnets, so we are going to define all.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-038.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.129/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.1.224.1/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.192.49/28&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.57/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.17/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.137/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.33.50.1/27&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click On Save &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that’s is the proxy server configured, next we are going to configure SquidGuard, click on the Services menu and select the Proxy Filter button, tick the following 3 check boxes &amp;quot;Enable&amp;quot;, &amp;quot;Enable GUI Log&amp;quot; and &amp;quot;Enable Log&amp;quot; then click the Save button, once the page has reloaded click on apply and then confirm that the Squidguard service is running by making sure the SquidGuard status is set to STARTED.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-039.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on the Black list tab and add URL &#039;&#039;&#039;http://www.shallalist.de/Downloads/shallalist.tar.gz&#039;&#039;&#039; to the Update Address and click on Download. Wait for the process to complete.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-040.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-041.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now we can set up common ACL’s&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-042.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-043.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Click on Save and restart the Squid and SquidGuard from Services. &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SARG:- ==&lt;br /&gt;
After Installing SARG package, we can configure SARG from Status &amp;gt; Sarg Reports&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-044.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select Proxy Servers as SQUID proxy . And leave Rest of Field set to Default&lt;br /&gt;
&lt;br /&gt;
And Save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Go to Next Tab Schedule&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click “+” Symbol to create new schedule &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-045.jpg]] &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Reports can be viewed From “View Reports”&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-046.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bandwidthd:- ==&lt;br /&gt;
After Installing Package &#039;&#039;&#039;bandwidthd&#039;&#039;&#039; , Configuration can be done via&lt;br /&gt;
&lt;br /&gt;
Services &amp;gt; bandwidthd&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-047.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-048.jpg]]&lt;br /&gt;
&lt;br /&gt;
Enable Bandwidthd by checking the BOX.&lt;br /&gt;
&lt;br /&gt;
Now Select the Interface: - LAN.&lt;br /&gt;
&lt;br /&gt;
Enter The Subnets from LAN interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Save and Restart bandwidthd service from Services.&lt;br /&gt;
&lt;br /&gt;
Now Bandwidthd can be accessed:-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/bandwidthd/index.html https://203.77.200.91:8080/bandwidthd/index.html]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of ntopng:- ==&lt;br /&gt;
After installing ntopng package, it appears under Diagnostics &amp;gt; ntopng. It will even track where connections were made by local PCs, and how much bandwidth was used on individual connections.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-049.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
First we have to configure ntopng settings. Via Diagnostics &amp;gt; ntopng settings.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-050.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Setup Admin Password &amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Select the Interfaces on Which ntopng will be monitoring traffic.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We have selected LAN, DMZ and BRIDGEINTERFACE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To save the changes Click “Change”&lt;br /&gt;
&lt;br /&gt;
Ntopng can be accessed via [http://203.77.200.91:3000/login.html http://203.77.200.91:3000/login.html]&lt;br /&gt;
&lt;br /&gt;
With username admin and password assigned in previous step.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Configuring OpenVPN  =&lt;br /&gt;
A VPN (virtual private network) allows us to connect directly to our home private network over the internet&lt;br /&gt;
&lt;br /&gt;
The certificate authority or CA will sign the certificates that we will be creating for the server and client side when we configure OpenVPN. You can access the certificate configuration by going over to System–&amp;gt;Cert Manager.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-051.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Under the CAs tab you might already have a CA created if you followed one of my previous articles as we needed to created one in order to sign an internal certificate to be used for securing the pfSense web interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Certificate Authority ===&lt;br /&gt;
Fill in the fields to &#039;&#039;&#039;create a new Certificate Authority&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Descriptive Name&#039;&#039;&#039; - Used as the Common Name (CN) for the CA. Do not spaces, punctuation or special characters (ex: &#039;&#039;VPN Server CA&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Key Length&#039;&#039;&#039; - Default is OK, the higher the better but will use more CPU. &lt;br /&gt;
* &#039;&#039;&#039;Lifetime&#039;&#039;&#039; - Default is OK, but can be lowered if it must be changed out more often. &lt;br /&gt;
* &#039;&#039;&#039;Country Code&#039;&#039;&#039;, &#039;&#039;&#039;State/Province&#039;&#039;&#039;, &#039;&#039;&#039;City&#039;&#039;&#039;, &#039;&#039;&#039;Organization&#039;&#039;&#039; - Enter values for this location/company. &lt;br /&gt;
* &#039;&#039;&#039;E-mail&#039;&#039;&#039; - Used as a reference on the certificate, does not receive any mail from the system. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Add New CA&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-052.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
After you finished setting up the CA the next step is to create some certificates that the recently created CA will sign for us. Since these are self-signed certificates most browsers will give you a warning&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Server Certificate ===&lt;br /&gt;
Fill in the fields to create a new &#039;&#039;&#039;Server Certificate&#039;&#039;&#039;. Similar Fields as CA entry, most of the fields carry over and do not need changed. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Create new Certificate&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-053.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that we have all the components in place we can configure OpenVPN. Head over to VPN–&amp;gt;OpenVPN.&lt;br /&gt;
&lt;br /&gt;
.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-054.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select “Wizards” from the tab at the top which will guide us step by step to configure OpenVPN&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-055.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-056.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We will select the local user access database provided by pfSense&lt;br /&gt;
&lt;br /&gt;
In the next step we will be selecting the CA that we created at the beginning of this article.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-057.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Following is the Server Certificate that we will be using which is the Certificate that we recently created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-058.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;OpenVPN Server Configuration&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;TLS Authentication&#039;&#039;&#039; -- Leave this checked, along with the box underneath to generate a new key. Using a TLS key is technically optional, but &#039;&#039;highly&#039;&#039; recommended&lt;br /&gt;
* &#039;&#039;&#039;Tunnel Network&#039;&#039;&#039; -- Should be a new, unique network that does not exist anywhere in the current network or routing table. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-059.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-060.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-061.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== Firewall Rules ===&lt;br /&gt;
The next screen offers the choice to add firewall rules automatically. For convenience, check both unless the rules will be managed manually. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== End of the Wizard ===&lt;br /&gt;
Click &#039;&#039;&#039;Finish&#039;&#039;&#039; to exit the wizard and the new settings will be saved and applied automatically. &lt;br /&gt;
&lt;br /&gt;
== Adding a User with a Certificate ==&lt;br /&gt;
Navigate to &#039;&#039;&#039;System &amp;gt; User Manager&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click &amp;quot;+&amp;quot; To add a &#039;&#039;&#039;user&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Username&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Password / Confirm password&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Check Click to create a &#039;&#039;&#039;user certificate.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in the Descriptive Name as the username&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-062.jpeg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-063.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The OpenVPN Client Export Package allows exporting configurations formatted for a wide variety of platforms. It also allows exporting a pre-packaged Windows installer executable which includes the configuration bundled inside for a painly client installation. &lt;br /&gt;
&lt;br /&gt;
=== Installing the OpenVPN Client Export Package ===&lt;br /&gt;
To Install the OpenVPN Client Export Package &lt;br /&gt;
&lt;br /&gt;
* Navigate to &#039;&#039;&#039;System &amp;gt; Packages&#039;&#039;&#039;, &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab &lt;br /&gt;
* Find &#039;&#039;&#039;OpenVPN Client Export Package&#039;&#039;&#039; in the list &lt;br /&gt;
&lt;br /&gt;
=== Exporting a Configuration ===&lt;br /&gt;
* Navigate to &#039;&#039;&#039;VPN &amp;gt; OpenVPN&#039;&#039;&#039; on the &#039;&#039;&#039;Client Export&#039;&#039;&#039; tab &lt;br /&gt;
* Choose the VPN from the &#039;&#039;&#039;Remote Access Server&#039;&#039;&#039; drop-down list &lt;br /&gt;
* Find the user in the list at the bottom of the page and select the appropriate configuration type to export. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-064.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-065.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Multiple instance of VPN server can be created with different tunnel network &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-066.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Firewall Rules are applied as per the requirement on tunnel network .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-067.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Firewall Logs =&lt;br /&gt;
The Firewall logs at &#039;&#039;&#039;Status &amp;gt; System Logs&#039;&#039;&#039; on the &#039;&#039;&#039;Firewall&#039;&#039;&#039; tab show all events logged by the firewall.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Each entry is displayed with the action ( pass or block, reject is only logged as block), time, interface, source, destination, and protocol.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Configuration Of rsyslog Server for Logs Storage:-&lt;br /&gt;
&lt;br /&gt;
Status: &amp;gt;System logs &amp;gt; Settings&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-068.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Configuration of rsyslog on Centos :-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Setup Log File Location =====&lt;br /&gt;
Now edit Rsyslog configuration file and configure the location’s to generate log files in system.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# vim /etc/rsyslog.conf&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
and add following lines as the end of file.&lt;br /&gt;
&lt;br /&gt;
$template TmplAuth, &amp;quot;/var/log/%HOSTNAME%/%PROGRAMNAME%.log&amp;quot; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
authpriv.* ?TmplAuth&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;*.info,mail.none,authpriv.none,cron.none &amp;lt;/nowiki&amp;gt;?TmplMsg&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Enable Module and UDP Protocol =====&lt;br /&gt;
Also remove comment from following lines ( remove starting # ) in rsyslog configuration file to enable UDP.&lt;br /&gt;
&lt;br /&gt;
$ModLoad imudp&lt;br /&gt;
&lt;br /&gt;
$UDPServerRun 514&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Restart Rsyslog  =====&lt;br /&gt;
After making above changes in Rsyslog central server, restart service using following command.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# service rsyslog restart&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Logrotation:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Create file&#039;&#039;&#039; :- &#039;&#039;&#039;/etc/logrotate.d/pfsense&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;And enter:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/var/log/pfsense/filterlog.log&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;{&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;daily&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;missingok&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;rotate 60&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;compress&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;notifempty&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;create 640 root root&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;postrotate&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/etc/init.d/rsyslog restart &amp;gt;/dev/null&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;endscript&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;}&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Save and Quit.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;RRD Graphs:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
These are located under &#039;&#039;&#039;Status &amp;gt; RRD Graphs&#039;&#039;&#039;. Several graphs are presented for each monitored item, with varying time intervals and averages. &lt;br /&gt;
&lt;br /&gt;
These graphs measure things such as CPU usage, memory usage, state table usage, throughput (in bytes as well as packets), link quality, traffic shaping queue usage, and so on. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-069.jpg]]&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1910</id>
		<title>PF Sense Firewall Implementation at GIPL</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1910"/>
		<updated>2015-04-16T11:16:39Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:Tetra Clients]]&lt;br /&gt;
[[category:GSPC]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;center&amp;gt;&amp;lt;u&amp;gt;&#039;&#039;&#039;PF Sense Firewall Implementation at GIPL , GandhiNagar &#039;&#039;&#039;&amp;lt;/u&amp;gt;&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-000.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Installation&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;pfSense&#039;&#039;&#039; is an open source firewall/router computer software distribution based on FreeBSD. It is installed on a computer to make a dedicated firewall/router for a network and is noted for its reliability[1] and offering features often only found in expensive commercial firewalls&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Download pfSense&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Visit https://www.pfsense.org/download/mirror.php?section=downloads&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Step 1 :- &#039;&#039;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Performing a Full Install (LiveCD) ==&lt;br /&gt;
Power on the target system and connect the install media: Place the CD into the drive or plug the Memstick into a USB port. If the BIOS is set to boot from CD/USB, pfSense will start. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-001.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
As the operating system boots and pfSense starts, a prompt is presented with some choices and a countdown timer. At this prompt, press &#039;&#039;i&#039;&#039; to invoke the installer now.&lt;br /&gt;
&lt;br /&gt;
When the installer detects multiple disks in the system the first screen available provides the option &#039;&#039;&#039;Setup GEOM Mirror&#039;&#039;&#039;. Choose that option, pick the primary disk, the disk to use for the mirror copy, and then proceed with the installation as normal. &lt;br /&gt;
&lt;br /&gt;
The Quick/Easy install choice will target the GEOM mirror automatically&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-002.jpeg]]&lt;br /&gt;
&lt;br /&gt;
At the &#039;&#039;&#039;Select Task&#039;&#039;&#039; prompt, choose &#039;&#039;Quick/Easy Install&#039;&#039;. [[Image:Gpil-003.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-004.jpeg]]&lt;br /&gt;
&lt;br /&gt;
The install will proceed, wiping the target disk and installing pfSense. Copying files may take some time to finish. &lt;br /&gt;
&lt;br /&gt;
After the files have been copied to the target disk, a choice is presented to select the console type. &#039;&#039;Standard&#039;&#039; defaults to the VGA console. &#039;&#039;Embedded&#039;&#039; defaults to serial console&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-005.jpeg]]&lt;br /&gt;
&lt;br /&gt;
Now the system must reboot so that pfSense may start from the target disk. Select &#039;&#039;Reboot&#039;&#039; and then press &#039;&#039;&#039;Enter (remove CD from Drive)&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-006.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After the system reboots, pfSense will be running from the target disk. The next step is to Assign Interfaces on the Console below.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-007.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After installation and assignment, a shell menu is presented on the console with a number of options. pfSense now is ready to be accessed via the network, LAN interface IP 192.168.1.1 is assigned by default.&lt;br /&gt;
&lt;br /&gt;
Open a web browser and navigate to https://192.168.1.1/, using the default username admin and password pfsense to login.&lt;br /&gt;
&lt;br /&gt;
The first visit to the WebGUI will be redirected to the setup wizard.&lt;br /&gt;
&lt;br /&gt;
== GUI Configuration Setup ==&lt;br /&gt;
Once The Setup is launched, Fill the details are follows:-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-008.jpg]]&lt;br /&gt;
&lt;br /&gt;
We have defined FQDN as gipl.firewall&lt;br /&gt;
&lt;br /&gt;
DNS servers:- 8.8.8.8 and 4.4.2.2 Global DNS&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click NEXT&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-009.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select The Time-Zone as Asia/Kolkata .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
And Click NEXT&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-010.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Here we have Set WAN as Static Interface&lt;br /&gt;
&lt;br /&gt;
With IP address :- 203.77.200.91/25&lt;br /&gt;
&lt;br /&gt;
Gateway :- 203.77.200.1&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-011.jpg]]&lt;br /&gt;
&lt;br /&gt;
Here we have Configured LAN interface with IP address 192.168.45.101/24&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
( note:-As per the client Network Topology , Lan interface have multiple Subnets configured , so we will be configuring Virtual IP’s from GUI )&lt;br /&gt;
&lt;br /&gt;
After Setting Admin Password, Page will be redirected to Pfsense-Dashboard.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We Have Changed Default Port from 443 to 8080 Via :-&lt;br /&gt;
[[Image:Gpil-012.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;System &amp;gt; Advanced&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-013.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Change TCP Port from Default 443 to 8080 .&lt;br /&gt;
&lt;br /&gt;
Save .&lt;br /&gt;
&lt;br /&gt;
Now pfsense Can be accessed via [https://IP:8080 https://IP:8080]&lt;br /&gt;
&lt;br /&gt;
IP Address of Firewall is 203.77.200.91 on WAN interface.&lt;br /&gt;
&lt;br /&gt;
Go to :- interface &amp;gt; assign , and edit Opt1 as DMZ , do not assign IP address to This interface , because we will be creating bridge interface .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bridge Interface ==&lt;br /&gt;
Now we have to configure &#039;&#039;&#039;Interface Bridges&#039;&#039;&#039; in order to Setup Pfsense in &lt;br /&gt;
&lt;br /&gt;
Transparent mode.&lt;br /&gt;
&lt;br /&gt;
Reference:- &amp;lt;u&amp;gt;https://doc.pfsense.org/index.php/Interface_Bridges&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Navigate To :- Interfaces &amp;gt; (assign) &lt;br /&gt;
&lt;br /&gt;
on the Bridges tab Click “ +” symbol to add a new bridge .&lt;br /&gt;
[[Image:Gpil-014.jpg]] &lt;br /&gt;
&lt;br /&gt;
Ctrl-Click to select the Member interfaces from the list of available interfaces and type a Description , we have selected WAN + DMZ as bridge0 and create new Interface BRIDGEINTERFACE using bridge0 .&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-015.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
By default, traffic is filtered on the member interfaces and not on the bridge interface itself. This behavior may be changed by toggling the values of &#039;&#039;&#039;net.link.bridge.pfil_member&#039;&#039;&#039; and net.link.bridge.pfil&#039;&#039;&#039;_bridge &#039;&#039;&#039;under System&#039;&#039;&#039; &amp;gt; Advanced &#039;&#039;&#039;on the &#039;&#039;&#039;System Tunables&#039;&#039;&#039; tab. With them set at &#039;&#039;0&#039;&#039; and &#039;&#039;1&#039;&#039;, respectively, then filtering would be performed on the bridge only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-016.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Pfsense is Configured In Bridge Mode with &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;WAN interface: - 203.77.200.91/25 gateway :- 203.77.200.1&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface:- 192.168.45.101/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;DMZ: - no ip &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;BRIDGEINTERFACE:- 203.77.200.92/25&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-017.jpg]]&lt;br /&gt;
&lt;br /&gt;
== Assign Virtual IP’s To LAN interface:- ==&lt;br /&gt;
[[Image:Gpil-018.jpg]]&lt;br /&gt;
Now as LAN environment have multiple Subnet configured, we will be assigning Virtual IP address to LAN interface.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-019.jpg]]&lt;br /&gt;
&lt;br /&gt;
Clients on LAN Environment have their Gateway Set from These Virtual IP’s.&lt;br /&gt;
&lt;br /&gt;
203.77.196.230 is added for outside access of Local Servers 203.77.192.49/28.&lt;br /&gt;
&lt;br /&gt;
(203.77.196.230) is configured in 203.77.192.2 switch which will receive any packet for 203.77.192.49/28 from Outside and send it to 203.77.196.230.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SNORT  ==&lt;br /&gt;
&amp;lt;u&amp;gt;&#039;&#039;&#039;Reference&#039;&#039;&#039;&amp;lt;/u&amp;gt; :- &amp;lt;u&amp;gt;&#039;&#039;&#039;https://doc.pfsense.org/index.php/Setup_Snort_Package&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Go to the &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab under the &#039;&#039;&#039;System&#039;&#039;&#039; menu and install the snort package.&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;When the installation completes, click on &#039;&#039;&#039;Snort&#039;&#039;&#039; under the &#039;&#039;&#039;Services&#039;&#039;&#039; menu. &amp;amp;nbsp;This will open the Snort main setup page.&lt;br /&gt;
&lt;br /&gt;
Click the &#039;&#039;&#039;Global Settings&#039;&#039;&#039; tab and perform the following At the top of the page you have three choices for Rule Sets to activate.&lt;br /&gt;
&lt;br /&gt;
Put Check mark on :-Install &#039;&#039;&#039;Snort Community&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Emerging Threats&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Snort VRT&#039;&#039;&#039; rules. And save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Updates&#039;&#039;&#039; tab is used to check the status of downloaded rules packages and to download new updates. The table shows the available rule packages and their current status [[Image:Gpil-020.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Update Button to Update the rules.&lt;br /&gt;
[[Image:Gpil-021.jpg]]&lt;br /&gt;
&lt;br /&gt;
== Add Snort to an interface ==&lt;br /&gt;
Click the Snort Interfaces tab and then the &amp;quot;+&amp;quot; icon to add a new Snort interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;On the &#039;&#039;&#039;WAN Settings&#039;&#039;&#039; tab, click the &#039;&#039;Enable&#039;&#039; checkbox.In the drop-down, choose the interface. &amp;amp;nbsp;The WAN interface is the default and is a good first choice.In the &#039;&#039;Description&#039;&#039; textbox, enter a name (WAN again, is fine here).Click the checkbox to &amp;quot;&#039;&#039;Send alerts to the main System logs&#039;&#039;&amp;quot;.leave the other settings at their defaults&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-022.jpg]]&lt;br /&gt;
&lt;br /&gt;
After saving, the browser will be returned to the Snort Interfaces tab. Note the warning icons in the image below showing no rules have been selected for the new Snort interface. Those rules will be configured next. Click the &amp;quot;e&amp;quot; icon to edit the new Snort interface again&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-023.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Select which types of rules will protect the network ==&lt;br /&gt;
Click the &#039;&#039;&#039;Categories&#039;&#039;&#039; tab for the new interface&lt;br /&gt;
&lt;br /&gt;
Check [https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=GPLv2_community.rules Snort GPLv2 Community Rules (VRT certified)] Box .&lt;br /&gt;
&lt;br /&gt;
And Manual Rules :-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-botcc.rules emerging-botcc.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_blacklist.rules snort_blacklist.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.so.rules snort_exploit-kit.so.rules] &lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_ddos.rules snort_ddos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_dos.rules snort_dos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.rules snort_exploit-kit.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-malware.rules emerging-malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-mobile_malware.rules emerging-mobile_malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-tor.rules emerging-tor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-trojan.rules emerging-trojan.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_malware-backdoor.rules snort_malware-backdoor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_virus.rules snort_virus.rules]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-024.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click SAVE when finished to save the selection and build the rules &lt;br /&gt;
&lt;br /&gt;
After that restart the service &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-025.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Managing Pass lists:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Pass Lists are lists of IP addresses that Snort should never block. These may be created and managed on the Pass Lists tab. When an IP address is listed on a Pass List, Snort will never insert a block on that address even when malicious traffic is detected.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;To create a new Pass List, click &amp;quot;+&amp;quot;. To edit an existing Pass List, click the &amp;quot;e&amp;quot;. To delete a Pass List, click &amp;quot;x&amp;quot;. Note that a Pass List may not be deleted if it is currently assigned to one or more Snort interfaces.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We have added GIPL IP’s in Pass list . i.e&#039;&#039;&#039; &amp;lt;u&amp;gt;203.77.192.0/20&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-026.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== IP Alias and Port Alias ==&lt;br /&gt;
IP aliases allow you to create a group of IP addresses that you can assign by group name instead of specifying each IP address individually. This can be great for specifying a group of servers that need ssh access and then in the firewall rules you can create a rule that allows ssh traffic for the ssh servers group.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Along the top menu hover over Firewall and click on Aliases.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-027.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The next tab is for setting up Port Aliases. &amp;amp;nbsp;Similar to the IP Aliases you can setup groups but on this tab you are creating groups of ports instead of IP addresses.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-028.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
IP Aliases Created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-029.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
PORT ALIAS CREATED&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-030.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Firewall Rules :- ==&lt;br /&gt;
Reference:- [https://doc.pfsense.org/index.php/Firewall_Rule_Basics https://doc.pfsense.org/index.php/Firewall_Rule_Basics]&lt;br /&gt;
&lt;br /&gt;
Firewall rules control what traffic is allowed to enter an interface on the firewall. Once traffic is passed on the interface it enters an entry in the state table is created. A state table entry allows through subsequent packets that are part of that connection.&lt;br /&gt;
&lt;br /&gt;
Firewall rules are managed at Firewall &amp;gt; Rules. Multiple rules may be selected for some actions by clicking on their row or checking the box at the start of their row. Rules may be deleted or reordered in bulk in this way. See Managing Lists of Items on pfSense for more information on the meaning of the icons when manipulating rules.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;any&#039;&#039;&#039; - &#039;&#039;0.0.0.0&#039;&#039; to &#039;&#039;255.255.255.255&#039;&#039;, or all IPv6 addresses &lt;br /&gt;
* &#039;&#039;&#039;Single host or alias&#039;&#039;&#039; - Select this and enter one IP address (&#039;&#039;1.2.3.4&#039;&#039;, &#039;&#039;aa:bb:cc:dd::1&#039;&#039;) or type the name of an Alias that has already been configured (&#039;&#039;&#039;Firewall &amp;gt; Aliases&#039;&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Network&#039;&#039;&#039; - Select this and enter a network and mask (&#039;&#039;10.99.0.0/16&#039;&#039;, &#039;&#039;aa:bb:cc:dd::0/64&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;LAN net&#039;&#039;&#039; - The subnet configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039;. On pfSense 2.2+, this also includes static route networks on that interface. &lt;br /&gt;
* &#039;&#039;&#039;LAN address&#039;&#039;&#039; - The IP address configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039; &lt;br /&gt;
* &#039;&#039;&#039;zzz Net&#039;&#039;&#039; / &#039;&#039;&#039;zzz address&#039;&#039;&#039; - Works the same as LAN above but for other interfaces (WAN, OPT1, OPT2, etc.) &lt;br /&gt;
* &#039;&#039;&#039;PPTP clients&#039;&#039;&#039; - Automatically locate and use the addresses of PPTP clients &lt;br /&gt;
* &#039;&#039;&#039;L2TP clients&#039;&#039;&#039; - Automatically locate and use the addresses of L2TP clients &lt;br /&gt;
* &#039;&#039;&#039;This Firewall (self)&#039;&#039;&#039; - Any IP address assigned to any interface on this firewall (pfSense 2.2+) &lt;br /&gt;
&lt;br /&gt;
Firewall rules are generally processed starting with Floating Rules, then Interface Group rules, then Interface tab rules&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Rules Created on bridge interface, for DMZ access&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-031.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-032.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface Rules Created:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-033.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Squid and Squidguard:- ==&lt;br /&gt;
&#039;&#039;&#039;Reference - &#039;&#039;&#039;[https://doc.pfsense.org/index.php/SquidGuard_package https://doc.pfsense.org/index.php/SquidGuard_package]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Login to your pfsense&#039;s Web Administrator, and click on &amp;quot;Server -&amp;gt; Packages&amp;quot;, scroll down the list and find squid and click on &amp;quot;+&amp;quot; button to install, wait for the process to finish then return to the packages section and look for squidguard and install that package as well.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-034.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now go to &amp;quot;Services&amp;quot; menu and look for Proxy Server &amp;amp; Proxy Filter &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-035.jpg]]&lt;br /&gt;
&lt;br /&gt;
(We are setting up the proxy server as a transparent proxy)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on Services -&amp;gt; Proxy Server.&lt;br /&gt;
&lt;br /&gt;
On the General Tab, you want to set the following settings, the Proxy Interface Option should be set to &amp;quot;LAN&amp;quot;, to set up transparent proxy server, tick the &amp;quot;Transparent Proxy&amp;quot; check box.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-036.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Tick the &amp;quot;Enabled Logging&amp;quot; Checkbox, set the log store to the default location &amp;quot; /var/squid/logs &amp;quot; rotate your logs every 30 days, set your proxy port to port number 3128 We have By-passed Proxy for 203.77.192.49/28, These are the Local Servers.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next click on the &amp;quot;Cache Mgmt.&amp;quot; tab, by default the Hard Disk Cache Size is set to 100mb, we have allocated 100GB , Memory Cache Size 3072 .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-037.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click on Save.&lt;br /&gt;
&lt;br /&gt;
Click on the Access Control Tab next, in the allowed subnets field type in your required subnets. As we have multiple Subnets, so we are going to define all.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-038.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.129/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.1.224.1/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.192.49/28&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.57/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.17/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.137/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.33.50.1/27&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click On Save &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that’s is the proxy server configured, next we are going to configure SquidGuard, click on the Services menu and select the Proxy Filter button, tick the following 3 check boxes &amp;quot;Enable&amp;quot;, &amp;quot;Enable GUI Log&amp;quot; and &amp;quot;Enable Log&amp;quot; then click the Save button, once the page has reloaded click on apply and then confirm that the Squidguard service is running by making sure the SquidGuard status is set to STARTED.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-039.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on the Black list tab and add URL &#039;&#039;&#039;http://www.shallalist.de/Downloads/shallalist.tar.gz&#039;&#039;&#039; to the Update Address and click on Download. Wait for the process to complete.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-040.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-041.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now we can set up common ACL’s&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-042.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-043.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Click on Save and restart the Squid and SquidGuard from Services. &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SARG:- ==&lt;br /&gt;
After Installing SARG package, we can configure SARG from Status &amp;gt; Sarg Reports&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-044.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select Proxy Servers as SQUID proxy . And leave Rest of Field set to Default&lt;br /&gt;
&lt;br /&gt;
And Save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Go to Next Tab Schedule&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click “+” Symbol to create new schedule &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-045.jpg]] &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Reports can be viewed From “View Reports”&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-046.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bandwidthd:- ==&lt;br /&gt;
After Installing Package &#039;&#039;&#039;bandwidthd&#039;&#039;&#039; , Configuration can be done via&lt;br /&gt;
&lt;br /&gt;
Services &amp;gt; bandwidthd&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-047.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-048.jpg]]&lt;br /&gt;
&lt;br /&gt;
Enable Bandwidthd by checking the BOX.&lt;br /&gt;
&lt;br /&gt;
Now Select the Interface: - LAN.&lt;br /&gt;
&lt;br /&gt;
Enter The Subnets from LAN interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Save and Restart bandwidthd service from Services.&lt;br /&gt;
&lt;br /&gt;
Now Bandwidthd can be accessed:-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/bandwidthd/index.html https://203.77.200.91:8080/bandwidthd/index.html]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of ntopng:- ==&lt;br /&gt;
After installing ntopng package, it appears under Diagnostics &amp;gt; ntopng. It will even track where connections were made by local PCs, and how much bandwidth was used on individual connections.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-049.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
First we have to configure ntopng settings. Via Diagnostics &amp;gt; ntopng settings.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-050.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Setup Admin Password &amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Select the Interfaces on Which ntopng will be monitoring traffic.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We have selected LAN, DMZ and BRIDGEINTERFACE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To save the changes Click “Change”&lt;br /&gt;
&lt;br /&gt;
Ntopng can be accessed via [http://203.77.200.91:3000/login.html http://203.77.200.91:3000/login.html]&lt;br /&gt;
&lt;br /&gt;
With username admin and password assigned in previous step.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Configuring OpenVPN  =&lt;br /&gt;
A VPN (virtual private network) allows us to connect directly to our home private network over the internet&lt;br /&gt;
&lt;br /&gt;
The certificate authority or CA will sign the certificates that we will be creating for the server and client side when we configure OpenVPN. You can access the certificate configuration by going over to System–&amp;gt;Cert Manager.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-051.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Under the CAs tab you might already have a CA created if you followed one of my previous articles as we needed to created one in order to sign an internal certificate to be used for securing the pfSense web interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Certificate Authority ===&lt;br /&gt;
Fill in the fields to &#039;&#039;&#039;create a new Certificate Authority&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Descriptive Name&#039;&#039;&#039; - Used as the Common Name (CN) for the CA. Do not spaces, punctuation or special characters (ex: &#039;&#039;VPN Server CA&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Key Length&#039;&#039;&#039; - Default is OK, the higher the better but will use more CPU. &lt;br /&gt;
* &#039;&#039;&#039;Lifetime&#039;&#039;&#039; - Default is OK, but can be lowered if it must be changed out more often. &lt;br /&gt;
* &#039;&#039;&#039;Country Code&#039;&#039;&#039;, &#039;&#039;&#039;State/Province&#039;&#039;&#039;, &#039;&#039;&#039;City&#039;&#039;&#039;, &#039;&#039;&#039;Organization&#039;&#039;&#039; - Enter values for this location/company. &lt;br /&gt;
* &#039;&#039;&#039;E-mail&#039;&#039;&#039; - Used as a reference on the certificate, does not receive any mail from the system. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Add New CA&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-052.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
After you finished setting up the CA the next step is to create some certificates that the recently created CA will sign for us. Since these are self-signed certificates most browsers will give you a warning&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Server Certificate ===&lt;br /&gt;
Fill in the fields to create a new &#039;&#039;&#039;Server Certificate&#039;&#039;&#039;. Similar Fields as CA entry, most of the fields carry over and do not need changed. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Create new Certificate&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-053.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that we have all the components in place we can configure OpenVPN. Head over to VPN–&amp;gt;OpenVPN.&lt;br /&gt;
&lt;br /&gt;
.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-054.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select “Wizards” from the tab at the top which will guide us step by step to configure OpenVPN&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-055.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-056.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We will select the local user access database provided by pfSense&lt;br /&gt;
&lt;br /&gt;
In the next step we will be selecting the CA that we created at the beginning of this article.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-057.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Following is the Server Certificate that we will be using which is the Certificate that we recently created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-058.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;OpenVPN Server Configuration&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;TLS Authentication&#039;&#039;&#039; -- Leave this checked, along with the box underneath to generate a new key. Using a TLS key is technically optional, but &#039;&#039;highly&#039;&#039; recommended&lt;br /&gt;
* &#039;&#039;&#039;Tunnel Network&#039;&#039;&#039; -- Should be a new, unique network that does not exist anywhere in the current network or routing table. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-059.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-060.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-061.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== Firewall Rules ===&lt;br /&gt;
The next screen offers the choice to add firewall rules automatically. For convenience, check both unless the rules will be managed manually. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== End of the Wizard ===&lt;br /&gt;
Click &#039;&#039;&#039;Finish&#039;&#039;&#039; to exit the wizard and the new settings will be saved and applied automatically. &lt;br /&gt;
&lt;br /&gt;
== Adding a User with a Certificate ==&lt;br /&gt;
Navigate to &#039;&#039;&#039;System &amp;gt; User Manager&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click &amp;quot;+&amp;quot; To add a &#039;&#039;&#039;user&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Username&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Password / Confirm password&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Check Click to create a &#039;&#039;&#039;user certificate.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in the Descriptive Name as the username&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-062.jpeg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-063.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The OpenVPN Client Export Package allows exporting configurations formatted for a wide variety of platforms. It also allows exporting a pre-packaged Windows installer executable which includes the configuration bundled inside for a painly client installation. &lt;br /&gt;
&lt;br /&gt;
=== Installing the OpenVPN Client Export Package ===&lt;br /&gt;
To Install the OpenVPN Client Export Package &lt;br /&gt;
&lt;br /&gt;
* Navigate to &#039;&#039;&#039;System &amp;gt; Packages&#039;&#039;&#039;, &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab &lt;br /&gt;
* Find &#039;&#039;&#039;OpenVPN Client Export Package&#039;&#039;&#039; in the list &lt;br /&gt;
&lt;br /&gt;
=== Exporting a Configuration ===&lt;br /&gt;
* Navigate to &#039;&#039;&#039;VPN &amp;gt; OpenVPN&#039;&#039;&#039; on the &#039;&#039;&#039;Client Export&#039;&#039;&#039; tab &lt;br /&gt;
* Choose the VPN from the &#039;&#039;&#039;Remote Access Server&#039;&#039;&#039; drop-down list &lt;br /&gt;
* Find the user in the list at the bottom of the page and select the appropriate configuration type to export. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-064.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-065.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Multiple instance of VPN server can be created with different tunnel network &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-066.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Firewall Rules are applied as per the requirement on tunnel network .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-067.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Firewall Logs =&lt;br /&gt;
The Firewall logs at &#039;&#039;&#039;Status &amp;gt; System Logs&#039;&#039;&#039; on the &#039;&#039;&#039;Firewall&#039;&#039;&#039; tab show all events logged by the firewall.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Each entry is displayed with the action ( pass or block, reject is only logged as block), time, interface, source, destination, and protocol.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Configuration Of rsyslog Server for Logs Storage:-&lt;br /&gt;
&lt;br /&gt;
Status: &amp;gt;System logs &amp;gt; Settings&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-068.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Configuration of rsyslog on Centos :-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Setup Log File Location =====&lt;br /&gt;
Now edit Rsyslog configuration file and configure the location’s to generate log files in system.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# vim /etc/rsyslog.conf&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
and add following lines as the end of file.&lt;br /&gt;
&lt;br /&gt;
$template TmplAuth, &amp;quot;/var/log/%HOSTNAME%/%PROGRAMNAME%.log&amp;quot; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
authpriv.* ?TmplAuth&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;*.info,mail.none,authpriv.none,cron.none &amp;lt;/nowiki&amp;gt;?TmplMsg&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Enable Module and UDP Protocol =====&lt;br /&gt;
Also remove comment from following lines ( remove starting # ) in rsyslog configuration file to enable UDP.&lt;br /&gt;
&lt;br /&gt;
$ModLoad imudp&lt;br /&gt;
&lt;br /&gt;
$UDPServerRun 514&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Restart Rsyslog  =====&lt;br /&gt;
After making above changes in Rsyslog central server, restart service using following command.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# service rsyslog restart&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Logrotation:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Create file&#039;&#039;&#039; :- &#039;&#039;&#039;/etc/logrotate.d/pfsense&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;And enter:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/var/log/pfsense/filterlog.log&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;{&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;daily&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;missingok&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;rotate 60&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;compress&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;notifempty&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;create 640 root root&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;postrotate&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/etc/init.d/rsyslog restart &amp;gt;/dev/null&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;endscript&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;}&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Save and Quit.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;RRD Graphs:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
These are located under &#039;&#039;&#039;Status &amp;gt; RRD Graphs&#039;&#039;&#039;. Several graphs are presented for each monitored item, with varying time intervals and averages. &lt;br /&gt;
&lt;br /&gt;
These graphs measure things such as CPU usage, memory usage, state table usage, throughput (in bytes as well as packets), link quality, traffic shaping queue usage, and so on. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-069.jpg]]&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1909</id>
		<title>PF Sense Firewall Implementation at GIPL</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1909"/>
		<updated>2015-04-16T11:13:23Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:Tetra Clients]]&lt;br /&gt;
[[category:GSPC]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;center&amp;gt;&amp;lt;u&amp;gt;&#039;&#039;&#039;PF Sense Firewall Implementation at GIPL , GandhiNagar &#039;&#039;&#039;&amp;lt;/u&amp;gt;&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-000.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Installation&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;pfSense&#039;&#039;&#039; is an open source firewall/router computer software distribution based on FreeBSD. It is installed on a computer to make a dedicated firewall/router for a network and is noted for its reliability[1] and offering features often only found in expensive commercial firewalls&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Download pfSense&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Visit https://www.pfsense.org/download/mirror.php?section=downloads&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Step 1 :- &#039;&#039;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Performing a Full Install (LiveCD) ==&lt;br /&gt;
Power on the target system and connect the install media: Place the CD into the drive or plug the Memstick into a USB port. If the BIOS is set to boot from CD/USB, pfSense will start. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-001.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
As the operating system boots and pfSense starts, a prompt is presented with some choices and a countdown timer. At this prompt, press &#039;&#039;i&#039;&#039; to invoke the installer now.&lt;br /&gt;
&lt;br /&gt;
When the installer detects multiple disks in the system the first screen available provides the option &#039;&#039;&#039;Setup GEOM Mirror&#039;&#039;&#039;. Choose that option, pick the primary disk, the disk to use for the mirror copy, and then proceed with the installation as normal. &lt;br /&gt;
&lt;br /&gt;
The Quick/Easy install choice will target the GEOM mirror automatically&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-002.jpeg]]&lt;br /&gt;
&lt;br /&gt;
At the &#039;&#039;&#039;Select Task&#039;&#039;&#039; prompt, choose &#039;&#039;Quick/Easy Install&#039;&#039;. [[Image:Gpil-003.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-004.jpeg]]&lt;br /&gt;
&lt;br /&gt;
The install will proceed, wiping the target disk and installing pfSense. Copying files may take some time to finish. &lt;br /&gt;
&lt;br /&gt;
After the files have been copied to the target disk, a choice is presented to select the console type. &#039;&#039;Standard&#039;&#039; defaults to the VGA console. &#039;&#039;Embedded&#039;&#039; defaults to serial console&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-005.jpeg]]&lt;br /&gt;
&lt;br /&gt;
Now the system must reboot so that pfSense may start from the target disk. Select &#039;&#039;Reboot&#039;&#039; and then press &#039;&#039;&#039;Enter (remove CD from Drive)&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-006.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After the system reboots, pfSense will be running from the target disk. The next step is to Assign Interfaces on the Console below.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-007.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After installation and assignment, a shell menu is presented on the console with a number of options. pfSense now is ready to be accessed via the network, LAN interface IP 192.168.1.1 is assigned by default.&lt;br /&gt;
&lt;br /&gt;
Open a web browser and navigate to https://192.168.1.1/, using the default username admin and password pfsense to login.&lt;br /&gt;
&lt;br /&gt;
The first visit to the WebGUI will be redirected to the setup wizard.&lt;br /&gt;
&lt;br /&gt;
== GUI Configuration Setup ==&lt;br /&gt;
Once The Setup is launched, Fill the details are follows:-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-008.jpg]]&lt;br /&gt;
&lt;br /&gt;
We have defined FQDN as gipl.firewall&lt;br /&gt;
&lt;br /&gt;
DNS servers:- 8.8.8.8 and 4.4.2.2 Global DNS&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click NEXT&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-009.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select The Time-Zone as Asia/Kolkata .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
And Click NEXT&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-010.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Here we have Set WAN as Static Interface&lt;br /&gt;
&lt;br /&gt;
With IP address :- 203.77.200.91/25&lt;br /&gt;
&lt;br /&gt;
Gateway :- 203.77.200.1&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-011.jpg]]&lt;br /&gt;
&lt;br /&gt;
Here we have Configured LAN interface with IP address 192.168.45.101/24&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
( note:-As per the client Network Topology , Lan interface have multiple Subnets configured , so we will be configuring Virtual IP’s from GUI )&lt;br /&gt;
&lt;br /&gt;
After Setting Admin Password, Page will be redirected to Pfsense-Dashboard.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-012.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We Have Changed Default Port from 443 to 8080 Via :-&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;System &amp;gt; Advanced&#039;&#039;&#039;&lt;br /&gt;
[[Image:Gpil-013.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Change TCP Port from Default 443 to 8080 .&lt;br /&gt;
[[Image:Gpil-014.jpg]] &lt;br /&gt;
Save .&lt;br /&gt;
&lt;br /&gt;
Now pfsense Can be accessed via [https://IP:8080 https://IP:8080]&lt;br /&gt;
&lt;br /&gt;
IP Address of Firewall is 203.77.200.91 on WAN interface.&lt;br /&gt;
&lt;br /&gt;
Go to :- interface &amp;gt; assign , and edit Opt1 as DMZ , do not assign IP address to This interface , because we will be creating bridge interface .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bridge Interface ==&lt;br /&gt;
Now we have to configure &#039;&#039;&#039;Interface Bridges&#039;&#039;&#039; in order to Setup Pfsense in &lt;br /&gt;
&lt;br /&gt;
Transparent mode.&lt;br /&gt;
&lt;br /&gt;
Reference:- &amp;lt;u&amp;gt;https://doc.pfsense.org/index.php/Interface_Bridges&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Navigate To :- Interfaces &amp;gt; (assign) &lt;br /&gt;
&lt;br /&gt;
on the Bridges tab Click “ +” symbol to add a new bridge .&lt;br /&gt;
&lt;br /&gt;
Ctrl-Click to select the Member interfaces from the list of available interfaces and type a Description , we have selected WAN + DMZ as bridge0 and create new Interface BRIDGEINTERFACE using bridge0 .&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-015.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
By default, traffic is filtered on the member interfaces and not on the bridge interface itself. This behavior may be changed by toggling the values of &#039;&#039;&#039;net.link.bridge.pfil_member&#039;&#039;&#039; and net.link.bridge.pfil&#039;&#039;&#039;_bridge &#039;&#039;&#039;under System&#039;&#039;&#039; &amp;gt; Advanced &#039;&#039;&#039;on the &#039;&#039;&#039;System Tunables&#039;&#039;&#039; tab. With them set at &#039;&#039;0&#039;&#039; and &#039;&#039;1&#039;&#039;, respectively, then filtering would be performed on the bridge only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-016.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Pfsense is Configured In Bridge Mode with &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;WAN interface: - 203.77.200.91/25 gateway :- 203.77.200.1&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface:- 192.168.45.101/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;DMZ: - no ip &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;BRIDGEINTERFACE:- 203.77.200.92/25&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-017.jpg]]&lt;br /&gt;
&lt;br /&gt;
== Assign Virtual IP’s To LAN interface:- ==&lt;br /&gt;
[[Image:Gpil-018.jpg]]&lt;br /&gt;
Now as LAN environment have multiple Subnet configured, we will be assigning Virtual IP address to LAN interface.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-019.jpg]]&lt;br /&gt;
&lt;br /&gt;
Clients on LAN Environment have their Gateway Set from These Virtual IP’s.&lt;br /&gt;
&lt;br /&gt;
203.77.196.230 is added for outside access of Local Servers 203.77.192.49/28.&lt;br /&gt;
&lt;br /&gt;
(203.77.196.230) is configured in 203.77.192.2 switch which will receive any packet for 203.77.192.49/28 from Outside and send it to 203.77.196.230.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SNORT  ==&lt;br /&gt;
&amp;lt;u&amp;gt;&#039;&#039;&#039;Reference&#039;&#039;&#039;&amp;lt;/u&amp;gt; :- &amp;lt;u&amp;gt;&#039;&#039;&#039;https://doc.pfsense.org/index.php/Setup_Snort_Package&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Go to the &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab under the &#039;&#039;&#039;System&#039;&#039;&#039; menu and install the snort package.&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;When the installation completes, click on &#039;&#039;&#039;Snort&#039;&#039;&#039; under the &#039;&#039;&#039;Services&#039;&#039;&#039; menu. &amp;amp;nbsp;This will open the Snort main setup page.&lt;br /&gt;
&lt;br /&gt;
Click the &#039;&#039;&#039;Global Settings&#039;&#039;&#039; tab and perform the following At the top of the page you have three choices for Rule Sets to activate.&lt;br /&gt;
&lt;br /&gt;
Put Check mark on :-Install &#039;&#039;&#039;Snort Community&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Emerging Threats&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Snort VRT&#039;&#039;&#039; rules. And save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Updates&#039;&#039;&#039; tab is used to check the status of downloaded rules packages and to download new updates. The table shows the available rule packages and their current status [[Image:Gpil-020.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Update Button to Update the rules.&lt;br /&gt;
[[Image:Gpil-021.jpg]]&lt;br /&gt;
&lt;br /&gt;
== Add Snort to an interface ==&lt;br /&gt;
Click the Snort Interfaces tab and then the &amp;quot;+&amp;quot; icon to add a new Snort interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;On the &#039;&#039;&#039;WAN Settings&#039;&#039;&#039; tab, click the &#039;&#039;Enable&#039;&#039; checkbox.In the drop-down, choose the interface. &amp;amp;nbsp;The WAN interface is the default and is a good first choice.In the &#039;&#039;Description&#039;&#039; textbox, enter a name (WAN again, is fine here).Click the checkbox to &amp;quot;&#039;&#039;Send alerts to the main System logs&#039;&#039;&amp;quot;.leave the other settings at their defaults&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-022.jpg]]&lt;br /&gt;
&lt;br /&gt;
After saving, the browser will be returned to the Snort Interfaces tab. Note the warning icons in the image below showing no rules have been selected for the new Snort interface. Those rules will be configured next. Click the &amp;quot;e&amp;quot; icon to edit the new Snort interface again&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-023.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Select which types of rules will protect the network ==&lt;br /&gt;
Click the &#039;&#039;&#039;Categories&#039;&#039;&#039; tab for the new interface&lt;br /&gt;
&lt;br /&gt;
Check [https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=GPLv2_community.rules Snort GPLv2 Community Rules (VRT certified)] Box .&lt;br /&gt;
&lt;br /&gt;
And Manual Rules :-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-botcc.rules emerging-botcc.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_blacklist.rules snort_blacklist.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.so.rules snort_exploit-kit.so.rules] &lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_ddos.rules snort_ddos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_dos.rules snort_dos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.rules snort_exploit-kit.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-malware.rules emerging-malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-mobile_malware.rules emerging-mobile_malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-tor.rules emerging-tor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-trojan.rules emerging-trojan.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_malware-backdoor.rules snort_malware-backdoor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_virus.rules snort_virus.rules]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-024.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click SAVE when finished to save the selection and build the rules &lt;br /&gt;
&lt;br /&gt;
After that restart the service &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-025.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Managing Pass lists:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Pass Lists are lists of IP addresses that Snort should never block. These may be created and managed on the Pass Lists tab. When an IP address is listed on a Pass List, Snort will never insert a block on that address even when malicious traffic is detected.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;To create a new Pass List, click &amp;quot;+&amp;quot;. To edit an existing Pass List, click the &amp;quot;e&amp;quot;. To delete a Pass List, click &amp;quot;x&amp;quot;. Note that a Pass List may not be deleted if it is currently assigned to one or more Snort interfaces.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We have added GIPL IP’s in Pass list . i.e&#039;&#039;&#039; &amp;lt;u&amp;gt;203.77.192.0/20&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-026.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== IP Alias and Port Alias ==&lt;br /&gt;
IP aliases allow you to create a group of IP addresses that you can assign by group name instead of specifying each IP address individually. This can be great for specifying a group of servers that need ssh access and then in the firewall rules you can create a rule that allows ssh traffic for the ssh servers group.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Along the top menu hover over Firewall and click on Aliases.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-027.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The next tab is for setting up Port Aliases. &amp;amp;nbsp;Similar to the IP Aliases you can setup groups but on this tab you are creating groups of ports instead of IP addresses.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-028.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
IP Aliases Created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-029.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
PORT ALIAS CREATED&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-030.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Firewall Rules :- ==&lt;br /&gt;
Reference:- [https://doc.pfsense.org/index.php/Firewall_Rule_Basics https://doc.pfsense.org/index.php/Firewall_Rule_Basics]&lt;br /&gt;
&lt;br /&gt;
Firewall rules control what traffic is allowed to enter an interface on the firewall. Once traffic is passed on the interface it enters an entry in the state table is created. A state table entry allows through subsequent packets that are part of that connection.&lt;br /&gt;
&lt;br /&gt;
Firewall rules are managed at Firewall &amp;gt; Rules. Multiple rules may be selected for some actions by clicking on their row or checking the box at the start of their row. Rules may be deleted or reordered in bulk in this way. See Managing Lists of Items on pfSense for more information on the meaning of the icons when manipulating rules.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;any&#039;&#039;&#039; - &#039;&#039;0.0.0.0&#039;&#039; to &#039;&#039;255.255.255.255&#039;&#039;, or all IPv6 addresses &lt;br /&gt;
* &#039;&#039;&#039;Single host or alias&#039;&#039;&#039; - Select this and enter one IP address (&#039;&#039;1.2.3.4&#039;&#039;, &#039;&#039;aa:bb:cc:dd::1&#039;&#039;) or type the name of an Alias that has already been configured (&#039;&#039;&#039;Firewall &amp;gt; Aliases&#039;&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Network&#039;&#039;&#039; - Select this and enter a network and mask (&#039;&#039;10.99.0.0/16&#039;&#039;, &#039;&#039;aa:bb:cc:dd::0/64&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;LAN net&#039;&#039;&#039; - The subnet configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039;. On pfSense 2.2+, this also includes static route networks on that interface. &lt;br /&gt;
* &#039;&#039;&#039;LAN address&#039;&#039;&#039; - The IP address configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039; &lt;br /&gt;
* &#039;&#039;&#039;zzz Net&#039;&#039;&#039; / &#039;&#039;&#039;zzz address&#039;&#039;&#039; - Works the same as LAN above but for other interfaces (WAN, OPT1, OPT2, etc.) &lt;br /&gt;
* &#039;&#039;&#039;PPTP clients&#039;&#039;&#039; - Automatically locate and use the addresses of PPTP clients &lt;br /&gt;
* &#039;&#039;&#039;L2TP clients&#039;&#039;&#039; - Automatically locate and use the addresses of L2TP clients &lt;br /&gt;
* &#039;&#039;&#039;This Firewall (self)&#039;&#039;&#039; - Any IP address assigned to any interface on this firewall (pfSense 2.2+) &lt;br /&gt;
&lt;br /&gt;
Firewall rules are generally processed starting with Floating Rules, then Interface Group rules, then Interface tab rules&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Rules Created on bridge interface, for DMZ access&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-031.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-032.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface Rules Created:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-033.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Squid and Squidguard:- ==&lt;br /&gt;
&#039;&#039;&#039;Reference - &#039;&#039;&#039;[https://doc.pfsense.org/index.php/SquidGuard_package https://doc.pfsense.org/index.php/SquidGuard_package]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Login to your pfsense&#039;s Web Administrator, and click on &amp;quot;Server -&amp;gt; Packages&amp;quot;, scroll down the list and find squid and click on &amp;quot;+&amp;quot; button to install, wait for the process to finish then return to the packages section and look for squidguard and install that package as well.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-034.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now go to &amp;quot;Services&amp;quot; menu and look for Proxy Server &amp;amp; Proxy Filter &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-035.jpg]]&lt;br /&gt;
&lt;br /&gt;
(We are setting up the proxy server as a transparent proxy)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on Services -&amp;gt; Proxy Server.&lt;br /&gt;
&lt;br /&gt;
On the General Tab, you want to set the following settings, the Proxy Interface Option should be set to &amp;quot;LAN&amp;quot;, to set up transparent proxy server, tick the &amp;quot;Transparent Proxy&amp;quot; check box.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-036.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Tick the &amp;quot;Enabled Logging&amp;quot; Checkbox, set the log store to the default location &amp;quot; /var/squid/logs &amp;quot; rotate your logs every 30 days, set your proxy port to port number 3128 We have By-passed Proxy for 203.77.192.49/28, These are the Local Servers.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next click on the &amp;quot;Cache Mgmt.&amp;quot; tab, by default the Hard Disk Cache Size is set to 100mb, we have allocated 100GB , Memory Cache Size 3072 .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-037.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click on Save.&lt;br /&gt;
&lt;br /&gt;
Click on the Access Control Tab next, in the allowed subnets field type in your required subnets. As we have multiple Subnets, so we are going to define all.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-038.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.129/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.1.224.1/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.192.49/28&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.57/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.17/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.137/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.33.50.1/27&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click On Save &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that’s is the proxy server configured, next we are going to configure SquidGuard, click on the Services menu and select the Proxy Filter button, tick the following 3 check boxes &amp;quot;Enable&amp;quot;, &amp;quot;Enable GUI Log&amp;quot; and &amp;quot;Enable Log&amp;quot; then click the Save button, once the page has reloaded click on apply and then confirm that the Squidguard service is running by making sure the SquidGuard status is set to STARTED.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-039.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on the Black list tab and add URL &#039;&#039;&#039;http://www.shallalist.de/Downloads/shallalist.tar.gz&#039;&#039;&#039; to the Update Address and click on Download. Wait for the process to complete.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-040.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-041.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now we can set up common ACL’s&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-042.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-043.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Click on Save and restart the Squid and SquidGuard from Services. &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SARG:- ==&lt;br /&gt;
After Installing SARG package, we can configure SARG from Status &amp;gt; Sarg Reports&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-044.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select Proxy Servers as SQUID proxy . And leave Rest of Field set to Default&lt;br /&gt;
&lt;br /&gt;
And Save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Go to Next Tab Schedule&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click “+” Symbol to create new schedule &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-045.jpg]] &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Reports can be viewed From “View Reports”&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-046.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bandwidthd:- ==&lt;br /&gt;
After Installing Package &#039;&#039;&#039;bandwidthd&#039;&#039;&#039; , Configuration can be done via&lt;br /&gt;
&lt;br /&gt;
Services &amp;gt; bandwidthd&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-047.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-048.jpg]]&lt;br /&gt;
&lt;br /&gt;
Enable Bandwidthd by checking the BOX.&lt;br /&gt;
&lt;br /&gt;
Now Select the Interface: - LAN.&lt;br /&gt;
&lt;br /&gt;
Enter The Subnets from LAN interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Save and Restart bandwidthd service from Services.&lt;br /&gt;
&lt;br /&gt;
Now Bandwidthd can be accessed:-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/bandwidthd/index.html https://203.77.200.91:8080/bandwidthd/index.html]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of ntopng:- ==&lt;br /&gt;
After installing ntopng package, it appears under Diagnostics &amp;gt; ntopng. It will even track where connections were made by local PCs, and how much bandwidth was used on individual connections.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-049.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
First we have to configure ntopng settings. Via Diagnostics &amp;gt; ntopng settings.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-050.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Setup Admin Password &amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Select the Interfaces on Which ntopng will be monitoring traffic.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We have selected LAN, DMZ and BRIDGEINTERFACE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To save the changes Click “Change”&lt;br /&gt;
&lt;br /&gt;
Ntopng can be accessed via [http://203.77.200.91:3000/login.html http://203.77.200.91:3000/login.html]&lt;br /&gt;
&lt;br /&gt;
With username admin and password assigned in previous step.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Configuring OpenVPN  =&lt;br /&gt;
A VPN (virtual private network) allows us to connect directly to our home private network over the internet&lt;br /&gt;
&lt;br /&gt;
The certificate authority or CA will sign the certificates that we will be creating for the server and client side when we configure OpenVPN. You can access the certificate configuration by going over to System–&amp;gt;Cert Manager.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-051.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Under the CAs tab you might already have a CA created if you followed one of my previous articles as we needed to created one in order to sign an internal certificate to be used for securing the pfSense web interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Certificate Authority ===&lt;br /&gt;
Fill in the fields to &#039;&#039;&#039;create a new Certificate Authority&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Descriptive Name&#039;&#039;&#039; - Used as the Common Name (CN) for the CA. Do not spaces, punctuation or special characters (ex: &#039;&#039;VPN Server CA&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Key Length&#039;&#039;&#039; - Default is OK, the higher the better but will use more CPU. &lt;br /&gt;
* &#039;&#039;&#039;Lifetime&#039;&#039;&#039; - Default is OK, but can be lowered if it must be changed out more often. &lt;br /&gt;
* &#039;&#039;&#039;Country Code&#039;&#039;&#039;, &#039;&#039;&#039;State/Province&#039;&#039;&#039;, &#039;&#039;&#039;City&#039;&#039;&#039;, &#039;&#039;&#039;Organization&#039;&#039;&#039; - Enter values for this location/company. &lt;br /&gt;
* &#039;&#039;&#039;E-mail&#039;&#039;&#039; - Used as a reference on the certificate, does not receive any mail from the system. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Add New CA&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-052.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
After you finished setting up the CA the next step is to create some certificates that the recently created CA will sign for us. Since these are self-signed certificates most browsers will give you a warning&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Server Certificate ===&lt;br /&gt;
Fill in the fields to create a new &#039;&#039;&#039;Server Certificate&#039;&#039;&#039;. Similar Fields as CA entry, most of the fields carry over and do not need changed. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Create new Certificate&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-053.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that we have all the components in place we can configure OpenVPN. Head over to VPN–&amp;gt;OpenVPN.&lt;br /&gt;
&lt;br /&gt;
.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-054.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select “Wizards” from the tab at the top which will guide us step by step to configure OpenVPN&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-055.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-056.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We will select the local user access database provided by pfSense&lt;br /&gt;
&lt;br /&gt;
In the next step we will be selecting the CA that we created at the beginning of this article.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-057.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Following is the Server Certificate that we will be using which is the Certificate that we recently created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-058.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;OpenVPN Server Configuration&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;TLS Authentication&#039;&#039;&#039; -- Leave this checked, along with the box underneath to generate a new key. Using a TLS key is technically optional, but &#039;&#039;highly&#039;&#039; recommended&lt;br /&gt;
* &#039;&#039;&#039;Tunnel Network&#039;&#039;&#039; -- Should be a new, unique network that does not exist anywhere in the current network or routing table. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-059.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-060.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-061.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== Firewall Rules ===&lt;br /&gt;
The next screen offers the choice to add firewall rules automatically. For convenience, check both unless the rules will be managed manually. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== End of the Wizard ===&lt;br /&gt;
Click &#039;&#039;&#039;Finish&#039;&#039;&#039; to exit the wizard and the new settings will be saved and applied automatically. &lt;br /&gt;
&lt;br /&gt;
== Adding a User with a Certificate ==&lt;br /&gt;
Navigate to &#039;&#039;&#039;System &amp;gt; User Manager&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click &amp;quot;+&amp;quot; To add a &#039;&#039;&#039;user&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Username&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Password / Confirm password&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Check Click to create a &#039;&#039;&#039;user certificate.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in the Descriptive Name as the username&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-062.jpeg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-063.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The OpenVPN Client Export Package allows exporting configurations formatted for a wide variety of platforms. It also allows exporting a pre-packaged Windows installer executable which includes the configuration bundled inside for a painly client installation. &lt;br /&gt;
&lt;br /&gt;
=== Installing the OpenVPN Client Export Package ===&lt;br /&gt;
To Install the OpenVPN Client Export Package &lt;br /&gt;
&lt;br /&gt;
* Navigate to &#039;&#039;&#039;System &amp;gt; Packages&#039;&#039;&#039;, &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab &lt;br /&gt;
* Find &#039;&#039;&#039;OpenVPN Client Export Package&#039;&#039;&#039; in the list &lt;br /&gt;
&lt;br /&gt;
=== Exporting a Configuration ===&lt;br /&gt;
* Navigate to &#039;&#039;&#039;VPN &amp;gt; OpenVPN&#039;&#039;&#039; on the &#039;&#039;&#039;Client Export&#039;&#039;&#039; tab &lt;br /&gt;
* Choose the VPN from the &#039;&#039;&#039;Remote Access Server&#039;&#039;&#039; drop-down list &lt;br /&gt;
* Find the user in the list at the bottom of the page and select the appropriate configuration type to export. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-064.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-065.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Multiple instance of VPN server can be created with different tunnel network &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-066.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Firewall Rules are applied as per the requirement on tunnel network .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-067.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Firewall Logs =&lt;br /&gt;
The Firewall logs at &#039;&#039;&#039;Status &amp;gt; System Logs&#039;&#039;&#039; on the &#039;&#039;&#039;Firewall&#039;&#039;&#039; tab show all events logged by the firewall.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Each entry is displayed with the action ( pass or block, reject is only logged as block), time, interface, source, destination, and protocol.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Configuration Of rsyslog Server for Logs Storage:-&lt;br /&gt;
&lt;br /&gt;
Status: &amp;gt;System logs &amp;gt; Settings&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-068.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Configuration of rsyslog on Centos :-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Setup Log File Location =====&lt;br /&gt;
Now edit Rsyslog configuration file and configure the location’s to generate log files in system.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# vim /etc/rsyslog.conf&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
and add following lines as the end of file.&lt;br /&gt;
&lt;br /&gt;
$template TmplAuth, &amp;quot;/var/log/%HOSTNAME%/%PROGRAMNAME%.log&amp;quot; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
authpriv.* ?TmplAuth&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;*.info,mail.none,authpriv.none,cron.none &amp;lt;/nowiki&amp;gt;?TmplMsg&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Enable Module and UDP Protocol =====&lt;br /&gt;
Also remove comment from following lines ( remove starting # ) in rsyslog configuration file to enable UDP.&lt;br /&gt;
&lt;br /&gt;
$ModLoad imudp&lt;br /&gt;
&lt;br /&gt;
$UDPServerRun 514&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Restart Rsyslog  =====&lt;br /&gt;
After making above changes in Rsyslog central server, restart service using following command.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# service rsyslog restart&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Logrotation:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Create file&#039;&#039;&#039; :- &#039;&#039;&#039;/etc/logrotate.d/pfsense&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;And enter:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/var/log/pfsense/filterlog.log&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;{&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;daily&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;missingok&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;rotate 60&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;compress&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;notifempty&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;create 640 root root&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;postrotate&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/etc/init.d/rsyslog restart &amp;gt;/dev/null&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;endscript&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;}&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Save and Quit.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;RRD Graphs:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
These are located under &#039;&#039;&#039;Status &amp;gt; RRD Graphs&#039;&#039;&#039;. Several graphs are presented for each monitored item, with varying time intervals and averages. &lt;br /&gt;
&lt;br /&gt;
These graphs measure things such as CPU usage, memory usage, state table usage, throughput (in bytes as well as packets), link quality, traffic shaping queue usage, and so on. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-069.jpg]]&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1908</id>
		<title>PF Sense Firewall Implementation at GIPL</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1908"/>
		<updated>2015-04-16T11:04:48Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:Tetra Clients]]&lt;br /&gt;
[[category:GSPC]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;center&amp;gt;&amp;lt;u&amp;gt;&#039;&#039;&#039;PF Sense Firewall Implementation at GIPL , GandhiNagar &#039;&#039;&#039;&amp;lt;/u&amp;gt;&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-000.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Installation&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;pfSense&#039;&#039;&#039; is an open source firewall/router computer software distribution based on FreeBSD. It is installed on a computer to make a dedicated firewall/router for a network and is noted for its reliability[1] and offering features often only found in expensive commercial firewalls&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Download pfSense&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Visit https://www.pfsense.org/download/mirror.php?section=downloads&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Step 1 :- &#039;&#039;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Performing a Full Install (LiveCD) ==&lt;br /&gt;
Power on the target system and connect the install media: Place the CD into the drive or plug the Memstick into a USB port. If the BIOS is set to boot from CD/USB, pfSense will start. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-001.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
As the operating system boots and pfSense starts, a prompt is presented with some choices and a countdown timer. At this prompt, press &#039;&#039;i&#039;&#039; to invoke the installer now.&lt;br /&gt;
&lt;br /&gt;
When the installer detects multiple disks in the system the first screen available provides the option &#039;&#039;&#039;Setup GEOM Mirror&#039;&#039;&#039;. Choose that option, pick the primary disk, the disk to use for the mirror copy, and then proceed with the installation as normal. &lt;br /&gt;
&lt;br /&gt;
The Quick/Easy install choice will target the GEOM mirror automatically&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-002.jpeg]]&lt;br /&gt;
&lt;br /&gt;
At the &#039;&#039;&#039;Select Task&#039;&#039;&#039; prompt, choose &#039;&#039;Quick/Easy Install&#039;&#039;. [[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-003.jpeg]]&lt;br /&gt;
&lt;br /&gt;
The install will proceed, wiping the target disk and installing pfSense. Copying files may take some time to finish. &lt;br /&gt;
&lt;br /&gt;
After the files have been copied to the target disk, a choice is presented to select the console type. &#039;&#039;Standard&#039;&#039; defaults to the VGA console. &#039;&#039;Embedded&#039;&#039; defaults to serial console&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-004.jpeg]]&lt;br /&gt;
&lt;br /&gt;
Now the system must reboot so that pfSense may start from the target disk. Select &#039;&#039;Reboot&#039;&#039; and then press &#039;&#039;&#039;Enter (remove CD from Drive)&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-005.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After the system reboots, pfSense will be running from the target disk. The next step is to Assign Interfaces on the Console below.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-006.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After installation and assignment, a shell menu is presented on the console with a number of options. pfSense now is ready to be accessed via the network, LAN interface IP 192.168.1.1 is assigned by default.&lt;br /&gt;
&lt;br /&gt;
Open a web browser and navigate to https://192.168.1.1/, using the default username admin and password pfsense to login.&lt;br /&gt;
&lt;br /&gt;
The first visit to the WebGUI will be redirected to the setup wizard.&lt;br /&gt;
&lt;br /&gt;
== GUI Configuration Setup ==&lt;br /&gt;
Once The Setup is launched, Fill the details are follows:-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-007.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We have defined FQDN as gipl.firewall&lt;br /&gt;
&lt;br /&gt;
DNS servers:- 8.8.8.8 and 4.4.2.2 Global DNS&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click NEXT&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-008.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select The Time-Zone as Asia/Kolkata .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
And Click NEXT&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-009.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Here we have Set WAN as Static Interface&lt;br /&gt;
&lt;br /&gt;
With IP address :- 203.77.200.91/25&lt;br /&gt;
&lt;br /&gt;
Gateway :- 203.77.200.1&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-010.jpg]]&lt;br /&gt;
&lt;br /&gt;
Here we have Configured LAN interface with IP address 192.168.45.101/24&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
( note:-As per the client Network Topology , Lan interface have multiple Subnets configured , so we will be configuring Virtual IP’s from GUI )&lt;br /&gt;
&lt;br /&gt;
After Setting Admin Password, Page will be redirected to Pfsense-Dashboard.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-011.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We Have Changed Default Port from 443 to 8080 Via :-&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;System &amp;gt; Advanced&#039;&#039;&#039;&lt;br /&gt;
[[Image:Gpil-012.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Change TCP Port from Default 443 to 8080 .&lt;br /&gt;
[[Image:Gpil-013.jpg]] &lt;br /&gt;
Save .&lt;br /&gt;
&lt;br /&gt;
Now pfsense Can be accessed via [https://IP:8080 https://IP:8080]&lt;br /&gt;
&lt;br /&gt;
IP Address of Firewall is 203.77.200.91 on WAN interface.&lt;br /&gt;
&lt;br /&gt;
Go to :- interface &amp;gt; assign , and edit Opt1 as DMZ , do not assign IP address to This interface , because we will be creating bridge interface .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bridge Interface ==&lt;br /&gt;
Now we have to configure &#039;&#039;&#039;Interface Bridges&#039;&#039;&#039; in order to Setup Pfsense in &lt;br /&gt;
&lt;br /&gt;
Transparent mode.&lt;br /&gt;
&lt;br /&gt;
Reference:- &amp;lt;u&amp;gt;https://doc.pfsense.org/index.php/Interface_Bridges&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Navigate To :- Interfaces &amp;gt; (assign) &lt;br /&gt;
&lt;br /&gt;
on the Bridges tab Click “ +” symbol to add a new bridge .&lt;br /&gt;
&lt;br /&gt;
Ctrl-Click to select the Member interfaces from the list of available interfaces and type a Description , we have selected WAN + DMZ as bridge0 and create new Interface BRIDGEINTERFACE using bridge0 .&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-014.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
By default, traffic is filtered on the member interfaces and not on the bridge interface itself. This behavior may be changed by toggling the values of &#039;&#039;&#039;net.link.bridge.pfil_member&#039;&#039;&#039; and net.link.bridge.pfil&#039;&#039;&#039;_bridge &#039;&#039;&#039;under System&#039;&#039;&#039; &amp;gt; Advanced &#039;&#039;&#039;on the &#039;&#039;&#039;System Tunables&#039;&#039;&#039; tab. With them set at &#039;&#039;0&#039;&#039; and &#039;&#039;1&#039;&#039;, respectively, then filtering would be performed on the bridge only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-015.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Pfsense is Configured In Bridge Mode with &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;WAN interface: - 203.77.200.91/25 gateway :- 203.77.200.1&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface:- 192.168.45.101/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;DMZ: - no ip &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;BRIDGEINTERFACE:- 203.77.200.92/25&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-016.jpg]]&lt;br /&gt;
&lt;br /&gt;
== Assign Virtual IP’s To LAN interface:- ==&lt;br /&gt;
[[Image:Gpil-018.jpg]]&lt;br /&gt;
Now as LAN environment have multiple Subnet configured, we will be assigning Virtual IP address to LAN interface.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-017.jpg]]&lt;br /&gt;
&lt;br /&gt;
Clients on LAN Environment have their Gateway Set from These Virtual IP’s.&lt;br /&gt;
&lt;br /&gt;
203.77.196.230 is added for outside access of Local Servers 203.77.192.49/28.&lt;br /&gt;
&lt;br /&gt;
(203.77.196.230) is configured in 203.77.192.2 switch which will receive any packet for 203.77.192.49/28 from Outside and send it to 203.77.196.230.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SNORT  ==&lt;br /&gt;
&amp;lt;u&amp;gt;&#039;&#039;&#039;Reference&#039;&#039;&#039;&amp;lt;/u&amp;gt; :- &amp;lt;u&amp;gt;&#039;&#039;&#039;https://doc.pfsense.org/index.php/Setup_Snort_Package&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Go to the &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab under the &#039;&#039;&#039;System&#039;&#039;&#039; menu and install the snort package.&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;When the installation completes, click on &#039;&#039;&#039;Snort&#039;&#039;&#039; under the &#039;&#039;&#039;Services&#039;&#039;&#039; menu. &amp;amp;nbsp;This will open the Snort main setup page.&lt;br /&gt;
&lt;br /&gt;
Click the &#039;&#039;&#039;Global Settings&#039;&#039;&#039; tab and perform the following At the top of the page you have three choices for Rule Sets to activate.&lt;br /&gt;
&lt;br /&gt;
Put Check mark on :-Install &#039;&#039;&#039;Snort Community&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Emerging Threats&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Snort VRT&#039;&#039;&#039; rules. And save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Updates&#039;&#039;&#039; tab is used to check the status of downloaded rules packages and to download new updates. The table shows the available rule packages and their current status [[Image:Gpil-019.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Update Button to Update the rules.&lt;br /&gt;
[[Image:Gpil-020.jpeg]]&lt;br /&gt;
&lt;br /&gt;
== Add Snort to an interface ==&lt;br /&gt;
Click the Snort Interfaces tab and then the &amp;quot;+&amp;quot; icon to add a new Snort interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;On the &#039;&#039;&#039;WAN Settings&#039;&#039;&#039; tab, click the &#039;&#039;Enable&#039;&#039; checkbox.In the drop-down, choose the interface. &amp;amp;nbsp;The WAN interface is the default and is a good first choice.In the &#039;&#039;Description&#039;&#039; textbox, enter a name (WAN again, is fine here).Click the checkbox to &amp;quot;&#039;&#039;Send alerts to the main System logs&#039;&#039;&amp;quot;.leave the other settings at their defaults&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-021.jpg]]&lt;br /&gt;
&lt;br /&gt;
After saving, the browser will be returned to the Snort Interfaces tab. Note the warning icons in the image below showing no rules have been selected for the new Snort interface. Those rules will be configured next. Click the &amp;quot;e&amp;quot; icon to edit the new Snort interface again&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-024.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Select which types of rules will protect the network ==&lt;br /&gt;
Click the &#039;&#039;&#039;Categories&#039;&#039;&#039; tab for the new interface&lt;br /&gt;
&lt;br /&gt;
Check [https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=GPLv2_community.rules Snort GPLv2 Community Rules (VRT certified)] Box .&lt;br /&gt;
&lt;br /&gt;
And Manual Rules :-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-botcc.rules emerging-botcc.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_blacklist.rules snort_blacklist.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.so.rules snort_exploit-kit.so.rules] &lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_ddos.rules snort_ddos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_dos.rules snort_dos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.rules snort_exploit-kit.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-malware.rules emerging-malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-mobile_malware.rules emerging-mobile_malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-tor.rules emerging-tor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-trojan.rules emerging-trojan.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_malware-backdoor.rules snort_malware-backdoor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_virus.rules snort_virus.rules]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-023.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click SAVE when finished to save the selection and build the rules &lt;br /&gt;
&lt;br /&gt;
After that restart the service &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-024.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Managing Pass lists:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Pass Lists are lists of IP addresses that Snort should never block. These may be created and managed on the Pass Lists tab. When an IP address is listed on a Pass List, Snort will never insert a block on that address even when malicious traffic is detected.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;To create a new Pass List, click &amp;quot;+&amp;quot;. To edit an existing Pass List, click the &amp;quot;e&amp;quot;. To delete a Pass List, click &amp;quot;x&amp;quot;. Note that a Pass List may not be deleted if it is currently assigned to one or more Snort interfaces.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We have added GIPL IP’s in Pass list . i.e&#039;&#039;&#039; &amp;lt;u&amp;gt;203.77.192.0/20&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-025.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== IP Alias and Port Alias ==&lt;br /&gt;
IP aliases allow you to create a group of IP addresses that you can assign by group name instead of specifying each IP address individually. This can be great for specifying a group of servers that need ssh access and then in the firewall rules you can create a rule that allows ssh traffic for the ssh servers group.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Along the top menu hover over Firewall and click on Aliases.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-026.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The next tab is for setting up Port Aliases. &amp;amp;nbsp;Similar to the IP Aliases you can setup groups but on this tab you are creating groups of ports instead of IP addresses.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-027.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
IP Aliases Created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-028.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
PORT ALIAS CREATED&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-029.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Firewall Rules :- ==&lt;br /&gt;
Reference:- [https://doc.pfsense.org/index.php/Firewall_Rule_Basics https://doc.pfsense.org/index.php/Firewall_Rule_Basics]&lt;br /&gt;
&lt;br /&gt;
Firewall rules control what traffic is allowed to enter an interface on the firewall. Once traffic is passed on the interface it enters an entry in the state table is created. A state table entry allows through subsequent packets that are part of that connection.&lt;br /&gt;
&lt;br /&gt;
Firewall rules are managed at Firewall &amp;gt; Rules. Multiple rules may be selected for some actions by clicking on their row or checking the box at the start of their row. Rules may be deleted or reordered in bulk in this way. See Managing Lists of Items on pfSense for more information on the meaning of the icons when manipulating rules.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;any&#039;&#039;&#039; - &#039;&#039;0.0.0.0&#039;&#039; to &#039;&#039;255.255.255.255&#039;&#039;, or all IPv6 addresses &lt;br /&gt;
* &#039;&#039;&#039;Single host or alias&#039;&#039;&#039; - Select this and enter one IP address (&#039;&#039;1.2.3.4&#039;&#039;, &#039;&#039;aa:bb:cc:dd::1&#039;&#039;) or type the name of an Alias that has already been configured (&#039;&#039;&#039;Firewall &amp;gt; Aliases&#039;&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Network&#039;&#039;&#039; - Select this and enter a network and mask (&#039;&#039;10.99.0.0/16&#039;&#039;, &#039;&#039;aa:bb:cc:dd::0/64&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;LAN net&#039;&#039;&#039; - The subnet configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039;. On pfSense 2.2+, this also includes static route networks on that interface. &lt;br /&gt;
* &#039;&#039;&#039;LAN address&#039;&#039;&#039; - The IP address configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039; &lt;br /&gt;
* &#039;&#039;&#039;zzz Net&#039;&#039;&#039; / &#039;&#039;&#039;zzz address&#039;&#039;&#039; - Works the same as LAN above but for other interfaces (WAN, OPT1, OPT2, etc.) &lt;br /&gt;
* &#039;&#039;&#039;PPTP clients&#039;&#039;&#039; - Automatically locate and use the addresses of PPTP clients &lt;br /&gt;
* &#039;&#039;&#039;L2TP clients&#039;&#039;&#039; - Automatically locate and use the addresses of L2TP clients &lt;br /&gt;
* &#039;&#039;&#039;This Firewall (self)&#039;&#039;&#039; - Any IP address assigned to any interface on this firewall (pfSense 2.2+) &lt;br /&gt;
&lt;br /&gt;
Firewall rules are generally processed starting with Floating Rules, then Interface Group rules, then Interface tab rules&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Rules Created on bridge interface, for DMZ access&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-030.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-031.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface Rules Created:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-032.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Squid and Squidguard:- ==&lt;br /&gt;
&#039;&#039;&#039;Reference - &#039;&#039;&#039;[https://doc.pfsense.org/index.php/SquidGuard_package https://doc.pfsense.org/index.php/SquidGuard_package]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Login to your pfsense&#039;s Web Administrator, and click on &amp;quot;Server -&amp;gt; Packages&amp;quot;, scroll down the list and find squid and click on &amp;quot;+&amp;quot; button to install, wait for the process to finish then return to the packages section and look for squidguard and install that package as well.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-033.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now go to &amp;quot;Services&amp;quot; menu and look for Proxy Server &amp;amp; Proxy Filter &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-034.jpg]]&lt;br /&gt;
&lt;br /&gt;
(We are setting up the proxy server as a transparent proxy)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on Services -&amp;gt; Proxy Server.&lt;br /&gt;
&lt;br /&gt;
On the General Tab, you want to set the following settings, the Proxy Interface Option should be set to &amp;quot;LAN&amp;quot;, to set up transparent proxy server, tick the &amp;quot;Transparent Proxy&amp;quot; check box.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-035.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Tick the &amp;quot;Enabled Logging&amp;quot; Checkbox, set the log store to the default location &amp;quot; /var/squid/logs &amp;quot; rotate your logs every 30 days, set your proxy port to port number 3128 We have By-passed Proxy for 203.77.192.49/28, These are the Local Servers.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next click on the &amp;quot;Cache Mgmt.&amp;quot; tab, by default the Hard Disk Cache Size is set to 100mb, we have allocated 100GB , Memory Cache Size 3072 .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-036.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click on Save.&lt;br /&gt;
&lt;br /&gt;
Click on the Access Control Tab next, in the allowed subnets field type in your required subnets. As we have multiple Subnets, so we are going to define all.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-037.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.129/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.1.224.1/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.192.49/28&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.57/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.17/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.137/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.33.50.1/27&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click On Save &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that’s is the proxy server configured, next we are going to configure SquidGuard, click on the Services menu and select the Proxy Filter button, tick the following 3 check boxes &amp;quot;Enable&amp;quot;, &amp;quot;Enable GUI Log&amp;quot; and &amp;quot;Enable Log&amp;quot; then click the Save button, once the page has reloaded click on apply and then confirm that the Squidguard service is running by making sure the SquidGuard status is set to STARTED.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-038.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on the Black list tab and add URL &#039;&#039;&#039;http://www.shallalist.de/Downloads/shallalist.tar.gz&#039;&#039;&#039; to the Update Address and click on Download. Wait for the process to complete.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-039.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-040.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now we can set up common ACL’s&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-041.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-042.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Click on Save and restart the Squid and SquidGuard from Services. &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SARG:- ==&lt;br /&gt;
After Installing SARG package, we can configure SARG from Status &amp;gt; Sarg Reports&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-043.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select Proxy Servers as SQUID proxy . And leave Rest of Field set to Default&lt;br /&gt;
&lt;br /&gt;
And Save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Go to Next Tab Schedule&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click “+” Symbol to create new schedule &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-044.jpg]] &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Reports can be viewed From “View Reports”&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-045.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bandwidthd:- ==&lt;br /&gt;
After Installing Package &#039;&#039;&#039;bandwidthd&#039;&#039;&#039; , Configuration can be done via&lt;br /&gt;
&lt;br /&gt;
Services &amp;gt; bandwidthd&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-046.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-047.jpg]]&lt;br /&gt;
&lt;br /&gt;
Enable Bandwidthd by checking the BOX.&lt;br /&gt;
&lt;br /&gt;
Now Select the Interface: - LAN.&lt;br /&gt;
&lt;br /&gt;
Enter The Subnets from LAN interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Save and Restart bandwidthd service from Services.&lt;br /&gt;
&lt;br /&gt;
Now Bandwidthd can be accessed:-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/bandwidthd/index.html https://203.77.200.91:8080/bandwidthd/index.html]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of ntopng:- ==&lt;br /&gt;
After installing ntopng package, it appears under Diagnostics &amp;gt; ntopng. It will even track where connections were made by local PCs, and how much bandwidth was used on individual connections.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-048.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
First we have to configure ntopng settings. Via Diagnostics &amp;gt; ntopng settings.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-049.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Setup Admin Password &amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Select the Interfaces on Which ntopng will be monitoring traffic.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We have selected LAN, DMZ and BRIDGEINTERFACE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To save the changes Click “Change”&lt;br /&gt;
&lt;br /&gt;
Ntopng can be accessed via [http://203.77.200.91:3000/login.html http://203.77.200.91:3000/login.html]&lt;br /&gt;
&lt;br /&gt;
With username admin and password assigned in previous step.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Configuring OpenVPN  =&lt;br /&gt;
A VPN (virtual private network) allows us to connect directly to our home private network over the internet&lt;br /&gt;
&lt;br /&gt;
The certificate authority or CA will sign the certificates that we will be creating for the server and client side when we configure OpenVPN. You can access the certificate configuration by going over to System–&amp;gt;Cert Manager.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-050.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Under the CAs tab you might already have a CA created if you followed one of my previous articles as we needed to created one in order to sign an internal certificate to be used for securing the pfSense web interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Certificate Authority ===&lt;br /&gt;
Fill in the fields to &#039;&#039;&#039;create a new Certificate Authority&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Descriptive Name&#039;&#039;&#039; - Used as the Common Name (CN) for the CA. Do not spaces, punctuation or special characters (ex: &#039;&#039;VPN Server CA&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Key Length&#039;&#039;&#039; - Default is OK, the higher the better but will use more CPU. &lt;br /&gt;
* &#039;&#039;&#039;Lifetime&#039;&#039;&#039; - Default is OK, but can be lowered if it must be changed out more often. &lt;br /&gt;
* &#039;&#039;&#039;Country Code&#039;&#039;&#039;, &#039;&#039;&#039;State/Province&#039;&#039;&#039;, &#039;&#039;&#039;City&#039;&#039;&#039;, &#039;&#039;&#039;Organization&#039;&#039;&#039; - Enter values for this location/company. &lt;br /&gt;
* &#039;&#039;&#039;E-mail&#039;&#039;&#039; - Used as a reference on the certificate, does not receive any mail from the system. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Add New CA&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-051.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
After you finished setting up the CA the next step is to create some certificates that the recently created CA will sign for us. Since these are self-signed certificates most browsers will give you a warning&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Server Certificate ===&lt;br /&gt;
Fill in the fields to create a new &#039;&#039;&#039;Server Certificate&#039;&#039;&#039;. Similar Fields as CA entry, most of the fields carry over and do not need changed. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Create new Certificate&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-052.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that we have all the components in place we can configure OpenVPN. Head over to VPN–&amp;gt;OpenVPN.&lt;br /&gt;
&lt;br /&gt;
.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-053.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select “Wizards” from the tab at the top which will guide us step by step to configure OpenVPN&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-054.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-055.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We will select the local user access database provided by pfSense&lt;br /&gt;
&lt;br /&gt;
In the next step we will be selecting the CA that we created at the beginning of this article.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-056.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Following is the Server Certificate that we will be using which is the Certificate that we recently created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-057.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;OpenVPN Server Configuration&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;TLS Authentication&#039;&#039;&#039; -- Leave this checked, along with the box underneath to generate a new key. Using a TLS key is technically optional, but &#039;&#039;highly&#039;&#039; recommended&lt;br /&gt;
* &#039;&#039;&#039;Tunnel Network&#039;&#039;&#039; -- Should be a new, unique network that does not exist anywhere in the current network or routing table. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-058.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-059.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-060.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== Firewall Rules ===&lt;br /&gt;
The next screen offers the choice to add firewall rules automatically. For convenience, check both unless the rules will be managed manually. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== End of the Wizard ===&lt;br /&gt;
Click &#039;&#039;&#039;Finish&#039;&#039;&#039; to exit the wizard and the new settings will be saved and applied automatically. &lt;br /&gt;
&lt;br /&gt;
== Adding a User with a Certificate ==&lt;br /&gt;
Navigate to &#039;&#039;&#039;System &amp;gt; User Manager&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click &amp;quot;+&amp;quot; To add a &#039;&#039;&#039;user&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Username&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Password / Confirm password&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Check Click to create a &#039;&#039;&#039;user certificate.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in the Descriptive Name as the username&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-061.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-062.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The OpenVPN Client Export Package allows exporting configurations formatted for a wide variety of platforms. It also allows exporting a pre-packaged Windows installer executable which includes the configuration bundled inside for a painly client installation. &lt;br /&gt;
&lt;br /&gt;
=== Installing the OpenVPN Client Export Package ===&lt;br /&gt;
To Install the OpenVPN Client Export Package &lt;br /&gt;
&lt;br /&gt;
* Navigate to &#039;&#039;&#039;System &amp;gt; Packages&#039;&#039;&#039;, &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab &lt;br /&gt;
* Find &#039;&#039;&#039;OpenVPN Client Export Package&#039;&#039;&#039; in the list &lt;br /&gt;
&lt;br /&gt;
=== Exporting a Configuration ===&lt;br /&gt;
* Navigate to &#039;&#039;&#039;VPN &amp;gt; OpenVPN&#039;&#039;&#039; on the &#039;&#039;&#039;Client Export&#039;&#039;&#039; tab &lt;br /&gt;
* Choose the VPN from the &#039;&#039;&#039;Remote Access Server&#039;&#039;&#039; drop-down list &lt;br /&gt;
* Find the user in the list at the bottom of the page and select the appropriate configuration type to export. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-063.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-064.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Multiple instance of VPN server can be created with different tunnel network &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-065.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Firewall Rules are applied as per the requirement on tunnel network .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-066.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Firewall Logs =&lt;br /&gt;
The Firewall logs at &#039;&#039;&#039;Status &amp;gt; System Logs&#039;&#039;&#039; on the &#039;&#039;&#039;Firewall&#039;&#039;&#039; tab show all events logged by the firewall.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Each entry is displayed with the action ( pass or block, reject is only logged as block), time, interface, source, destination, and protocol.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Configuration Of rsyslog Server for Logs Storage:-&lt;br /&gt;
&lt;br /&gt;
Status: &amp;gt;System logs &amp;gt; Settings&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-067.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Configuration of rsyslog on Centos :-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Setup Log File Location =====&lt;br /&gt;
Now edit Rsyslog configuration file and configure the location’s to generate log files in system.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# vim /etc/rsyslog.conf&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
and add following lines as the end of file.&lt;br /&gt;
&lt;br /&gt;
$template TmplAuth, &amp;quot;/var/log/%HOSTNAME%/%PROGRAMNAME%.log&amp;quot; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
authpriv.* ?TmplAuth&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;*.info,mail.none,authpriv.none,cron.none &amp;lt;/nowiki&amp;gt;?TmplMsg&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Enable Module and UDP Protocol =====&lt;br /&gt;
Also remove comment from following lines ( remove starting # ) in rsyslog configuration file to enable UDP.&lt;br /&gt;
&lt;br /&gt;
$ModLoad imudp&lt;br /&gt;
&lt;br /&gt;
$UDPServerRun 514&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Restart Rsyslog  =====&lt;br /&gt;
After making above changes in Rsyslog central server, restart service using following command.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# service rsyslog restart&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Logrotation:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Create file&#039;&#039;&#039; :- &#039;&#039;&#039;/etc/logrotate.d/pfsense&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;And enter:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/var/log/pfsense/filterlog.log&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;{&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;daily&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;missingok&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;rotate 60&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;compress&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;notifempty&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;create 640 root root&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;postrotate&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/etc/init.d/rsyslog restart &amp;gt;/dev/null&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;endscript&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;}&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Save and Quit.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;RRD Graphs:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
These are located under &#039;&#039;&#039;Status &amp;gt; RRD Graphs&#039;&#039;&#039;. Several graphs are presented for each monitored item, with varying time intervals and averages. &lt;br /&gt;
&lt;br /&gt;
These graphs measure things such as CPU usage, memory usage, state table usage, throughput (in bytes as well as packets), link quality, traffic shaping queue usage, and so on. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-068.jpg]]&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1907</id>
		<title>PF Sense Firewall Implementation at GIPL</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1907"/>
		<updated>2015-04-16T11:03:56Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:Tetra Clients]]&lt;br /&gt;
[[category:GSPC]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;center&amp;gt;&amp;lt;u&amp;gt;&#039;&#039;&#039;PF Sense Firewall Implementation at GIPL , GandhiNagar &#039;&#039;&#039;&amp;lt;/u&amp;gt;&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-000.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Installation&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;pfSense&#039;&#039;&#039; is an open source firewall/router computer software distribution based on FreeBSD. It is installed on a computer to make a dedicated firewall/router for a network and is noted for its reliability[1] and offering features often only found in expensive commercial firewalls&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Download pfSense&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Visit https://www.pfsense.org/download/mirror.php?section=downloads&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Step 1 :- &#039;&#039;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Performing a Full Install (LiveCD) ==&lt;br /&gt;
Power on the target system and connect the install media: Place the CD into the drive or plug the Memstick into a USB port. If the BIOS is set to boot from CD/USB, pfSense will start. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-001.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
As the operating system boots and pfSense starts, a prompt is presented with some choices and a countdown timer. At this prompt, press &#039;&#039;i&#039;&#039; to invoke the installer now.&lt;br /&gt;
&lt;br /&gt;
When the installer detects multiple disks in the system the first screen available provides the option &#039;&#039;&#039;Setup GEOM Mirror&#039;&#039;&#039;. Choose that option, pick the primary disk, the disk to use for the mirror copy, and then proceed with the installation as normal. &lt;br /&gt;
&lt;br /&gt;
The Quick/Easy install choice will target the GEOM mirror automatically&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-002.jpeg]]&lt;br /&gt;
&lt;br /&gt;
At the &#039;&#039;&#039;Select Task&#039;&#039;&#039; prompt, choose &#039;&#039;Quick/Easy Install&#039;&#039;. [[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-003.jpeg]]&lt;br /&gt;
&lt;br /&gt;
The install will proceed, wiping the target disk and installing pfSense. Copying files may take some time to finish. &lt;br /&gt;
&lt;br /&gt;
After the files have been copied to the target disk, a choice is presented to select the console type. &#039;&#039;Standard&#039;&#039; defaults to the VGA console. &#039;&#039;Embedded&#039;&#039; defaults to serial console&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-004.jpeg]]&lt;br /&gt;
&lt;br /&gt;
Now the system must reboot so that pfSense may start from the target disk. Select &#039;&#039;Reboot&#039;&#039; and then press &#039;&#039;&#039;Enter (remove CD from Drive)&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-005.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After the system reboots, pfSense will be running from the target disk. The next step is to Assign Interfaces on the Console below.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-006.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After installation and assignment, a shell menu is presented on the console with a number of options. pfSense now is ready to be accessed via the network, LAN interface IP 192.168.1.1 is assigned by default.&lt;br /&gt;
&lt;br /&gt;
Open a web browser and navigate to https://192.168.1.1/, using the default username admin and password pfsense to login.&lt;br /&gt;
&lt;br /&gt;
The first visit to the WebGUI will be redirected to the setup wizard.&lt;br /&gt;
&lt;br /&gt;
== GUI Configuration Setup ==&lt;br /&gt;
Once The Setup is launched, Fill the details are follows:-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-007.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We have defined FQDN as gipl.firewall&lt;br /&gt;
&lt;br /&gt;
DNS servers:- 8.8.8.8 and 4.4.2.2 Global DNS&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click NEXT&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-008.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select The Time-Zone as Asia/Kolkata .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
And Click NEXT&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-009.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Here we have Set WAN as Static Interface&lt;br /&gt;
&lt;br /&gt;
With IP address :- 203.77.200.91/25&lt;br /&gt;
&lt;br /&gt;
Gateway :- 203.77.200.1&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-010.jpg]]&lt;br /&gt;
&lt;br /&gt;
Here we have Configured LAN interface with IP address 192.168.45.101/24&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
( note:-As per the client Network Topology , Lan interface have multiple Subnets configured , so we will be configuring Virtual IP’s from GUI )&lt;br /&gt;
&lt;br /&gt;
After Setting Admin Password, Page will be redirected to Pfsense-Dashboard.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-011.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We Have Changed Default Port from 443 to 8080 Via :-&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;System &amp;gt; Advanced&#039;&#039;&#039;&lt;br /&gt;
[[Image:Gpil-012.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Change TCP Port from Default 443 to 8080 .&lt;br /&gt;
[[Image:Gpil-013.jpg]] &lt;br /&gt;
Save .&lt;br /&gt;
&lt;br /&gt;
Now pfsense Can be accessed via [https://IP:8080 https://IP:8080]&lt;br /&gt;
&lt;br /&gt;
IP Address of Firewall is 203.77.200.91 on WAN interface.&lt;br /&gt;
&lt;br /&gt;
Go to :- interface &amp;gt; assign , and edit Opt1 as DMZ , do not assign IP address to This interface , because we will be creating bridge interface .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bridge Interface ==&lt;br /&gt;
Now we have to configure &#039;&#039;&#039;Interface Bridges&#039;&#039;&#039; in order to Setup Pfsense in &lt;br /&gt;
&lt;br /&gt;
Transparent mode.&lt;br /&gt;
&lt;br /&gt;
Reference:- &amp;lt;u&amp;gt;https://doc.pfsense.org/index.php/Interface_Bridges&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Navigate To :- Interfaces &amp;gt; (assign) &lt;br /&gt;
&lt;br /&gt;
on the Bridges tab Click “ +” symbol to add a new bridge .&lt;br /&gt;
&lt;br /&gt;
Ctrl-Click to select the Member interfaces from the list of available interfaces and type a Description , we have selected WAN + DMZ as bridge0 and create new Interface BRIDGEINTERFACE using bridge0 .&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-014.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
By default, traffic is filtered on the member interfaces and not on the bridge interface itself. This behavior may be changed by toggling the values of &#039;&#039;&#039;net.link.bridge.pfil_member&#039;&#039;&#039; and net.link.bridge.pfil&#039;&#039;&#039;_bridge &#039;&#039;&#039;under System&#039;&#039;&#039; &amp;gt; Advanced &#039;&#039;&#039;on the &#039;&#039;&#039;System Tunables&#039;&#039;&#039; tab. With them set at &#039;&#039;0&#039;&#039; and &#039;&#039;1&#039;&#039;, respectively, then filtering would be performed on the bridge only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-015.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Pfsense is Configured In Bridge Mode with &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;WAN interface: - 203.77.200.91/25 gateway :- 203.77.200.1&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface:- 192.168.45.101/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;DMZ: - no ip &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;BRIDGEINTERFACE:- 203.77.200.92/25&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-016.jpg]]&lt;br /&gt;
&lt;br /&gt;
== Assign Virtual IP’s To LAN interface:- ==&lt;br /&gt;
[[Image:Gpil-018.jpg]]&lt;br /&gt;
Now as LAN environment have multiple Subnet configured, we will be assigning Virtual IP address to LAN interface.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-017.jpg]]&lt;br /&gt;
&lt;br /&gt;
Clients on LAN Environment have their Gateway Set from These Virtual IP’s.&lt;br /&gt;
&lt;br /&gt;
203.77.196.230 is added for outside access of Local Servers 203.77.192.49/28.&lt;br /&gt;
&lt;br /&gt;
(203.77.196.230) is configured in 203.77.192.2 switch which will receive any packet for 203.77.192.49/28 from Outside and send it to 203.77.196.230.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SNORT  ==&lt;br /&gt;
&amp;lt;u&amp;gt;&#039;&#039;&#039;Reference&#039;&#039;&#039;&amp;lt;/u&amp;gt; :- &amp;lt;u&amp;gt;&#039;&#039;&#039;https://doc.pfsense.org/index.php/Setup_Snort_Package&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Go to the &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab under the &#039;&#039;&#039;System&#039;&#039;&#039; menu and install the snort package.&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;When the installation completes, click on &#039;&#039;&#039;Snort&#039;&#039;&#039; under the &#039;&#039;&#039;Services&#039;&#039;&#039; menu. &amp;amp;nbsp;This will open the Snort main setup page.&lt;br /&gt;
&lt;br /&gt;
Click the &#039;&#039;&#039;Global Settings&#039;&#039;&#039; tab and perform the following At the top of the page you have three choices for Rule Sets to activate.&lt;br /&gt;
&lt;br /&gt;
Put Check mark on :-Install &#039;&#039;&#039;Snort Community&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Emerging Threats&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Snort VRT&#039;&#039;&#039; rules. And save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Updates&#039;&#039;&#039; tab is used to check the status of downloaded rules packages and to download new updates. The table shows the available rule packages and their current status [[Image:Gpil-019.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Update Button to Update the rules.&lt;br /&gt;
[[Image:Gpil-020.jpeg]]&lt;br /&gt;
&lt;br /&gt;
== Add Snort to an interface ==&lt;br /&gt;
Click the Snort Interfaces tab and then the &amp;quot;+&amp;quot; icon to add a new Snort interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;On the &#039;&#039;&#039;WAN Settings&#039;&#039;&#039; tab, click the &#039;&#039;Enable&#039;&#039; checkbox.In the drop-down, choose the interface. &amp;amp;nbsp;The WAN interface is the default and is a good first choice.In the &#039;&#039;Description&#039;&#039; textbox, enter a name (WAN again, is fine here).Click the checkbox to &amp;quot;&#039;&#039;Send alerts to the main System logs&#039;&#039;&amp;quot;.leave the other settings at their defaults&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-021.jpg]]&lt;br /&gt;
&lt;br /&gt;
After saving, the browser will be returned to the Snort Interfaces tab. Note the warning icons in the image below showing no rules have been selected for the new Snort interface. Those rules will be configured next. Click the &amp;quot;e&amp;quot; icon to edit the new Snort interface again&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-024.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Select which types of rules will protect the network ==&lt;br /&gt;
Click the &#039;&#039;&#039;Categories&#039;&#039;&#039; tab for the new interface&lt;br /&gt;
&lt;br /&gt;
Check [https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=GPLv2_community.rules Snort GPLv2 Community Rules (VRT certified)] Box .&lt;br /&gt;
&lt;br /&gt;
And Manual Rules :-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-botcc.rules emerging-botcc.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_blacklist.rules snort_blacklist.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.so.rules snort_exploit-kit.so.rules] &lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_ddos.rules snort_ddos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_dos.rules snort_dos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.rules snort_exploit-kit.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-malware.rules emerging-malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-mobile_malware.rules emerging-mobile_malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-tor.rules emerging-tor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-trojan.rules emerging-trojan.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_malware-backdoor.rules snort_malware-backdoor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_virus.rules snort_virus.rules]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-023.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click SAVE when finished to save the selection and build the rules &lt;br /&gt;
&lt;br /&gt;
After that restart the service &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-024.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Managing Pass lists:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Pass Lists are lists of IP addresses that Snort should never block. These may be created and managed on the Pass Lists tab. When an IP address is listed on a Pass List, Snort will never insert a block on that address even when malicious traffic is detected.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;To create a new Pass List, click &amp;quot;+&amp;quot;. To edit an existing Pass List, click the &amp;quot;e&amp;quot;. To delete a Pass List, click &amp;quot;x&amp;quot;. Note that a Pass List may not be deleted if it is currently assigned to one or more Snort interfaces.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We have added GIPL IP’s in Pass list . i.e&#039;&#039;&#039; &amp;lt;u&amp;gt;203.77.192.0/20&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-025.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== IP Alias and Port Alias ==&lt;br /&gt;
IP aliases allow you to create a group of IP addresses that you can assign by group name instead of specifying each IP address individually. This can be great for specifying a group of servers that need ssh access and then in the firewall rules you can create a rule that allows ssh traffic for the ssh servers group.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Along the top menu hover over Firewall and click on Aliases.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-026.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The next tab is for setting up Port Aliases. &amp;amp;nbsp;Similar to the IP Aliases you can setup groups but on this tab you are creating groups of ports instead of IP addresses.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-027.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
IP Aliases Created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-028.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
PORT ALIAS CREATED&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-029.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Firewall Rules :- ==&lt;br /&gt;
Reference:- [https://doc.pfsense.org/index.php/Firewall_Rule_Basics https://doc.pfsense.org/index.php/Firewall_Rule_Basics]&lt;br /&gt;
&lt;br /&gt;
Firewall rules control what traffic is allowed to enter an interface on the firewall. Once traffic is passed on the interface it enters an entry in the state table is created. A state table entry allows through subsequent packets that are part of that connection.&lt;br /&gt;
&lt;br /&gt;
Firewall rules are managed at Firewall &amp;gt; Rules. Multiple rules may be selected for some actions by clicking on their row or checking the box at the start of their row. Rules may be deleted or reordered in bulk in this way. See Managing Lists of Items on pfSense for more information on the meaning of the icons when manipulating rules.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;any&#039;&#039;&#039; - &#039;&#039;0.0.0.0&#039;&#039; to &#039;&#039;255.255.255.255&#039;&#039;, or all IPv6 addresses &lt;br /&gt;
* &#039;&#039;&#039;Single host or alias&#039;&#039;&#039; - Select this and enter one IP address (&#039;&#039;1.2.3.4&#039;&#039;, &#039;&#039;aa:bb:cc:dd::1&#039;&#039;) or type the name of an Alias that has already been configured (&#039;&#039;&#039;Firewall &amp;gt; Aliases&#039;&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Network&#039;&#039;&#039; - Select this and enter a network and mask (&#039;&#039;10.99.0.0/16&#039;&#039;, &#039;&#039;aa:bb:cc:dd::0/64&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;LAN net&#039;&#039;&#039; - The subnet configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039;. On pfSense 2.2+, this also includes static route networks on that interface. &lt;br /&gt;
* &#039;&#039;&#039;LAN address&#039;&#039;&#039; - The IP address configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039; &lt;br /&gt;
* &#039;&#039;&#039;zzz Net&#039;&#039;&#039; / &#039;&#039;&#039;zzz address&#039;&#039;&#039; - Works the same as LAN above but for other interfaces (WAN, OPT1, OPT2, etc.) &lt;br /&gt;
* &#039;&#039;&#039;PPTP clients&#039;&#039;&#039; - Automatically locate and use the addresses of PPTP clients &lt;br /&gt;
* &#039;&#039;&#039;L2TP clients&#039;&#039;&#039; - Automatically locate and use the addresses of L2TP clients &lt;br /&gt;
* &#039;&#039;&#039;This Firewall (self)&#039;&#039;&#039; - Any IP address assigned to any interface on this firewall (pfSense 2.2+) &lt;br /&gt;
&lt;br /&gt;
Firewall rules are generally processed starting with Floating Rules, then Interface Group rules, then Interface tab rules&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Rules Created on bridge interface, for DMZ access&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-030.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-031.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface Rules Created:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-032.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Squid and Squidguard:- ==&lt;br /&gt;
&#039;&#039;&#039;Reference - &#039;&#039;&#039;[https://doc.pfsense.org/index.php/SquidGuard_package https://doc.pfsense.org/index.php/SquidGuard_package]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Login to your pfsense&#039;s Web Administrator, and click on &amp;quot;Server -&amp;gt; Packages&amp;quot;, scroll down the list and find squid and click on &amp;quot;+&amp;quot; button to install, wait for the process to finish then return to the packages section and look for squidguard and install that package as well.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-033.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now go to &amp;quot;Services&amp;quot; menu and look for Proxy Server &amp;amp; Proxy Filter &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-034.jpg]]&lt;br /&gt;
&lt;br /&gt;
(We are setting up the proxy server as a transparent proxy)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on Services -&amp;gt; Proxy Server.&lt;br /&gt;
&lt;br /&gt;
On the General Tab, you want to set the following settings, the Proxy Interface Option should be set to &amp;quot;LAN&amp;quot;, to set up transparent proxy server, tick the &amp;quot;Transparent Proxy&amp;quot; check box.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-035.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Tick the &amp;quot;Enabled Logging&amp;quot; Checkbox, set the log store to the default location &amp;quot; /var/squid/logs &amp;quot; rotate your logs every 30 days, set your proxy port to port number 3128 We have By-passed Proxy for 203.77.192.49/28, These are the Local Servers.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next click on the &amp;quot;Cache Mgmt.&amp;quot; tab, by default the Hard Disk Cache Size is set to 100mb, we have allocated 100GB , Memory Cache Size 3072 .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-036.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click on Save.&lt;br /&gt;
&lt;br /&gt;
Click on the Access Control Tab next, in the allowed subnets field type in your required subnets. As we have multiple Subnets, so we are going to define all.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-037.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.129/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.1.224.1/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.192.49/28&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.57/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.17/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.137/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.33.50.1/27&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click On Save &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that’s is the proxy server configured, next we are going to configure SquidGuard, click on the Services menu and select the Proxy Filter button, tick the following 3 check boxes &amp;quot;Enable&amp;quot;, &amp;quot;Enable GUI Log&amp;quot; and &amp;quot;Enable Log&amp;quot; then click the Save button, once the page has reloaded click on apply and then confirm that the Squidguard service is running by making sure the SquidGuard status is set to STARTED.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-038.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on the Black list tab and add URL &#039;&#039;&#039;http://www.shallalist.de/Downloads/shallalist.tar.gz&#039;&#039;&#039; to the Update Address and click on Download. Wait for the process to complete.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-039.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-040.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now we can set up common ACL’s&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-041.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-042.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Click on Save and restart the Squid and SquidGuard from Services. &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SARG:- ==&lt;br /&gt;
After Installing SARG package, we can configure SARG from Status &amp;gt; Sarg Reports&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-043.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select Proxy Servers as SQUID proxy . And leave Rest of Field set to Default&lt;br /&gt;
&lt;br /&gt;
And Save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Go to Next Tab Schedule&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click “+” Symbol to create new schedule &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-044.jpg]] &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Reports can be viewed From “View Reports”&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-045.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bandwidthd:- ==&lt;br /&gt;
After Installing Package &#039;&#039;&#039;bandwidthd&#039;&#039;&#039; , Configuration can be done via&lt;br /&gt;
&lt;br /&gt;
Services &amp;gt; bandwidthd&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-046.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-047.jpg]]&lt;br /&gt;
&lt;br /&gt;
Enable Bandwidthd by checking the BOX.&lt;br /&gt;
&lt;br /&gt;
Now Select the Interface: - LAN.&lt;br /&gt;
&lt;br /&gt;
Enter The Subnets from LAN interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Save and Restart bandwidthd service from Services.&lt;br /&gt;
&lt;br /&gt;
Now Bandwidthd can be accessed:-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/bandwidthd/index.html https://203.77.200.91:8080/bandwidthd/index.html]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of ntopng:- ==&lt;br /&gt;
After installing ntopng package, it appears under Diagnostics &amp;gt; ntopng. It will even track where connections were made by local PCs, and how much bandwidth was used on individual connections.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-048.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
First we have to configure ntopng settings. Via Diagnostics &amp;gt; ntopng settings.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-049.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Setup Admin Password &amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Select the Interfaces on Which ntopng will be monitoring traffic.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We have selected LAN, DMZ and BRIDGEINTERFACE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To save the changes Click “Change”&lt;br /&gt;
&lt;br /&gt;
Ntopng can be accessed via [http://203.77.200.91:3000/login.html http://203.77.200.91:3000/login.html]&lt;br /&gt;
&lt;br /&gt;
With username admin and password assigned in previous step.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Configuring OpenVPN  =&lt;br /&gt;
A VPN (virtual private network) allows us to connect directly to our home private network over the internet&lt;br /&gt;
&lt;br /&gt;
The certificate authority or CA will sign the certificates that we will be creating for the server and client side when we configure OpenVPN. You can access the certificate configuration by going over to System–&amp;gt;Cert Manager.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-050.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Under the CAs tab you might already have a CA created if you followed one of my previous articles as we needed to created one in order to sign an internal certificate to be used for securing the pfSense web interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Certificate Authority ===&lt;br /&gt;
Fill in the fields to &#039;&#039;&#039;create a new Certificate Authority&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Descriptive Name&#039;&#039;&#039; - Used as the Common Name (CN) for the CA. Do not spaces, punctuation or special characters (ex: &#039;&#039;VPN Server CA&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Key Length&#039;&#039;&#039; - Default is OK, the higher the better but will use more CPU. &lt;br /&gt;
* &#039;&#039;&#039;Lifetime&#039;&#039;&#039; - Default is OK, but can be lowered if it must be changed out more often. &lt;br /&gt;
* &#039;&#039;&#039;Country Code&#039;&#039;&#039;, &#039;&#039;&#039;State/Province&#039;&#039;&#039;, &#039;&#039;&#039;City&#039;&#039;&#039;, &#039;&#039;&#039;Organization&#039;&#039;&#039; - Enter values for this location/company. &lt;br /&gt;
* &#039;&#039;&#039;E-mail&#039;&#039;&#039; - Used as a reference on the certificate, does not receive any mail from the system. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Add New CA&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-051.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
After you finished setting up the CA the next step is to create some certificates that the recently created CA will sign for us. Since these are self-signed certificates most browsers will give you a warning&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Server Certificate ===&lt;br /&gt;
Fill in the fields to create a new &#039;&#039;&#039;Server Certificate&#039;&#039;&#039;. Similar Fields as CA entry, most of the fields carry over and do not need changed. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Create new Certificate&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-052.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that we have all the components in place we can configure OpenVPN. Head over to VPN–&amp;gt;OpenVPN.&lt;br /&gt;
&lt;br /&gt;
.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-053.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select “Wizards” from the tab at the top which will guide us step by step to configure OpenVPN&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-054.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-055.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We will select the local user access database provided by pfSense&lt;br /&gt;
&lt;br /&gt;
In the next step we will be selecting the CA that we created at the beginning of this article.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-056.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Following is the Server Certificate that we will be using which is the Certificate that we recently created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-057.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;OpenVPN Server Configuration&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;TLS Authentication&#039;&#039;&#039; -- Leave this checked, along with the box underneath to generate a new key. Using a TLS key is technically optional, but &#039;&#039;highly&#039;&#039; recommended&lt;br /&gt;
* &#039;&#039;&#039;Tunnel Network&#039;&#039;&#039; -- Should be a new, unique network that does not exist anywhere in the current network or routing table. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-058.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-059.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-060.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== Firewall Rules ===&lt;br /&gt;
The next screen offers the choice to add firewall rules automatically. For convenience, check both unless the rules will be managed manually. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== End of the Wizard ===&lt;br /&gt;
Click &#039;&#039;&#039;Finish&#039;&#039;&#039; to exit the wizard and the new settings will be saved and applied automatically. &lt;br /&gt;
&lt;br /&gt;
== Adding a User with a Certificate ==&lt;br /&gt;
Navigate to &#039;&#039;&#039;System &amp;gt; User Manager&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click &amp;quot;+&amp;quot; To add a &#039;&#039;&#039;user&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Username&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Password / Confirm password&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Check Click to create a &#039;&#039;&#039;user certificate.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in the Descriptive Name as the username&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-061.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-062.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The OpenVPN Client Export Package allows exporting configurations formatted for a wide variety of platforms. It also allows exporting a pre-packaged Windows installer executable which includes the configuration bundled inside for a painly client installation. &lt;br /&gt;
&lt;br /&gt;
=== Installing the OpenVPN Client Export Package ===&lt;br /&gt;
To Install the OpenVPN Client Export Package &lt;br /&gt;
&lt;br /&gt;
* Navigate to &#039;&#039;&#039;System &amp;gt; Packages&#039;&#039;&#039;, &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab &lt;br /&gt;
* Find &#039;&#039;&#039;OpenVPN Client Export Package&#039;&#039;&#039; in the list &lt;br /&gt;
&lt;br /&gt;
=== Exporting a Configuration ===&lt;br /&gt;
* Navigate to &#039;&#039;&#039;VPN &amp;gt; OpenVPN&#039;&#039;&#039; on the &#039;&#039;&#039;Client Export&#039;&#039;&#039; tab &lt;br /&gt;
* Choose the VPN from the &#039;&#039;&#039;Remote Access Server&#039;&#039;&#039; drop-down list &lt;br /&gt;
* Find the user in the list at the bottom of the page and select the appropriate configuration type to export. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-063.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-064.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Multiple instance of VPN server can be created with different tunnel network &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-065.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Firewall Rules are applied as per the requirement on tunnel network .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-066.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Firewall Logs =&lt;br /&gt;
The Firewall logs at &#039;&#039;&#039;Status &amp;gt; System Logs&#039;&#039;&#039; on the &#039;&#039;&#039;Firewall&#039;&#039;&#039; tab show all events logged by the firewall.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Each entry is displayed with the action ( pass or block, reject is only logged as block), time, interface, source, destination, and protocol.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Configuration Of rsyslog Server for Logs Storage:-&lt;br /&gt;
&lt;br /&gt;
Status: &amp;gt;System logs &amp;gt; Settings&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-067.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Configuration of rsyslog on Centos :-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Setup Log File Location =====&lt;br /&gt;
Now edit Rsyslog configuration file and configure the location’s to generate log files in system.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# vim /etc/rsyslog.conf&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
and add following lines as the end of file.&lt;br /&gt;
&lt;br /&gt;
$template TmplAuth, &amp;quot;/var/log/%HOSTNAME%/%PROGRAMNAME%.log&amp;quot; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
authpriv.* ?TmplAuth&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;*.info,mail.none,authpriv.none,cron.none &amp;lt;/nowiki&amp;gt;?TmplMsg&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Enable Module and UDP Protocol =====&lt;br /&gt;
Also remove comment from following lines ( remove starting # ) in rsyslog configuration file to enable UDP.&lt;br /&gt;
&lt;br /&gt;
$ModLoad imudp&lt;br /&gt;
&lt;br /&gt;
$UDPServerRun 514&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Restart Rsyslog  =====&lt;br /&gt;
After making above changes in Rsyslog central server, restart service using following command.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# service rsyslog restart&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Logrotation:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Create file&#039;&#039;&#039; :- &#039;&#039;&#039;/etc/logrotate.d/pfsense&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;And enter:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/var/log/pfsense/filterlog.log&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;{&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;daily&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;missingok&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;rotate 60&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;compress&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;notifempty&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;create 640 root root&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;postrotate&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/etc/init.d/rsyslog restart &amp;gt;/dev/null&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;endscript&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;}&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Save and Quit.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;RRD Graphs:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
These are located under &#039;&#039;&#039;Status &amp;gt; RRD Graphs&#039;&#039;&#039;. Several graphs are presented for each monitored item, with varying time intervals and averages. &lt;br /&gt;
&lt;br /&gt;
These graphs measure things such as CPU usage, memory usage, state table usage, throughput (in bytes as well as packets), link quality, traffic shaping queue usage, and so on. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-068.jpg]]&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1906</id>
		<title>PF Sense Firewall Implementation at GIPL</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1906"/>
		<updated>2015-04-16T11:02:16Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category:Tetra Clients]]&lt;br /&gt;
[[category:GSPC]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;center&amp;gt;&amp;lt;u&amp;gt;&#039;&#039;&#039;PF Sense Firewall Implementation at GIPL , GandhiNagar &#039;&#039;&#039;&amp;lt;/u&amp;gt;&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Table of Contents ==&lt;br /&gt;
[#__RefHeading__2322_1445225205 NETWORK DIAGRAM2]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2324_1445225205 Performing a Full Install (LiveCD)3]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2326_1445225205 GUI Configuration Setup8]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2328_1445225205 Configuration Of Bridge Interface13]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2330_1445225205 Assign Virtual IP’s To LAN interface:-15]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2332_1445225205 Configuration of SNORT17]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2334_1445225205 Add Snort to an interface20]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2336_1445225205 Select which types of rules will protect the network22]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2338_1445225205 IP Alias and Port Alias24]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2340_1445225205 Firewall Rules :-27]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2342_1445225205 Configuration Of Squid and Squidguard:-31]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2344_1445225205 Configuration of SARG:-39]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2346_1445225205 Configuration Of Bandwidthd:-42]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2348_1445225205 Configuration Of ntopng:-44]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2350_1445225205 Configuring OpenVPN46]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2352_1445225205 Certificate Authority47]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2354_1445225205 Server Certificate48]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2356_1445225205 Firewall Rules54]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2358_1445225205 End of the Wizard54]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2360_1445225205 Adding a User with a Certificate54]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2362_1445225205 Installing the OpenVPN Client Export Package57]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2364_1445225205 Exporting a Configuration57]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2366_1445225205 Firewall Logs60]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2368_1445225205 Setup Log File Location61]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2370_1445225205 Enable Module and UDP Protocol61]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2372_1445225205 Restart Rsyslog61]= NETWORK DIAGRAM =&lt;br /&gt;
[[Image:Gpil-000.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Installation&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;pfSense&#039;&#039;&#039; is an open source firewall/router computer software distribution based on FreeBSD. It is installed on a computer to make a dedicated firewall/router for a network and is noted for its reliability[1] and offering features often only found in expensive commercial firewalls&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Download pfSense&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Visit https://www.pfsense.org/download/mirror.php?section=downloads&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Step 1 :- &#039;&#039;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Performing a Full Install (LiveCD) ==&lt;br /&gt;
Power on the target system and connect the install media: Place the CD into the drive or plug the Memstick into a USB port. If the BIOS is set to boot from CD/USB, pfSense will start. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-001.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
As the operating system boots and pfSense starts, a prompt is presented with some choices and a countdown timer. At this prompt, press &#039;&#039;i&#039;&#039; to invoke the installer now.&lt;br /&gt;
&lt;br /&gt;
When the installer detects multiple disks in the system the first screen available provides the option &#039;&#039;&#039;Setup GEOM Mirror&#039;&#039;&#039;. Choose that option, pick the primary disk, the disk to use for the mirror copy, and then proceed with the installation as normal. &lt;br /&gt;
&lt;br /&gt;
The Quick/Easy install choice will target the GEOM mirror automatically&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-002.jpeg]]&lt;br /&gt;
&lt;br /&gt;
At the &#039;&#039;&#039;Select Task&#039;&#039;&#039; prompt, choose &#039;&#039;Quick/Easy Install&#039;&#039;. [[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-003.jpeg]]&lt;br /&gt;
&lt;br /&gt;
The install will proceed, wiping the target disk and installing pfSense. Copying files may take some time to finish. &lt;br /&gt;
&lt;br /&gt;
After the files have been copied to the target disk, a choice is presented to select the console type. &#039;&#039;Standard&#039;&#039; defaults to the VGA console. &#039;&#039;Embedded&#039;&#039; defaults to serial console&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-004.jpeg]]&lt;br /&gt;
&lt;br /&gt;
Now the system must reboot so that pfSense may start from the target disk. Select &#039;&#039;Reboot&#039;&#039; and then press &#039;&#039;&#039;Enter (remove CD from Drive)&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-005.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After the system reboots, pfSense will be running from the target disk. The next step is to Assign Interfaces on the Console below.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-006.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After installation and assignment, a shell menu is presented on the console with a number of options. pfSense now is ready to be accessed via the network, LAN interface IP 192.168.1.1 is assigned by default.&lt;br /&gt;
&lt;br /&gt;
Open a web browser and navigate to https://192.168.1.1/, using the default username admin and password pfsense to login.&lt;br /&gt;
&lt;br /&gt;
The first visit to the WebGUI will be redirected to the setup wizard.&lt;br /&gt;
&lt;br /&gt;
== GUI Configuration Setup ==&lt;br /&gt;
Once The Setup is launched, Fill the details are follows:-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-007.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We have defined FQDN as gipl.firewall&lt;br /&gt;
&lt;br /&gt;
DNS servers:- 8.8.8.8 and 4.4.2.2 Global DNS&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click NEXT&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-008.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select The Time-Zone as Asia/Kolkata .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
And Click NEXT&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-009.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Here we have Set WAN as Static Interface&lt;br /&gt;
&lt;br /&gt;
With IP address :- 203.77.200.91/25&lt;br /&gt;
&lt;br /&gt;
Gateway :- 203.77.200.1&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-010.jpg]]&lt;br /&gt;
&lt;br /&gt;
Here we have Configured LAN interface with IP address 192.168.45.101/24&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
( note:-As per the client Network Topology , Lan interface have multiple Subnets configured , so we will be configuring Virtual IP’s from GUI )&lt;br /&gt;
&lt;br /&gt;
After Setting Admin Password, Page will be redirected to Pfsense-Dashboard.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-011.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We Have Changed Default Port from 443 to 8080 Via :-&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;System &amp;gt; Advanced&#039;&#039;&#039;&lt;br /&gt;
[[Image:Gpil-012.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Change TCP Port from Default 443 to 8080 .&lt;br /&gt;
[[Image:Gpil-013.jpg]] &lt;br /&gt;
Save .&lt;br /&gt;
&lt;br /&gt;
Now pfsense Can be accessed via [https://IP:8080 https://IP:8080]&lt;br /&gt;
&lt;br /&gt;
IP Address of Firewall is 203.77.200.91 on WAN interface.&lt;br /&gt;
&lt;br /&gt;
Go to :- interface &amp;gt; assign , and edit Opt1 as DMZ , do not assign IP address to This interface , because we will be creating bridge interface .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bridge Interface ==&lt;br /&gt;
Now we have to configure &#039;&#039;&#039;Interface Bridges&#039;&#039;&#039; in order to Setup Pfsense in &lt;br /&gt;
&lt;br /&gt;
Transparent mode.&lt;br /&gt;
&lt;br /&gt;
Reference:- &amp;lt;u&amp;gt;https://doc.pfsense.org/index.php/Interface_Bridges&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Navigate To :- Interfaces &amp;gt; (assign) &lt;br /&gt;
&lt;br /&gt;
on the Bridges tab Click “ +” symbol to add a new bridge .&lt;br /&gt;
&lt;br /&gt;
Ctrl-Click to select the Member interfaces from the list of available interfaces and type a Description , we have selected WAN + DMZ as bridge0 and create new Interface BRIDGEINTERFACE using bridge0 .&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-014.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
By default, traffic is filtered on the member interfaces and not on the bridge interface itself. This behavior may be changed by toggling the values of &#039;&#039;&#039;net.link.bridge.pfil_member&#039;&#039;&#039; and net.link.bridge.pfil&#039;&#039;&#039;_bridge &#039;&#039;&#039;under System&#039;&#039;&#039; &amp;gt; Advanced &#039;&#039;&#039;on the &#039;&#039;&#039;System Tunables&#039;&#039;&#039; tab. With them set at &#039;&#039;0&#039;&#039; and &#039;&#039;1&#039;&#039;, respectively, then filtering would be performed on the bridge only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-015.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Pfsense is Configured In Bridge Mode with &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;WAN interface: - 203.77.200.91/25 gateway :- 203.77.200.1&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface:- 192.168.45.101/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;DMZ: - no ip &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;BRIDGEINTERFACE:- 203.77.200.92/25&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-016.jpg]]&lt;br /&gt;
&lt;br /&gt;
== Assign Virtual IP’s To LAN interface:- ==&lt;br /&gt;
[[Image:Gpil-018.jpg]]&lt;br /&gt;
Now as LAN environment have multiple Subnet configured, we will be assigning Virtual IP address to LAN interface.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-017.jpg]]&lt;br /&gt;
&lt;br /&gt;
Clients on LAN Environment have their Gateway Set from These Virtual IP’s.&lt;br /&gt;
&lt;br /&gt;
203.77.196.230 is added for outside access of Local Servers 203.77.192.49/28.&lt;br /&gt;
&lt;br /&gt;
(203.77.196.230) is configured in 203.77.192.2 switch which will receive any packet for 203.77.192.49/28 from Outside and send it to 203.77.196.230.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SNORT  ==&lt;br /&gt;
&amp;lt;u&amp;gt;&#039;&#039;&#039;Reference&#039;&#039;&#039;&amp;lt;/u&amp;gt; :- &amp;lt;u&amp;gt;&#039;&#039;&#039;https://doc.pfsense.org/index.php/Setup_Snort_Package&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Go to the &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab under the &#039;&#039;&#039;System&#039;&#039;&#039; menu and install the snort package.&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;When the installation completes, click on &#039;&#039;&#039;Snort&#039;&#039;&#039; under the &#039;&#039;&#039;Services&#039;&#039;&#039; menu. &amp;amp;nbsp;This will open the Snort main setup page.&lt;br /&gt;
&lt;br /&gt;
Click the &#039;&#039;&#039;Global Settings&#039;&#039;&#039; tab and perform the following At the top of the page you have three choices for Rule Sets to activate.&lt;br /&gt;
&lt;br /&gt;
Put Check mark on :-Install &#039;&#039;&#039;Snort Community&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Emerging Threats&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Snort VRT&#039;&#039;&#039; rules. And save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Updates&#039;&#039;&#039; tab is used to check the status of downloaded rules packages and to download new updates. The table shows the available rule packages and their current status [[Image:Gpil-019.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Update Button to Update the rules.&lt;br /&gt;
[[Image:Gpil-020.jpeg]]&lt;br /&gt;
&lt;br /&gt;
== Add Snort to an interface ==&lt;br /&gt;
Click the Snort Interfaces tab and then the &amp;quot;+&amp;quot; icon to add a new Snort interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;On the &#039;&#039;&#039;WAN Settings&#039;&#039;&#039; tab, click the &#039;&#039;Enable&#039;&#039; checkbox.In the drop-down, choose the interface. &amp;amp;nbsp;The WAN interface is the default and is a good first choice.In the &#039;&#039;Description&#039;&#039; textbox, enter a name (WAN again, is fine here).Click the checkbox to &amp;quot;&#039;&#039;Send alerts to the main System logs&#039;&#039;&amp;quot;.leave the other settings at their defaults&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-021.jpg]]&lt;br /&gt;
&lt;br /&gt;
After saving, the browser will be returned to the Snort Interfaces tab. Note the warning icons in the image below showing no rules have been selected for the new Snort interface. Those rules will be configured next. Click the &amp;quot;e&amp;quot; icon to edit the new Snort interface again&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-024.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Select which types of rules will protect the network ==&lt;br /&gt;
Click the &#039;&#039;&#039;Categories&#039;&#039;&#039; tab for the new interface&lt;br /&gt;
&lt;br /&gt;
Check [https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=GPLv2_community.rules Snort GPLv2 Community Rules (VRT certified)] Box .&lt;br /&gt;
&lt;br /&gt;
And Manual Rules :-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-botcc.rules emerging-botcc.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_blacklist.rules snort_blacklist.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.so.rules snort_exploit-kit.so.rules] &lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_ddos.rules snort_ddos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_dos.rules snort_dos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.rules snort_exploit-kit.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-malware.rules emerging-malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-mobile_malware.rules emerging-mobile_malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-tor.rules emerging-tor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-trojan.rules emerging-trojan.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_malware-backdoor.rules snort_malware-backdoor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_virus.rules snort_virus.rules]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-023.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click SAVE when finished to save the selection and build the rules &lt;br /&gt;
&lt;br /&gt;
After that restart the service &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-024.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Managing Pass lists:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Pass Lists are lists of IP addresses that Snort should never block. These may be created and managed on the Pass Lists tab. When an IP address is listed on a Pass List, Snort will never insert a block on that address even when malicious traffic is detected.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;To create a new Pass List, click &amp;quot;+&amp;quot;. To edit an existing Pass List, click the &amp;quot;e&amp;quot;. To delete a Pass List, click &amp;quot;x&amp;quot;. Note that a Pass List may not be deleted if it is currently assigned to one or more Snort interfaces.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We have added GIPL IP’s in Pass list . i.e&#039;&#039;&#039; &amp;lt;u&amp;gt;203.77.192.0/20&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-025.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== IP Alias and Port Alias ==&lt;br /&gt;
IP aliases allow you to create a group of IP addresses that you can assign by group name instead of specifying each IP address individually. This can be great for specifying a group of servers that need ssh access and then in the firewall rules you can create a rule that allows ssh traffic for the ssh servers group.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Along the top menu hover over Firewall and click on Aliases.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-026.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The next tab is for setting up Port Aliases. &amp;amp;nbsp;Similar to the IP Aliases you can setup groups but on this tab you are creating groups of ports instead of IP addresses.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-027.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
IP Aliases Created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-028.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
PORT ALIAS CREATED&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-029.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Firewall Rules :- ==&lt;br /&gt;
Reference:- [https://doc.pfsense.org/index.php/Firewall_Rule_Basics https://doc.pfsense.org/index.php/Firewall_Rule_Basics]&lt;br /&gt;
&lt;br /&gt;
Firewall rules control what traffic is allowed to enter an interface on the firewall. Once traffic is passed on the interface it enters an entry in the state table is created. A state table entry allows through subsequent packets that are part of that connection.&lt;br /&gt;
&lt;br /&gt;
Firewall rules are managed at Firewall &amp;gt; Rules. Multiple rules may be selected for some actions by clicking on their row or checking the box at the start of their row. Rules may be deleted or reordered in bulk in this way. See Managing Lists of Items on pfSense for more information on the meaning of the icons when manipulating rules.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;any&#039;&#039;&#039; - &#039;&#039;0.0.0.0&#039;&#039; to &#039;&#039;255.255.255.255&#039;&#039;, or all IPv6 addresses &lt;br /&gt;
* &#039;&#039;&#039;Single host or alias&#039;&#039;&#039; - Select this and enter one IP address (&#039;&#039;1.2.3.4&#039;&#039;, &#039;&#039;aa:bb:cc:dd::1&#039;&#039;) or type the name of an Alias that has already been configured (&#039;&#039;&#039;Firewall &amp;gt; Aliases&#039;&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Network&#039;&#039;&#039; - Select this and enter a network and mask (&#039;&#039;10.99.0.0/16&#039;&#039;, &#039;&#039;aa:bb:cc:dd::0/64&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;LAN net&#039;&#039;&#039; - The subnet configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039;. On pfSense 2.2+, this also includes static route networks on that interface. &lt;br /&gt;
* &#039;&#039;&#039;LAN address&#039;&#039;&#039; - The IP address configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039; &lt;br /&gt;
* &#039;&#039;&#039;zzz Net&#039;&#039;&#039; / &#039;&#039;&#039;zzz address&#039;&#039;&#039; - Works the same as LAN above but for other interfaces (WAN, OPT1, OPT2, etc.) &lt;br /&gt;
* &#039;&#039;&#039;PPTP clients&#039;&#039;&#039; - Automatically locate and use the addresses of PPTP clients &lt;br /&gt;
* &#039;&#039;&#039;L2TP clients&#039;&#039;&#039; - Automatically locate and use the addresses of L2TP clients &lt;br /&gt;
* &#039;&#039;&#039;This Firewall (self)&#039;&#039;&#039; - Any IP address assigned to any interface on this firewall (pfSense 2.2+) &lt;br /&gt;
&lt;br /&gt;
Firewall rules are generally processed starting with Floating Rules, then Interface Group rules, then Interface tab rules&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Rules Created on bridge interface, for DMZ access&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-030.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-031.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface Rules Created:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-032.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Squid and Squidguard:- ==&lt;br /&gt;
&#039;&#039;&#039;Reference - &#039;&#039;&#039;[https://doc.pfsense.org/index.php/SquidGuard_package https://doc.pfsense.org/index.php/SquidGuard_package]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Login to your pfsense&#039;s Web Administrator, and click on &amp;quot;Server -&amp;gt; Packages&amp;quot;, scroll down the list and find squid and click on &amp;quot;+&amp;quot; button to install, wait for the process to finish then return to the packages section and look for squidguard and install that package as well.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-033.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now go to &amp;quot;Services&amp;quot; menu and look for Proxy Server &amp;amp; Proxy Filter &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-034.jpg]]&lt;br /&gt;
&lt;br /&gt;
(We are setting up the proxy server as a transparent proxy)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on Services -&amp;gt; Proxy Server.&lt;br /&gt;
&lt;br /&gt;
On the General Tab, you want to set the following settings, the Proxy Interface Option should be set to &amp;quot;LAN&amp;quot;, to set up transparent proxy server, tick the &amp;quot;Transparent Proxy&amp;quot; check box.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-035.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Tick the &amp;quot;Enabled Logging&amp;quot; Checkbox, set the log store to the default location &amp;quot; /var/squid/logs &amp;quot; rotate your logs every 30 days, set your proxy port to port number 3128 We have By-passed Proxy for 203.77.192.49/28, These are the Local Servers.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next click on the &amp;quot;Cache Mgmt.&amp;quot; tab, by default the Hard Disk Cache Size is set to 100mb, we have allocated 100GB , Memory Cache Size 3072 .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-036.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click on Save.&lt;br /&gt;
&lt;br /&gt;
Click on the Access Control Tab next, in the allowed subnets field type in your required subnets. As we have multiple Subnets, so we are going to define all.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-037.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.129/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.1.224.1/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.192.49/28&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.57/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.17/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.137/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.33.50.1/27&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click On Save &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that’s is the proxy server configured, next we are going to configure SquidGuard, click on the Services menu and select the Proxy Filter button, tick the following 3 check boxes &amp;quot;Enable&amp;quot;, &amp;quot;Enable GUI Log&amp;quot; and &amp;quot;Enable Log&amp;quot; then click the Save button, once the page has reloaded click on apply and then confirm that the Squidguard service is running by making sure the SquidGuard status is set to STARTED.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-038.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on the Black list tab and add URL &#039;&#039;&#039;http://www.shallalist.de/Downloads/shallalist.tar.gz&#039;&#039;&#039; to the Update Address and click on Download. Wait for the process to complete.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-039.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-040.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now we can set up common ACL’s&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-041.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-042.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Click on Save and restart the Squid and SquidGuard from Services. &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SARG:- ==&lt;br /&gt;
After Installing SARG package, we can configure SARG from Status &amp;gt; Sarg Reports&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-043.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select Proxy Servers as SQUID proxy . And leave Rest of Field set to Default&lt;br /&gt;
&lt;br /&gt;
And Save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Go to Next Tab Schedule&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click “+” Symbol to create new schedule &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-044.jpg]] &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Reports can be viewed From “View Reports”&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-045.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bandwidthd:- ==&lt;br /&gt;
After Installing Package &#039;&#039;&#039;bandwidthd&#039;&#039;&#039; , Configuration can be done via&lt;br /&gt;
&lt;br /&gt;
Services &amp;gt; bandwidthd&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-046.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-047.jpg]]&lt;br /&gt;
&lt;br /&gt;
Enable Bandwidthd by checking the BOX.&lt;br /&gt;
&lt;br /&gt;
Now Select the Interface: - LAN.&lt;br /&gt;
&lt;br /&gt;
Enter The Subnets from LAN interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Save and Restart bandwidthd service from Services.&lt;br /&gt;
&lt;br /&gt;
Now Bandwidthd can be accessed:-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/bandwidthd/index.html https://203.77.200.91:8080/bandwidthd/index.html]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of ntopng:- ==&lt;br /&gt;
After installing ntopng package, it appears under Diagnostics &amp;gt; ntopng. It will even track where connections were made by local PCs, and how much bandwidth was used on individual connections.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-048.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
First we have to configure ntopng settings. Via Diagnostics &amp;gt; ntopng settings.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-049.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Setup Admin Password &amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Select the Interfaces on Which ntopng will be monitoring traffic.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We have selected LAN, DMZ and BRIDGEINTERFACE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To save the changes Click “Change”&lt;br /&gt;
&lt;br /&gt;
Ntopng can be accessed via [http://203.77.200.91:3000/login.html http://203.77.200.91:3000/login.html]&lt;br /&gt;
&lt;br /&gt;
With username admin and password assigned in previous step.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Configuring OpenVPN  =&lt;br /&gt;
A VPN (virtual private network) allows us to connect directly to our home private network over the internet&lt;br /&gt;
&lt;br /&gt;
The certificate authority or CA will sign the certificates that we will be creating for the server and client side when we configure OpenVPN. You can access the certificate configuration by going over to System–&amp;gt;Cert Manager.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-050.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Under the CAs tab you might already have a CA created if you followed one of my previous articles as we needed to created one in order to sign an internal certificate to be used for securing the pfSense web interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Certificate Authority ===&lt;br /&gt;
Fill in the fields to &#039;&#039;&#039;create a new Certificate Authority&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Descriptive Name&#039;&#039;&#039; - Used as the Common Name (CN) for the CA. Do not spaces, punctuation or special characters (ex: &#039;&#039;VPN Server CA&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Key Length&#039;&#039;&#039; - Default is OK, the higher the better but will use more CPU. &lt;br /&gt;
* &#039;&#039;&#039;Lifetime&#039;&#039;&#039; - Default is OK, but can be lowered if it must be changed out more often. &lt;br /&gt;
* &#039;&#039;&#039;Country Code&#039;&#039;&#039;, &#039;&#039;&#039;State/Province&#039;&#039;&#039;, &#039;&#039;&#039;City&#039;&#039;&#039;, &#039;&#039;&#039;Organization&#039;&#039;&#039; - Enter values for this location/company. &lt;br /&gt;
* &#039;&#039;&#039;E-mail&#039;&#039;&#039; - Used as a reference on the certificate, does not receive any mail from the system. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Add New CA&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-051.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
After you finished setting up the CA the next step is to create some certificates that the recently created CA will sign for us. Since these are self-signed certificates most browsers will give you a warning&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Server Certificate ===&lt;br /&gt;
Fill in the fields to create a new &#039;&#039;&#039;Server Certificate&#039;&#039;&#039;. Similar Fields as CA entry, most of the fields carry over and do not need changed. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Create new Certificate&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-052.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that we have all the components in place we can configure OpenVPN. Head over to VPN–&amp;gt;OpenVPN.&lt;br /&gt;
&lt;br /&gt;
.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-053.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select “Wizards” from the tab at the top which will guide us step by step to configure OpenVPN&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-054.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-055.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We will select the local user access database provided by pfSense&lt;br /&gt;
&lt;br /&gt;
In the next step we will be selecting the CA that we created at the beginning of this article.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-056.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Following is the Server Certificate that we will be using which is the Certificate that we recently created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-057.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;OpenVPN Server Configuration&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;TLS Authentication&#039;&#039;&#039; -- Leave this checked, along with the box underneath to generate a new key. Using a TLS key is technically optional, but &#039;&#039;highly&#039;&#039; recommended&lt;br /&gt;
* &#039;&#039;&#039;Tunnel Network&#039;&#039;&#039; -- Should be a new, unique network that does not exist anywhere in the current network or routing table. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-058.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-059.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-060.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== Firewall Rules ===&lt;br /&gt;
The next screen offers the choice to add firewall rules automatically. For convenience, check both unless the rules will be managed manually. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== End of the Wizard ===&lt;br /&gt;
Click &#039;&#039;&#039;Finish&#039;&#039;&#039; to exit the wizard and the new settings will be saved and applied automatically. &lt;br /&gt;
&lt;br /&gt;
== Adding a User with a Certificate ==&lt;br /&gt;
Navigate to &#039;&#039;&#039;System &amp;gt; User Manager&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click &amp;quot;+&amp;quot; To add a &#039;&#039;&#039;user&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Username&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Password / Confirm password&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Check Click to create a &#039;&#039;&#039;user certificate.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in the Descriptive Name as the username&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-061.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-062.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The OpenVPN Client Export Package allows exporting configurations formatted for a wide variety of platforms. It also allows exporting a pre-packaged Windows installer executable which includes the configuration bundled inside for a painly client installation. &lt;br /&gt;
&lt;br /&gt;
=== Installing the OpenVPN Client Export Package ===&lt;br /&gt;
To Install the OpenVPN Client Export Package &lt;br /&gt;
&lt;br /&gt;
* Navigate to &#039;&#039;&#039;System &amp;gt; Packages&#039;&#039;&#039;, &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab &lt;br /&gt;
* Find &#039;&#039;&#039;OpenVPN Client Export Package&#039;&#039;&#039; in the list &lt;br /&gt;
&lt;br /&gt;
=== Exporting a Configuration ===&lt;br /&gt;
* Navigate to &#039;&#039;&#039;VPN &amp;gt; OpenVPN&#039;&#039;&#039; on the &#039;&#039;&#039;Client Export&#039;&#039;&#039; tab &lt;br /&gt;
* Choose the VPN from the &#039;&#039;&#039;Remote Access Server&#039;&#039;&#039; drop-down list &lt;br /&gt;
* Find the user in the list at the bottom of the page and select the appropriate configuration type to export. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-063.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-064.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Multiple instance of VPN server can be created with different tunnel network &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-065.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Firewall Rules are applied as per the requirement on tunnel network .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-066.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Firewall Logs =&lt;br /&gt;
The Firewall logs at &#039;&#039;&#039;Status &amp;gt; System Logs&#039;&#039;&#039; on the &#039;&#039;&#039;Firewall&#039;&#039;&#039; tab show all events logged by the firewall.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Each entry is displayed with the action ( pass or block, reject is only logged as block), time, interface, source, destination, and protocol.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Configuration Of rsyslog Server for Logs Storage:-&lt;br /&gt;
&lt;br /&gt;
Status: &amp;gt;System logs &amp;gt; Settings&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-067.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Configuration of rsyslog on Centos :-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Setup Log File Location =====&lt;br /&gt;
Now edit Rsyslog configuration file and configure the location’s to generate log files in system.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# vim /etc/rsyslog.conf&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
and add following lines as the end of file.&lt;br /&gt;
&lt;br /&gt;
$template TmplAuth, &amp;quot;/var/log/%HOSTNAME%/%PROGRAMNAME%.log&amp;quot; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
authpriv.* ?TmplAuth&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;*.info,mail.none,authpriv.none,cron.none &amp;lt;/nowiki&amp;gt;?TmplMsg&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Enable Module and UDP Protocol =====&lt;br /&gt;
Also remove comment from following lines ( remove starting # ) in rsyslog configuration file to enable UDP.&lt;br /&gt;
&lt;br /&gt;
$ModLoad imudp&lt;br /&gt;
&lt;br /&gt;
$UDPServerRun 514&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Restart Rsyslog  =====&lt;br /&gt;
After making above changes in Rsyslog central server, restart service using following command.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# service rsyslog restart&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Logrotation:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Create file&#039;&#039;&#039; :- &#039;&#039;&#039;/etc/logrotate.d/pfsense&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;And enter:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/var/log/pfsense/filterlog.log&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;{&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;daily&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;missingok&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;rotate 60&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;compress&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;notifempty&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;create 640 root root&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;postrotate&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/etc/init.d/rsyslog restart &amp;gt;/dev/null&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;endscript&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;}&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Save and Quit.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;RRD Graphs:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
These are located under &#039;&#039;&#039;Status &amp;gt; RRD Graphs&#039;&#039;&#039;. Several graphs are presented for each monitored item, with varying time intervals and averages. &lt;br /&gt;
&lt;br /&gt;
These graphs measure things such as CPU usage, memory usage, state table usage, throughput (in bytes as well as packets), link quality, traffic shaping queue usage, and so on. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-068.jpg]]&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=Category:GSPC&amp;diff=1905</id>
		<title>Category:GSPC</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=Category:GSPC&amp;diff=1905"/>
		<updated>2015-04-16T11:01:02Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category: Tetra Clients]]&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=Category:GSPC&amp;diff=1904</id>
		<title>Category:GSPC</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=Category:GSPC&amp;diff=1904"/>
		<updated>2015-04-16T10:55:14Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Implementation Of Pfsense Firewall Server&#039;&#039;&#039;&lt;br /&gt;
[[http://192.168.1.15/wiki/index.php/PF_Sense_Firewall_Implementation_at_GIPL]]&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=Category:GSPC&amp;diff=1903</id>
		<title>Category:GSPC</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=Category:GSPC&amp;diff=1903"/>
		<updated>2015-04-16T10:54:31Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Implementation Of Pfsense Firewall Server&#039;&#039;&#039;&lt;br /&gt;
[http://192.168.1.15/wiki/index.php/PF_Sense_Firewall_Implementation_at_GIPL]&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=Category:GSPC&amp;diff=1902</id>
		<title>Category:GSPC</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=Category:GSPC&amp;diff=1902"/>
		<updated>2015-04-16T10:53:53Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Implementation Of Pfsense Firewall Server&lt;br /&gt;
[http://192.168.1.15/wiki/index.php/PF_Sense_Firewall_Implementation_at_GIPL]&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=Category:GSPC&amp;diff=1901</id>
		<title>Category:GSPC</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=Category:GSPC&amp;diff=1901"/>
		<updated>2015-04-16T10:52:48Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[http://192.168.1.15/wiki/index.php/PF_Sense_Firewall_Implementation_at_GIPL]&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=Category:GSPC&amp;diff=1900</id>
		<title>Category:GSPC</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=Category:GSPC&amp;diff=1900"/>
		<updated>2015-04-16T10:52:24Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Installaion]]&lt;br /&gt;
[http://192.168.1.15/wiki/index.php/PF_Sense_Firewall_Implementation_at_GIPL]&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=Category:GSPC&amp;diff=1899</id>
		<title>Category:GSPC</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=Category:GSPC&amp;diff=1899"/>
		<updated>2015-04-16T10:51:19Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: Created page with &amp;quot;192.168.1.15/wiki/index.php/PF_Sense_Firewall_Implementation_at_GIPL&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;192.168.1.15/wiki/index.php/PF_Sense_Firewall_Implementation_at_GIPL&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1898</id>
		<title>PF Sense Firewall Implementation at GIPL</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1898"/>
		<updated>2015-04-16T10:47:44Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;center&amp;gt;&amp;lt;u&amp;gt;&#039;&#039;&#039;PF Sense Firewall Implementation at GIPL , GandhiNagar &#039;&#039;&#039;&amp;lt;/u&amp;gt;&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Table of Contents ==&lt;br /&gt;
[#__RefHeading__2322_1445225205 NETWORK DIAGRAM2]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2324_1445225205 Performing a Full Install (LiveCD)3]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2326_1445225205 GUI Configuration Setup8]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2328_1445225205 Configuration Of Bridge Interface13]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2330_1445225205 Assign Virtual IP’s To LAN interface:-15]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2332_1445225205 Configuration of SNORT17]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2334_1445225205 Add Snort to an interface20]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2336_1445225205 Select which types of rules will protect the network22]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2338_1445225205 IP Alias and Port Alias24]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2340_1445225205 Firewall Rules :-27]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2342_1445225205 Configuration Of Squid and Squidguard:-31]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2344_1445225205 Configuration of SARG:-39]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2346_1445225205 Configuration Of Bandwidthd:-42]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2348_1445225205 Configuration Of ntopng:-44]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2350_1445225205 Configuring OpenVPN46]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2352_1445225205 Certificate Authority47]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2354_1445225205 Server Certificate48]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2356_1445225205 Firewall Rules54]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2358_1445225205 End of the Wizard54]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2360_1445225205 Adding a User with a Certificate54]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2362_1445225205 Installing the OpenVPN Client Export Package57]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2364_1445225205 Exporting a Configuration57]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2366_1445225205 Firewall Logs60]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2368_1445225205 Setup Log File Location61]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2370_1445225205 Enable Module and UDP Protocol61]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2372_1445225205 Restart Rsyslog61]= NETWORK DIAGRAM =&lt;br /&gt;
[[Image:Gpil-000.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Installation&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;pfSense&#039;&#039;&#039; is an open source firewall/router computer software distribution based on FreeBSD. It is installed on a computer to make a dedicated firewall/router for a network and is noted for its reliability[1] and offering features often only found in expensive commercial firewalls&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Download pfSense&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Visit https://www.pfsense.org/download/mirror.php?section=downloads&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Step 1 :- &#039;&#039;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Performing a Full Install (LiveCD) ==&lt;br /&gt;
Power on the target system and connect the install media: Place the CD into the drive or plug the Memstick into a USB port. If the BIOS is set to boot from CD/USB, pfSense will start. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-001.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
As the operating system boots and pfSense starts, a prompt is presented with some choices and a countdown timer. At this prompt, press &#039;&#039;i&#039;&#039; to invoke the installer now.&lt;br /&gt;
&lt;br /&gt;
When the installer detects multiple disks in the system the first screen available provides the option &#039;&#039;&#039;Setup GEOM Mirror&#039;&#039;&#039;. Choose that option, pick the primary disk, the disk to use for the mirror copy, and then proceed with the installation as normal. &lt;br /&gt;
&lt;br /&gt;
The Quick/Easy install choice will target the GEOM mirror automatically&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-002.jpeg]]&lt;br /&gt;
&lt;br /&gt;
At the &#039;&#039;&#039;Select Task&#039;&#039;&#039; prompt, choose &#039;&#039;Quick/Easy Install&#039;&#039;. [[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-003.jpeg]]&lt;br /&gt;
&lt;br /&gt;
The install will proceed, wiping the target disk and installing pfSense. Copying files may take some time to finish. &lt;br /&gt;
&lt;br /&gt;
After the files have been copied to the target disk, a choice is presented to select the console type. &#039;&#039;Standard&#039;&#039; defaults to the VGA console. &#039;&#039;Embedded&#039;&#039; defaults to serial console&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-004.jpeg]]&lt;br /&gt;
&lt;br /&gt;
Now the system must reboot so that pfSense may start from the target disk. Select &#039;&#039;Reboot&#039;&#039; and then press &#039;&#039;&#039;Enter (remove CD from Drive)&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-005.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After the system reboots, pfSense will be running from the target disk. The next step is to Assign Interfaces on the Console below.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-006.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After installation and assignment, a shell menu is presented on the console with a number of options. pfSense now is ready to be accessed via the network, LAN interface IP 192.168.1.1 is assigned by default.&lt;br /&gt;
&lt;br /&gt;
Open a web browser and navigate to https://192.168.1.1/, using the default username admin and password pfsense to login.&lt;br /&gt;
&lt;br /&gt;
The first visit to the WebGUI will be redirected to the setup wizard.&lt;br /&gt;
&lt;br /&gt;
== GUI Configuration Setup ==&lt;br /&gt;
Once The Setup is launched, Fill the details are follows:-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-007.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We have defined FQDN as gipl.firewall&lt;br /&gt;
&lt;br /&gt;
DNS servers:- 8.8.8.8 and 4.4.2.2 Global DNS&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click NEXT&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-008.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select The Time-Zone as Asia/Kolkata .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
And Click NEXT&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-009.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Here we have Set WAN as Static Interface&lt;br /&gt;
&lt;br /&gt;
With IP address :- 203.77.200.91/25&lt;br /&gt;
&lt;br /&gt;
Gateway :- 203.77.200.1&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-010.jpg]]&lt;br /&gt;
&lt;br /&gt;
Here we have Configured LAN interface with IP address 192.168.45.101/24&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
( note:-As per the client Network Topology , Lan interface have multiple Subnets configured , so we will be configuring Virtual IP’s from GUI )&lt;br /&gt;
&lt;br /&gt;
After Setting Admin Password, Page will be redirected to Pfsense-Dashboard.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-011.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We Have Changed Default Port from 443 to 8080 Via :-&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;System &amp;gt; Advanced&#039;&#039;&#039;&lt;br /&gt;
[[Image:Gpil-012.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Change TCP Port from Default 443 to 8080 .&lt;br /&gt;
[[Image:Gpil-013.jpg]] &lt;br /&gt;
Save .&lt;br /&gt;
&lt;br /&gt;
Now pfsense Can be accessed via [https://IP:8080 https://IP:8080]&lt;br /&gt;
&lt;br /&gt;
IP Address of Firewall is 203.77.200.91 on WAN interface.&lt;br /&gt;
&lt;br /&gt;
Go to :- interface &amp;gt; assign , and edit Opt1 as DMZ , do not assign IP address to This interface , because we will be creating bridge interface .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bridge Interface ==&lt;br /&gt;
Now we have to configure &#039;&#039;&#039;Interface Bridges&#039;&#039;&#039; in order to Setup Pfsense in &lt;br /&gt;
&lt;br /&gt;
Transparent mode.&lt;br /&gt;
&lt;br /&gt;
Reference:- &amp;lt;u&amp;gt;https://doc.pfsense.org/index.php/Interface_Bridges&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Navigate To :- Interfaces &amp;gt; (assign) &lt;br /&gt;
&lt;br /&gt;
on the Bridges tab Click “ +” symbol to add a new bridge .&lt;br /&gt;
&lt;br /&gt;
Ctrl-Click to select the Member interfaces from the list of available interfaces and type a Description , we have selected WAN + DMZ as bridge0 and create new Interface BRIDGEINTERFACE using bridge0 .&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-014.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
By default, traffic is filtered on the member interfaces and not on the bridge interface itself. This behavior may be changed by toggling the values of &#039;&#039;&#039;net.link.bridge.pfil_member&#039;&#039;&#039; and net.link.bridge.pfil&#039;&#039;&#039;_bridge &#039;&#039;&#039;under System&#039;&#039;&#039; &amp;gt; Advanced &#039;&#039;&#039;on the &#039;&#039;&#039;System Tunables&#039;&#039;&#039; tab. With them set at &#039;&#039;0&#039;&#039; and &#039;&#039;1&#039;&#039;, respectively, then filtering would be performed on the bridge only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-015.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Pfsense is Configured In Bridge Mode with &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;WAN interface: - 203.77.200.91/25 gateway :- 203.77.200.1&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface:- 192.168.45.101/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;DMZ: - no ip &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;BRIDGEINTERFACE:- 203.77.200.92/25&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-016.jpg]]&lt;br /&gt;
&lt;br /&gt;
== Assign Virtual IP’s To LAN interface:- ==&lt;br /&gt;
[[Image:Gpil-018.jpg]]&lt;br /&gt;
Now as LAN environment have multiple Subnet configured, we will be assigning Virtual IP address to LAN interface.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-017.jpg]]&lt;br /&gt;
&lt;br /&gt;
Clients on LAN Environment have their Gateway Set from These Virtual IP’s.&lt;br /&gt;
&lt;br /&gt;
203.77.196.230 is added for outside access of Local Servers 203.77.192.49/28.&lt;br /&gt;
&lt;br /&gt;
(203.77.196.230) is configured in 203.77.192.2 switch which will receive any packet for 203.77.192.49/28 from Outside and send it to 203.77.196.230.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SNORT  ==&lt;br /&gt;
&amp;lt;u&amp;gt;&#039;&#039;&#039;Reference&#039;&#039;&#039;&amp;lt;/u&amp;gt; :- &amp;lt;u&amp;gt;&#039;&#039;&#039;https://doc.pfsense.org/index.php/Setup_Snort_Package&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Go to the &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab under the &#039;&#039;&#039;System&#039;&#039;&#039; menu and install the snort package.&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;When the installation completes, click on &#039;&#039;&#039;Snort&#039;&#039;&#039; under the &#039;&#039;&#039;Services&#039;&#039;&#039; menu. &amp;amp;nbsp;This will open the Snort main setup page.&lt;br /&gt;
&lt;br /&gt;
Click the &#039;&#039;&#039;Global Settings&#039;&#039;&#039; tab and perform the following At the top of the page you have three choices for Rule Sets to activate.&lt;br /&gt;
&lt;br /&gt;
Put Check mark on :-Install &#039;&#039;&#039;Snort Community&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Emerging Threats&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Snort VRT&#039;&#039;&#039; rules. And save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Updates&#039;&#039;&#039; tab is used to check the status of downloaded rules packages and to download new updates. The table shows the available rule packages and their current status [[Image:Gpil-019.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Update Button to Update the rules.&lt;br /&gt;
[[Image:Gpil-020.jpeg]]&lt;br /&gt;
&lt;br /&gt;
== Add Snort to an interface ==&lt;br /&gt;
Click the Snort Interfaces tab and then the &amp;quot;+&amp;quot; icon to add a new Snort interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;On the &#039;&#039;&#039;WAN Settings&#039;&#039;&#039; tab, click the &#039;&#039;Enable&#039;&#039; checkbox.In the drop-down, choose the interface. &amp;amp;nbsp;The WAN interface is the default and is a good first choice.In the &#039;&#039;Description&#039;&#039; textbox, enter a name (WAN again, is fine here).Click the checkbox to &amp;quot;&#039;&#039;Send alerts to the main System logs&#039;&#039;&amp;quot;.leave the other settings at their defaults&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-021.jpg]]&lt;br /&gt;
&lt;br /&gt;
After saving, the browser will be returned to the Snort Interfaces tab. Note the warning icons in the image below showing no rules have been selected for the new Snort interface. Those rules will be configured next. Click the &amp;quot;e&amp;quot; icon to edit the new Snort interface again&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-024.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Select which types of rules will protect the network ==&lt;br /&gt;
Click the &#039;&#039;&#039;Categories&#039;&#039;&#039; tab for the new interface&lt;br /&gt;
&lt;br /&gt;
Check [https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=GPLv2_community.rules Snort GPLv2 Community Rules (VRT certified)] Box .&lt;br /&gt;
&lt;br /&gt;
And Manual Rules :-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-botcc.rules emerging-botcc.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_blacklist.rules snort_blacklist.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.so.rules snort_exploit-kit.so.rules] &lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_ddos.rules snort_ddos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_dos.rules snort_dos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.rules snort_exploit-kit.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-malware.rules emerging-malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-mobile_malware.rules emerging-mobile_malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-tor.rules emerging-tor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-trojan.rules emerging-trojan.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_malware-backdoor.rules snort_malware-backdoor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_virus.rules snort_virus.rules]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-023.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click SAVE when finished to save the selection and build the rules &lt;br /&gt;
&lt;br /&gt;
After that restart the service &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-024.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Managing Pass lists:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Pass Lists are lists of IP addresses that Snort should never block. These may be created and managed on the Pass Lists tab. When an IP address is listed on a Pass List, Snort will never insert a block on that address even when malicious traffic is detected.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;To create a new Pass List, click &amp;quot;+&amp;quot;. To edit an existing Pass List, click the &amp;quot;e&amp;quot;. To delete a Pass List, click &amp;quot;x&amp;quot;. Note that a Pass List may not be deleted if it is currently assigned to one or more Snort interfaces.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We have added GIPL IP’s in Pass list . i.e&#039;&#039;&#039; &amp;lt;u&amp;gt;203.77.192.0/20&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-025.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== IP Alias and Port Alias ==&lt;br /&gt;
IP aliases allow you to create a group of IP addresses that you can assign by group name instead of specifying each IP address individually. This can be great for specifying a group of servers that need ssh access and then in the firewall rules you can create a rule that allows ssh traffic for the ssh servers group.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Along the top menu hover over Firewall and click on Aliases.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-026.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The next tab is for setting up Port Aliases. &amp;amp;nbsp;Similar to the IP Aliases you can setup groups but on this tab you are creating groups of ports instead of IP addresses.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-027.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
IP Aliases Created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-028.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
PORT ALIAS CREATED&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-029.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Firewall Rules :- ==&lt;br /&gt;
Reference:- [https://doc.pfsense.org/index.php/Firewall_Rule_Basics https://doc.pfsense.org/index.php/Firewall_Rule_Basics]&lt;br /&gt;
&lt;br /&gt;
Firewall rules control what traffic is allowed to enter an interface on the firewall. Once traffic is passed on the interface it enters an entry in the state table is created. A state table entry allows through subsequent packets that are part of that connection.&lt;br /&gt;
&lt;br /&gt;
Firewall rules are managed at Firewall &amp;gt; Rules. Multiple rules may be selected for some actions by clicking on their row or checking the box at the start of their row. Rules may be deleted or reordered in bulk in this way. See Managing Lists of Items on pfSense for more information on the meaning of the icons when manipulating rules.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;any&#039;&#039;&#039; - &#039;&#039;0.0.0.0&#039;&#039; to &#039;&#039;255.255.255.255&#039;&#039;, or all IPv6 addresses &lt;br /&gt;
* &#039;&#039;&#039;Single host or alias&#039;&#039;&#039; - Select this and enter one IP address (&#039;&#039;1.2.3.4&#039;&#039;, &#039;&#039;aa:bb:cc:dd::1&#039;&#039;) or type the name of an Alias that has already been configured (&#039;&#039;&#039;Firewall &amp;gt; Aliases&#039;&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Network&#039;&#039;&#039; - Select this and enter a network and mask (&#039;&#039;10.99.0.0/16&#039;&#039;, &#039;&#039;aa:bb:cc:dd::0/64&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;LAN net&#039;&#039;&#039; - The subnet configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039;. On pfSense 2.2+, this also includes static route networks on that interface. &lt;br /&gt;
* &#039;&#039;&#039;LAN address&#039;&#039;&#039; - The IP address configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039; &lt;br /&gt;
* &#039;&#039;&#039;zzz Net&#039;&#039;&#039; / &#039;&#039;&#039;zzz address&#039;&#039;&#039; - Works the same as LAN above but for other interfaces (WAN, OPT1, OPT2, etc.) &lt;br /&gt;
* &#039;&#039;&#039;PPTP clients&#039;&#039;&#039; - Automatically locate and use the addresses of PPTP clients &lt;br /&gt;
* &#039;&#039;&#039;L2TP clients&#039;&#039;&#039; - Automatically locate and use the addresses of L2TP clients &lt;br /&gt;
* &#039;&#039;&#039;This Firewall (self)&#039;&#039;&#039; - Any IP address assigned to any interface on this firewall (pfSense 2.2+) &lt;br /&gt;
&lt;br /&gt;
Firewall rules are generally processed starting with Floating Rules, then Interface Group rules, then Interface tab rules&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Rules Created on bridge interface, for DMZ access&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-030.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-031.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface Rules Created:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-032.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Squid and Squidguard:- ==&lt;br /&gt;
&#039;&#039;&#039;Reference - &#039;&#039;&#039;[https://doc.pfsense.org/index.php/SquidGuard_package https://doc.pfsense.org/index.php/SquidGuard_package]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Login to your pfsense&#039;s Web Administrator, and click on &amp;quot;Server -&amp;gt; Packages&amp;quot;, scroll down the list and find squid and click on &amp;quot;+&amp;quot; button to install, wait for the process to finish then return to the packages section and look for squidguard and install that package as well.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-033.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now go to &amp;quot;Services&amp;quot; menu and look for Proxy Server &amp;amp; Proxy Filter &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-034.jpg]]&lt;br /&gt;
&lt;br /&gt;
(We are setting up the proxy server as a transparent proxy)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on Services -&amp;gt; Proxy Server.&lt;br /&gt;
&lt;br /&gt;
On the General Tab, you want to set the following settings, the Proxy Interface Option should be set to &amp;quot;LAN&amp;quot;, to set up transparent proxy server, tick the &amp;quot;Transparent Proxy&amp;quot; check box.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-035.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Tick the &amp;quot;Enabled Logging&amp;quot; Checkbox, set the log store to the default location &amp;quot; /var/squid/logs &amp;quot; rotate your logs every 30 days, set your proxy port to port number 3128 We have By-passed Proxy for 203.77.192.49/28, These are the Local Servers.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next click on the &amp;quot;Cache Mgmt.&amp;quot; tab, by default the Hard Disk Cache Size is set to 100mb, we have allocated 100GB , Memory Cache Size 3072 .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-036.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click on Save.&lt;br /&gt;
&lt;br /&gt;
Click on the Access Control Tab next, in the allowed subnets field type in your required subnets. As we have multiple Subnets, so we are going to define all.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-037.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.129/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.1.224.1/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.192.49/28&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.57/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.17/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.137/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.33.50.1/27&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click On Save &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that’s is the proxy server configured, next we are going to configure SquidGuard, click on the Services menu and select the Proxy Filter button, tick the following 3 check boxes &amp;quot;Enable&amp;quot;, &amp;quot;Enable GUI Log&amp;quot; and &amp;quot;Enable Log&amp;quot; then click the Save button, once the page has reloaded click on apply and then confirm that the Squidguard service is running by making sure the SquidGuard status is set to STARTED.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-038.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on the Black list tab and add URL &#039;&#039;&#039;http://www.shallalist.de/Downloads/shallalist.tar.gz&#039;&#039;&#039; to the Update Address and click on Download. Wait for the process to complete.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-039.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-040.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now we can set up common ACL’s&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-041.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-042.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Click on Save and restart the Squid and SquidGuard from Services. &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SARG:- ==&lt;br /&gt;
After Installing SARG package, we can configure SARG from Status &amp;gt; Sarg Reports&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-043.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select Proxy Servers as SQUID proxy . And leave Rest of Field set to Default&lt;br /&gt;
&lt;br /&gt;
And Save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Go to Next Tab Schedule&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click “+” Symbol to create new schedule &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-044.jpg]] &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Reports can be viewed From “View Reports”&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-045.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bandwidthd:- ==&lt;br /&gt;
After Installing Package &#039;&#039;&#039;bandwidthd&#039;&#039;&#039; , Configuration can be done via&lt;br /&gt;
&lt;br /&gt;
Services &amp;gt; bandwidthd&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-046.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-047.jpg]]&lt;br /&gt;
&lt;br /&gt;
Enable Bandwidthd by checking the BOX.&lt;br /&gt;
&lt;br /&gt;
Now Select the Interface: - LAN.&lt;br /&gt;
&lt;br /&gt;
Enter The Subnets from LAN interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Save and Restart bandwidthd service from Services.&lt;br /&gt;
&lt;br /&gt;
Now Bandwidthd can be accessed:-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/bandwidthd/index.html https://203.77.200.91:8080/bandwidthd/index.html]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of ntopng:- ==&lt;br /&gt;
After installing ntopng package, it appears under Diagnostics &amp;gt; ntopng. It will even track where connections were made by local PCs, and how much bandwidth was used on individual connections.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-048.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
First we have to configure ntopng settings. Via Diagnostics &amp;gt; ntopng settings.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-049.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Setup Admin Password &amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Select the Interfaces on Which ntopng will be monitoring traffic.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We have selected LAN, DMZ and BRIDGEINTERFACE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To save the changes Click “Change”&lt;br /&gt;
&lt;br /&gt;
Ntopng can be accessed via [http://203.77.200.91:3000/login.html http://203.77.200.91:3000/login.html]&lt;br /&gt;
&lt;br /&gt;
With username admin and password assigned in previous step.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Configuring OpenVPN  =&lt;br /&gt;
A VPN (virtual private network) allows us to connect directly to our home private network over the internet&lt;br /&gt;
&lt;br /&gt;
The certificate authority or CA will sign the certificates that we will be creating for the server and client side when we configure OpenVPN. You can access the certificate configuration by going over to System–&amp;gt;Cert Manager.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-050.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Under the CAs tab you might already have a CA created if you followed one of my previous articles as we needed to created one in order to sign an internal certificate to be used for securing the pfSense web interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Certificate Authority ===&lt;br /&gt;
Fill in the fields to &#039;&#039;&#039;create a new Certificate Authority&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Descriptive Name&#039;&#039;&#039; - Used as the Common Name (CN) for the CA. Do not spaces, punctuation or special characters (ex: &#039;&#039;VPN Server CA&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Key Length&#039;&#039;&#039; - Default is OK, the higher the better but will use more CPU. &lt;br /&gt;
* &#039;&#039;&#039;Lifetime&#039;&#039;&#039; - Default is OK, but can be lowered if it must be changed out more often. &lt;br /&gt;
* &#039;&#039;&#039;Country Code&#039;&#039;&#039;, &#039;&#039;&#039;State/Province&#039;&#039;&#039;, &#039;&#039;&#039;City&#039;&#039;&#039;, &#039;&#039;&#039;Organization&#039;&#039;&#039; - Enter values for this location/company. &lt;br /&gt;
* &#039;&#039;&#039;E-mail&#039;&#039;&#039; - Used as a reference on the certificate, does not receive any mail from the system. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Add New CA&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-051.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
After you finished setting up the CA the next step is to create some certificates that the recently created CA will sign for us. Since these are self-signed certificates most browsers will give you a warning&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Server Certificate ===&lt;br /&gt;
Fill in the fields to create a new &#039;&#039;&#039;Server Certificate&#039;&#039;&#039;. Similar Fields as CA entry, most of the fields carry over and do not need changed. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Create new Certificate&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-052.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that we have all the components in place we can configure OpenVPN. Head over to VPN–&amp;gt;OpenVPN.&lt;br /&gt;
&lt;br /&gt;
.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-053.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select “Wizards” from the tab at the top which will guide us step by step to configure OpenVPN&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-054.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-055.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We will select the local user access database provided by pfSense&lt;br /&gt;
&lt;br /&gt;
In the next step we will be selecting the CA that we created at the beginning of this article.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-056.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Following is the Server Certificate that we will be using which is the Certificate that we recently created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-057.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;OpenVPN Server Configuration&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;TLS Authentication&#039;&#039;&#039; -- Leave this checked, along with the box underneath to generate a new key. Using a TLS key is technically optional, but &#039;&#039;highly&#039;&#039; recommended&lt;br /&gt;
* &#039;&#039;&#039;Tunnel Network&#039;&#039;&#039; -- Should be a new, unique network that does not exist anywhere in the current network or routing table. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-058.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-059.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-060.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== Firewall Rules ===&lt;br /&gt;
The next screen offers the choice to add firewall rules automatically. For convenience, check both unless the rules will be managed manually. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== End of the Wizard ===&lt;br /&gt;
Click &#039;&#039;&#039;Finish&#039;&#039;&#039; to exit the wizard and the new settings will be saved and applied automatically. &lt;br /&gt;
&lt;br /&gt;
== Adding a User with a Certificate ==&lt;br /&gt;
Navigate to &#039;&#039;&#039;System &amp;gt; User Manager&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click &amp;quot;+&amp;quot; To add a &#039;&#039;&#039;user&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Username&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Password / Confirm password&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Check Click to create a &#039;&#039;&#039;user certificate.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in the Descriptive Name as the username&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-061.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-062.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The OpenVPN Client Export Package allows exporting configurations formatted for a wide variety of platforms. It also allows exporting a pre-packaged Windows installer executable which includes the configuration bundled inside for a painly client installation. &lt;br /&gt;
&lt;br /&gt;
=== Installing the OpenVPN Client Export Package ===&lt;br /&gt;
To Install the OpenVPN Client Export Package &lt;br /&gt;
&lt;br /&gt;
* Navigate to &#039;&#039;&#039;System &amp;gt; Packages&#039;&#039;&#039;, &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab &lt;br /&gt;
* Find &#039;&#039;&#039;OpenVPN Client Export Package&#039;&#039;&#039; in the list &lt;br /&gt;
&lt;br /&gt;
=== Exporting a Configuration ===&lt;br /&gt;
* Navigate to &#039;&#039;&#039;VPN &amp;gt; OpenVPN&#039;&#039;&#039; on the &#039;&#039;&#039;Client Export&#039;&#039;&#039; tab &lt;br /&gt;
* Choose the VPN from the &#039;&#039;&#039;Remote Access Server&#039;&#039;&#039; drop-down list &lt;br /&gt;
* Find the user in the list at the bottom of the page and select the appropriate configuration type to export. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-063.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-064.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Multiple instance of VPN server can be created with different tunnel network &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-065.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Firewall Rules are applied as per the requirement on tunnel network .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-066.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Firewall Logs =&lt;br /&gt;
The Firewall logs at &#039;&#039;&#039;Status &amp;gt; System Logs&#039;&#039;&#039; on the &#039;&#039;&#039;Firewall&#039;&#039;&#039; tab show all events logged by the firewall.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Each entry is displayed with the action ( pass or block, reject is only logged as block), time, interface, source, destination, and protocol.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Configuration Of rsyslog Server for Logs Storage:-&lt;br /&gt;
&lt;br /&gt;
Status: &amp;gt;System logs &amp;gt; Settings&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-067.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Configuration of rsyslog on Centos :-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Setup Log File Location =====&lt;br /&gt;
Now edit Rsyslog configuration file and configure the location’s to generate log files in system.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# vim /etc/rsyslog.conf&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
and add following lines as the end of file.&lt;br /&gt;
&lt;br /&gt;
$template TmplAuth, &amp;quot;/var/log/%HOSTNAME%/%PROGRAMNAME%.log&amp;quot; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
authpriv.* ?TmplAuth&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;*.info,mail.none,authpriv.none,cron.none &amp;lt;/nowiki&amp;gt;?TmplMsg&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Enable Module and UDP Protocol =====&lt;br /&gt;
Also remove comment from following lines ( remove starting # ) in rsyslog configuration file to enable UDP.&lt;br /&gt;
&lt;br /&gt;
$ModLoad imudp&lt;br /&gt;
&lt;br /&gt;
$UDPServerRun 514&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Restart Rsyslog  =====&lt;br /&gt;
After making above changes in Rsyslog central server, restart service using following command.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# service rsyslog restart&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Logrotation:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Create file&#039;&#039;&#039; :- &#039;&#039;&#039;/etc/logrotate.d/pfsense&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;And enter:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/var/log/pfsense/filterlog.log&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;{&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;daily&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;missingok&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;rotate 60&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;compress&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;notifempty&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;create 640 root root&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;postrotate&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/etc/init.d/rsyslog restart &amp;gt;/dev/null&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;endscript&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;}&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Save and Quit.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;RRD Graphs:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
These are located under &#039;&#039;&#039;Status &amp;gt; RRD Graphs&#039;&#039;&#039;. Several graphs are presented for each monitored item, with varying time intervals and averages. &lt;br /&gt;
&lt;br /&gt;
These graphs measure things such as CPU usage, memory usage, state table usage, throughput (in bytes as well as packets), link quality, traffic shaping queue usage, and so on. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-068.jpg]]&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1897</id>
		<title>PF Sense Firewall Implementation at GIPL</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1897"/>
		<updated>2015-04-16T10:44:56Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;center&amp;gt;&amp;lt;u&amp;gt;&#039;&#039;&#039;PF Sense Firewall Implementation at GIPL , GandhiNagar &#039;&#039;&#039;&amp;lt;/u&amp;gt;&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Table of Contents ==&lt;br /&gt;
[#__RefHeading__2322_1445225205 NETWORK DIAGRAM2]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2324_1445225205 Performing a Full Install (LiveCD)3]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2326_1445225205 GUI Configuration Setup8]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2328_1445225205 Configuration Of Bridge Interface13]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2330_1445225205 Assign Virtual IP’s To LAN interface:-15]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2332_1445225205 Configuration of SNORT17]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2334_1445225205 Add Snort to an interface20]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2336_1445225205 Select which types of rules will protect the network22]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2338_1445225205 IP Alias and Port Alias24]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2340_1445225205 Firewall Rules :-27]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2342_1445225205 Configuration Of Squid and Squidguard:-31]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2344_1445225205 Configuration of SARG:-39]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2346_1445225205 Configuration Of Bandwidthd:-42]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2348_1445225205 Configuration Of ntopng:-44]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2350_1445225205 Configuring OpenVPN46]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2352_1445225205 Certificate Authority47]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2354_1445225205 Server Certificate48]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2356_1445225205 Firewall Rules54]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2358_1445225205 End of the Wizard54]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2360_1445225205 Adding a User with a Certificate54]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2362_1445225205 Installing the OpenVPN Client Export Package57]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2364_1445225205 Exporting a Configuration57]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2366_1445225205 Firewall Logs60]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2368_1445225205 Setup Log File Location61]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2370_1445225205 Enable Module and UDP Protocol61]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2372_1445225205 Restart Rsyslog61]= NETWORK DIAGRAM =&lt;br /&gt;
[[Image:Gpil-000.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Installation&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;pfSense&#039;&#039;&#039; is an open source firewall/router computer software distribution based on FreeBSD. It is installed on a computer to make a dedicated firewall/router for a network and is noted for its reliability[1] and offering features often only found in expensive commercial firewalls&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Download pfSense&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Visit https://www.pfsense.org/download/mirror.php?section=downloads&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Step 1 :- &#039;&#039;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Performing a Full Install (LiveCD) ==&lt;br /&gt;
Power on the target system and connect the install media: Place the CD into the drive or plug the Memstick into a USB port. If the BIOS is set to boot from CD/USB, pfSense will start. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-001.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
As the operating system boots and pfSense starts, a prompt is presented with some choices and a countdown timer. At this prompt, press &#039;&#039;i&#039;&#039; to invoke the installer now.&lt;br /&gt;
&lt;br /&gt;
When the installer detects multiple disks in the system the first screen available provides the option &#039;&#039;&#039;Setup GEOM Mirror&#039;&#039;&#039;. Choose that option, pick the primary disk, the disk to use for the mirror copy, and then proceed with the installation as normal. &lt;br /&gt;
&lt;br /&gt;
The Quick/Easy install choice will target the GEOM mirror automatically&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-002.jpeg]]&lt;br /&gt;
&lt;br /&gt;
At the &#039;&#039;&#039;Select Task&#039;&#039;&#039; prompt, choose &#039;&#039;Quick/Easy Install&#039;&#039;. [[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-003.jpeg]]&lt;br /&gt;
&lt;br /&gt;
The install will proceed, wiping the target disk and installing pfSense. Copying files may take some time to finish. &lt;br /&gt;
&lt;br /&gt;
After the files have been copied to the target disk, a choice is presented to select the console type. &#039;&#039;Standard&#039;&#039; defaults to the VGA console. &#039;&#039;Embedded&#039;&#039; defaults to serial console&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-004.jpeg]]&lt;br /&gt;
&lt;br /&gt;
Now the system must reboot so that pfSense may start from the target disk. Select &#039;&#039;Reboot&#039;&#039; and then press &#039;&#039;&#039;Enter (remove CD from Drive)&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-005.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After the system reboots, pfSense will be running from the target disk. The next step is to Assign Interfaces on the Console below.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-006.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After installation and assignment, a shell menu is presented on the console with a number of options. pfSense now is ready to be accessed via the network, LAN interface IP 192.168.1.1 is assigned by default.&lt;br /&gt;
&lt;br /&gt;
Open a web browser and navigate to https://192.168.1.1/, using the default username admin and password pfsense to login.&lt;br /&gt;
&lt;br /&gt;
The first visit to the WebGUI will be redirected to the setup wizard.&lt;br /&gt;
&lt;br /&gt;
== GUI Configuration Setup ==&lt;br /&gt;
Once The Setup is launched, Fill the details are follows:-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-007.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We have defined FQDN as gipl.firewall&lt;br /&gt;
&lt;br /&gt;
DNS servers:- 8.8.8.8 and 4.4.2.2 Global DNS&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click NEXT&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-008.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select The Time-Zone as Asia/Kolkata .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
And Click NEXT&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-009.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Here we have Set WAN as Static Interface&lt;br /&gt;
&lt;br /&gt;
With IP address :- 203.77.200.91/25&lt;br /&gt;
&lt;br /&gt;
Gateway :- 203.77.200.1&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-010.jpg]]&lt;br /&gt;
&lt;br /&gt;
Here we have Configured LAN interface with IP address 192.168.45.101/24&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
( note:-As per the client Network Topology , Lan interface have multiple Subnets configured , so we will be configuring Virtual IP’s from GUI )&lt;br /&gt;
&lt;br /&gt;
After Setting Admin Password, Page will be redirected to Pfsense-Dashboard.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-011.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We Have Changed Default Port from 443 to 8080 Via :-&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;System &amp;gt; Advanced&#039;&#039;&#039;&lt;br /&gt;
[[Image:Gpil-012.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Change TCP Port from Default 443 to 8080 .&lt;br /&gt;
[[Image:Gpil-013.jpg]] &lt;br /&gt;
Save .&lt;br /&gt;
&lt;br /&gt;
Now pfsense Can be accessed via [https://IP:8080 https://IP:8080]&lt;br /&gt;
&lt;br /&gt;
IP Address of Firewall is 203.77.200.91 on WAN interface.&lt;br /&gt;
&lt;br /&gt;
Go to :- interface &amp;gt; assign , and edit Opt1 as DMZ , do not assign IP address to This interface , because we will be creating bridge interface .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bridge Interface ==&lt;br /&gt;
Now we have to configure &#039;&#039;&#039;Interface Bridges&#039;&#039;&#039; in order to Setup Pfsense in &lt;br /&gt;
&lt;br /&gt;
Transparent mode.&lt;br /&gt;
&lt;br /&gt;
Reference:- &amp;lt;u&amp;gt;https://doc.pfsense.org/index.php/Interface_Bridges&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Navigate To :- Interfaces &amp;gt; (assign) &lt;br /&gt;
&lt;br /&gt;
on the Bridges tab Click “ +” symbol to add a new bridge .&lt;br /&gt;
&lt;br /&gt;
Ctrl-Click to select the Member interfaces from the list of available interfaces and type a Description , we have selected WAN + DMZ as bridge0 and create new Interface BRIDGEINTERFACE using bridge0 .&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-014.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
By default, traffic is filtered on the member interfaces and not on the bridge interface itself. This behavior may be changed by toggling the values of &#039;&#039;&#039;net.link.bridge.pfil_member&#039;&#039;&#039; and net.link.bridge.pfil&#039;&#039;&#039;_bridge &#039;&#039;&#039;under System&#039;&#039;&#039; &amp;gt; Advanced &#039;&#039;&#039;on the &#039;&#039;&#039;System Tunables&#039;&#039;&#039; tab. With them set at &#039;&#039;0&#039;&#039; and &#039;&#039;1&#039;&#039;, respectively, then filtering would be performed on the bridge only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-015.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Pfsense is Configured In Bridge Mode with &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;WAN interface: - 203.77.200.91/25 gateway :- 203.77.200.1&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface:- 192.168.45.101/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;DMZ: - no ip &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;BRIDGEINTERFACE:- 203.77.200.92/25&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-016.jpg]]&lt;br /&gt;
&lt;br /&gt;
== Assign Virtual IP’s To LAN interface:- ==&lt;br /&gt;
[[Image:Gpil-018.jpg]]&lt;br /&gt;
Now as LAN environment have multiple Subnet configured, we will be assigning Virtual IP address to LAN interface.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-017.jpg]]&lt;br /&gt;
&lt;br /&gt;
Clients on LAN Environment have their Gateway Set from These Virtual IP’s.&lt;br /&gt;
&lt;br /&gt;
203.77.196.230 is added for outside access of Local Servers 203.77.192.49/28.&lt;br /&gt;
&lt;br /&gt;
(203.77.196.230) is configured in 203.77.192.2 switch which will receive any packet for 203.77.192.49/28 from Outside and send it to 203.77.196.230.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SNORT  ==&lt;br /&gt;
&amp;lt;u&amp;gt;&#039;&#039;&#039;Reference&#039;&#039;&#039;&amp;lt;/u&amp;gt; :- &amp;lt;u&amp;gt;&#039;&#039;&#039;https://doc.pfsense.org/index.php/Setup_Snort_Package&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Go to the &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab under the &#039;&#039;&#039;System&#039;&#039;&#039; menu and install the snort package.&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;When the installation completes, click on &#039;&#039;&#039;Snort&#039;&#039;&#039; under the &#039;&#039;&#039;Services&#039;&#039;&#039; menu. &amp;amp;nbsp;This will open the Snort main setup page.&lt;br /&gt;
&lt;br /&gt;
Click the &#039;&#039;&#039;Global Settings&#039;&#039;&#039; tab and perform the following At the top of the page you have three choices for Rule Sets to activate.&lt;br /&gt;
&lt;br /&gt;
Put Check mark on :-Install &#039;&#039;&#039;Snort Community&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Emerging Threats&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Snort VRT&#039;&#039;&#039; rules. And save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Updates&#039;&#039;&#039; tab is used to check the status of downloaded rules packages and to download new updates. The table shows the available rule packages and their current status [[Image:Gpil-019.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Update Button to Update the rules.&lt;br /&gt;
[[Image:Gpil-020.jpeg]]&lt;br /&gt;
&lt;br /&gt;
== Add Snort to an interface ==&lt;br /&gt;
Click the Snort Interfaces tab and then the &amp;quot;+&amp;quot; icon to add a new Snort interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;On the &#039;&#039;&#039;WAN Settings&#039;&#039;&#039; tab, click the &#039;&#039;Enable&#039;&#039; checkbox.In the drop-down, choose the interface. &amp;amp;nbsp;The WAN interface is the default and is a good first choice.In the &#039;&#039;Description&#039;&#039; textbox, enter a name (WAN again, is fine here).Click the checkbox to &amp;quot;&#039;&#039;Send alerts to the main System logs&#039;&#039;&amp;quot;.leave the other settings at their defaults&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-021.jpg]]&lt;br /&gt;
&lt;br /&gt;
After saving, the browser will be returned to the Snort Interfaces tab. Note the warning icons in the image below showing no rules have been selected for the new Snort interface. Those rules will be configured next. Click the &amp;quot;e&amp;quot; icon to edit the new Snort interface again&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-024.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Select which types of rules will protect the network ==&lt;br /&gt;
Click the &#039;&#039;&#039;Categories&#039;&#039;&#039; tab for the new interface&lt;br /&gt;
&lt;br /&gt;
Check [https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=GPLv2_community.rules Snort GPLv2 Community Rules (VRT certified)] Box .&lt;br /&gt;
&lt;br /&gt;
And Manual Rules :-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-botcc.rules emerging-botcc.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_blacklist.rules snort_blacklist.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.so.rules snort_exploit-kit.so.rules] &lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_ddos.rules snort_ddos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_dos.rules snort_dos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.rules snort_exploit-kit.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-malware.rules emerging-malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-mobile_malware.rules emerging-mobile_malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-tor.rules emerging-tor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-trojan.rules emerging-trojan.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_malware-backdoor.rules snort_malware-backdoor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_virus.rules snort_virus.rules]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-023.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click SAVE when finished to save the selection and build the rules &lt;br /&gt;
&lt;br /&gt;
After that restart the service &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-024.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Managing Pass lists:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Pass Lists are lists of IP addresses that Snort should never block. These may be created and managed on the Pass Lists tab. When an IP address is listed on a Pass List, Snort will never insert a block on that address even when malicious traffic is detected.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;To create a new Pass List, click &amp;quot;+&amp;quot;. To edit an existing Pass List, click the &amp;quot;e&amp;quot;. To delete a Pass List, click &amp;quot;x&amp;quot;. Note that a Pass List may not be deleted if it is currently assigned to one or more Snort interfaces.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We have added GIPL IP’s in Pass list . i.e&#039;&#039;&#039; &amp;lt;u&amp;gt;203.77.192.0/20&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-025.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== IP Alias and Port Alias ==&lt;br /&gt;
IP aliases allow you to create a group of IP addresses that you can assign by group name instead of specifying each IP address individually. This can be great for specifying a group of servers that need ssh access and then in the firewall rules you can create a rule that allows ssh traffic for the ssh servers group.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Along the top menu hover over Firewall and click on Aliases.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-026.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The next tab is for setting up Port Aliases. &amp;amp;nbsp;Similar to the IP Aliases you can setup groups but on this tab you are creating groups of ports instead of IP addresses.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-027.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
IP Aliases Created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-028.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
PORT ALIAS CREATED&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-029.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Firewall Rules :- ==&lt;br /&gt;
Reference:- [https://doc.pfsense.org/index.php/Firewall_Rule_Basics https://doc.pfsense.org/index.php/Firewall_Rule_Basics]&lt;br /&gt;
&lt;br /&gt;
Firewall rules control what traffic is allowed to enter an interface on the firewall. Once traffic is passed on the interface it enters an entry in the state table is created. A state table entry allows through subsequent packets that are part of that connection.&lt;br /&gt;
&lt;br /&gt;
Firewall rules are managed at Firewall &amp;gt; Rules. Multiple rules may be selected for some actions by clicking on their row or checking the box at the start of their row. Rules may be deleted or reordered in bulk in this way. See Managing Lists of Items on pfSense for more information on the meaning of the icons when manipulating rules.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;any&#039;&#039;&#039; - &#039;&#039;0.0.0.0&#039;&#039; to &#039;&#039;255.255.255.255&#039;&#039;, or all IPv6 addresses &lt;br /&gt;
* &#039;&#039;&#039;Single host or alias&#039;&#039;&#039; - Select this and enter one IP address (&#039;&#039;1.2.3.4&#039;&#039;, &#039;&#039;aa:bb:cc:dd::1&#039;&#039;) or type the name of an Alias that has already been configured (&#039;&#039;&#039;Firewall &amp;gt; Aliases&#039;&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Network&#039;&#039;&#039; - Select this and enter a network and mask (&#039;&#039;10.99.0.0/16&#039;&#039;, &#039;&#039;aa:bb:cc:dd::0/64&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;LAN net&#039;&#039;&#039; - The subnet configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039;. On pfSense 2.2+, this also includes static route networks on that interface. &lt;br /&gt;
* &#039;&#039;&#039;LAN address&#039;&#039;&#039; - The IP address configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039; &lt;br /&gt;
* &#039;&#039;&#039;zzz Net&#039;&#039;&#039; / &#039;&#039;&#039;zzz address&#039;&#039;&#039; - Works the same as LAN above but for other interfaces (WAN, OPT1, OPT2, etc.) &lt;br /&gt;
* &#039;&#039;&#039;PPTP clients&#039;&#039;&#039; - Automatically locate and use the addresses of PPTP clients &lt;br /&gt;
* &#039;&#039;&#039;L2TP clients&#039;&#039;&#039; - Automatically locate and use the addresses of L2TP clients &lt;br /&gt;
* &#039;&#039;&#039;This Firewall (self)&#039;&#039;&#039; - Any IP address assigned to any interface on this firewall (pfSense 2.2+) &lt;br /&gt;
&lt;br /&gt;
Firewall rules are generally processed starting with Floating Rules, then Interface Group rules, then Interface tab rules&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Rules Created on bridge interface, for DMZ access&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-030.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-031.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface Rules Created:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-032.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Squid and Squidguard:- ==&lt;br /&gt;
&#039;&#039;&#039;Reference - &#039;&#039;&#039;[https://doc.pfsense.org/index.php/SquidGuard_package https://doc.pfsense.org/index.php/SquidGuard_package]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Login to your pfsense&#039;s Web Administrator, and click on &amp;quot;Server -&amp;gt; Packages&amp;quot;, scroll down the list and find squid and click on &amp;quot;+&amp;quot; button to install, wait for the process to finish then return to the packages section and look for squidguard and install that package as well.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-033.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now go to &amp;quot;Services&amp;quot; menu and look for Proxy Server &amp;amp; Proxy Filter &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-034.jpg]]&lt;br /&gt;
&lt;br /&gt;
(We are setting up the proxy server as a transparent proxy)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on Services -&amp;gt; Proxy Server.&lt;br /&gt;
&lt;br /&gt;
On the General Tab, you want to set the following settings, the Proxy Interface Option should be set to &amp;quot;LAN&amp;quot;, to set up transparent proxy server, tick the &amp;quot;Transparent Proxy&amp;quot; check box.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-035.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Tick the &amp;quot;Enabled Logging&amp;quot; Checkbox, set the log store to the default location &amp;quot; /var/squid/logs &amp;quot; rotate your logs every 30 days, set your proxy port to port number 3128 We have By-passed Proxy for 203.77.192.49/28, These are the Local Servers.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next click on the &amp;quot;Cache Mgmt.&amp;quot; tab, by default the Hard Disk Cache Size is set to 100mb, we have allocated 100GB , Memory Cache Size 3072 .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-036.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click on Save.&lt;br /&gt;
&lt;br /&gt;
Click on the Access Control Tab next, in the allowed subnets field type in your required subnets. As we have multiple Subnets, so we are going to define all.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-037.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.129/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.1.224.1/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.192.49/28&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.57/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.17/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.137/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.33.50.1/27&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click On Save &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that’s is the proxy server configured, next we are going to configure SquidGuard, click on the Services menu and select the Proxy Filter button, tick the following 3 check boxes &amp;quot;Enable&amp;quot;, &amp;quot;Enable GUI Log&amp;quot; and &amp;quot;Enable Log&amp;quot; then click the Save button, once the page has reloaded click on apply and then confirm that the Squidguard service is running by making sure the SquidGuard status is set to STARTED.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-038.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on the Black list tab and add URL &#039;&#039;&#039;http://www.shallalist.de/Downloads/shallalist.tar.gz&#039;&#039;&#039; to the Update Address and click on Download. Wait for the process to complete.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-039.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-040.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now we can set up common ACL’s&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-041.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-042.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Click on Save and restart the Squid and SquidGuard from Services. &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SARG:- ==&lt;br /&gt;
After Installing SARG package, we can configure SARG from Status &amp;gt; Sarg Reports&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-043.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select Proxy Servers as SQUID proxy . And leave Rest of Field set to Default&lt;br /&gt;
&lt;br /&gt;
And Save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Go to Next Tab Schedule&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click “+” Symbol to create new schedule &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-044.jpg]] &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Reports can be viewed From “View Reports”&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-045.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bandwidthd:- ==&lt;br /&gt;
After Installing Package &#039;&#039;&#039;bandwidthd&#039;&#039;&#039; , Configuration can be done via&lt;br /&gt;
&lt;br /&gt;
Services &amp;gt; bandwidthd&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-046.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-047.jpg]]&lt;br /&gt;
&lt;br /&gt;
Enable Bandwidthd by checking the BOX.&lt;br /&gt;
&lt;br /&gt;
Now Select the Interface: - LAN.&lt;br /&gt;
&lt;br /&gt;
Enter The Subnets from LAN interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Save and Restart bandwidthd service from Services.&lt;br /&gt;
&lt;br /&gt;
Now Bandwidthd can be accessed:-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/bandwidthd/index.html https://203.77.200.91:8080/bandwidthd/index.html]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of ntopng:- ==&lt;br /&gt;
After installing ntopng package, it appears under Diagnostics &amp;gt; ntopng. It will even track where connections were made by local PCs, and how much bandwidth was used on individual connections.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-048.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
First we have to configure ntopng settings. Via Diagnostics &amp;gt; ntopng settings.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-049.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Setup Admin Password &amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Select the Interfaces on Which ntopng will be monitoring traffic.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We have selected LAN, DMZ and BRIDGEINTERFACE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To save the changes Click “Change”&lt;br /&gt;
&lt;br /&gt;
Ntopng can be accessed via [http://203.77.200.91:3000/login.html http://203.77.200.91:3000/login.html]&lt;br /&gt;
&lt;br /&gt;
With username admin and password assigned in previous step.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Configuring OpenVPN  =&lt;br /&gt;
A VPN (virtual private network) allows us to connect directly to our home private network over the internet&lt;br /&gt;
&lt;br /&gt;
The certificate authority or CA will sign the certificates that we will be creating for the server and client side when we configure OpenVPN. You can access the certificate configuration by going over to System–&amp;gt;Cert Manager.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-050.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Under the CAs tab you might already have a CA created if you followed one of my previous articles as we needed to created one in order to sign an internal certificate to be used for securing the pfSense web interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Certificate Authority ===&lt;br /&gt;
Fill in the fields to &#039;&#039;&#039;create a new Certificate Authority&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Descriptive Name&#039;&#039;&#039; - Used as the Common Name (CN) for the CA. Do not spaces, punctuation or special characters (ex: &#039;&#039;VPN Server CA&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Key Length&#039;&#039;&#039; - Default is OK, the higher the better but will use more CPU. &lt;br /&gt;
* &#039;&#039;&#039;Lifetime&#039;&#039;&#039; - Default is OK, but can be lowered if it must be changed out more often. &lt;br /&gt;
* &#039;&#039;&#039;Country Code&#039;&#039;&#039;, &#039;&#039;&#039;State/Province&#039;&#039;&#039;, &#039;&#039;&#039;City&#039;&#039;&#039;, &#039;&#039;&#039;Organization&#039;&#039;&#039; - Enter values for this location/company. &lt;br /&gt;
* &#039;&#039;&#039;E-mail&#039;&#039;&#039; - Used as a reference on the certificate, does not receive any mail from the system. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Add New CA&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-051.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
After you finished setting up the CA the next step is to create some certificates that the recently created CA will sign for us. Since these are self-signed certificates most browsers will give you a warning&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Server Certificate ===&lt;br /&gt;
Fill in the fields to create a new &#039;&#039;&#039;Server Certificate&#039;&#039;&#039;. Similar Fields as CA entry, most of the fields carry over and do not need changed. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Create new Certificate&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-052.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that we have all the components in place we can configure OpenVPN. Head over to VPN–&amp;gt;OpenVPN.&lt;br /&gt;
&lt;br /&gt;
.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-053.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select “Wizards” from the tab at the top which will guide us step by step to configure OpenVPN&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-054.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-055.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We will select the local user access database provided by pfSense&lt;br /&gt;
&lt;br /&gt;
In the next step we will be selecting the CA that we created at the beginning of this article.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-056.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Following is the Server Certificate that we will be using which is the Certificate that we recently created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-057.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;OpenVPN Server Configuration&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;TLS Authentication&#039;&#039;&#039; -- Leave this checked, along with the box underneath to generate a new key. Using a TLS key is technically optional, but &#039;&#039;highly&#039;&#039; recommended&lt;br /&gt;
* &#039;&#039;&#039;Tunnel Network&#039;&#039;&#039; -- Should be a new, unique network that does not exist anywhere in the current network or routing table. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-058.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-059.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-060.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== Firewall Rules ===&lt;br /&gt;
The next screen offers the choice to add firewall rules automatically. For convenience, check both unless the rules will be managed manually. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== End of the Wizard ===&lt;br /&gt;
Click &#039;&#039;&#039;Finish&#039;&#039;&#039; to exit the wizard and the new settings will be saved and applied automatically. &lt;br /&gt;
&lt;br /&gt;
== Adding a User with a Certificate ==&lt;br /&gt;
Navigate to &#039;&#039;&#039;System &amp;gt; User Manager&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click &amp;quot;+&amp;quot; To add a &#039;&#039;&#039;user&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Username&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Password / Confirm password&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Check Click to create a &#039;&#039;&#039;user certificate.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in the Descriptive Name as the username&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-061.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-062.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The OpenVPN Client Export Package allows exporting configurations formatted for a wide variety of platforms. It also allows exporting a pre-packaged Windows installer executable which includes the configuration bundled inside for a painly client installation. &lt;br /&gt;
&lt;br /&gt;
=== Installing the OpenVPN Client Export Package ===&lt;br /&gt;
To Install the OpenVPN Client Export Package &lt;br /&gt;
&lt;br /&gt;
* Navigate to &#039;&#039;&#039;System &amp;gt; Packages&#039;&#039;&#039;, &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab &lt;br /&gt;
* Find &#039;&#039;&#039;OpenVPN Client Export Package&#039;&#039;&#039; in the list &lt;br /&gt;
&lt;br /&gt;
=== Exporting a Configuration ===&lt;br /&gt;
* Navigate to &#039;&#039;&#039;VPN &amp;gt; OpenVPN&#039;&#039;&#039; on the &#039;&#039;&#039;Client Export&#039;&#039;&#039; tab &lt;br /&gt;
* Choose the VPN from the &#039;&#039;&#039;Remote Access Server&#039;&#039;&#039; drop-down list &lt;br /&gt;
* Find the user in the list at the bottom of the page and select the appropriate configuration type to export. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-063.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-064.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Multiple instance of VPN server can be created with different tunnel network &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-065.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Firewall Rules are applied as per the requirement on tunnel network .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-066.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Firewall Logs =&lt;br /&gt;
The Firewall logs at &#039;&#039;&#039;Status &amp;gt; System Logs&#039;&#039;&#039; on the &#039;&#039;&#039;Firewall&#039;&#039;&#039; tab show all events logged by the firewall.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Each entry is displayed with the action ( pass or block, reject is only logged as block), time, interface, source, destination, and protocol.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Configuration Of rsyslog Server for Logs Storage:-&lt;br /&gt;
&lt;br /&gt;
Status: &amp;gt;System logs &amp;gt; Settings&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-067.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Configuration of rsyslog on Centos :-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Setup Log File Location =====&lt;br /&gt;
Now edit Rsyslog configuration file and configure the location’s to generate log files in system.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# vim /etc/rsyslog.conf&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
and add following lines as the end of file.&lt;br /&gt;
&lt;br /&gt;
$template TmplAuth, &amp;quot;/var/log/%HOSTNAME%/%PROGRAMNAME%.log&amp;quot; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
authpriv.* ?TmplAuth&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;*.info,mail.none,authpriv.none,cron.none &amp;lt;/nowiki&amp;gt;?TmplMsg&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Enable Module and UDP Protocol =====&lt;br /&gt;
Also remove comment from following lines ( remove starting # ) in rsyslog configuration file to enable UDP.&lt;br /&gt;
&lt;br /&gt;
$ModLoad imudp&lt;br /&gt;
&lt;br /&gt;
$UDPServerRun 514&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Restart Rsyslog  =====&lt;br /&gt;
After making above changes in Rsyslog central server, restart service using following command.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# service rsyslog restart&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Logrotation:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Create file&#039;&#039;&#039; :- &#039;&#039;&#039;/etc/logrotate.d/pfsense&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;And enter:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/var/log/pfsense/filterlog.log&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;{&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;daily&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;missingok&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;rotate 60&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;compress&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;notifempty&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;create 640 root root&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;postrotate&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/etc/init.d/rsyslog restart &amp;gt;/dev/null&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;endscript&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;}&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Save and Quit.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;RRD Graphs:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
These are located under &#039;&#039;&#039;Status &amp;gt; RRD Graphs&#039;&#039;&#039;. Several graphs are presented for each monitored item, with varying time intervals and averages. &lt;br /&gt;
&lt;br /&gt;
These graphs measure things such as CPU usage, memory usage, state table usage, throughput (in bytes as well as packets), link quality, traffic shaping queue usage, and so on. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-068.jpg]]&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1896</id>
		<title>PF Sense Firewall Implementation at GIPL</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1896"/>
		<updated>2015-04-16T10:43:50Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;center&amp;gt;&amp;lt;u&amp;gt;&#039;&#039;&#039;PF Sense Firewall Implementation at GIPL , GandhiNagar &#039;&#039;&#039;&amp;lt;/u&amp;gt;&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Table of Contents ==&lt;br /&gt;
[#__RefHeading__2322_1445225205 NETWORK DIAGRAM2]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2324_1445225205 Performing a Full Install (LiveCD)3]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2326_1445225205 GUI Configuration Setup8]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2328_1445225205 Configuration Of Bridge Interface13]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2330_1445225205 Assign Virtual IP’s To LAN interface:-15]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2332_1445225205 Configuration of SNORT17]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2334_1445225205 Add Snort to an interface20]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2336_1445225205 Select which types of rules will protect the network22]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2338_1445225205 IP Alias and Port Alias24]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2340_1445225205 Firewall Rules :-27]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2342_1445225205 Configuration Of Squid and Squidguard:-31]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2344_1445225205 Configuration of SARG:-39]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2346_1445225205 Configuration Of Bandwidthd:-42]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2348_1445225205 Configuration Of ntopng:-44]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2350_1445225205 Configuring OpenVPN46]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2352_1445225205 Certificate Authority47]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2354_1445225205 Server Certificate48]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2356_1445225205 Firewall Rules54]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2358_1445225205 End of the Wizard54]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2360_1445225205 Adding a User with a Certificate54]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2362_1445225205 Installing the OpenVPN Client Export Package57]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2364_1445225205 Exporting a Configuration57]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2366_1445225205 Firewall Logs60]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2368_1445225205 Setup Log File Location61]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2370_1445225205 Enable Module and UDP Protocol61]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2372_1445225205 Restart Rsyslog61]= NETWORK DIAGRAM =&lt;br /&gt;
[[Image:Gpil-000.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Installation&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;pfSense&#039;&#039;&#039; is an open source firewall/router computer software distribution based on FreeBSD. It is installed on a computer to make a dedicated firewall/router for a network and is noted for its reliability[1] and offering features often only found in expensive commercial firewalls&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Download pfSense&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Visit https://www.pfsense.org/download/mirror.php?section=downloads&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Step 1 :- &#039;&#039;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Performing a Full Install (LiveCD) ==&lt;br /&gt;
Power on the target system and connect the install media: Place the CD into the drive or plug the Memstick into a USB port. If the BIOS is set to boot from CD/USB, pfSense will start. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-001.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
As the operating system boots and pfSense starts, a prompt is presented with some choices and a countdown timer. At this prompt, press &#039;&#039;i&#039;&#039; to invoke the installer now.&lt;br /&gt;
&lt;br /&gt;
When the installer detects multiple disks in the system the first screen available provides the option &#039;&#039;&#039;Setup GEOM Mirror&#039;&#039;&#039;. Choose that option, pick the primary disk, the disk to use for the mirror copy, and then proceed with the installation as normal. &lt;br /&gt;
&lt;br /&gt;
The Quick/Easy install choice will target the GEOM mirror automatically&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-002.jpeg]]&lt;br /&gt;
&lt;br /&gt;
At the &#039;&#039;&#039;Select Task&#039;&#039;&#039; prompt, choose &#039;&#039;Quick/Easy Install&#039;&#039;. [[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-003.jpeg]]&lt;br /&gt;
&lt;br /&gt;
The install will proceed, wiping the target disk and installing pfSense. Copying files may take some time to finish. &lt;br /&gt;
&lt;br /&gt;
After the files have been copied to the target disk, a choice is presented to select the console type. &#039;&#039;Standard&#039;&#039; defaults to the VGA console. &#039;&#039;Embedded&#039;&#039; defaults to serial console&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-004.jpeg]]&lt;br /&gt;
&lt;br /&gt;
Now the system must reboot so that pfSense may start from the target disk. Select &#039;&#039;Reboot&#039;&#039; and then press &#039;&#039;&#039;Enter (remove CD from Drive)&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-005.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After the system reboots, pfSense will be running from the target disk. The next step is to Assign Interfaces on the Console below.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-006.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After installation and assignment, a shell menu is presented on the console with a number of options. pfSense now is ready to be accessed via the network, LAN interface IP 192.168.1.1 is assigned by default.&lt;br /&gt;
&lt;br /&gt;
Open a web browser and navigate to https://192.168.1.1/, using the default username admin and password pfsense to login.&lt;br /&gt;
&lt;br /&gt;
The first visit to the WebGUI will be redirected to the setup wizard.&lt;br /&gt;
&lt;br /&gt;
== GUI Configuration Setup ==&lt;br /&gt;
Once The Setup is launched, Fill the details are follows:-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-007.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We have defined FQDN as gipl.firewall&lt;br /&gt;
&lt;br /&gt;
DNS servers:- 8.8.8.8 and 4.4.2.2 Global DNS&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click NEXT&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-008.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select The Time-Zone as Asia/Kolkata .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
And Click NEXT&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-009.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Here we have Set WAN as Static Interface&lt;br /&gt;
&lt;br /&gt;
With IP address :- 203.77.200.91/25&lt;br /&gt;
&lt;br /&gt;
Gateway :- 203.77.200.1&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-010.jpg]]&lt;br /&gt;
&lt;br /&gt;
Here we have Configured LAN interface with IP address 192.168.45.101/24&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
( note:-As per the client Network Topology , Lan interface have multiple Subnets configured , so we will be configuring Virtual IP’s from GUI )&lt;br /&gt;
&lt;br /&gt;
After Setting Admin Password, Page will be redirected to Pfsense-Dashboard.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-011.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We Have Changed Default Port from 443 to 8080 Via :-&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;System &amp;gt; Advanced&#039;&#039;&#039;&lt;br /&gt;
[[Image:Gpil-012.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Change TCP Port from Default 443 to 8080 .&lt;br /&gt;
[[Image:Gpil-013.jpg]] &lt;br /&gt;
Save .&lt;br /&gt;
&lt;br /&gt;
Now pfsense Can be accessed via [https://IP:8080 https://IP:8080]&lt;br /&gt;
&lt;br /&gt;
IP Address of Firewall is 203.77.200.91 on WAN interface.&lt;br /&gt;
&lt;br /&gt;
Go to :- interface &amp;gt; assign , and edit Opt1 as DMZ , do not assign IP address to This interface , because we will be creating bridge interface .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bridge Interface ==&lt;br /&gt;
Now we have to configure &#039;&#039;&#039;Interface Bridges&#039;&#039;&#039; in order to Setup Pfsense in &lt;br /&gt;
&lt;br /&gt;
Transparent mode.&lt;br /&gt;
&lt;br /&gt;
Reference:- &amp;lt;u&amp;gt;https://doc.pfsense.org/index.php/Interface_Bridges&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Navigate To :- Interfaces &amp;gt; (assign) &lt;br /&gt;
&lt;br /&gt;
on the Bridges tab Click “ +” symbol to add a new bridge .&lt;br /&gt;
&lt;br /&gt;
Ctrl-Click to select the Member interfaces from the list of available interfaces and type a Description , we have selected WAN + DMZ as bridge0 and create new Interface BRIDGEINTERFACE using bridge0 .&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-014.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
By default, traffic is filtered on the member interfaces and not on the bridge interface itself. This behavior may be changed by toggling the values of &#039;&#039;&#039;net.link.bridge.pfil_member&#039;&#039;&#039; and net.link.bridge.pfil&#039;&#039;&#039;_bridge &#039;&#039;&#039;under System&#039;&#039;&#039; &amp;gt; Advanced &#039;&#039;&#039;on the &#039;&#039;&#039;System Tunables&#039;&#039;&#039; tab. With them set at &#039;&#039;0&#039;&#039; and &#039;&#039;1&#039;&#039;, respectively, then filtering would be performed on the bridge only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-015.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Pfsense is Configured In Bridge Mode with &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;WAN interface: - 203.77.200.91/25 gateway :- 203.77.200.1&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface:- 192.168.45.101/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;DMZ: - no ip &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;BRIDGEINTERFACE:- 203.77.200.92/25&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-016.jpg]]&lt;br /&gt;
&lt;br /&gt;
== Assign Virtual IP’s To LAN interface:- ==&lt;br /&gt;
[[Image:Gpil-018.jpg]]&lt;br /&gt;
Now as LAN environment have multiple Subnet configured, we will be assigning Virtual IP address to LAN interface.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-017.jpg]]&lt;br /&gt;
&lt;br /&gt;
Clients on LAN Environment have their Gateway Set from These Virtual IP’s.&lt;br /&gt;
&lt;br /&gt;
203.77.196.230 is added for outside access of Local Servers 203.77.192.49/28.&lt;br /&gt;
&lt;br /&gt;
(203.77.196.230) is configured in 203.77.192.2 switch which will receive any packet for 203.77.192.49/28 from Outside and send it to 203.77.196.230.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SNORT  ==&lt;br /&gt;
&amp;lt;u&amp;gt;&#039;&#039;&#039;Reference&#039;&#039;&#039;&amp;lt;/u&amp;gt; :- &amp;lt;u&amp;gt;&#039;&#039;&#039;https://doc.pfsense.org/index.php/Setup_Snort_Package&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Go to the &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab under the &#039;&#039;&#039;System&#039;&#039;&#039; menu and install the snort package.&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;When the installation completes, click on &#039;&#039;&#039;Snort&#039;&#039;&#039; under the &#039;&#039;&#039;Services&#039;&#039;&#039; menu. &amp;amp;nbsp;This will open the Snort main setup page.&lt;br /&gt;
&lt;br /&gt;
Click the &#039;&#039;&#039;Global Settings&#039;&#039;&#039; tab and perform the following At the top of the page you have three choices for Rule Sets to activate.&lt;br /&gt;
&lt;br /&gt;
Put Check mark on :-Install &#039;&#039;&#039;Snort Community&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Emerging Threats&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Snort VRT&#039;&#039;&#039; rules. And save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Updates&#039;&#039;&#039; tab is used to check the status of downloaded rules packages and to download new updates. The table shows the available rule packages and their current status [[Image:Gpil-019.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Update Button to Update the rules.&lt;br /&gt;
[[Image:Gpil-020.jpeg]]&lt;br /&gt;
&lt;br /&gt;
== Add Snort to an interface ==&lt;br /&gt;
Click the Snort Interfaces tab and then the &amp;quot;+&amp;quot; icon to add a new Snort interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;On the &#039;&#039;&#039;WAN Settings&#039;&#039;&#039; tab, click the &#039;&#039;Enable&#039;&#039; checkbox.In the drop-down, choose the interface. &amp;amp;nbsp;The WAN interface is the default and is a good first choice.In the &#039;&#039;Description&#039;&#039; textbox, enter a name (WAN again, is fine here).Click the checkbox to &amp;quot;&#039;&#039;Send alerts to the main System logs&#039;&#039;&amp;quot;.leave the other settings at their defaults&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-021.jpg]]&lt;br /&gt;
&lt;br /&gt;
After saving, the browser will be returned to the Snort Interfaces tab. Note the warning icons in the image below showing no rules have been selected for the new Snort interface. Those rules will be configured next. Click the &amp;quot;e&amp;quot; icon to edit the new Snort interface again&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-024.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Select which types of rules will protect the network ==&lt;br /&gt;
Click the &#039;&#039;&#039;Categories&#039;&#039;&#039; tab for the new interface&lt;br /&gt;
&lt;br /&gt;
Check [https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=GPLv2_community.rules Snort GPLv2 Community Rules (VRT certified)] Box .&lt;br /&gt;
&lt;br /&gt;
And Manual Rules :-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-botcc.rules emerging-botcc.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_blacklist.rules snort_blacklist.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.so.rules snort_exploit-kit.so.rules] &lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_ddos.rules snort_ddos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_dos.rules snort_dos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.rules snort_exploit-kit.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-malware.rules emerging-malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-mobile_malware.rules emerging-mobile_malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-tor.rules emerging-tor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-trojan.rules emerging-trojan.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_malware-backdoor.rules snort_malware-backdoor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_virus.rules snort_virus.rules]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-023.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click SAVE when finished to save the selection and build the rules &lt;br /&gt;
&lt;br /&gt;
After that restart the service &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-024.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Managing Pass lists:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Pass Lists are lists of IP addresses that Snort should never block. These may be created and managed on the Pass Lists tab. When an IP address is listed on a Pass List, Snort will never insert a block on that address even when malicious traffic is detected.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;To create a new Pass List, click &amp;quot;+&amp;quot;. To edit an existing Pass List, click the &amp;quot;e&amp;quot;. To delete a Pass List, click &amp;quot;x&amp;quot;. Note that a Pass List may not be deleted if it is currently assigned to one or more Snort interfaces.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We have added GIPL IP’s in Pass list . i.e&#039;&#039;&#039; &amp;lt;u&amp;gt;203.77.192.0/20&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-025.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== IP Alias and Port Alias ==&lt;br /&gt;
IP aliases allow you to create a group of IP addresses that you can assign by group name instead of specifying each IP address individually. This can be great for specifying a group of servers that need ssh access and then in the firewall rules you can create a rule that allows ssh traffic for the ssh servers group.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Along the top menu hover over Firewall and click on Aliases.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-026.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The next tab is for setting up Port Aliases. &amp;amp;nbsp;Similar to the IP Aliases you can setup groups but on this tab you are creating groups of ports instead of IP addresses.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-027.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
IP Aliases Created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-028.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
PORT ALIAS CREATED&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-029.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Firewall Rules :- ==&lt;br /&gt;
Reference:- [https://doc.pfsense.org/index.php/Firewall_Rule_Basics https://doc.pfsense.org/index.php/Firewall_Rule_Basics]&lt;br /&gt;
&lt;br /&gt;
Firewall rules control what traffic is allowed to enter an interface on the firewall. Once traffic is passed on the interface it enters an entry in the state table is created. A state table entry allows through subsequent packets that are part of that connection.&lt;br /&gt;
&lt;br /&gt;
Firewall rules are managed at Firewall &amp;gt; Rules. Multiple rules may be selected for some actions by clicking on their row or checking the box at the start of their row. Rules may be deleted or reordered in bulk in this way. See Managing Lists of Items on pfSense for more information on the meaning of the icons when manipulating rules.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;any&#039;&#039;&#039; - &#039;&#039;0.0.0.0&#039;&#039; to &#039;&#039;255.255.255.255&#039;&#039;, or all IPv6 addresses &lt;br /&gt;
* &#039;&#039;&#039;Single host or alias&#039;&#039;&#039; - Select this and enter one IP address (&#039;&#039;1.2.3.4&#039;&#039;, &#039;&#039;aa:bb:cc:dd::1&#039;&#039;) or type the name of an Alias that has already been configured (&#039;&#039;&#039;Firewall &amp;gt; Aliases&#039;&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Network&#039;&#039;&#039; - Select this and enter a network and mask (&#039;&#039;10.99.0.0/16&#039;&#039;, &#039;&#039;aa:bb:cc:dd::0/64&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;LAN net&#039;&#039;&#039; - The subnet configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039;. On pfSense 2.2+, this also includes static route networks on that interface. &lt;br /&gt;
* &#039;&#039;&#039;LAN address&#039;&#039;&#039; - The IP address configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039; &lt;br /&gt;
* &#039;&#039;&#039;zzz Net&#039;&#039;&#039; / &#039;&#039;&#039;zzz address&#039;&#039;&#039; - Works the same as LAN above but for other interfaces (WAN, OPT1, OPT2, etc.) &lt;br /&gt;
* &#039;&#039;&#039;PPTP clients&#039;&#039;&#039; - Automatically locate and use the addresses of PPTP clients &lt;br /&gt;
* &#039;&#039;&#039;L2TP clients&#039;&#039;&#039; - Automatically locate and use the addresses of L2TP clients &lt;br /&gt;
* &#039;&#039;&#039;This Firewall (self)&#039;&#039;&#039; - Any IP address assigned to any interface on this firewall (pfSense 2.2+) &lt;br /&gt;
&lt;br /&gt;
Firewall rules are generally processed starting with Floating Rules, then Interface Group rules, then Interface tab rules&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Rules Created on bridge interface, for DMZ access&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-030.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-031.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface Rules Created:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-032.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Squid and Squidguard:- ==&lt;br /&gt;
&#039;&#039;&#039;Reference - &#039;&#039;&#039;[https://doc.pfsense.org/index.php/SquidGuard_package https://doc.pfsense.org/index.php/SquidGuard_package]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Login to your pfsense&#039;s Web Administrator, and click on &amp;quot;Server -&amp;gt; Packages&amp;quot;, scroll down the list and find squid and click on &amp;quot;+&amp;quot; button to install, wait for the process to finish then return to the packages section and look for squidguard and install that package as well.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-033.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now go to &amp;quot;Services&amp;quot; menu and look for Proxy Server &amp;amp; Proxy Filter &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-034.jpg]]&lt;br /&gt;
&lt;br /&gt;
(We are setting up the proxy server as a transparent proxy)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on Services -&amp;gt; Proxy Server.&lt;br /&gt;
&lt;br /&gt;
On the General Tab, you want to set the following settings, the Proxy Interface Option should be set to &amp;quot;LAN&amp;quot;, to set up transparent proxy server, tick the &amp;quot;Transparent Proxy&amp;quot; check box.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-035.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Tick the &amp;quot;Enabled Logging&amp;quot; Checkbox, set the log store to the default location &amp;quot; /var/squid/logs &amp;quot; rotate your logs every 30 days, set your proxy port to port number 3128 We have By-passed Proxy for 203.77.192.49/28, These are the Local Servers.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next click on the &amp;quot;Cache Mgmt.&amp;quot; tab, by default the Hard Disk Cache Size is set to 100mb, we have allocated 100GB , Memory Cache Size 3072 .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-036.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click on Save.&lt;br /&gt;
&lt;br /&gt;
Click on the Access Control Tab next, in the allowed subnets field type in your required subnets. As we have multiple Subnets, so we are going to define all.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-037.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.129/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.1.224.1/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.192.49/28&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.57/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.17/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.137/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.33.50.1/27&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click On Save &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that’s is the proxy server configured, next we are going to configure SquidGuard, click on the Services menu and select the Proxy Filter button, tick the following 3 check boxes &amp;quot;Enable&amp;quot;, &amp;quot;Enable GUI Log&amp;quot; and &amp;quot;Enable Log&amp;quot; then click the Save button, once the page has reloaded click on apply and then confirm that the Squidguard service is running by making sure the SquidGuard status is set to STARTED.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-038.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on the Black list tab and add URL &#039;&#039;&#039;http://www.shallalist.de/Downloads/shallalist.tar.gz&#039;&#039;&#039; to the Update Address and click on Download. Wait for the process to complete.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-039.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-040.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now we can set up common ACL’s&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-041.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-042.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Click on Save and restart the Squid and SquidGuard from Services. &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SARG:- ==&lt;br /&gt;
After Installing SARG package, we can configure SARG from Status &amp;gt; Sarg Reports&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-043.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select Proxy Servers as SQUID proxy . And leave Rest of Field set to Default&lt;br /&gt;
&lt;br /&gt;
And Save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Go to Next Tab Schedule&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click “+” Symbol to create new schedule &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-044.jpg]] &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Reports can be viewed From “View Reports”&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-045.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bandwidthd:- ==&lt;br /&gt;
After Installing Package &#039;&#039;&#039;bandwidthd&#039;&#039;&#039; , Configuration can be done via&lt;br /&gt;
&lt;br /&gt;
Services &amp;gt; bandwidthd&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-046.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-047.jpg]]&lt;br /&gt;
&lt;br /&gt;
Enable Bandwidthd by checking the BOX.&lt;br /&gt;
&lt;br /&gt;
Now Select the Interface: - LAN.&lt;br /&gt;
&lt;br /&gt;
Enter The Subnets from LAN interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Save and Restart bandwidthd service from Services.&lt;br /&gt;
&lt;br /&gt;
Now Bandwidthd can be accessed:-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/bandwidthd/index.html https://203.77.200.91:8080/bandwidthd/index.html]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of ntopng:- ==&lt;br /&gt;
After installing ntopng package, it appears under Diagnostics &amp;gt; ntopng. It will even track where connections were made by local PCs, and how much bandwidth was used on individual connections.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-048.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
First we have to configure ntopng settings. Via Diagnostics &amp;gt; ntopng settings.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-049.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Setup Admin Password &amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Select the Interfaces on Which ntopng will be monitoring traffic.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We have selected LAN, DMZ and BRIDGEINTERFACE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To save the changes Click “Change”&lt;br /&gt;
&lt;br /&gt;
Ntopng can be accessed via [http://203.77.200.91:3000/login.html http://203.77.200.91:3000/login.html]&lt;br /&gt;
&lt;br /&gt;
With username admin and password assigned in previous step.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Configuring OpenVPN  =&lt;br /&gt;
A VPN (virtual private network) allows us to connect directly to our home private network over the internet&lt;br /&gt;
&lt;br /&gt;
The certificate authority or CA will sign the certificates that we will be creating for the server and client side when we configure OpenVPN. You can access the certificate configuration by going over to System–&amp;gt;Cert Manager.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-050.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Under the CAs tab you might already have a CA created if you followed one of my previous articles as we needed to created one in order to sign an internal certificate to be used for securing the pfSense web interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Certificate Authority ===&lt;br /&gt;
Fill in the fields to &#039;&#039;&#039;create a new Certificate Authority&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Descriptive Name&#039;&#039;&#039; - Used as the Common Name (CN) for the CA. Do not spaces, punctuation or special characters (ex: &#039;&#039;VPN Server CA&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Key Length&#039;&#039;&#039; - Default is OK, the higher the better but will use more CPU. &lt;br /&gt;
* &#039;&#039;&#039;Lifetime&#039;&#039;&#039; - Default is OK, but can be lowered if it must be changed out more often. &lt;br /&gt;
* &#039;&#039;&#039;Country Code&#039;&#039;&#039;, &#039;&#039;&#039;State/Province&#039;&#039;&#039;, &#039;&#039;&#039;City&#039;&#039;&#039;, &#039;&#039;&#039;Organization&#039;&#039;&#039; - Enter values for this location/company. &lt;br /&gt;
* &#039;&#039;&#039;E-mail&#039;&#039;&#039; - Used as a reference on the certificate, does not receive any mail from the system. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Add New CA&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-051.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
After you finished setting up the CA the next step is to create some certificates that the recently created CA will sign for us. Since these are self-signed certificates most browsers will give you a warning&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Server Certificate ===&lt;br /&gt;
Fill in the fields to create a new &#039;&#039;&#039;Server Certificate&#039;&#039;&#039;. Similar Fields as CA entry, most of the fields carry over and do not need changed. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Create new Certificate&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-052.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that we have all the components in place we can configure OpenVPN. Head over to VPN–&amp;gt;OpenVPN.&lt;br /&gt;
&lt;br /&gt;
.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-053.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select “Wizards” from the tab at the top which will guide us step by step to configure OpenVPN&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-054.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-055.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We will select the local user access database provided by pfSense&lt;br /&gt;
&lt;br /&gt;
In the next step we will be selecting the CA that we created at the beginning of this article.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-056.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Following is the Server Certificate that we will be using which is the Certificate that we recently created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-057.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;OpenVPN Server Configuration&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;TLS Authentication&#039;&#039;&#039; -- Leave this checked, along with the box underneath to generate a new key. Using a TLS key is technically optional, but &#039;&#039;highly&#039;&#039; recommended&lt;br /&gt;
* &#039;&#039;&#039;Tunnel Network&#039;&#039;&#039; -- Should be a new, unique network that does not exist anywhere in the current network or routing table. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-058.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-059.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-060.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== Firewall Rules ===&lt;br /&gt;
The next screen offers the choice to add firewall rules automatically. For convenience, check both unless the rules will be managed manually. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== End of the Wizard ===&lt;br /&gt;
Click &#039;&#039;&#039;Finish&#039;&#039;&#039; to exit the wizard and the new settings will be saved and applied automatically. &lt;br /&gt;
&lt;br /&gt;
== Adding a User with a Certificate ==&lt;br /&gt;
Navigate to &#039;&#039;&#039;System &amp;gt; User Manager&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click &amp;quot;+&amp;quot; To add a &#039;&#039;&#039;user&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Username&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Password / Confirm password&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Check Click to create a &#039;&#039;&#039;user certificate.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in the Descriptive Name as the username&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-061.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-062.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The OpenVPN Client Export Package allows exporting configurations formatted for a wide variety of platforms. It also allows exporting a pre-packaged Windows installer executable which includes the configuration bundled inside for a painly client installation. &lt;br /&gt;
&lt;br /&gt;
=== Installing the OpenVPN Client Export Package ===&lt;br /&gt;
To Install the OpenVPN Client Export Package &lt;br /&gt;
&lt;br /&gt;
* Navigate to &#039;&#039;&#039;System &amp;gt; Packages&#039;&#039;&#039;, &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab &lt;br /&gt;
* Find &#039;&#039;&#039;OpenVPN Client Export Package&#039;&#039;&#039; in the list &lt;br /&gt;
&lt;br /&gt;
=== Exporting a Configuration ===&lt;br /&gt;
* Navigate to &#039;&#039;&#039;VPN &amp;gt; OpenVPN&#039;&#039;&#039; on the &#039;&#039;&#039;Client Export&#039;&#039;&#039; tab &lt;br /&gt;
* Choose the VPN from the &#039;&#039;&#039;Remote Access Server&#039;&#039;&#039; drop-down list &lt;br /&gt;
* Find the user in the list at the bottom of the page and select the appropriate configuration type to export. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-063.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-064.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Multiple instance of VPN server can be created with different tunnel network &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-065.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Firewall Rules are applied as per the requirement on tunnel network .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-066.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Firewall Logs =&lt;br /&gt;
The Firewall logs at &#039;&#039;&#039;Status &amp;gt; System Logs&#039;&#039;&#039; on the &#039;&#039;&#039;Firewall&#039;&#039;&#039; tab show all events logged by the firewall.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Each entry is displayed with the action ( pass or block, reject is only logged as block), time, interface, source, destination, and protocol.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Configuration Of rsyslog Server for Logs Storage:-&lt;br /&gt;
&lt;br /&gt;
Status: &amp;gt;System logs &amp;gt; Settings&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-067.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Configuration of rsyslog on Centos :-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Setup Log File Location =====&lt;br /&gt;
Now edit Rsyslog configuration file and configure the location’s to generate log files in system.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# vim /etc/rsyslog.conf&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
and add following lines as the end of file.&lt;br /&gt;
&lt;br /&gt;
$template TmplAuth, &amp;quot;/var/log/%HOSTNAME%/%PROGRAMNAME%.log&amp;quot; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
authpriv.* ?TmplAuth&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;*.info,mail.none,authpriv.none,cron.none &amp;lt;/nowiki&amp;gt;?TmplMsg&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Enable Module and UDP Protocol =====&lt;br /&gt;
Also remove comment from following lines ( remove starting # ) in rsyslog configuration file to enable UDP.&lt;br /&gt;
&lt;br /&gt;
$ModLoad imudp&lt;br /&gt;
&lt;br /&gt;
$UDPServerRun 514&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Restart Rsyslog  =====&lt;br /&gt;
After making above changes in Rsyslog central server, restart service using following command.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# service rsyslog restart&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Logrotation:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Create file&#039;&#039;&#039; :- &#039;&#039;&#039;/etc/logrotate.d/pfsense&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;And enter:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/var/log/pfsense/filterlog.log&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;{&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;daily&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;missingok&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;rotate 60&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;compress&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;notifempty&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;create 640 root root&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;postrotate&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/etc/init.d/rsyslog restart &amp;gt;/dev/null&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;endscript&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;}&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Save and Quit.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;RRD Graphs:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
These are located under &#039;&#039;&#039;Status &amp;gt; RRD Graphs&#039;&#039;&#039;. Several graphs are presented for each monitored item, with varying time intervals and averages. &lt;br /&gt;
&lt;br /&gt;
These graphs measure things such as CPU usage, memory usage, state table usage, throughput (in bytes as well as packets), link quality, traffic shaping queue usage, and so on. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-068.jpg]]&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=File:Gpil-028.jpeg&amp;diff=1895</id>
		<title>File:Gpil-028.jpeg</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=File:Gpil-028.jpeg&amp;diff=1895"/>
		<updated>2015-04-16T10:42:21Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: uploaded a new version of &amp;amp;quot;File:Gpil-028.jpeg&amp;amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=File:Gpil-024.jpg&amp;diff=1894</id>
		<title>File:Gpil-024.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=File:Gpil-024.jpg&amp;diff=1894"/>
		<updated>2015-04-16T10:40:13Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: uploaded a new version of &amp;amp;quot;File:Gpil-024.jpg&amp;amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1893</id>
		<title>PF Sense Firewall Implementation at GIPL</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1893"/>
		<updated>2015-04-16T10:38:44Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;center&amp;gt;&amp;lt;u&amp;gt;&#039;&#039;&#039;PF Sense Firewall Implementation at GIPL , GandhiNagar &#039;&#039;&#039;&amp;lt;/u&amp;gt;&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Table of Contents ==&lt;br /&gt;
[#__RefHeading__2322_1445225205 NETWORK DIAGRAM2]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2324_1445225205 Performing a Full Install (LiveCD)3]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2326_1445225205 GUI Configuration Setup8]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2328_1445225205 Configuration Of Bridge Interface13]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2330_1445225205 Assign Virtual IP’s To LAN interface:-15]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2332_1445225205 Configuration of SNORT17]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2334_1445225205 Add Snort to an interface20]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2336_1445225205 Select which types of rules will protect the network22]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2338_1445225205 IP Alias and Port Alias24]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2340_1445225205 Firewall Rules :-27]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2342_1445225205 Configuration Of Squid and Squidguard:-31]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2344_1445225205 Configuration of SARG:-39]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2346_1445225205 Configuration Of Bandwidthd:-42]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2348_1445225205 Configuration Of ntopng:-44]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2350_1445225205 Configuring OpenVPN46]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2352_1445225205 Certificate Authority47]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2354_1445225205 Server Certificate48]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2356_1445225205 Firewall Rules54]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2358_1445225205 End of the Wizard54]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2360_1445225205 Adding a User with a Certificate54]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2362_1445225205 Installing the OpenVPN Client Export Package57]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2364_1445225205 Exporting a Configuration57]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2366_1445225205 Firewall Logs60]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2368_1445225205 Setup Log File Location61]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2370_1445225205 Enable Module and UDP Protocol61]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2372_1445225205 Restart Rsyslog61]= NETWORK DIAGRAM =&lt;br /&gt;
[[Image:Gpil-000.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Installation&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;pfSense&#039;&#039;&#039; is an open source firewall/router computer software distribution based on FreeBSD. It is installed on a computer to make a dedicated firewall/router for a network and is noted for its reliability[1] and offering features often only found in expensive commercial firewalls&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Download pfSense&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Visit https://www.pfsense.org/download/mirror.php?section=downloads&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Step 1 :- &#039;&#039;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Performing a Full Install (LiveCD) ==&lt;br /&gt;
Power on the target system and connect the install media: Place the CD into the drive or plug the Memstick into a USB port. If the BIOS is set to boot from CD/USB, pfSense will start. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-001.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
As the operating system boots and pfSense starts, a prompt is presented with some choices and a countdown timer. At this prompt, press &#039;&#039;i&#039;&#039; to invoke the installer now.&lt;br /&gt;
&lt;br /&gt;
When the installer detects multiple disks in the system the first screen available provides the option &#039;&#039;&#039;Setup GEOM Mirror&#039;&#039;&#039;. Choose that option, pick the primary disk, the disk to use for the mirror copy, and then proceed with the installation as normal. &lt;br /&gt;
&lt;br /&gt;
The Quick/Easy install choice will target the GEOM mirror automatically&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-002.jpeg]]&lt;br /&gt;
&lt;br /&gt;
At the &#039;&#039;&#039;Select Task&#039;&#039;&#039; prompt, choose &#039;&#039;Quick/Easy Install&#039;&#039;. [[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-003.jpeg]]&lt;br /&gt;
&lt;br /&gt;
The install will proceed, wiping the target disk and installing pfSense. Copying files may take some time to finish. &lt;br /&gt;
&lt;br /&gt;
After the files have been copied to the target disk, a choice is presented to select the console type. &#039;&#039;Standard&#039;&#039; defaults to the VGA console. &#039;&#039;Embedded&#039;&#039; defaults to serial console&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-004.jpeg]]&lt;br /&gt;
&lt;br /&gt;
Now the system must reboot so that pfSense may start from the target disk. Select &#039;&#039;Reboot&#039;&#039; and then press &#039;&#039;&#039;Enter (remove CD from Drive)&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-005.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After the system reboots, pfSense will be running from the target disk. The next step is to Assign Interfaces on the Console below.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-006.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After installation and assignment, a shell menu is presented on the console with a number of options. pfSense now is ready to be accessed via the network, LAN interface IP 192.168.1.1 is assigned by default.&lt;br /&gt;
&lt;br /&gt;
Open a web browser and navigate to https://192.168.1.1/, using the default username admin and password pfsense to login.&lt;br /&gt;
&lt;br /&gt;
The first visit to the WebGUI will be redirected to the setup wizard.&lt;br /&gt;
&lt;br /&gt;
== GUI Configuration Setup ==&lt;br /&gt;
Once The Setup is launched, Fill the details are follows:-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-007.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We have defined FQDN as gipl.firewall&lt;br /&gt;
&lt;br /&gt;
DNS servers:- 8.8.8.8 and 4.4.2.2 Global DNS&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click NEXT&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-008.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select The Time-Zone as Asia/Kolkata .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
And Click NEXT&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-009.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Here we have Set WAN as Static Interface&lt;br /&gt;
&lt;br /&gt;
With IP address :- 203.77.200.91/25&lt;br /&gt;
&lt;br /&gt;
Gateway :- 203.77.200.1&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-010.jpg]]&lt;br /&gt;
&lt;br /&gt;
Here we have Configured LAN interface with IP address 192.168.45.101/24&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
( note:-As per the client Network Topology , Lan interface have multiple Subnets configured , so we will be configuring Virtual IP’s from GUI )&lt;br /&gt;
&lt;br /&gt;
After Setting Admin Password, Page will be redirected to Pfsense-Dashboard.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-011.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We Have Changed Default Port from 443 to 8080 Via :-&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;System &amp;gt; Advanced&#039;&#039;&#039;&lt;br /&gt;
[[Image:Gpil-012.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Change TCP Port from Default 443 to 8080 .&lt;br /&gt;
[[Image:Gpil-013.jpg]] &lt;br /&gt;
Save .&lt;br /&gt;
&lt;br /&gt;
Now pfsense Can be accessed via [https://IP:8080 https://IP:8080]&lt;br /&gt;
&lt;br /&gt;
IP Address of Firewall is 203.77.200.91 on WAN interface.&lt;br /&gt;
&lt;br /&gt;
Go to :- interface &amp;gt; assign , and edit Opt1 as DMZ , do not assign IP address to This interface , because we will be creating bridge interface .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bridge Interface ==&lt;br /&gt;
Now we have to configure &#039;&#039;&#039;Interface Bridges&#039;&#039;&#039; in order to Setup Pfsense in &lt;br /&gt;
&lt;br /&gt;
Transparent mode.&lt;br /&gt;
&lt;br /&gt;
Reference:- &amp;lt;u&amp;gt;https://doc.pfsense.org/index.php/Interface_Bridges&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Navigate To :- Interfaces &amp;gt; (assign) &lt;br /&gt;
&lt;br /&gt;
on the Bridges tab Click “ +” symbol to add a new bridge .&lt;br /&gt;
&lt;br /&gt;
Ctrl-Click to select the Member interfaces from the list of available interfaces and type a Description , we have selected WAN + DMZ as bridge0 and create new Interface BRIDGEINTERFACE using bridge0 .&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-014.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
By default, traffic is filtered on the member interfaces and not on the bridge interface itself. This behavior may be changed by toggling the values of &#039;&#039;&#039;net.link.bridge.pfil_member&#039;&#039;&#039; and net.link.bridge.pfil&#039;&#039;&#039;_bridge &#039;&#039;&#039;under System&#039;&#039;&#039; &amp;gt; Advanced &#039;&#039;&#039;on the &#039;&#039;&#039;System Tunables&#039;&#039;&#039; tab. With them set at &#039;&#039;0&#039;&#039; and &#039;&#039;1&#039;&#039;, respectively, then filtering would be performed on the bridge only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-015.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Pfsense is Configured In Bridge Mode with &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;WAN interface: - 203.77.200.91/25 gateway :- 203.77.200.1&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface:- 192.168.45.101/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;DMZ: - no ip &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;BRIDGEINTERFACE:- 203.77.200.92/25&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-016.jpg]]&lt;br /&gt;
&lt;br /&gt;
== Assign Virtual IP’s To LAN interface:- ==&lt;br /&gt;
[[Image:Gpil-018.jpg]]&lt;br /&gt;
Now as LAN environment have multiple Subnet configured, we will be assigning Virtual IP address to LAN interface.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-017.jpg]]&lt;br /&gt;
&lt;br /&gt;
Clients on LAN Environment have their Gateway Set from These Virtual IP’s.&lt;br /&gt;
&lt;br /&gt;
203.77.196.230 is added for outside access of Local Servers 203.77.192.49/28.&lt;br /&gt;
&lt;br /&gt;
(203.77.196.230) is configured in 203.77.192.2 switch which will receive any packet for 203.77.192.49/28 from Outside and send it to 203.77.196.230.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SNORT  ==&lt;br /&gt;
&amp;lt;u&amp;gt;&#039;&#039;&#039;Reference&#039;&#039;&#039;&amp;lt;/u&amp;gt; :- &amp;lt;u&amp;gt;&#039;&#039;&#039;https://doc.pfsense.org/index.php/Setup_Snort_Package&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Go to the &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab under the &#039;&#039;&#039;System&#039;&#039;&#039; menu and install the snort package.&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;When the installation completes, click on &#039;&#039;&#039;Snort&#039;&#039;&#039; under the &#039;&#039;&#039;Services&#039;&#039;&#039; menu. &amp;amp;nbsp;This will open the Snort main setup page.&lt;br /&gt;
&lt;br /&gt;
Click the &#039;&#039;&#039;Global Settings&#039;&#039;&#039; tab and perform the following At the top of the page you have three choices for Rule Sets to activate.&lt;br /&gt;
&lt;br /&gt;
Put Check mark on :-Install &#039;&#039;&#039;Snort Community&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Emerging Threats&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Snort VRT&#039;&#039;&#039; rules. And save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Updates&#039;&#039;&#039; tab is used to check the status of downloaded rules packages and to download new updates. The table shows the available rule packages and their current status [[Image:Gpil-019.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Update Button to Update the rules.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Add Snort to an interface ==&lt;br /&gt;
Click the Snort Interfaces tab and then the &amp;quot;+&amp;quot; icon to add a new Snort interface.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-020.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;On the &#039;&#039;&#039;WAN Settings&#039;&#039;&#039; tab, click the &#039;&#039;Enable&#039;&#039; checkbox.In the drop-down, choose the interface. &amp;amp;nbsp;The WAN interface is the default and is a good first choice.In the &#039;&#039;Description&#039;&#039; textbox, enter a name (WAN again, is fine here).Click the checkbox to &amp;quot;&#039;&#039;Send alerts to the main System logs&#039;&#039;&amp;quot;.leave the other settings at their defaults&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-021.jpg]]&lt;br /&gt;
&lt;br /&gt;
After saving, the browser will be returned to the Snort Interfaces tab. Note the warning icons in the image below showing no rules have been selected for the new Snort interface. Those rules will be configured next. Click the &amp;quot;e&amp;quot; icon to edit the new Snort interface again&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-024.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Select which types of rules will protect the network ==&lt;br /&gt;
Click the &#039;&#039;&#039;Categories&#039;&#039;&#039; tab for the new interface&lt;br /&gt;
&lt;br /&gt;
Check [https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=GPLv2_community.rules Snort GPLv2 Community Rules (VRT certified)] Box .&lt;br /&gt;
&lt;br /&gt;
And Manual Rules :-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-botcc.rules emerging-botcc.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_blacklist.rules snort_blacklist.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.so.rules snort_exploit-kit.so.rules] &lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_ddos.rules snort_ddos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_dos.rules snort_dos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.rules snort_exploit-kit.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-malware.rules emerging-malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-mobile_malware.rules emerging-mobile_malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-tor.rules emerging-tor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-trojan.rules emerging-trojan.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_malware-backdoor.rules snort_malware-backdoor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_virus.rules snort_virus.rules]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-023.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click SAVE when finished to save the selection and build the rules &lt;br /&gt;
&lt;br /&gt;
After that restart the service &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-024.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Managing Pass lists:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Pass Lists are lists of IP addresses that Snort should never block. These may be created and managed on the Pass Lists tab. When an IP address is listed on a Pass List, Snort will never insert a block on that address even when malicious traffic is detected.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;To create a new Pass List, click &amp;quot;+&amp;quot;. To edit an existing Pass List, click the &amp;quot;e&amp;quot;. To delete a Pass List, click &amp;quot;x&amp;quot;. Note that a Pass List may not be deleted if it is currently assigned to one or more Snort interfaces.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We have added GIPL IP’s in Pass list . i.e&#039;&#039;&#039; &amp;lt;u&amp;gt;203.77.192.0/20&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-025.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== IP Alias and Port Alias ==&lt;br /&gt;
IP aliases allow you to create a group of IP addresses that you can assign by group name instead of specifying each IP address individually. This can be great for specifying a group of servers that need ssh access and then in the firewall rules you can create a rule that allows ssh traffic for the ssh servers group.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Along the top menu hover over Firewall and click on Aliases.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-026.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The next tab is for setting up Port Aliases. &amp;amp;nbsp;Similar to the IP Aliases you can setup groups but on this tab you are creating groups of ports instead of IP addresses.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-027.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
IP Aliases Created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-028.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
PORT ALIAS CREATED&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-029.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Firewall Rules :- ==&lt;br /&gt;
Reference:- [https://doc.pfsense.org/index.php/Firewall_Rule_Basics https://doc.pfsense.org/index.php/Firewall_Rule_Basics]&lt;br /&gt;
&lt;br /&gt;
Firewall rules control what traffic is allowed to enter an interface on the firewall. Once traffic is passed on the interface it enters an entry in the state table is created. A state table entry allows through subsequent packets that are part of that connection.&lt;br /&gt;
&lt;br /&gt;
Firewall rules are managed at Firewall &amp;gt; Rules. Multiple rules may be selected for some actions by clicking on their row or checking the box at the start of their row. Rules may be deleted or reordered in bulk in this way. See Managing Lists of Items on pfSense for more information on the meaning of the icons when manipulating rules.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;any&#039;&#039;&#039; - &#039;&#039;0.0.0.0&#039;&#039; to &#039;&#039;255.255.255.255&#039;&#039;, or all IPv6 addresses &lt;br /&gt;
* &#039;&#039;&#039;Single host or alias&#039;&#039;&#039; - Select this and enter one IP address (&#039;&#039;1.2.3.4&#039;&#039;, &#039;&#039;aa:bb:cc:dd::1&#039;&#039;) or type the name of an Alias that has already been configured (&#039;&#039;&#039;Firewall &amp;gt; Aliases&#039;&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Network&#039;&#039;&#039; - Select this and enter a network and mask (&#039;&#039;10.99.0.0/16&#039;&#039;, &#039;&#039;aa:bb:cc:dd::0/64&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;LAN net&#039;&#039;&#039; - The subnet configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039;. On pfSense 2.2+, this also includes static route networks on that interface. &lt;br /&gt;
* &#039;&#039;&#039;LAN address&#039;&#039;&#039; - The IP address configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039; &lt;br /&gt;
* &#039;&#039;&#039;zzz Net&#039;&#039;&#039; / &#039;&#039;&#039;zzz address&#039;&#039;&#039; - Works the same as LAN above but for other interfaces (WAN, OPT1, OPT2, etc.) &lt;br /&gt;
* &#039;&#039;&#039;PPTP clients&#039;&#039;&#039; - Automatically locate and use the addresses of PPTP clients &lt;br /&gt;
* &#039;&#039;&#039;L2TP clients&#039;&#039;&#039; - Automatically locate and use the addresses of L2TP clients &lt;br /&gt;
* &#039;&#039;&#039;This Firewall (self)&#039;&#039;&#039; - Any IP address assigned to any interface on this firewall (pfSense 2.2+) &lt;br /&gt;
&lt;br /&gt;
Firewall rules are generally processed starting with Floating Rules, then Interface Group rules, then Interface tab rules&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Rules Created on bridge interface, for DMZ access&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-030.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-031.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface Rules Created:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-032.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Squid and Squidguard:- ==&lt;br /&gt;
&#039;&#039;&#039;Reference - &#039;&#039;&#039;[https://doc.pfsense.org/index.php/SquidGuard_package https://doc.pfsense.org/index.php/SquidGuard_package]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Login to your pfsense&#039;s Web Administrator, and click on &amp;quot;Server -&amp;gt; Packages&amp;quot;, scroll down the list and find squid and click on &amp;quot;+&amp;quot; button to install, wait for the process to finish then return to the packages section and look for squidguard and install that package as well.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-033.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now go to &amp;quot;Services&amp;quot; menu and look for Proxy Server &amp;amp; Proxy Filter &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-034.jpg]]&lt;br /&gt;
&lt;br /&gt;
(We are setting up the proxy server as a transparent proxy)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on Services -&amp;gt; Proxy Server.&lt;br /&gt;
&lt;br /&gt;
On the General Tab, you want to set the following settings, the Proxy Interface Option should be set to &amp;quot;LAN&amp;quot;, to set up transparent proxy server, tick the &amp;quot;Transparent Proxy&amp;quot; check box.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-035.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Tick the &amp;quot;Enabled Logging&amp;quot; Checkbox, set the log store to the default location &amp;quot; /var/squid/logs &amp;quot; rotate your logs every 30 days, set your proxy port to port number 3128 We have By-passed Proxy for 203.77.192.49/28, These are the Local Servers.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next click on the &amp;quot;Cache Mgmt.&amp;quot; tab, by default the Hard Disk Cache Size is set to 100mb, we have allocated 100GB , Memory Cache Size 3072 .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-036.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click on Save.&lt;br /&gt;
&lt;br /&gt;
Click on the Access Control Tab next, in the allowed subnets field type in your required subnets. As we have multiple Subnets, so we are going to define all.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-037.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.129/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.1.224.1/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.192.49/28&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.57/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.17/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.137/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.33.50.1/27&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click On Save &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that’s is the proxy server configured, next we are going to configure SquidGuard, click on the Services menu and select the Proxy Filter button, tick the following 3 check boxes &amp;quot;Enable&amp;quot;, &amp;quot;Enable GUI Log&amp;quot; and &amp;quot;Enable Log&amp;quot; then click the Save button, once the page has reloaded click on apply and then confirm that the Squidguard service is running by making sure the SquidGuard status is set to STARTED.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-038.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on the Black list tab and add URL &#039;&#039;&#039;http://www.shallalist.de/Downloads/shallalist.tar.gz&#039;&#039;&#039; to the Update Address and click on Download. Wait for the process to complete.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-039.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-040.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now we can set up common ACL’s&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-041.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-042.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Click on Save and restart the Squid and SquidGuard from Services. &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SARG:- ==&lt;br /&gt;
After Installing SARG package, we can configure SARG from Status &amp;gt; Sarg Reports&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-043.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select Proxy Servers as SQUID proxy . And leave Rest of Field set to Default&lt;br /&gt;
&lt;br /&gt;
And Save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Go to Next Tab Schedule&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click “+” Symbol to create new schedule &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-044.jpg]] &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Reports can be viewed From “View Reports”&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-045.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bandwidthd:- ==&lt;br /&gt;
After Installing Package &#039;&#039;&#039;bandwidthd&#039;&#039;&#039; , Configuration can be done via&lt;br /&gt;
&lt;br /&gt;
Services &amp;gt; bandwidthd&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-046.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-047.jpg]]&lt;br /&gt;
&lt;br /&gt;
Enable Bandwidthd by checking the BOX.&lt;br /&gt;
&lt;br /&gt;
Now Select the Interface: - LAN.&lt;br /&gt;
&lt;br /&gt;
Enter The Subnets from LAN interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Save and Restart bandwidthd service from Services.&lt;br /&gt;
&lt;br /&gt;
Now Bandwidthd can be accessed:-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/bandwidthd/index.html https://203.77.200.91:8080/bandwidthd/index.html]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of ntopng:- ==&lt;br /&gt;
After installing ntopng package, it appears under Diagnostics &amp;gt; ntopng. It will even track where connections were made by local PCs, and how much bandwidth was used on individual connections.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-048.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
First we have to configure ntopng settings. Via Diagnostics &amp;gt; ntopng settings.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-049.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Setup Admin Password &amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Select the Interfaces on Which ntopng will be monitoring traffic.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We have selected LAN, DMZ and BRIDGEINTERFACE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To save the changes Click “Change”&lt;br /&gt;
&lt;br /&gt;
Ntopng can be accessed via [http://203.77.200.91:3000/login.html http://203.77.200.91:3000/login.html]&lt;br /&gt;
&lt;br /&gt;
With username admin and password assigned in previous step.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Configuring OpenVPN  =&lt;br /&gt;
A VPN (virtual private network) allows us to connect directly to our home private network over the internet&lt;br /&gt;
&lt;br /&gt;
The certificate authority or CA will sign the certificates that we will be creating for the server and client side when we configure OpenVPN. You can access the certificate configuration by going over to System–&amp;gt;Cert Manager.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-050.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Under the CAs tab you might already have a CA created if you followed one of my previous articles as we needed to created one in order to sign an internal certificate to be used for securing the pfSense web interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Certificate Authority ===&lt;br /&gt;
Fill in the fields to &#039;&#039;&#039;create a new Certificate Authority&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Descriptive Name&#039;&#039;&#039; - Used as the Common Name (CN) for the CA. Do not spaces, punctuation or special characters (ex: &#039;&#039;VPN Server CA&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Key Length&#039;&#039;&#039; - Default is OK, the higher the better but will use more CPU. &lt;br /&gt;
* &#039;&#039;&#039;Lifetime&#039;&#039;&#039; - Default is OK, but can be lowered if it must be changed out more often. &lt;br /&gt;
* &#039;&#039;&#039;Country Code&#039;&#039;&#039;, &#039;&#039;&#039;State/Province&#039;&#039;&#039;, &#039;&#039;&#039;City&#039;&#039;&#039;, &#039;&#039;&#039;Organization&#039;&#039;&#039; - Enter values for this location/company. &lt;br /&gt;
* &#039;&#039;&#039;E-mail&#039;&#039;&#039; - Used as a reference on the certificate, does not receive any mail from the system. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Add New CA&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-051.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
After you finished setting up the CA the next step is to create some certificates that the recently created CA will sign for us. Since these are self-signed certificates most browsers will give you a warning&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Server Certificate ===&lt;br /&gt;
Fill in the fields to create a new &#039;&#039;&#039;Server Certificate&#039;&#039;&#039;. Similar Fields as CA entry, most of the fields carry over and do not need changed. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Create new Certificate&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-052.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that we have all the components in place we can configure OpenVPN. Head over to VPN–&amp;gt;OpenVPN.&lt;br /&gt;
&lt;br /&gt;
.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-053.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select “Wizards” from the tab at the top which will guide us step by step to configure OpenVPN&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-054.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-055.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We will select the local user access database provided by pfSense&lt;br /&gt;
&lt;br /&gt;
In the next step we will be selecting the CA that we created at the beginning of this article.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-056.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Following is the Server Certificate that we will be using which is the Certificate that we recently created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-057.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;OpenVPN Server Configuration&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;TLS Authentication&#039;&#039;&#039; -- Leave this checked, along with the box underneath to generate a new key. Using a TLS key is technically optional, but &#039;&#039;highly&#039;&#039; recommended&lt;br /&gt;
* &#039;&#039;&#039;Tunnel Network&#039;&#039;&#039; -- Should be a new, unique network that does not exist anywhere in the current network or routing table. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-058.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-059.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-060.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== Firewall Rules ===&lt;br /&gt;
The next screen offers the choice to add firewall rules automatically. For convenience, check both unless the rules will be managed manually. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== End of the Wizard ===&lt;br /&gt;
Click &#039;&#039;&#039;Finish&#039;&#039;&#039; to exit the wizard and the new settings will be saved and applied automatically. &lt;br /&gt;
&lt;br /&gt;
== Adding a User with a Certificate ==&lt;br /&gt;
Navigate to &#039;&#039;&#039;System &amp;gt; User Manager&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click &amp;quot;+&amp;quot; To add a &#039;&#039;&#039;user&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Username&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Password / Confirm password&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Check Click to create a &#039;&#039;&#039;user certificate.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in the Descriptive Name as the username&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-061.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-062.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The OpenVPN Client Export Package allows exporting configurations formatted for a wide variety of platforms. It also allows exporting a pre-packaged Windows installer executable which includes the configuration bundled inside for a painly client installation. &lt;br /&gt;
&lt;br /&gt;
=== Installing the OpenVPN Client Export Package ===&lt;br /&gt;
To Install the OpenVPN Client Export Package &lt;br /&gt;
&lt;br /&gt;
* Navigate to &#039;&#039;&#039;System &amp;gt; Packages&#039;&#039;&#039;, &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab &lt;br /&gt;
* Find &#039;&#039;&#039;OpenVPN Client Export Package&#039;&#039;&#039; in the list &lt;br /&gt;
&lt;br /&gt;
=== Exporting a Configuration ===&lt;br /&gt;
* Navigate to &#039;&#039;&#039;VPN &amp;gt; OpenVPN&#039;&#039;&#039; on the &#039;&#039;&#039;Client Export&#039;&#039;&#039; tab &lt;br /&gt;
* Choose the VPN from the &#039;&#039;&#039;Remote Access Server&#039;&#039;&#039; drop-down list &lt;br /&gt;
* Find the user in the list at the bottom of the page and select the appropriate configuration type to export. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-063.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-064.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Multiple instance of VPN server can be created with different tunnel network &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-065.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Firewall Rules are applied as per the requirement on tunnel network .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-066.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Firewall Logs =&lt;br /&gt;
The Firewall logs at &#039;&#039;&#039;Status &amp;gt; System Logs&#039;&#039;&#039; on the &#039;&#039;&#039;Firewall&#039;&#039;&#039; tab show all events logged by the firewall.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Each entry is displayed with the action ( pass or block, reject is only logged as block), time, interface, source, destination, and protocol.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Configuration Of rsyslog Server for Logs Storage:-&lt;br /&gt;
&lt;br /&gt;
Status: &amp;gt;System logs &amp;gt; Settings&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-067.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Configuration of rsyslog on Centos :-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Setup Log File Location =====&lt;br /&gt;
Now edit Rsyslog configuration file and configure the location’s to generate log files in system.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# vim /etc/rsyslog.conf&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
and add following lines as the end of file.&lt;br /&gt;
&lt;br /&gt;
$template TmplAuth, &amp;quot;/var/log/%HOSTNAME%/%PROGRAMNAME%.log&amp;quot; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
authpriv.* ?TmplAuth&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;*.info,mail.none,authpriv.none,cron.none &amp;lt;/nowiki&amp;gt;?TmplMsg&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Enable Module and UDP Protocol =====&lt;br /&gt;
Also remove comment from following lines ( remove starting # ) in rsyslog configuration file to enable UDP.&lt;br /&gt;
&lt;br /&gt;
$ModLoad imudp&lt;br /&gt;
&lt;br /&gt;
$UDPServerRun 514&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Restart Rsyslog  =====&lt;br /&gt;
After making above changes in Rsyslog central server, restart service using following command.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# service rsyslog restart&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Logrotation:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Create file&#039;&#039;&#039; :- &#039;&#039;&#039;/etc/logrotate.d/pfsense&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;And enter:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/var/log/pfsense/filterlog.log&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;{&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;daily&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;missingok&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;rotate 60&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;compress&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;notifempty&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;create 640 root root&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;postrotate&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/etc/init.d/rsyslog restart &amp;gt;/dev/null&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;endscript&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;}&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Save and Quit.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;RRD Graphs:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
These are located under &#039;&#039;&#039;Status &amp;gt; RRD Graphs&#039;&#039;&#039;. Several graphs are presented for each monitored item, with varying time intervals and averages. &lt;br /&gt;
&lt;br /&gt;
These graphs measure things such as CPU usage, memory usage, state table usage, throughput (in bytes as well as packets), link quality, traffic shaping queue usage, and so on. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-068.jpg]]&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1892</id>
		<title>PF Sense Firewall Implementation at GIPL</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1892"/>
		<updated>2015-04-16T10:35:58Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;center&amp;gt;&amp;lt;u&amp;gt;&#039;&#039;&#039;PF Sense Firewall Implementation at GIPL , GandhiNagar &#039;&#039;&#039;&amp;lt;/u&amp;gt;&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Table of Contents ==&lt;br /&gt;
[#__RefHeading__2322_1445225205 NETWORK DIAGRAM2]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2324_1445225205 Performing a Full Install (LiveCD)3]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2326_1445225205 GUI Configuration Setup8]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2328_1445225205 Configuration Of Bridge Interface13]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2330_1445225205 Assign Virtual IP’s To LAN interface:-15]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2332_1445225205 Configuration of SNORT17]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2334_1445225205 Add Snort to an interface20]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2336_1445225205 Select which types of rules will protect the network22]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2338_1445225205 IP Alias and Port Alias24]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2340_1445225205 Firewall Rules :-27]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2342_1445225205 Configuration Of Squid and Squidguard:-31]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2344_1445225205 Configuration of SARG:-39]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2346_1445225205 Configuration Of Bandwidthd:-42]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2348_1445225205 Configuration Of ntopng:-44]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2350_1445225205 Configuring OpenVPN46]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2352_1445225205 Certificate Authority47]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2354_1445225205 Server Certificate48]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2356_1445225205 Firewall Rules54]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2358_1445225205 End of the Wizard54]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2360_1445225205 Adding a User with a Certificate54]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2362_1445225205 Installing the OpenVPN Client Export Package57]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2364_1445225205 Exporting a Configuration57]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2366_1445225205 Firewall Logs60]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2368_1445225205 Setup Log File Location61]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2370_1445225205 Enable Module and UDP Protocol61]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2372_1445225205 Restart Rsyslog61]= NETWORK DIAGRAM =&lt;br /&gt;
[[Image:Gpil-000.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Installation&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;pfSense&#039;&#039;&#039; is an open source firewall/router computer software distribution based on FreeBSD. It is installed on a computer to make a dedicated firewall/router for a network and is noted for its reliability[1] and offering features often only found in expensive commercial firewalls&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Download pfSense&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Visit https://www.pfsense.org/download/mirror.php?section=downloads&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Step 1 :- &#039;&#039;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Performing a Full Install (LiveCD) ==&lt;br /&gt;
Power on the target system and connect the install media: Place the CD into the drive or plug the Memstick into a USB port. If the BIOS is set to boot from CD/USB, pfSense will start. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-001.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
As the operating system boots and pfSense starts, a prompt is presented with some choices and a countdown timer. At this prompt, press &#039;&#039;i&#039;&#039; to invoke the installer now.&lt;br /&gt;
&lt;br /&gt;
When the installer detects multiple disks in the system the first screen available provides the option &#039;&#039;&#039;Setup GEOM Mirror&#039;&#039;&#039;. Choose that option, pick the primary disk, the disk to use for the mirror copy, and then proceed with the installation as normal. &lt;br /&gt;
&lt;br /&gt;
The Quick/Easy install choice will target the GEOM mirror automatically&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-002.jpeg]]&lt;br /&gt;
&lt;br /&gt;
At the &#039;&#039;&#039;Select Task&#039;&#039;&#039; prompt, choose &#039;&#039;Quick/Easy Install&#039;&#039;. [[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-003.jpeg]]&lt;br /&gt;
&lt;br /&gt;
The install will proceed, wiping the target disk and installing pfSense. Copying files may take some time to finish. &lt;br /&gt;
&lt;br /&gt;
After the files have been copied to the target disk, a choice is presented to select the console type. &#039;&#039;Standard&#039;&#039; defaults to the VGA console. &#039;&#039;Embedded&#039;&#039; defaults to serial console&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-004.jpeg]]&lt;br /&gt;
&lt;br /&gt;
Now the system must reboot so that pfSense may start from the target disk. Select &#039;&#039;Reboot&#039;&#039; and then press &#039;&#039;&#039;Enter (remove CD from Drive)&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-005.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After the system reboots, pfSense will be running from the target disk. The next step is to Assign Interfaces on the Console below.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-006.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After installation and assignment, a shell menu is presented on the console with a number of options. pfSense now is ready to be accessed via the network, LAN interface IP 192.168.1.1 is assigned by default.&lt;br /&gt;
&lt;br /&gt;
Open a web browser and navigate to https://192.168.1.1/, using the default username admin and password pfsense to login.&lt;br /&gt;
&lt;br /&gt;
The first visit to the WebGUI will be redirected to the setup wizard.&lt;br /&gt;
&lt;br /&gt;
== GUI Configuration Setup ==&lt;br /&gt;
Once The Setup is launched, Fill the details are follows:-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-007.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We have defined FQDN as gipl.firewall&lt;br /&gt;
&lt;br /&gt;
DNS servers:- 8.8.8.8 and 4.4.2.2 Global DNS&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click NEXT&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-008.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select The Time-Zone as Asia/Kolkata .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
And Click NEXT&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-009.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Here we have Set WAN as Static Interface&lt;br /&gt;
&lt;br /&gt;
With IP address :- 203.77.200.91/25&lt;br /&gt;
&lt;br /&gt;
Gateway :- 203.77.200.1&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-010.jpg]]&lt;br /&gt;
&lt;br /&gt;
Here we have Configured LAN interface with IP address 192.168.45.101/24&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
( note:-As per the client Network Topology , Lan interface have multiple Subnets configured , so we will be configuring Virtual IP’s from GUI )&lt;br /&gt;
&lt;br /&gt;
After Setting Admin Password, Page will be redirected to Pfsense-Dashboard.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-011.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We Have Changed Default Port from 443 to 8080 Via :-&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;System &amp;gt; Advanced&#039;&#039;&#039;&lt;br /&gt;
[[Image:Gpil-012.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Change TCP Port from Default 443 to 8080 .&lt;br /&gt;
[[Image:Gpil-013.jpg]] &lt;br /&gt;
Save .&lt;br /&gt;
&lt;br /&gt;
Now pfsense Can be accessed via [https://IP:8080 https://IP:8080]&lt;br /&gt;
&lt;br /&gt;
IP Address of Firewall is 203.77.200.91 on WAN interface.&lt;br /&gt;
&lt;br /&gt;
Go to :- interface &amp;gt; assign , and edit Opt1 as DMZ , do not assign IP address to This interface , because we will be creating bridge interface .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bridge Interface ==&lt;br /&gt;
Now we have to configure &#039;&#039;&#039;Interface Bridges&#039;&#039;&#039; in order to Setup Pfsense in &lt;br /&gt;
&lt;br /&gt;
Transparent mode.&lt;br /&gt;
&lt;br /&gt;
Reference:- &amp;lt;u&amp;gt;https://doc.pfsense.org/index.php/Interface_Bridges&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Navigate To :- Interfaces &amp;gt; (assign) &lt;br /&gt;
&lt;br /&gt;
on the Bridges tab Click “ +” symbol to add a new bridge .&lt;br /&gt;
&lt;br /&gt;
Ctrl-Click to select the Member interfaces from the list of available interfaces and type a Description , we have selected WAN + DMZ as bridge0 and create new Interface BRIDGEINTERFACE using bridge0 .&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-014.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
By default, traffic is filtered on the member interfaces and not on the bridge interface itself. This behavior may be changed by toggling the values of &#039;&#039;&#039;net.link.bridge.pfil_member&#039;&#039;&#039; and net.link.bridge.pfil&#039;&#039;&#039;_bridge &#039;&#039;&#039;under System&#039;&#039;&#039; &amp;gt; Advanced &#039;&#039;&#039;on the &#039;&#039;&#039;System Tunables&#039;&#039;&#039; tab. With them set at &#039;&#039;0&#039;&#039; and &#039;&#039;1&#039;&#039;, respectively, then filtering would be performed on the bridge only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-015.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Pfsense is Configured In Bridge Mode with &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;WAN interface: - 203.77.200.91/25 gateway :- 203.77.200.1&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface:- 192.168.45.101/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;DMZ: - no ip &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;BRIDGEINTERFACE:- 203.77.200.92/25&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-016.jpg]]&lt;br /&gt;
&lt;br /&gt;
== Assign Virtual IP’s To LAN interface:- ==&lt;br /&gt;
[[Image:Gpil-018.jpg]]&lt;br /&gt;
Now as LAN environment have multiple Subnet configured, we will be assigning Virtual IP address to LAN interface.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-017.jpg]]&lt;br /&gt;
&lt;br /&gt;
Clients on LAN Environment have their Gateway Set from These Virtual IP’s.&lt;br /&gt;
&lt;br /&gt;
203.77.196.230 is added for outside access of Local Servers 203.77.192.49/28.&lt;br /&gt;
&lt;br /&gt;
(203.77.196.230) is configured in 203.77.192.2 switch which will receive any packet for 203.77.192.49/28 from Outside and send it to 203.77.196.230.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SNORT  ==&lt;br /&gt;
&amp;lt;u&amp;gt;&#039;&#039;&#039;Reference&#039;&#039;&#039;&amp;lt;/u&amp;gt; :- &amp;lt;u&amp;gt;&#039;&#039;&#039;https://doc.pfsense.org/index.php/Setup_Snort_Package&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Go to the &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab under the &#039;&#039;&#039;System&#039;&#039;&#039; menu and install the snort package.&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;When the installation completes, click on &#039;&#039;&#039;Snort&#039;&#039;&#039; under the &#039;&#039;&#039;Services&#039;&#039;&#039; menu. &amp;amp;nbsp;This will open the Snort main setup page.&lt;br /&gt;
&lt;br /&gt;
Click the &#039;&#039;&#039;Global Settings&#039;&#039;&#039; tab and perform the following At the top of the page you have three choices for Rule Sets to activate.&lt;br /&gt;
&lt;br /&gt;
Put Check mark on :-Install &#039;&#039;&#039;Snort Community&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Emerging Threats&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Snort VRT&#039;&#039;&#039; rules. And save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Updates&#039;&#039;&#039; tab is used to check the status of downloaded rules packages and to download new updates. The table shows the available rule packages and their current status [[Image:Gpil-019.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Update Button to Update the rules.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Add Snort to an interface ==&lt;br /&gt;
Click the Snort Interfaces tab and then the &amp;quot;+&amp;quot; icon to add a new Snort interface.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-020.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;On the &#039;&#039;&#039;WAN Settings&#039;&#039;&#039; tab, click the &#039;&#039;Enable&#039;&#039; checkbox.In the drop-down, choose the interface. &amp;amp;nbsp;The WAN interface is the default and is a good first choice.In the &#039;&#039;Description&#039;&#039; textbox, enter a name (WAN again, is fine here).Click the checkbox to &amp;quot;&#039;&#039;Send alerts to the main System logs&#039;&#039;&amp;quot;.leave the other settings at their defaults&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-021.jpg]]&lt;br /&gt;
&lt;br /&gt;
After saving, the browser will be returned to the Snort Interfaces tab. Note the warning icons in the image below showing no rules have been selected for the new Snort interface. Those rules will be configured next. Click the &amp;quot;e&amp;quot; icon to edit the new Snort interface again&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-022.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Select which types of rules will protect the network ==&lt;br /&gt;
Click the &#039;&#039;&#039;Categories&#039;&#039;&#039; tab for the new interface&lt;br /&gt;
&lt;br /&gt;
Check [https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=GPLv2_community.rules Snort GPLv2 Community Rules (VRT certified)] Box .&lt;br /&gt;
&lt;br /&gt;
And Manual Rules :-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-botcc.rules emerging-botcc.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_blacklist.rules snort_blacklist.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.so.rules snort_exploit-kit.so.rules] &lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_ddos.rules snort_ddos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_dos.rules snort_dos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.rules snort_exploit-kit.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-malware.rules emerging-malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-mobile_malware.rules emerging-mobile_malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-tor.rules emerging-tor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-trojan.rules emerging-trojan.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_malware-backdoor.rules snort_malware-backdoor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_virus.rules snort_virus.rules]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-023.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click SAVE when finished to save the selection and build the rules &lt;br /&gt;
&lt;br /&gt;
After that restart the service &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-024.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Managing Pass lists:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Pass Lists are lists of IP addresses that Snort should never block. These may be created and managed on the Pass Lists tab. When an IP address is listed on a Pass List, Snort will never insert a block on that address even when malicious traffic is detected.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;To create a new Pass List, click &amp;quot;+&amp;quot;. To edit an existing Pass List, click the &amp;quot;e&amp;quot;. To delete a Pass List, click &amp;quot;x&amp;quot;. Note that a Pass List may not be deleted if it is currently assigned to one or more Snort interfaces.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We have added GIPL IP’s in Pass list . i.e&#039;&#039;&#039; &amp;lt;u&amp;gt;203.77.192.0/20&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-025.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== IP Alias and Port Alias ==&lt;br /&gt;
IP aliases allow you to create a group of IP addresses that you can assign by group name instead of specifying each IP address individually. This can be great for specifying a group of servers that need ssh access and then in the firewall rules you can create a rule that allows ssh traffic for the ssh servers group.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Along the top menu hover over Firewall and click on Aliases.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-026.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The next tab is for setting up Port Aliases. &amp;amp;nbsp;Similar to the IP Aliases you can setup groups but on this tab you are creating groups of ports instead of IP addresses.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-027.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
IP Aliases Created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-028.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
PORT ALIAS CREATED&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-029.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Firewall Rules :- ==&lt;br /&gt;
Reference:- [https://doc.pfsense.org/index.php/Firewall_Rule_Basics https://doc.pfsense.org/index.php/Firewall_Rule_Basics]&lt;br /&gt;
&lt;br /&gt;
Firewall rules control what traffic is allowed to enter an interface on the firewall. Once traffic is passed on the interface it enters an entry in the state table is created. A state table entry allows through subsequent packets that are part of that connection.&lt;br /&gt;
&lt;br /&gt;
Firewall rules are managed at Firewall &amp;gt; Rules. Multiple rules may be selected for some actions by clicking on their row or checking the box at the start of their row. Rules may be deleted or reordered in bulk in this way. See Managing Lists of Items on pfSense for more information on the meaning of the icons when manipulating rules.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;any&#039;&#039;&#039; - &#039;&#039;0.0.0.0&#039;&#039; to &#039;&#039;255.255.255.255&#039;&#039;, or all IPv6 addresses &lt;br /&gt;
* &#039;&#039;&#039;Single host or alias&#039;&#039;&#039; - Select this and enter one IP address (&#039;&#039;1.2.3.4&#039;&#039;, &#039;&#039;aa:bb:cc:dd::1&#039;&#039;) or type the name of an Alias that has already been configured (&#039;&#039;&#039;Firewall &amp;gt; Aliases&#039;&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Network&#039;&#039;&#039; - Select this and enter a network and mask (&#039;&#039;10.99.0.0/16&#039;&#039;, &#039;&#039;aa:bb:cc:dd::0/64&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;LAN net&#039;&#039;&#039; - The subnet configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039;. On pfSense 2.2+, this also includes static route networks on that interface. &lt;br /&gt;
* &#039;&#039;&#039;LAN address&#039;&#039;&#039; - The IP address configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039; &lt;br /&gt;
* &#039;&#039;&#039;zzz Net&#039;&#039;&#039; / &#039;&#039;&#039;zzz address&#039;&#039;&#039; - Works the same as LAN above but for other interfaces (WAN, OPT1, OPT2, etc.) &lt;br /&gt;
* &#039;&#039;&#039;PPTP clients&#039;&#039;&#039; - Automatically locate and use the addresses of PPTP clients &lt;br /&gt;
* &#039;&#039;&#039;L2TP clients&#039;&#039;&#039; - Automatically locate and use the addresses of L2TP clients &lt;br /&gt;
* &#039;&#039;&#039;This Firewall (self)&#039;&#039;&#039; - Any IP address assigned to any interface on this firewall (pfSense 2.2+) &lt;br /&gt;
&lt;br /&gt;
Firewall rules are generally processed starting with Floating Rules, then Interface Group rules, then Interface tab rules&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Rules Created on bridge interface, for DMZ access&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-030.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-031.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface Rules Created:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-032.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Squid and Squidguard:- ==&lt;br /&gt;
&#039;&#039;&#039;Reference - &#039;&#039;&#039;[https://doc.pfsense.org/index.php/SquidGuard_package https://doc.pfsense.org/index.php/SquidGuard_package]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Login to your pfsense&#039;s Web Administrator, and click on &amp;quot;Server -&amp;gt; Packages&amp;quot;, scroll down the list and find squid and click on &amp;quot;+&amp;quot; button to install, wait for the process to finish then return to the packages section and look for squidguard and install that package as well.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-033.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now go to &amp;quot;Services&amp;quot; menu and look for Proxy Server &amp;amp; Proxy Filter &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-034.jpg]]&lt;br /&gt;
&lt;br /&gt;
(We are setting up the proxy server as a transparent proxy)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on Services -&amp;gt; Proxy Server.&lt;br /&gt;
&lt;br /&gt;
On the General Tab, you want to set the following settings, the Proxy Interface Option should be set to &amp;quot;LAN&amp;quot;, to set up transparent proxy server, tick the &amp;quot;Transparent Proxy&amp;quot; check box.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-035.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Tick the &amp;quot;Enabled Logging&amp;quot; Checkbox, set the log store to the default location &amp;quot; /var/squid/logs &amp;quot; rotate your logs every 30 days, set your proxy port to port number 3128 We have By-passed Proxy for 203.77.192.49/28, These are the Local Servers.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next click on the &amp;quot;Cache Mgmt.&amp;quot; tab, by default the Hard Disk Cache Size is set to 100mb, we have allocated 100GB , Memory Cache Size 3072 .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-036.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click on Save.&lt;br /&gt;
&lt;br /&gt;
Click on the Access Control Tab next, in the allowed subnets field type in your required subnets. As we have multiple Subnets, so we are going to define all.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-037.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.129/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.1.224.1/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.192.49/28&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.57/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.17/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.137/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.33.50.1/27&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click On Save &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that’s is the proxy server configured, next we are going to configure SquidGuard, click on the Services menu and select the Proxy Filter button, tick the following 3 check boxes &amp;quot;Enable&amp;quot;, &amp;quot;Enable GUI Log&amp;quot; and &amp;quot;Enable Log&amp;quot; then click the Save button, once the page has reloaded click on apply and then confirm that the Squidguard service is running by making sure the SquidGuard status is set to STARTED.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-038.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on the Black list tab and add URL &#039;&#039;&#039;http://www.shallalist.de/Downloads/shallalist.tar.gz&#039;&#039;&#039; to the Update Address and click on Download. Wait for the process to complete.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-039.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-040.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now we can set up common ACL’s&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-041.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-042.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Click on Save and restart the Squid and SquidGuard from Services. &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SARG:- ==&lt;br /&gt;
After Installing SARG package, we can configure SARG from Status &amp;gt; Sarg Reports&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-043.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select Proxy Servers as SQUID proxy . And leave Rest of Field set to Default&lt;br /&gt;
&lt;br /&gt;
And Save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Go to Next Tab Schedule&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click “+” Symbol to create new schedule &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-044.jpg]] &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Reports can be viewed From “View Reports”&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-045.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bandwidthd:- ==&lt;br /&gt;
After Installing Package &#039;&#039;&#039;bandwidthd&#039;&#039;&#039; , Configuration can be done via&lt;br /&gt;
&lt;br /&gt;
Services &amp;gt; bandwidthd&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-046.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-047.jpg]]&lt;br /&gt;
&lt;br /&gt;
Enable Bandwidthd by checking the BOX.&lt;br /&gt;
&lt;br /&gt;
Now Select the Interface: - LAN.&lt;br /&gt;
&lt;br /&gt;
Enter The Subnets from LAN interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Save and Restart bandwidthd service from Services.&lt;br /&gt;
&lt;br /&gt;
Now Bandwidthd can be accessed:-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/bandwidthd/index.html https://203.77.200.91:8080/bandwidthd/index.html]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of ntopng:- ==&lt;br /&gt;
After installing ntopng package, it appears under Diagnostics &amp;gt; ntopng. It will even track where connections were made by local PCs, and how much bandwidth was used on individual connections.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-048.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
First we have to configure ntopng settings. Via Diagnostics &amp;gt; ntopng settings.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-049.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Setup Admin Password &amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Select the Interfaces on Which ntopng will be monitoring traffic.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We have selected LAN, DMZ and BRIDGEINTERFACE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To save the changes Click “Change”&lt;br /&gt;
&lt;br /&gt;
Ntopng can be accessed via [http://203.77.200.91:3000/login.html http://203.77.200.91:3000/login.html]&lt;br /&gt;
&lt;br /&gt;
With username admin and password assigned in previous step.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Configuring OpenVPN  =&lt;br /&gt;
A VPN (virtual private network) allows us to connect directly to our home private network over the internet&lt;br /&gt;
&lt;br /&gt;
The certificate authority or CA will sign the certificates that we will be creating for the server and client side when we configure OpenVPN. You can access the certificate configuration by going over to System–&amp;gt;Cert Manager.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-050.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Under the CAs tab you might already have a CA created if you followed one of my previous articles as we needed to created one in order to sign an internal certificate to be used for securing the pfSense web interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Certificate Authority ===&lt;br /&gt;
Fill in the fields to &#039;&#039;&#039;create a new Certificate Authority&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Descriptive Name&#039;&#039;&#039; - Used as the Common Name (CN) for the CA. Do not spaces, punctuation or special characters (ex: &#039;&#039;VPN Server CA&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Key Length&#039;&#039;&#039; - Default is OK, the higher the better but will use more CPU. &lt;br /&gt;
* &#039;&#039;&#039;Lifetime&#039;&#039;&#039; - Default is OK, but can be lowered if it must be changed out more often. &lt;br /&gt;
* &#039;&#039;&#039;Country Code&#039;&#039;&#039;, &#039;&#039;&#039;State/Province&#039;&#039;&#039;, &#039;&#039;&#039;City&#039;&#039;&#039;, &#039;&#039;&#039;Organization&#039;&#039;&#039; - Enter values for this location/company. &lt;br /&gt;
* &#039;&#039;&#039;E-mail&#039;&#039;&#039; - Used as a reference on the certificate, does not receive any mail from the system. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Add New CA&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-051.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
After you finished setting up the CA the next step is to create some certificates that the recently created CA will sign for us. Since these are self-signed certificates most browsers will give you a warning&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Server Certificate ===&lt;br /&gt;
Fill in the fields to create a new &#039;&#039;&#039;Server Certificate&#039;&#039;&#039;. Similar Fields as CA entry, most of the fields carry over and do not need changed. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Create new Certificate&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-052.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that we have all the components in place we can configure OpenVPN. Head over to VPN–&amp;gt;OpenVPN.&lt;br /&gt;
&lt;br /&gt;
.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-053.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select “Wizards” from the tab at the top which will guide us step by step to configure OpenVPN&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-054.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-055.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We will select the local user access database provided by pfSense&lt;br /&gt;
&lt;br /&gt;
In the next step we will be selecting the CA that we created at the beginning of this article.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-056.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Following is the Server Certificate that we will be using which is the Certificate that we recently created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-057.jpg]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;OpenVPN Server Configuration&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;TLS Authentication&#039;&#039;&#039; -- Leave this checked, along with the box underneath to generate a new key. Using a TLS key is technically optional, but &#039;&#039;highly&#039;&#039; recommended&lt;br /&gt;
* &#039;&#039;&#039;Tunnel Network&#039;&#039;&#039; -- Should be a new, unique network that does not exist anywhere in the current network or routing table. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-058.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-059.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-060.jpg]]&lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== Firewall Rules ===&lt;br /&gt;
The next screen offers the choice to add firewall rules automatically. For convenience, check both unless the rules will be managed manually. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== End of the Wizard ===&lt;br /&gt;
Click &#039;&#039;&#039;Finish&#039;&#039;&#039; to exit the wizard and the new settings will be saved and applied automatically. &lt;br /&gt;
&lt;br /&gt;
== Adding a User with a Certificate ==&lt;br /&gt;
Navigate to &#039;&#039;&#039;System &amp;gt; User Manager&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click &amp;quot;+&amp;quot; To add a &#039;&#039;&#039;user&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Username&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Password / Confirm password&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Check Click to create a &#039;&#039;&#039;user certificate.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in the Descriptive Name as the username&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-061.jpg]]&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-062.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The OpenVPN Client Export Package allows exporting configurations formatted for a wide variety of platforms. It also allows exporting a pre-packaged Windows installer executable which includes the configuration bundled inside for a painly client installation. &lt;br /&gt;
&lt;br /&gt;
=== Installing the OpenVPN Client Export Package ===&lt;br /&gt;
To Install the OpenVPN Client Export Package &lt;br /&gt;
&lt;br /&gt;
* Navigate to &#039;&#039;&#039;System &amp;gt; Packages&#039;&#039;&#039;, &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab &lt;br /&gt;
* Find &#039;&#039;&#039;OpenVPN Client Export Package&#039;&#039;&#039; in the list &lt;br /&gt;
&lt;br /&gt;
=== Exporting a Configuration ===&lt;br /&gt;
* Navigate to &#039;&#039;&#039;VPN &amp;gt; OpenVPN&#039;&#039;&#039; on the &#039;&#039;&#039;Client Export&#039;&#039;&#039; tab &lt;br /&gt;
* Choose the VPN from the &#039;&#039;&#039;Remote Access Server&#039;&#039;&#039; drop-down list &lt;br /&gt;
* Find the user in the list at the bottom of the page and select the appropriate configuration type to export. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-063.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-064.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Multiple instance of VPN server can be created with different tunnel network &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-065.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Firewall Rules are applied as per the requirement on tunnel network .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-066.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Firewall Logs =&lt;br /&gt;
The Firewall logs at &#039;&#039;&#039;Status &amp;gt; System Logs&#039;&#039;&#039; on the &#039;&#039;&#039;Firewall&#039;&#039;&#039; tab show all events logged by the firewall.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Each entry is displayed with the action ( pass or block, reject is only logged as block), time, interface, source, destination, and protocol.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Configuration Of rsyslog Server for Logs Storage:-&lt;br /&gt;
&lt;br /&gt;
Status: &amp;gt;System logs &amp;gt; Settings&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-067.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Configuration of rsyslog on Centos :-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Setup Log File Location =====&lt;br /&gt;
Now edit Rsyslog configuration file and configure the location’s to generate log files in system.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# vim /etc/rsyslog.conf&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
and add following lines as the end of file.&lt;br /&gt;
&lt;br /&gt;
$template TmplAuth, &amp;quot;/var/log/%HOSTNAME%/%PROGRAMNAME%.log&amp;quot; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
authpriv.* ?TmplAuth&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;*.info,mail.none,authpriv.none,cron.none &amp;lt;/nowiki&amp;gt;?TmplMsg&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Enable Module and UDP Protocol =====&lt;br /&gt;
Also remove comment from following lines ( remove starting # ) in rsyslog configuration file to enable UDP.&lt;br /&gt;
&lt;br /&gt;
$ModLoad imudp&lt;br /&gt;
&lt;br /&gt;
$UDPServerRun 514&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Restart Rsyslog  =====&lt;br /&gt;
After making above changes in Rsyslog central server, restart service using following command.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# service rsyslog restart&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Logrotation:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Create file&#039;&#039;&#039; :- &#039;&#039;&#039;/etc/logrotate.d/pfsense&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;And enter:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/var/log/pfsense/filterlog.log&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;{&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;daily&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;missingok&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;rotate 60&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;compress&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;notifempty&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;create 640 root root&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;postrotate&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/etc/init.d/rsyslog restart &amp;gt;/dev/null&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;endscript&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;}&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Save and Quit.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;RRD Graphs:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
These are located under &#039;&#039;&#039;Status &amp;gt; RRD Graphs&#039;&#039;&#039;. Several graphs are presented for each monitored item, with varying time intervals and averages. &lt;br /&gt;
&lt;br /&gt;
These graphs measure things such as CPU usage, memory usage, state table usage, throughput (in bytes as well as packets), link quality, traffic shaping queue usage, and so on. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-068.jpg]]&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1891</id>
		<title>PF Sense Firewall Implementation at GIPL</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=PF_Sense_Firewall_Implementation_at_GIPL&amp;diff=1891"/>
		<updated>2015-04-16T10:21:11Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;center&amp;gt;&amp;lt;u&amp;gt;&#039;&#039;&#039;PF Sense Firewall Implementation at GIPL , GandhiNagar &#039;&#039;&#039;&amp;lt;/u&amp;gt;&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Table of Contents ==&lt;br /&gt;
[#__RefHeading__2322_1445225205 NETWORK DIAGRAM2]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2324_1445225205 Performing a Full Install (LiveCD)3]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2326_1445225205 GUI Configuration Setup8]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2328_1445225205 Configuration Of Bridge Interface13]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2330_1445225205 Assign Virtual IP’s To LAN interface:-15]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2332_1445225205 Configuration of SNORT17]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2334_1445225205 Add Snort to an interface20]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2336_1445225205 Select which types of rules will protect the network22]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2338_1445225205 IP Alias and Port Alias24]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2340_1445225205 Firewall Rules :-27]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2342_1445225205 Configuration Of Squid and Squidguard:-31]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2344_1445225205 Configuration of SARG:-39]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2346_1445225205 Configuration Of Bandwidthd:-42]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2348_1445225205 Configuration Of ntopng:-44]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2350_1445225205 Configuring OpenVPN46]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2352_1445225205 Certificate Authority47]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2354_1445225205 Server Certificate48]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2356_1445225205 Firewall Rules54]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2358_1445225205 End of the Wizard54]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2360_1445225205 Adding a User with a Certificate54]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2362_1445225205 Installing the OpenVPN Client Export Package57]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2364_1445225205 Exporting a Configuration57]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2366_1445225205 Firewall Logs60]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2368_1445225205 Setup Log File Location61]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2370_1445225205 Enable Module and UDP Protocol61]&lt;br /&gt;
&lt;br /&gt;
[#__RefHeading__2372_1445225205 Restart Rsyslog61]= NETWORK DIAGRAM =&lt;br /&gt;
[[Image:Gpil-000.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Installation&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;pfSense&#039;&#039;&#039; is an open source firewall/router computer software distribution based on FreeBSD. It is installed on a computer to make a dedicated firewall/router for a network and is noted for its reliability[1] and offering features often only found in expensive commercial firewalls&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Download pfSense&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Visit https://www.pfsense.org/download/mirror.php?section=downloads&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Step 1 :- &#039;&#039;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Performing a Full Install (LiveCD) ==&lt;br /&gt;
Power on the target system and connect the install media: Place the CD into the drive or plug the Memstick into a USB port. If the BIOS is set to boot from CD/USB, pfSense will start. &lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-001.jpeg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
As the operating system boots and pfSense starts, a prompt is presented with some choices and a countdown timer. At this prompt, press &#039;&#039;i&#039;&#039; to invoke the installer now.&lt;br /&gt;
&lt;br /&gt;
When the installer detects multiple disks in the system the first screen available provides the option &#039;&#039;&#039;Setup GEOM Mirror&#039;&#039;&#039;. Choose that option, pick the primary disk, the disk to use for the mirror copy, and then proceed with the installation as normal. &lt;br /&gt;
&lt;br /&gt;
The Quick/Easy install choice will target the GEOM mirror automatically&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-002.jpeg]]&lt;br /&gt;
&lt;br /&gt;
At the &#039;&#039;&#039;Select Task&#039;&#039;&#039; prompt, choose &#039;&#039;Quick/Easy Install&#039;&#039;. [[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-003.jpeg]]&lt;br /&gt;
&lt;br /&gt;
The install will proceed, wiping the target disk and installing pfSense. Copying files may take some time to finish. &lt;br /&gt;
&lt;br /&gt;
After the files have been copied to the target disk, a choice is presented to select the console type. &#039;&#039;Standard&#039;&#039; defaults to the VGA console. &#039;&#039;Embedded&#039;&#039; defaults to serial console&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-004.jpeg]]&lt;br /&gt;
&lt;br /&gt;
Now the system must reboot so that pfSense may start from the target disk. Select &#039;&#039;Reboot&#039;&#039; and then press &#039;&#039;&#039;Enter (remove CD from Drive)&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-005.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After the system reboots, pfSense will be running from the target disk. The next step is to Assign Interfaces on the Console below.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-006.jpeg]]&lt;br /&gt;
&lt;br /&gt;
After installation and assignment, a shell menu is presented on the console with a number of options. pfSense now is ready to be accessed via the network, LAN interface IP 192.168.1.1 is assigned by default.&lt;br /&gt;
&lt;br /&gt;
Open a web browser and navigate to https://192.168.1.1/, using the default username admin and password pfsense to login.&lt;br /&gt;
&lt;br /&gt;
The first visit to the WebGUI will be redirected to the setup wizard.&lt;br /&gt;
&lt;br /&gt;
== GUI Configuration Setup ==&lt;br /&gt;
Once The Setup is launched, Fill the details are follows:-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-007.jpeg]]&lt;br /&gt;
&lt;br /&gt;
We have defined FQDN as gipl.firewall&lt;br /&gt;
&lt;br /&gt;
DNS servers:- 8.8.8.8 and 4.4.2.2 Global DNS&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click NEXT&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-008.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select The Time-Zone as Asia/Kolkata .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
And Click NEXT&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-009.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Here we have Set WAN as Static Interface&lt;br /&gt;
&lt;br /&gt;
With IP address :- 203.77.200.91/25&lt;br /&gt;
&lt;br /&gt;
Gateway :- 203.77.200.1&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-010.jpg]]&lt;br /&gt;
&lt;br /&gt;
Here we have Configured LAN interface with IP address 192.168.45.101/24&lt;br /&gt;
&lt;br /&gt;
Click Next.&lt;br /&gt;
&lt;br /&gt;
( note:-As per the client Network Topology , Lan interface have multiple Subnets configured , so we will be configuring Virtual IP’s from GUI )&lt;br /&gt;
&lt;br /&gt;
After Setting Admin Password, Page will be redirected to Pfsense-Dashboard.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-011.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We Have Changed Default Port from 443 to 8080 Via :-&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;System &amp;gt; Advanced&#039;&#039;&#039;&lt;br /&gt;
[[Image:Gpil-012.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Change TCP Port from Default 443 to 8080 .&lt;br /&gt;
[[Image:Gpil-013.jpg]] &lt;br /&gt;
Save .&lt;br /&gt;
&lt;br /&gt;
Now pfsense Can be accessed via [https://IP:8080 https://IP:8080]&lt;br /&gt;
&lt;br /&gt;
IP Address of Firewall is 203.77.200.91 on WAN interface.&lt;br /&gt;
&lt;br /&gt;
Go to :- interface &amp;gt; assign , and edit Opt1 as DMZ , do not assign IP address to This interface , because we will be creating bridge interface .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bridge Interface ==&lt;br /&gt;
Now we have to configure &#039;&#039;&#039;Interface Bridges&#039;&#039;&#039; in order to Setup Pfsense in &lt;br /&gt;
&lt;br /&gt;
Transparent mode.&lt;br /&gt;
&lt;br /&gt;
Reference:- &amp;lt;u&amp;gt;https://doc.pfsense.org/index.php/Interface_Bridges&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Navigate To :- Interfaces &amp;gt; (assign) &lt;br /&gt;
&lt;br /&gt;
on the Bridges tab Click “ +” symbol to add a new bridge .&lt;br /&gt;
&lt;br /&gt;
Ctrl-Click to select the Member interfaces from the list of available interfaces and type a Description , we have selected WAN + DMZ as bridge0 and create new Interface BRIDGEINTERFACE using bridge0 .&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-014.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
By default, traffic is filtered on the member interfaces and not on the bridge interface itself. This behavior may be changed by toggling the values of &#039;&#039;&#039;net.link.bridge.pfil_member&#039;&#039;&#039; and net.link.bridge.pfil&#039;&#039;&#039;_bridge &#039;&#039;&#039;under System&#039;&#039;&#039; &amp;gt; Advanced &#039;&#039;&#039;on the &#039;&#039;&#039;System Tunables&#039;&#039;&#039; tab. With them set at &#039;&#039;0&#039;&#039; and &#039;&#039;1&#039;&#039;, respectively, then filtering would be performed on the bridge only.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-015.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Pfsense is Configured In Bridge Mode with &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;WAN interface: - 203.77.200.91/25 gateway :- 203.77.200.1&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface:- 192.168.45.101/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;DMZ: - no ip &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;BRIDGEINTERFACE:- 203.77.200.92/25&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-016.jpg]]&lt;br /&gt;
&lt;br /&gt;
== Assign Virtual IP’s To LAN interface:- ==&lt;br /&gt;
[[Image:Gpil-018.jpg]]&lt;br /&gt;
Now as LAN environment have multiple Subnet configured, we will be assigning Virtual IP address to LAN interface.&lt;br /&gt;
&lt;br /&gt;
[[Image:Gpil-017.jpg]]&lt;br /&gt;
&lt;br /&gt;
Clients on LAN Environment have their Gateway Set from These Virtual IP’s.&lt;br /&gt;
&lt;br /&gt;
203.77.196.230 is added for outside access of Local Servers 203.77.192.49/28.&lt;br /&gt;
&lt;br /&gt;
(203.77.196.230) is configured in 203.77.192.2 switch which will receive any packet for 203.77.192.49/28 from Outside and send it to 203.77.196.230.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SNORT  ==&lt;br /&gt;
&amp;lt;u&amp;gt;&#039;&#039;&#039;Reference&#039;&#039;&#039;&amp;lt;/u&amp;gt; :- &amp;lt;u&amp;gt;&#039;&#039;&#039;https://doc.pfsense.org/index.php/Setup_Snort_Package&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Go to the &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab under the &#039;&#039;&#039;System&#039;&#039;&#039; menu and install the snort package.&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;When the installation completes, click on &#039;&#039;&#039;Snort&#039;&#039;&#039; under the &#039;&#039;&#039;Services&#039;&#039;&#039; menu. &amp;amp;nbsp;This will open the Snort main setup page.&lt;br /&gt;
&lt;br /&gt;
Click the &#039;&#039;&#039;Global Settings&#039;&#039;&#039; tab and perform the following At the top of the page you have three choices for Rule Sets to activate.&lt;br /&gt;
&lt;br /&gt;
Put Check mark on :-Install &#039;&#039;&#039;Snort Community&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Emerging Threats&#039;&#039;&#039; rules , Install &#039;&#039;&#039;Snort VRT&#039;&#039;&#039; rules. And save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;Updates&#039;&#039;&#039; tab is used to check the status of downloaded rules packages and to download new updates. The table shows the available rule packages and their current status [[Image:Gpil-019.jpg]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Update Button to Update the rules.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Add Snort to an interface ==&lt;br /&gt;
Click the Snort Interfaces tab and then the &amp;quot;+&amp;quot; icon to add a new Snort interface.&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&amp;amp;nbsp;On the &#039;&#039;&#039;WAN Settings&#039;&#039;&#039; tab, click the &#039;&#039;Enable&#039;&#039; checkbox.In the drop-down, choose the interface. &amp;amp;nbsp;The WAN interface is the default and is a good first choice.In the &#039;&#039;Description&#039;&#039; textbox, enter a name (WAN again, is fine here).Click the checkbox to &amp;quot;&#039;&#039;Send alerts to the main System logs&#039;&#039;&amp;quot;.leave the other settings at their defaults&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
After saving, the browser will be returned to the Snort Interfaces tab. Note the warning icons in the image below showing no rules have been selected for the new Snort interface. Those rules will be configured next. Click the &amp;quot;e&amp;quot; icon to edit the new Snort interface again&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Select which types of rules will protect the network ==&lt;br /&gt;
Click the &#039;&#039;&#039;Categories&#039;&#039;&#039; tab for the new interface&lt;br /&gt;
&lt;br /&gt;
Check [https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=GPLv2_community.rules Snort GPLv2 Community Rules (VRT certified)] Box .&lt;br /&gt;
&lt;br /&gt;
And Manual Rules :-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-botcc.rules emerging-botcc.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_blacklist.rules snort_blacklist.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.so.rules snort_exploit-kit.so.rules] &lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_ddos.rules snort_ddos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_dos.rules snort_dos.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_exploit-kit.rules snort_exploit-kit.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-malware.rules emerging-malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-mobile_malware.rules emerging-mobile_malware.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-tor.rules emerging-tor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=emerging-trojan.rules emerging-trojan.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_malware-backdoor.rules snort_malware-backdoor.rules]&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/snort/snort_rules.php?id=0&amp;amp;openruleset=snort_virus.rules snort_virus.rules]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
Click SAVE when finished to save the selection and build the rules &lt;br /&gt;
&lt;br /&gt;
After that restart the service &lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Managing Pass lists:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Pass Lists are lists of IP addresses that Snort should never block. These may be created and managed on the Pass Lists tab. When an IP address is listed on a Pass List, Snort will never insert a block on that address even when malicious traffic is detected.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;To create a new Pass List, click &amp;quot;+&amp;quot;. To edit an existing Pass List, click the &amp;quot;e&amp;quot;. To delete a Pass List, click &amp;quot;x&amp;quot;. Note that a Pass List may not be deleted if it is currently assigned to one or more Snort interfaces.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
We have added GIPL IP’s in Pass list . i.e&#039;&#039;&#039; &amp;lt;u&amp;gt;203.77.192.0/20&#039;&#039;&#039;&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== IP Alias and Port Alias ==&lt;br /&gt;
IP aliases allow you to create a group of IP addresses that you can assign by group name instead of specifying each IP address individually. This can be great for specifying a group of servers that need ssh access and then in the firewall rules you can create a rule that allows ssh traffic for the ssh servers group.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Along the top menu hover over Firewall and click on Aliases.&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The next tab is for setting up Port Aliases. &amp;amp;nbsp;Similar to the IP Aliases you can setup groups but on this tab you are creating groups of ports instead of IP addresses.&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
IP Aliases Created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
PORT ALIAS CREATED&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Firewall Rules :- ==&lt;br /&gt;
Reference:- [https://doc.pfsense.org/index.php/Firewall_Rule_Basics https://doc.pfsense.org/index.php/Firewall_Rule_Basics]&lt;br /&gt;
&lt;br /&gt;
Firewall rules control what traffic is allowed to enter an interface on the firewall. Once traffic is passed on the interface it enters an entry in the state table is created. A state table entry allows through subsequent packets that are part of that connection.&lt;br /&gt;
&lt;br /&gt;
Firewall rules are managed at Firewall &amp;gt; Rules. Multiple rules may be selected for some actions by clicking on their row or checking the box at the start of their row. Rules may be deleted or reordered in bulk in this way. See Managing Lists of Items on pfSense for more information on the meaning of the icons when manipulating rules.&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;any&#039;&#039;&#039; - &#039;&#039;0.0.0.0&#039;&#039; to &#039;&#039;255.255.255.255&#039;&#039;, or all IPv6 addresses &lt;br /&gt;
* &#039;&#039;&#039;Single host or alias&#039;&#039;&#039; - Select this and enter one IP address (&#039;&#039;1.2.3.4&#039;&#039;, &#039;&#039;aa:bb:cc:dd::1&#039;&#039;) or type the name of an Alias that has already been configured (&#039;&#039;&#039;Firewall &amp;gt; Aliases&#039;&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Network&#039;&#039;&#039; - Select this and enter a network and mask (&#039;&#039;10.99.0.0/16&#039;&#039;, &#039;&#039;aa:bb:cc:dd::0/64&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;LAN net&#039;&#039;&#039; - The subnet configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039;. On pfSense 2.2+, this also includes static route networks on that interface. &lt;br /&gt;
* &#039;&#039;&#039;LAN address&#039;&#039;&#039; - The IP address configured on the LAN interface under &#039;&#039;&#039;Interfaces &amp;gt; LAN&#039;&#039;&#039; &lt;br /&gt;
* &#039;&#039;&#039;zzz Net&#039;&#039;&#039; / &#039;&#039;&#039;zzz address&#039;&#039;&#039; - Works the same as LAN above but for other interfaces (WAN, OPT1, OPT2, etc.) &lt;br /&gt;
* &#039;&#039;&#039;PPTP clients&#039;&#039;&#039; - Automatically locate and use the addresses of PPTP clients &lt;br /&gt;
* &#039;&#039;&#039;L2TP clients&#039;&#039;&#039; - Automatically locate and use the addresses of L2TP clients &lt;br /&gt;
* &#039;&#039;&#039;This Firewall (self)&#039;&#039;&#039; - Any IP address assigned to any interface on this firewall (pfSense 2.2+) &lt;br /&gt;
&lt;br /&gt;
Firewall rules are generally processed starting with Floating Rules, then Interface Group rules, then Interface tab rules&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Rules Created on bridge interface, for DMZ access&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;LAN interface Rules Created:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Squid and Squidguard:- ==&lt;br /&gt;
&#039;&#039;&#039;Reference - &#039;&#039;&#039;[https://doc.pfsense.org/index.php/SquidGuard_package https://doc.pfsense.org/index.php/SquidGuard_package]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Login to your pfsense&#039;s Web Administrator, and click on &amp;quot;Server -&amp;gt; Packages&amp;quot;, scroll down the list and find squid and click on &amp;quot;+&amp;quot; button to install, wait for the process to finish then return to the packages section and look for squidguard and install that package as well.&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now go to &amp;quot;Services&amp;quot; menu and look for Proxy Server &amp;amp; Proxy Filter &lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
(We are setting up the proxy server as a transparent proxy)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on Services -&amp;gt; Proxy Server.&lt;br /&gt;
&lt;br /&gt;
On the General Tab, you want to set the following settings, the Proxy Interface Option should be set to &amp;quot;LAN&amp;quot;, to set up transparent proxy server, tick the &amp;quot;Transparent Proxy&amp;quot; check box.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Tick the &amp;quot;Enabled Logging&amp;quot; Checkbox, set the log store to the default location &amp;quot; /var/squid/logs &amp;quot; rotate your logs every 30 days, set your proxy port to port number 3128 We have By-passed Proxy for 203.77.192.49/28, These are the Local Servers.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Next click on the &amp;quot;Cache Mgmt.&amp;quot; tab, by default the Hard Disk Cache Size is set to 100mb, we have allocated 100GB , Memory Cache Size 3072 .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
Click on Save.&lt;br /&gt;
&lt;br /&gt;
Click on the Access Control Tab next, in the allowed subnets field type in your required subnets. As we have multiple Subnets, so we are going to define all.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.129/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.1.224.1/24&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.192.49/28&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.57/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.206.17/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;203.77.201.137/29&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;10.33.50.1/27&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click On Save &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that’s is the proxy server configured, next we are going to configure SquidGuard, click on the Services menu and select the Proxy Filter button, tick the following 3 check boxes &amp;quot;Enable&amp;quot;, &amp;quot;Enable GUI Log&amp;quot; and &amp;quot;Enable Log&amp;quot; then click the Save button, once the page has reloaded click on apply and then confirm that the Squidguard service is running by making sure the SquidGuard status is set to STARTED.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click on the Black list tab and add URL &#039;&#039;&#039;http://www.shallalist.de/Downloads/shallalist.tar.gz&#039;&#039;&#039; to the Update Address and click on Download. Wait for the process to complete.&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now we can set up common ACL’s&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Click on Save and restart the Squid and SquidGuard from Services. &#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration of SARG:- ==&lt;br /&gt;
After Installing SARG package, we can configure SARG from Status &amp;gt; Sarg Reports&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select Proxy Servers as SQUID proxy . And leave Rest of Field set to Default&lt;br /&gt;
&lt;br /&gt;
And Save.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Now Go to Next Tab Schedule&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click “+” Symbol to create new schedule &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]] &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Reports can be viewed From “View Reports”&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of Bandwidthd:- ==&lt;br /&gt;
After Installing Package &#039;&#039;&#039;bandwidthd&#039;&#039;&#039; , Configuration can be done via&lt;br /&gt;
&lt;br /&gt;
Services &amp;gt; bandwidthd&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
Enable Bandwidthd by checking the BOX.&lt;br /&gt;
&lt;br /&gt;
Now Select the Interface: - LAN.&lt;br /&gt;
&lt;br /&gt;
Enter The Subnets from LAN interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click Save and Restart bandwidthd service from Services.&lt;br /&gt;
&lt;br /&gt;
Now Bandwidthd can be accessed:-&lt;br /&gt;
&lt;br /&gt;
[https://203.77.200.91:8080/bandwidthd/index.html https://203.77.200.91:8080/bandwidthd/index.html]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Configuration Of ntopng:- ==&lt;br /&gt;
After installing ntopng package, it appears under Diagnostics &amp;gt; ntopng. It will even track where connections were made by local PCs, and how much bandwidth was used on individual connections.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
First we have to configure ntopng settings. Via Diagnostics &amp;gt; ntopng settings.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Setup Admin Password &amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# Select the Interfaces on Which ntopng will be monitoring traffic.&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We have selected LAN, DMZ and BRIDGEINTERFACE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To save the changes Click “Change”&lt;br /&gt;
&lt;br /&gt;
Ntopng can be accessed via [http://203.77.200.91:3000/login.html http://203.77.200.91:3000/login.html]&lt;br /&gt;
&lt;br /&gt;
With username admin and password assigned in previous step.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Configuring OpenVPN  =&lt;br /&gt;
A VPN (virtual private network) allows us to connect directly to our home private network over the internet&lt;br /&gt;
&lt;br /&gt;
The certificate authority or CA will sign the certificates that we will be creating for the server and client side when we configure OpenVPN. You can access the certificate configuration by going over to System–&amp;gt;Cert Manager.&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Under the CAs tab you might already have a CA created if you followed one of my previous articles as we needed to created one in order to sign an internal certificate to be used for securing the pfSense web interface.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Certificate Authority ===&lt;br /&gt;
Fill in the fields to &#039;&#039;&#039;create a new Certificate Authority&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Descriptive Name&#039;&#039;&#039; - Used as the Common Name (CN) for the CA. Do not spaces, punctuation or special characters (ex: &#039;&#039;VPN Server CA&#039;&#039;) &lt;br /&gt;
* &#039;&#039;&#039;Key Length&#039;&#039;&#039; - Default is OK, the higher the better but will use more CPU. &lt;br /&gt;
* &#039;&#039;&#039;Lifetime&#039;&#039;&#039; - Default is OK, but can be lowered if it must be changed out more often. &lt;br /&gt;
* &#039;&#039;&#039;Country Code&#039;&#039;&#039;, &#039;&#039;&#039;State/Province&#039;&#039;&#039;, &#039;&#039;&#039;City&#039;&#039;&#039;, &#039;&#039;&#039;Organization&#039;&#039;&#039; - Enter values for this location/company. &lt;br /&gt;
* &#039;&#039;&#039;E-mail&#039;&#039;&#039; - Used as a reference on the certificate, does not receive any mail from the system. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Add New CA&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
After you finished setting up the CA the next step is to create some certificates that the recently created CA will sign for us. Since these are self-signed certificates most browsers will give you a warning&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Server Certificate ===&lt;br /&gt;
Fill in the fields to create a new &#039;&#039;&#039;Server Certificate&#039;&#039;&#039;. Similar Fields as CA entry, most of the fields carry over and do not need changed. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Create new Certificate&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now that we have all the components in place we can configure OpenVPN. Head over to VPN–&amp;gt;OpenVPN.&lt;br /&gt;
&lt;br /&gt;
.&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Select “Wizards” from the tab at the top which will guide us step by step to configure OpenVPN&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
We will select the local user access database provided by pfSense&lt;br /&gt;
&lt;br /&gt;
In the next step we will be selecting the CA that we created at the beginning of this article.&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Following is the Server Certificate that we will be using which is the Certificate that we recently created.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;OpenVPN Server Configuration&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;TLS Authentication&#039;&#039;&#039; -- Leave this checked, along with the box underneath to generate a new key. Using a TLS key is technically optional, but &#039;&#039;highly&#039;&#039; recommended&lt;br /&gt;
* &#039;&#039;&#039;Tunnel Network&#039;&#039;&#039; -- Should be a new, unique network that does not exist anywhere in the current network or routing table. &lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== Firewall Rules ===&lt;br /&gt;
The next screen offers the choice to add firewall rules automatically. For convenience, check both unless the rules will be managed manually. &lt;br /&gt;
&lt;br /&gt;
Click &#039;&#039;&#039;Next&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
=== End of the Wizard ===&lt;br /&gt;
Click &#039;&#039;&#039;Finish&#039;&#039;&#039; to exit the wizard and the new settings will be saved and applied automatically. &lt;br /&gt;
&lt;br /&gt;
== Adding a User with a Certificate ==&lt;br /&gt;
Navigate to &#039;&#039;&#039;System &amp;gt; User Manager&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Click &amp;quot;+&amp;quot; To add a &#039;&#039;&#039;user&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Username&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in &#039;&#039;&#039;Password / Confirm password&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Check Click to create a &#039;&#039;&#039;user certificate.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Fill in the Descriptive Name as the username&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The OpenVPN Client Export Package allows exporting configurations formatted for a wide variety of platforms. It also allows exporting a pre-packaged Windows installer executable which includes the configuration bundled inside for a painly client installation. &lt;br /&gt;
&lt;br /&gt;
=== Installing the OpenVPN Client Export Package ===&lt;br /&gt;
To Install the OpenVPN Client Export Package &lt;br /&gt;
&lt;br /&gt;
* Navigate to &#039;&#039;&#039;System &amp;gt; Packages&#039;&#039;&#039;, &#039;&#039;&#039;Available Packages&#039;&#039;&#039; tab &lt;br /&gt;
* Find &#039;&#039;&#039;OpenVPN Client Export Package&#039;&#039;&#039; in the list &lt;br /&gt;
&lt;br /&gt;
=== Exporting a Configuration ===&lt;br /&gt;
* Navigate to &#039;&#039;&#039;VPN &amp;gt; OpenVPN&#039;&#039;&#039; on the &#039;&#039;&#039;Client Export&#039;&#039;&#039; tab &lt;br /&gt;
* Choose the VPN from the &#039;&#039;&#039;Remote Access Server&#039;&#039;&#039; drop-down list &lt;br /&gt;
* Find the user in the list at the bottom of the page and select the appropriate configuration type to export. &lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Multiple instance of VPN server can be created with different tunnel network &lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Firewall Rules are applied as per the requirement on tunnel network .&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Firewall Logs =&lt;br /&gt;
The Firewall logs at &#039;&#039;&#039;Status &amp;gt; System Logs&#039;&#039;&#039; on the &#039;&#039;&#039;Firewall&#039;&#039;&#039; tab show all events logged by the firewall.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Each entry is displayed with the action ( pass or block, reject is only logged as block), time, interface, source, destination, and protocol.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Configuration Of rsyslog Server for Logs Storage:-&lt;br /&gt;
&lt;br /&gt;
Status: &amp;gt;System logs &amp;gt; Settings&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Configuration of rsyslog on Centos :-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Setup Log File Location =====&lt;br /&gt;
Now edit Rsyslog configuration file and configure the location’s to generate log files in system.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# vim /etc/rsyslog.conf&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
and add following lines as the end of file.&lt;br /&gt;
&lt;br /&gt;
$template TmplAuth, &amp;quot;/var/log/%HOSTNAME%/%PROGRAMNAME%.log&amp;quot; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
authpriv.* ?TmplAuth&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;*.info,mail.none,authpriv.none,cron.none &amp;lt;/nowiki&amp;gt;?TmplMsg&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Enable Module and UDP Protocol =====&lt;br /&gt;
Also remove comment from following lines ( remove starting # ) in rsyslog configuration file to enable UDP.&lt;br /&gt;
&lt;br /&gt;
$ModLoad imudp&lt;br /&gt;
&lt;br /&gt;
$UDPServerRun 514&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===== Restart Rsyslog  =====&lt;br /&gt;
After making above changes in Rsyslog central server, restart service using following command.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;# service rsyslog restart&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Logrotation:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Create file&#039;&#039;&#039; :- &#039;&#039;&#039;/etc/logrotate.d/pfsense&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;And enter:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/var/log/pfsense/filterlog.log&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;{&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;daily&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;missingok&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;rotate 60&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;compress&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;notifempty&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;create 640 root root&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;postrotate&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;/etc/init.d/rsyslog restart &amp;gt;/dev/null&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;endscript&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;}&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Save and Quit.&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;RRD Graphs:-&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
These are located under &#039;&#039;&#039;Status &amp;gt; RRD Graphs&#039;&#039;&#039;. Several graphs are presented for each monitored item, with varying time intervals and averages. &lt;br /&gt;
&lt;br /&gt;
These graphs measure things such as CPU usage, memory usage, state table usage, throughput (in bytes as well as packets), link quality, traffic shaping queue usage, and so on. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:]]&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=File:Gpil-069.jpg&amp;diff=1890</id>
		<title>File:Gpil-069.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=File:Gpil-069.jpg&amp;diff=1890"/>
		<updated>2015-04-16T09:59:26Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=File:Gpil-068.jpg&amp;diff=1889</id>
		<title>File:Gpil-068.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=File:Gpil-068.jpg&amp;diff=1889"/>
		<updated>2015-04-16T09:59:07Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=File:Gpil-067.jpeg&amp;diff=1888</id>
		<title>File:Gpil-067.jpeg</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=File:Gpil-067.jpeg&amp;diff=1888"/>
		<updated>2015-04-16T09:58:50Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=File:Gpil-066.jpg&amp;diff=1887</id>
		<title>File:Gpil-066.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=File:Gpil-066.jpg&amp;diff=1887"/>
		<updated>2015-04-16T09:58:32Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=File:Gpil-065.jpg&amp;diff=1886</id>
		<title>File:Gpil-065.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=File:Gpil-065.jpg&amp;diff=1886"/>
		<updated>2015-04-16T09:58:13Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=File:Gpil-064.jpg&amp;diff=1885</id>
		<title>File:Gpil-064.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=File:Gpil-064.jpg&amp;diff=1885"/>
		<updated>2015-04-16T09:57:53Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=File:Gpil-063.jpg&amp;diff=1884</id>
		<title>File:Gpil-063.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=File:Gpil-063.jpg&amp;diff=1884"/>
		<updated>2015-04-16T09:57:33Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=File:Gpil-062.jpeg&amp;diff=1883</id>
		<title>File:Gpil-062.jpeg</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=File:Gpil-062.jpeg&amp;diff=1883"/>
		<updated>2015-04-16T09:57:13Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
	<entry>
		<id>https://wiki.tetrain.com/index.php?title=File:Gpil-061.jpg&amp;diff=1882</id>
		<title>File:Gpil-061.jpg</title>
		<link rel="alternate" type="text/html" href="https://wiki.tetrain.com/index.php?title=File:Gpil-061.jpg&amp;diff=1882"/>
		<updated>2015-04-16T09:56:55Z</updated>

		<summary type="html">&lt;p&gt;Manojsemwal: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Manojsemwal</name></author>
	</entry>
</feed>