]> git.ipfire.org Git - people/stevee/network.git/commitdiff
Remove support for Teredo
authorMichael Tremer <michael.tremer@ipfire.org>
Sat, 6 Dec 2014 19:14:17 +0000 (20:14 +0100)
committerMichael Tremer <michael.tremer@ipfire.org>
Sat, 6 Dec 2014 19:14:17 +0000 (20:14 +0100)
The protocol is not in much use any more
and it didn't work very well for our needs
as it just gave you a single address from
the IPv6 address space.

Makefile.am
src/functions/functions.teredo [deleted file]
src/helpers/miredo-config-helper [deleted file]
src/helpers/miredo-helper [deleted file]
src/hooks/zones/teredo [deleted file]

index d4dfc3d19528c5afedd34c766b9ed4d99932c4ad..364588292ed72b485cb7206b44aaa170938d452e 100644 (file)
@@ -145,7 +145,6 @@ dist_network_SCRIPTS = \
        src/functions/functions.settings \
        src/functions/functions.stp \
        src/functions/functions.sysctl \
-       src/functions/functions.teredo \
        src/functions/functions.usb \
        src/functions/functions.util \
        src/functions/functions.vlan \
@@ -166,8 +165,6 @@ dist_helpers_SCRIPTS = \
        src/helpers/dhcpd-config-helper \
        src/helpers/firewall-kernel-init \
        src/helpers/hostapd-config-helper \
-       src/helpers/miredo-config-helper \
-       src/helpers/miredo-helper \
        src/helpers/pppd-angel \
        src/helpers/wpa_supplicant \
        src/helpers/wpa_supplicant-config-helper
@@ -207,7 +204,6 @@ dist_hooks_zones_SCRIPTS = \
        src/hooks/zones/modem \
        src/hooks/zones/pppoe \
        src/hooks/zones/pptp \
-       src/hooks/zones/teredo \
        src/hooks/zones/wireless
 
 # ------------------------------------------------------------------------------
