Forward Firewall: added GPL header to all files

This commit is contained in:
Alexander Marx
2013-08-13 12:44:01 +02:00
parent caca013c11
commit dc21519f68
11 changed files with 151 additions and 64 deletions

View File

@@ -1,17 +1,33 @@
#!/usr/bin/perl
########################################################################
# Script: convert-dmz
# Date: 03.04.2013
# Author: Alexander Marx (amarx@ipfire.org)
########################################################################
#
# This script converts old dmz holes rules from old Firewall
# to the new one. This is a 2-step process.
# STEP1: read old config and normalize settings
# STEP2: check valid ip and save valid rules to new firewall
#
########################################################################
###############################################################################
# #
# IPFire.org - A linux based firewall #
# Copyright (C) 2013 #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
# the Free Software Foundation, either version 3 of the License, or #
# (at your option) any later version. #
# #
# This program is distributed in the hope that it will be useful, #
# but WITHOUT ANY WARRANTY; without even the implied warranty of #
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
# GNU General Public License for more details. #
# #
# You should have received a copy of the GNU General Public License #
# along with this program. If not, see <http://www.gnu.org/licenses/>. #
# #
###############################################################################
# Author: Alexander Marx (amarx@ipfire.org) #
###############################################################################
# #
# This script converts old dmz holes rules from old firewall #
# to the new one. This is a 2-step process. #
# STEP1: read old config and normalize settings #
# STEP2: check valid ip and save valid rules to new firewall #
# #
###############################################################################
my @current=();
my @alias=();
my %configdmz=();

View File

@@ -1,17 +1,33 @@
#!/usr/bin/perl
########################################################################
# Script: convert-outgoingfw
# Date: 21.03.2013
# Author: Alexander Marx (amarx@ipfire.org)
########################################################################
#
# This script converts old groups and firewallrules
# to the new one. This is a 3-step process.
# STEP1: convert groups ->LOG /var/log/converters
# STEP2: convert rules ->LOG /var/log/converters
# STEP3: convert P2P rules
#
########################################################################
###############################################################################
# #
# IPFire.org - A linux based firewall #
# Copyright (C) 2013 #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
# the Free Software Foundation, either version 3 of the License, or #
# (at your option) any later version. #
# #
# This program is distributed in the hope that it will be useful, #
# but WITHOUT ANY WARRANTY; without even the implied warranty of #
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
# GNU General Public License for more details. #
# #
# You should have received a copy of the GNU General Public License #
# along with this program. If not, see <http://www.gnu.org/licenses/>. #
# #
###############################################################################
# Author: Alexander Marx (amarx@ipfire.org) #
###############################################################################
# #
# This script converts old groups and firewallrules #
# to the new one. This is a 3-step process. #
# STEP1: convert groups ->LOG /var/log/converters #
# STEP2: convert rules ->LOG /var/log/converters #
# STEP3: convert P2P rules #
# #
###############################################################################
require '/var/ipfire/general-functions.pl';

View File

@@ -1,18 +1,33 @@
#!/usr/bin/perl
########################################################################
# Script: convert-portfw
# Date: 21.03.2013
# Author: Alexander Marx (amarx@ipfire.org)
########################################################################
#
# This script converts old portforwarding rules from old Firewall
# to the new one. This is a 3-step process.
# STEP1: read old config and normalize settings
# STEP2: create new rules from old ones
# STEP3: check if rule already exists, when not, put it into
# /var/ipfire/forward/nat
########################################################################
###############################################################################
# #
# IPFire.org - A linux based firewall #
# Copyright (C) 2013 #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
# the Free Software Foundation, either version 3 of the License, or #
# (at your option) any later version. #
# #
# This program is distributed in the hope that it will be useful, #
# but WITHOUT ANY WARRANTY; without even the implied warranty of #
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
# GNU General Public License for more details. #
# #
# You should have received a copy of the GNU General Public License #
# along with this program. If not, see <http://www.gnu.org/licenses/>. #
# #
###############################################################################
# Author: Alexander Marx (amarx@ipfire.org) #
###############################################################################
# #
# This script converts old portforwarding rules from old Firewall #
# to the new one. This is a 3-step process. #
# STEP1: read old config and normalize settings #
# STEP2: create new rules from old ones #
# STEP3: check if rule already exists, when not, put it into #
# /var/ipfire/forward/nat #
###############################################################################
require '/var/ipfire/general-functions.pl';
my @values=();
my @built_rules=();

View File

@@ -1,4 +1,30 @@
#!/usr/bin/perl
###############################################################################
# #
# IPFire.org - A linux based firewall #
# Copyright (C) 2013 #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
# the Free Software Foundation, either version 3 of the License, or #
# (at your option) any later version. #
# #
# This program is distributed in the hope that it will be useful, #
# but WITHOUT ANY WARRANTY; without even the implied warranty of #
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
# GNU General Public License for more details. #
# #
# You should have received a copy of the GNU General Public License #
# along with this program. If not, see <http://www.gnu.org/licenses/>. #
# #
###############################################################################
# Author: Alexander Marx (amarx@ipfire.org) #
###############################################################################
# #
#This script converts old xtaccess rules to new firewall #
#Logfiles are created under /var/log/converters #
# #
###############################################################################
my @current=();
my @alias=();
my %configinputfw=();

View File

@@ -2,7 +2,7 @@
###############################################################################
# #
# IPFire.org - A linux based firewall #
# Copyright (C) 2012 #
# Copyright (C) 2013 #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
@@ -18,7 +18,8 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>. #
# #
###############################################################################
# Author: Alexander Marx (amarx@ipfire.org) #
###############################################################################
use strict;
no warnings 'uninitialized';

View File

@@ -1,5 +1,28 @@
#!/bin/sh
###############################################################################
# #
# IPFire.org - A linux based firewall #
# Copyright (C) 2013 #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
# the Free Software Foundation, either version 3 of the License, or #
# (at your option) any later version. #
# #
# This program is distributed in the hope that it will be useful, #
# but WITHOUT ANY WARRANTY; without even the implied warranty of #
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
# GNU General Public License for more details. #
# #
# You should have received a copy of the GNU General Public License #
# along with this program. If not, see <http://www.gnu.org/licenses/>. #
# #
###############################################################################
# Author: Alexander Marx (amarx@ipfire.org) #
###############################################################################
eval $(/usr/local/bin/readhash /var/ipfire/forward/settings)
eval $(/usr/local/bin/readhash /var/ipfire/optionsfw/settings)
eval $(/usr/local/bin/readhash /var/ipfire/ethernet/settings)

View File

@@ -2,7 +2,7 @@
###############################################################################
# #
# IPFire.org - A linux based firewall #
# Copyright (C) 2012 #
# Copyright (C) 2013 #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
@@ -18,10 +18,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>. #
# #
###############################################################################
# #
# Hi folks! I hope this code is useful for all. I needed something to handle #
# my VPN Connections in a comfortable way. #
# This script builds firewallrules from the webinterface #
# Author: Alexander Marx (amarx@ipfire.org) #
###############################################################################
use strict;
@@ -89,7 +86,7 @@ close(CONN1);
################################
# DEBUG/TEST #
################################
my $MODE=1; # 0 - normal operation
my $MODE=0; # 0 - normal operation
# 1 - print configline and rules to console
#
################################

View File

@@ -2,7 +2,7 @@
###############################################################################
# #
# IPFire.org - A linux based firewall #
# Copyright (C) 2012 #
# Copyright (C) 2013 #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
@@ -18,7 +18,8 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>. #
# #
###############################################################################
# Author: Alexander Marx (amarx@ipfire.org) #
###############################################################################
use strict;
use Sort::Naturally;

View File

@@ -2,7 +2,7 @@
###############################################################################
# #
# IPFire.org - A linux based firewall #
# Copyright (C) 2011 IPFire Team <info@ipfire.org> #
# Copyright (C) 2013 #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
@@ -18,9 +18,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>. #
# #
###############################################################################
# New function for forwarding firewall. To make it comfortable to create #
# rules, we need "spelling names" for single Hosts. If you have any questions #
# <amarx@ipfire.org> #
# Author: Alexander Marx (amarx@ipfire.org) #
###############################################################################
use strict;

View File

@@ -11,6 +11,9 @@
# $Id: optionsfw.cgi,v 1.1.2.10 2005/10/03 00:34:10 gespinasse Exp $
#
#
########################################################################
# Modifications for new Firewall (C) 2013 by amarx@ipfire.org
########################################################################
# enable only the following on debugging purpose
#use warnings;

View File

@@ -2,7 +2,7 @@
###############################################################################
# #
# IPFire.org - A linux based firewall #
# Copyright (C) 2012 #
# Copyright (C) 2013 #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
@@ -18,16 +18,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>. #
# #
###############################################################################
# #
# Hi folks! I hope this code is useful for all. I needed something to handle #
# my VPN Connections in a comfortable way. As a prerequisite i needed #
# something that makes sure the vpn roadwarrior are able to have a fixed #
# ip-address. So i developed the ccd extension for the vpn server. #
# #
# Now that the ccd extension is ready i am able to develop the main request. #
# Any feedback is appreciated. #
# #
#Copymaster #
# Author: Alexander Marx (Amarx@ipfire.org) #
###############################################################################
use strict;