diff --git a/src/functions/functions.teredo b/src/functions/functions.teredo
deleted file mode 100644 (file)
index 8135597..0000000
+++ /dev/null
@@ -1,85 +0,0 @@
-#!/bin/bash
-###############################################################################
-#                                                                             #
-# IPFire.org - A linux based firewall                                         #
-# Copyright (C) 2012  IPFire Network Development Team                         #
-#                                                                             #
-# 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/>.       #
-#                                                                             #
-###############################################################################
-
-function teredo_start() {
-       local zone=${1}
-       assert isset zone
-
-       service_start "miredo-client@${zone}.service"
-}
-
-function teredo_stop() {
-       local zone=${1}
-       assert isset zone
-
-       # Just stop the miredo daemon for this device.
-       service_stop "miredo-client@${zone}.service"
-}
-
-function teredo_write_config() {
-       local zone=${1}
-       local file=${2}
-       shift 2
-
-       assert isset zone
-       assert isset file
-
-       local server
-
-       while [ $# -gt 0 ]; do
-               case "${1}" in
-                       --server=*)
-                               server=$(cli_get_val ${1})
-                               ;;
-               esac
-               shift
-       done
-
-       # Check if all required parameters are correctly set.
-       assert isset server
-
-       # Create the file's directory if necessary and
-       # make sure there is nothing in the file, yet.
-       mkdir -p $(dirname ${file}) 2>/dev/null
-       : > ${file}
-
-       # Print the header.
-       (       echo "#"
-               echo "# This is a miredo client configuration file for ${interface}."
-               echo "# THIS FILE IS AUTOMATICALLY GENERATED AND WILL OVERWRITE"
-               echo "# ANY CUSTOM CHANGES!"
-               echo "#"
-               echo "# $(date -u)"
-               echo "#"
-               echo
-       ) >>${file}
-
-       # All teredo connections we have are in client mode.
-       echo "RelayType client" >> ${file}
-
-       # The interface equals the name of the zone.
-       echo "InterfaceName ${zone}" >> ${file}
-
-       # Add the server information.
-       echo "ServerAddress ${server}" >> ${file}
-
-       exit ${EXIT_OK}
-}
diff --git a/src/helpers/miredo-config-helper b/src/helpers/miredo-config-helper
deleted file mode 100644 (file)
index 9fb1725..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-#!/bin/bash
-###############################################################################
-#                                                                             #
-# IPFire.org - A linux based firewall                                         #
-# Copyright (C) 2012  IPFire Network Development Team                         #
-#                                                                             #
-# 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/>.       #
-#                                                                             #
-###############################################################################
-
-. /usr/lib/network/functions
-
-# Read network settings
-network_settings_read
-
-action="${1}"
-assert isset action
-
-zone="${2}"
-assert isset zone
-assert zone_exists ${zone}
-
-config_file="${RUN_DIR}/miredo/${zone}/client.conf"
-
-case "${action}" in
-       create)
-               # Create the configuration file for this zone.
-               zone_settings_read ${zone}
-
-               teredo_write_config ${zone} ${config_file} \
-                       --server="${SERVER}"
-               ;;
-
-       remove)
-               rm -f ${config_file}
-               ;;
-
-       *)
-               log ERROR "Unknown action passed: ${action}"
-               exit ${EXIT_ERROR}
-               ;;
-esac
-
-exit ${EXIT_OK}
diff --git a/src/helpers/miredo-helper b/src/helpers/miredo-helper
deleted file mode 100644 (file)
index c8b42b5..0000000
+++ /dev/null
@@ -1,81 +0,0 @@
-#!/bin/bash
-###############################################################################
-#                                                                             #
-# IPFire.org - A linux based firewall                                         #
-# Copyright (C) 2012  IPFire Network Development Team                         #
-#                                                                             #
-# 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/>.       #
-#                                                                             #
-###############################################################################
-
-LOG_FACILITY="miredo-helper"
-
-. /usr/lib/network/functions
-
-# Read network settings
-network_settings_read
-
-action="${STATE}"
-assert isset action
-
-zone="${IFACE}"
-assert zone_exists ${zone}
-
-log DEBUG "Called for zone=${zone} action=${action}."
-
-case "${action}" in
-       up)
-               # Configure the requested MTU.
-               isset MTU && device_set_mtu ${zone} ${MTU}
-
-               # Bring up the device.
-               device_set_up ${zone}
-
-               # Apply the link-local address.
-               ip_address_add ${zone} "${LLADDRESS}/64"
-
-               # Apply the public IP address.
-               ip_address_add ${zone} "${ADDRESS}/32"
-
-               # Write all data to the routing database.
-               routing_db_set ${zone} ipv6 type "teredo"
-               routing_db_set ${zone} ipv6 local-ip-address "${ADDRESS}/32"
-               routing_db_set ${zone} ipv6 active 1
-
-               # Update the routing database.
-               routing_update ${zone} ipv6
-               routing_default_update
-               ;;
-
-       down)
-               # Remove the routing database and update the tables.
-               routing_db_remove ${zone} ipv6
-               routing_update ${zone} ipv6
-               routing_default_update
-
-               # Set down the device.
-               device_set_down ${zone}
-               ;;
-
-       destroy)
-               # Do nothing here.
-               ;;
-
-       *)
-               log ERROR "Unknown action passed: ${action}"
-               exit ${EXIT_ERROR}
-               ;;
-esac
-
-exit ${EXIT_OK}
diff --git a/src/hooks/zones/teredo b/src/hooks/zones/teredo
deleted file mode 100644 (file)
index 6c5abe0..0000000
+++ /dev/null
@@ -1,90 +0,0 @@
-#!/bin/bash
-###############################################################################
-#                                                                             #
-# IPFire.org - A linux based firewall                                         #
-# Copyright (C) 2010  Michael Tremer & Christian Schmidt                      #
-#                                                                             #
-# 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/>.       #
-#                                                                             #
-###############################################################################
-
-. /usr/lib/network/header-zone
-
-HOOK_SETTINGS="HOOK SERVER"
-
-SERVER=""
-
-function hook_check() {
-       assert isset SERVER
-}
-
-function hook_parse_cmdline() {
-       local value
-
-       while [ $# -gt 0 ]; do
-               case "${1}" in
-                       --server=*)
-                               SERVER=$(cli_get_val ${1})
-                               ;;
-                       *)
-                               echo "Unknown option: ${1}" >&2
-                               exit ${EXIT_ERROR}
-                               ;;
-               esac
-               shift
-       done
-}
-
-function hook_up() {
-       local zone=${1}
-       assert isset zone
-
-       teredo_start ${zone}
-
-       exit ${EXIT_OK}
-}
-
-function hook_down() {
-       local zone=${1}
-       assert isset zone
-
-       teredo_stop ${zone}
-
-       exit ${EXIT_OK}
-}
-
-function hook_status() {
-       local zone=${1}
-       assert isset zone
-
-       # Print a nice header.
-       cli_device_headline ${zone}
-
-       zone_settings_read "${zone}" ${HOOK_SETTINGS}
-
-       cli_headline 2 "Configuration"
-       cli_print_fmt1 2 "Server" "${SERVER}"
-
-       # Exit if zone is down
-       if ! zone_is_up ${zone}; then
-               cli_space
-               exit ${EXIT_ERROR}
-       fi
-
-       cli_headline 2 "Protocol information"
-       cli_print_fmt1 2 "MTU" "$(device_get_mtu ${zone})"
-       cli_space
-
-       exit ${EXIT_OK}
-}