From: Saverio Proto Date: Sat, 4 Mar 2017 20:57:06 +0000 (+0100) Subject: Merge pull request #283 from gabri94/master X-Git-Url: http://git.openwrt.org/?p=feed%2Frouting.git;a=commitdiff_plain;h=8a75154cdc35426354d95503d6998f8ccacaf8c9;hp=a377a065f4129afd511fcd4775e08af270a80675 Merge pull request #283 from gabri94/master Prince v0.3.1 --- diff --git a/alfred/Makefile b/alfred/Makefile index b5d37ce..379c0fe 100644 --- a/alfred/Makefile +++ b/alfred/Makefile @@ -14,6 +14,7 @@ PKG_NAME:=alfred PKG_VERSION:=2016.5 PKG_RELEASE:=0 PKG_MD5SUM:=e03d422ed3b5a162b90e8af13389523f +PKG_HASH:=37b3babf7f37643cf296be11fb82d5730cf441a5a56f72fba96edae9f149c9d2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://downloads.open-mesh.org/batman/releases/batman-adv-$(PKG_VERSION) diff --git a/batctl/Makefile b/batctl/Makefile index bf305a2..24bd16b 100644 --- a/batctl/Makefile +++ b/batctl/Makefile @@ -12,6 +12,7 @@ PKG_NAME:=batctl PKG_VERSION:=2016.5 PKG_RELEASE:=0 PKG_MD5SUM:=7b33fb47c7fa5b317e9a152a286999fc +PKG_HASH:=07edeb1d87a548285be8c499542790a158fc8d94ef7ebb295f27ebf710024ae9 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://downloads.open-mesh.org/batman/releases/batman-adv-$(PKG_VERSION) @@ -27,7 +28,7 @@ define Package/batctl CATEGORY:=Network DEPENDS:=+kmod-batman-adv +libnl-tiny +libc +librt TITLE:=B.A.T.M.A.N. Advanced user space configuration tool batctl - MAINTAINER:=Marek Lindner + MAINTAINER:=Simon Wunderlich endef define Package/batctl/description diff --git a/batman-adv/Config.in b/batman-adv/Config.in index 8c75f31..1b2399f 100644 --- a/batman-adv/Config.in +++ b/batman-adv/Config.in @@ -32,4 +32,4 @@ config KMOD_BATMAN_ADV_NC config KMOD_BATMAN_ADV_BATMAN_V bool "enable batman v routing algorithm" depends on PACKAGE_kmod-batman-adv - default n + default y diff --git a/batman-adv/Makefile b/batman-adv/Makefile index df64571..d3e916e 100644 --- a/batman-adv/Makefile +++ b/batman-adv/Makefile @@ -11,21 +11,20 @@ include $(TOPDIR)/rules.mk PKG_NAME:=batman-adv PKG_VERSION:=2016.5 -PKG_RELEASE:=0 +PKG_RELEASE:=4 PKG_MD5SUM:=6717a933a08dd2a01b00df30cb9f16a8 +PKG_HASH:=d0a0fc90c4f410b57d043215e253bb0b855efa5edbe165d87c17bfdcfafd0db7 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://downloads.open-mesh.org/batman/releases/batman-adv-$(PKG_VERSION) PKG_LICENSE:=GPL-2.0 -PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)/$(PKG_NAME)-$(PKG_VERSION) - -include $(INCLUDE_DIR)/package.mk include $(INCLUDE_DIR)/kernel.mk +include $(INCLUDE_DIR)/package.mk define KernelPackage/batman-adv URL:=https://www.open-mesh.org/ - MAINTAINER:=Marek Lindner + MAINTAINER:=Simon Wunderlich SUBMENU:=Network Support DEPENDS:=+KMOD_BATMAN_ADV_BLA:kmod-lib-crc16 +kmod-crypto-crc32c +kmod-lib-crc32c +kmod-cfg80211 TITLE:=B.A.T.M.A.N. Adv diff --git a/batman-adv/files/etc/config/batman-adv b/batman-adv/files/etc/config/batman-adv index f38855e..97be622 100644 --- a/batman-adv/files/etc/config/batman-adv +++ b/batman-adv/files/etc/config/batman-adv @@ -9,7 +9,6 @@ config 'mesh' 'bat0' option 'gw_sel_class' option 'log_level' option 'orig_interval' - option 'vis_mode' option 'bridge_loop_avoidance' option 'distributed_arp_table' option 'multicast_mode' diff --git a/batman-adv/files/lib/batman-adv/config.sh b/batman-adv/files/lib/batman-adv/config.sh index 1429a43..3a746a3 100644 --- a/batman-adv/files/lib/batman-adv/config.sh +++ b/batman-adv/files/lib/batman-adv/config.sh @@ -13,7 +13,7 @@ bat_config() local mesh="$1" local aggregated_ogms ap_isolation bonding bridge_loop_avoidance distributed_arp_table fragmentation local gw_bandwidth gw_mode gw_sel_class isolation_mark hop_penalty multicast_mode network_coding log_level - local orig_interval vis_mode + local orig_interval config_get aggregated_ogms "$mesh" aggregated_ogms config_get ap_isolation "$mesh" ap_isolation @@ -30,11 +30,10 @@ bat_config() config_get network_coding "$mesh" network_coding config_get log_level "$mesh" log_level config_get orig_interval "$mesh" orig_interval - config_get vis_mode "$mesh" vis_mode [ ! -f "/sys/class/net/$mesh/mesh/orig_interval" ] && echo "batman-adv mesh $mesh does not exist - check your interface configuration" && return 1 - [ -n "$aggregate_ogms" ] && echo $aggregate_ogms > /sys/class/net/$mesh/mesh/aggregate_ogms + [ -n "$aggregated_ogms" ] && echo $aggregated_ogms > /sys/class/net/$mesh/mesh/aggregated_ogms [ -n "$ap_isolation" ] && echo $ap_isolation > /sys/class/net/$mesh/mesh/ap_isolation [ -n "$bonding" ] && echo $bonding > /sys/class/net/$mesh/mesh/bonding [ -n "$bridge_loop_avoidance" ] && echo $bridge_loop_avoidance > /sys/class/net/$mesh/mesh/bridge_loop_avoidance 2>&- @@ -49,5 +48,4 @@ bat_config() [ -n "$network_coding" ] && echo $network_coding > /sys/class/net/$mesh/mesh/network_coding 2>&- [ -n "$log_level" ] && echo $log_level > /sys/class/net/$mesh/mesh/log_level 2>&- [ -n "$orig_interval" ] && echo $orig_interval > /sys/class/net/$mesh/mesh/orig_interval - [ -n "$vis_mode" ] && echo $vis_mode > /sys/class/net/$mesh/mesh/vis_mode } diff --git a/batman-adv/patches/0002-batman-adv-Decrease-hardif-refcnt-on-fragmentation-s.patch b/batman-adv/patches/0002-batman-adv-Decrease-hardif-refcnt-on-fragmentation-s.patch new file mode 100644 index 0000000..92da394 --- /dev/null +++ b/batman-adv/patches/0002-batman-adv-Decrease-hardif-refcnt-on-fragmentation-s.patch @@ -0,0 +1,63 @@ +From: Sven Eckelmann +Date: Tue, 27 Dec 2016 08:51:17 +0100 +Subject: [PATCH] batman-adv: Decrease hardif refcnt on fragmentation send error + +An error before the hardif is found has to free the skb. But every error +after that has to free the skb + put the hard interface. + +Fixes: 8b4132b1447a ("batman-adv: Consume skb in batadv_frag_send_packet") +Signed-off-by: Sven Eckelmann +Signed-off-by: Simon Wunderlich +--- + net/batman-adv/fragmentation.c | 10 +++++----- + 1 file changed, 5 insertions(+), 5 deletions(-) + +diff --git a/net/batman-adv/fragmentation.c b/net/batman-adv/fragmentation.c +index 9c561e6..0854ebd 100644 +--- a/net/batman-adv/fragmentation.c ++++ b/net/batman-adv/fragmentation.c +@@ -474,7 +474,7 @@ int batadv_frag_send_packet(struct sk_buff *skb, + primary_if = batadv_primary_if_get_selected(bat_priv); + if (!primary_if) { + ret = -EINVAL; +- goto put_primary_if; ++ goto free_skb; + } + + /* Create one header to be copied to all fragments */ +@@ -502,7 +502,7 @@ int batadv_frag_send_packet(struct sk_buff *skb, + skb_fragment = batadv_frag_create(skb, &frag_header, mtu); + if (!skb_fragment) { + ret = -ENOMEM; +- goto free_skb; ++ goto put_primary_if; + } + + batadv_inc_counter(bat_priv, BATADV_CNT_FRAG_TX); +@@ -511,7 +511,7 @@ int batadv_frag_send_packet(struct sk_buff *skb, + ret = batadv_send_unicast_skb(skb_fragment, neigh_node); + if (ret != NET_XMIT_SUCCESS) { + ret = NET_XMIT_DROP; +- goto free_skb; ++ goto put_primary_if; + } + + frag_header.no++; +@@ -519,7 +519,7 @@ int batadv_frag_send_packet(struct sk_buff *skb, + /* The initial check in this function should cover this case */ + if (frag_header.no == BATADV_FRAG_MAX_FRAGMENTS - 1) { + ret = -EINVAL; +- goto free_skb; ++ goto put_primary_if; + } + } + +@@ -527,7 +527,7 @@ int batadv_frag_send_packet(struct sk_buff *skb, + if (batadv_skb_head_push(skb, header_size) < 0 || + pskb_expand_head(skb, header_size + ETH_HLEN, 0, GFP_ATOMIC) < 0) { + ret = -ENOMEM; +- goto free_skb; ++ goto put_primary_if; + } + + memcpy(skb->data, &frag_header, header_size); diff --git a/batman-adv/patches/0003-batman-adv-Fix-double-free-during-fragment-merge-err.patch b/batman-adv/patches/0003-batman-adv-Fix-double-free-during-fragment-merge-err.patch new file mode 100644 index 0000000..f4baf46 --- /dev/null +++ b/batman-adv/patches/0003-batman-adv-Fix-double-free-during-fragment-merge-err.patch @@ -0,0 +1,61 @@ +From: Sven Eckelmann +Date: Sun, 12 Feb 2017 11:26:33 +0100 +Subject: [PATCH] batman-adv: Fix double free during fragment merge error + +The function batadv_frag_skb_buffer was supposed not to consume the skbuff +on errors. This was followed in the helper function +batadv_frag_insert_packet when the skb would potentially be inserted in the +fragment queue. But it could happen that the next helper function +batadv_frag_merge_packets would try to merge the fragments and fail. This +results in a kfree_skb of all the enqueued fragments (including the just +inserted one). batadv_recv_frag_packet would detect the error in +batadv_frag_skb_buffer and try to free the skb again. + +The behavior of batadv_frag_skb_buffer (and its helper +batadv_frag_insert_packet) must therefore be changed to always consume the +skbuff to have a common behavior and avoid the double kfree_skb. + +Fixes: 9b3eab61754d ("batman-adv: Receive fragmented packets and merge") +Signed-off-by: Sven Eckelmann + +Origin: upstream, https://git.open-mesh.org/batman-adv.git/commit/e3bab02816097f860545d9ce9ae0808c69d7c92f +--- + net/batman-adv/fragmentation.c | 8 +++++--- + 1 file changed, 5 insertions(+), 3 deletions(-) + +diff --git a/net/batman-adv/fragmentation.c b/net/batman-adv/fragmentation.c +index 0854ebd8..31e97e9a 100644 +--- a/net/batman-adv/fragmentation.c ++++ b/net/batman-adv/fragmentation.c +@@ -239,8 +239,10 @@ err_unlock: + spin_unlock_bh(&chain->lock); + + err: +- if (!ret) ++ if (!ret) { + kfree(frag_entry_new); ++ kfree_skb(skb); ++ } + + return ret; + } +@@ -313,7 +315,7 @@ free: + * + * There are three possible outcomes: 1) Packet is merged: Return true and + * set *skb to merged packet; 2) Packet is buffered: Return true and set *skb +- * to NULL; 3) Error: Return false and leave skb as is. ++ * to NULL; 3) Error: Return false and free skb. + * + * Return: true when packet is merged or buffered, false when skb is not not + * used. +@@ -338,9 +340,9 @@ bool batadv_frag_skb_buffer(struct sk_buff **skb, + goto out_err; + + out: +- *skb = skb_out; + ret = true; + out_err: ++ *skb = skb_out; + return ret; + } + diff --git a/batman-adv/patches/0004-batman-adv-Fix-transmission-of-final-16th-fragment.patch b/batman-adv/patches/0004-batman-adv-Fix-transmission-of-final-16th-fragment.patch new file mode 100644 index 0000000..6dec0f6 --- /dev/null +++ b/batman-adv/patches/0004-batman-adv-Fix-transmission-of-final-16th-fragment.patch @@ -0,0 +1,54 @@ +From: Linus Lüssing +Date: Mon, 13 Feb 2017 20:44:31 +0100 +Subject: [PATCH] batman-adv: Fix transmission of final, 16th fragment + +Trying to split and transmit a unicast packet in 16 parts will fail for +the final fragment: After having sent the 15th one with a frag_packet.no +index of 14, we will increase the the index to 15 - and return with an +error code immediately, even though one more fragment is due for +transmission and allowed. + +Fixing this issue by moving the check before incrementing the index. + +While at it, adding an unlikely(), because the check is actually more of +an assertion. + +Fixes: db56e4ecf5c2 ("batman-adv: Fragment and send skbs larger than mtu") +Signed-off-by: Linus Lüssing +Signed-off-by: Sven Eckelmann + +Origin: upstream, https://git.open-mesh.org/batman-adv.git/commit/464eff3b1768ff190466a453a57ac140ea5cb756 +--- + net/batman-adv/fragmentation.c | 12 ++++++------ + 1 file changed, 6 insertions(+), 6 deletions(-) + +diff --git a/net/batman-adv/fragmentation.c b/net/batman-adv/fragmentation.c +index 31e97e9a..11149e5b 100644 +--- a/net/batman-adv/fragmentation.c ++++ b/net/batman-adv/fragmentation.c +@@ -501,6 +501,12 @@ int batadv_frag_send_packet(struct sk_buff *skb, + + /* Eat and send fragments from the tail of skb */ + while (skb->len > max_fragment_size) { ++ /* The initial check in this function should cover this case */ ++ if (unlikely(frag_header.no == BATADV_FRAG_MAX_FRAGMENTS - 1)) { ++ ret = -EINVAL; ++ goto put_primary_if; ++ } ++ + skb_fragment = batadv_frag_create(skb, &frag_header, mtu); + if (!skb_fragment) { + ret = -ENOMEM; +@@ -517,12 +523,6 @@ int batadv_frag_send_packet(struct sk_buff *skb, + } + + frag_header.no++; +- +- /* The initial check in this function should cover this case */ +- if (frag_header.no == BATADV_FRAG_MAX_FRAGMENTS - 1) { +- ret = -EINVAL; +- goto put_primary_if; +- } + } + + /* Make room for the fragment header. */ diff --git a/batmand/Makefile b/batmand/Makefile index 2372ce3..b4ed301 100644 --- a/batmand/Makefile +++ b/batmand/Makefile @@ -9,24 +9,29 @@ include $(TOPDIR)/rules.mk include $(INCLUDE_DIR)/kernel.mk PKG_NAME:=batmand -PKG_REV:=1439 -PKG_VERSION:=r$(PKG_REV) -PKG_RELEASE:=3 -PKG_EXTRA_CFLAGS=-DDEBUG_MALLOC -DMEMORY_USAGE -DPROFILE_DATA -DREVISION_VERSION=\"\ rv$(PKG_REV)\" -D_GNU_SOURCE -PKG_HASH:=3c72ce2aae889944acfc898434c6e9573b20815862db1938f3132cc50b669667 -PKG_SOURCE_VERSION:=$(PKG_REV) -PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz -PKG_SOURCE_URL:=https://sources.lede-project.org https://downloads.openwrt.org/sources +PKG_SOURCE_PROTO:=git +PKG_SOURCE_URL:=git://git.open-mesh.org/batmand.git +PKG_REV:=b67a7087b51d7a5e90d27ac39116d1f57257c86e +PKG_VERSION:=1440 +PKG_RELEASE:=0 PKG_LICENSE:=GPL-2.0 -PKG_KMOD_BUILD_DIR:=$(PKG_BUILD_DIR)/batman/linux/modules +PKG_SOURCE_VERSION:=$(PKG_REV) +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) +PKG_SOURCE:=$(PKG_SOURCE_SUBDIR).tar.gz +PKG_MIRROR_HASH:=ceb8e0e399f79b1b663594fcf9642e1efc40e696a7604daf709c77da9b6ec52f +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_SOURCE_SUBDIR) + +PKG_EXTRA_CFLAGS=-DDEBUG_MALLOC -DMEMORY_USAGE -DPROFILE_DATA -DREVISION_VERSION=\"\ rv$(PKG_REV)\" -D_GNU_SOURCE + +PKG_KMOD_BUILD_DIR:=$(PKG_BUILD_DIR)/linux/modules include $(INCLUDE_DIR)/package.mk define Package/batmand/Default - URL:=http://www.open-mesh.org/ - MAINTAINER:=Marek Lindner + URL:=https://www.open-mesh.org/ + MAINTAINER:=Corinna "Elektra" Aichele endef define Package/batmand @@ -42,19 +47,6 @@ define Package/batmand/description B.A.T.M.A.N. layer 3 routing daemon endef -define Package/vis -$(call Package/batmand/Default) - SECTION:=net - CATEGORY:=Network - SUBMENU:=Routing and Redirection - DEPENDS:=+libpthread - TITLE:=visualization server for B.A.T.M.A.N. layer 3 -endef - -define Package/vis/description -visualization server for B.A.T.M.A.N. layer 3 -endef - define KernelPackage/batgat $(call Package/batmand/Default) SUBMENU:=Network Support @@ -80,18 +72,6 @@ MAKE_BATMAND_ARGS += \ INSTALL_PREFIX="$(PKG_INSTALL_DIR)" \ STRIP="/bin/true" \ batmand install - -MAKE_VIS_ARGS += \ - EXTRA_CFLAGS='$(TARGET_CFLAGS) $(PKG_EXTRA_CFLAGS)' \ - CCFLAGS="$(TARGET_CFLAGS)" \ - OFLAGS="$(TARGET_CFLAGS)" \ - REVISION="$(PKG_REV)" \ - CC="$(TARGET_CC)" \ - NODEBUG=1 \ - UNAME="Linux" \ - INSTALL_PREFIX="$(PKG_INSTALL_DIR)" \ - STRIP="/bin/true" \ - vis install MAKE_BATGAT_ARGS += \ CROSS_COMPILE="$(TARGET_CROSS)" \ @@ -106,11 +86,7 @@ define Build/Configure endef ifneq ($(DEVELOPER)$(CONFIG_PACKAGE_batmand),) - BUILD_BATMAND := $(MAKE) -C $(PKG_BUILD_DIR)/batman $(MAKE_BATMAND_ARGS) -endif - -ifneq ($(DEVELOPER)$(CONFIG_PACKAGE_vis),) - BUILD_VIS := $(MAKE) -C $(PKG_BUILD_DIR)/vis $(MAKE_VIS_ARGS) + BUILD_BATMAND := $(MAKE) -C $(PKG_BUILD_DIR) $(MAKE_BATMAND_ARGS) endif ifneq ($(DEVELOPER)$(CONFIG_PACKAGE_kmod-batgat),) @@ -119,7 +95,6 @@ endif define Build/Compile $(BUILD_BATMAND) - $(BUILD_VIS) cp $(PKG_KMOD_BUILD_DIR)/Makefile.kbuild $(PKG_KMOD_BUILD_DIR)/Makefile $(BUILD_BATGAT) endef @@ -135,17 +110,5 @@ define Package/batmand/conffiles /etc/config/batmand endef -define Package/vis/install - $(INSTALL_DIR) $(1)/usr/sbin $(1)/etc/config $(1)/etc/init.d - $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/vis $(1)/usr/sbin/ - $(INSTALL_BIN) ./files/etc/init.d/vis $(1)/etc/init.d - $(INSTALL_DATA) ./files/etc/config/vis $(1)/etc/config -endef - -define Package/vis/conffiles -/etc/config/vis -endef - $(eval $(call BuildPackage,batmand)) -$(eval $(call BuildPackage,vis)) $(eval $(call KernelPackage,batgat)) diff --git a/batmand/files/etc/config/vis b/batmand/files/etc/config/vis deleted file mode 100644 index 6d30023..0000000 --- a/batmand/files/etc/config/vis +++ /dev/null @@ -1,3 +0,0 @@ -config vis general - option interface ath0 - diff --git a/batmand/files/etc/init.d/vis b/batmand/files/etc/init.d/vis deleted file mode 100644 index ef18eb7..0000000 --- a/batmand/files/etc/init.d/vis +++ /dev/null @@ -1,19 +0,0 @@ -#!/bin/sh /etc/rc.common -START=90 - -start () { - interface=$(uci get vis.general.interface) - if [ "$interface" = "" ]; then - echo $1 Error, you must specify at least a network interface - exit - fi - vis_args=$interface - - vis $vis_args >/dev/null 2>&1 -} - -stop () { - killall vis -} - - diff --git a/batmand/patches/100-2.6.36.patch b/batmand/patches/100-2.6.36.patch index 566c23b..13318e0 100644 --- a/batmand/patches/100-2.6.36.patch +++ b/batmand/patches/100-2.6.36.patch @@ -2,8 +2,8 @@ batman/linux/modules/gateway.c | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) ---- batmand-r1439.orig/batman/linux/modules/gateway.c -+++ batmand-r1439/batman/linux/modules/gateway.c +--- batmand-r1439.orig/linux/modules/gateway.c ++++ batmand-r1439/linux/modules/gateway.c @@ -29,6 +29,7 @@ static struct class *batman_class; static int batgat_open(struct inode *inode, struct file *filp); static int batgat_release(struct inode *inode, struct file *file); diff --git a/bmx6/Makefile b/bmx6/Makefile index 425c298..411d9cb 100644 --- a/bmx6/Makefile +++ b/bmx6/Makefile @@ -31,8 +31,8 @@ PKG_SOURCE_PROTO:=git #PKG_SOURCE_URL:=git://bmx6.net/bmx6.git PKG_SOURCE_URL:=git://github.com/axn/bmx6.git -PKG_REV:=2a87b770d3f9c254e3927dc159e2f425f2e0e83a -PKG_VERSION:=r2015080701 +PKG_REV:=d9b985d8838ad6fe6d5c79f858a588b96abcf306 +PKG_VERSION:=r2017021601 PKG_RELEASE:=4 PKG_LICENSE:=GPL-2.0 diff --git a/miniupnpd/Makefile b/miniupnpd/Makefile index fdfac91..5537e2c 100644 --- a/miniupnpd/Makefile +++ b/miniupnpd/Makefile @@ -29,6 +29,13 @@ define Package/miniupnpd URL:=http://miniupnp.free.fr/ endef +define Package/miniupnpd/config +config MINIUPNPD_IGDv2 + bool + default y + prompt "Enable IGDv2" +endef + define Package/miniupnpd/conffiles /etc/config/upnpd endef @@ -54,10 +61,13 @@ MAKE_FLAGS += \ LIBS="" \ CC="$(TARGET_CC) -DIPTABLES_143 \ -lip4tc $(if $(CONFIG_IPV6),-lip6tc) -luuid" \ - CONFIG_OPTIONS="$(if $(CONFIG_IPV6),--ipv6) --leasefile" \ + CONFIG_OPTIONS="--portinuse --leasefile \ + $(if $(CONFIG_IPV6),--ipv6) \ + $(if $(CONFIG_MINIUPNPD_IGDv2),--igd2)" \ -f Makefile.linux \ miniupnpd + define Package/miniupnpd/install $(INSTALL_DIR) $(1)/usr/sbin $(1)/etc/init.d $(1)/etc/config $(1)/etc/uci-defaults $(1)/etc/hotplug.d/iface $(1)/usr/share/miniupnpd $(INSTALL_BIN) $(PKG_BUILD_DIR)/miniupnpd $(1)/usr/sbin/miniupnpd diff --git a/miniupnpd/files/miniupnpd.init b/miniupnpd/files/miniupnpd.init index c7dc6a2..c934a28 100644 --- a/miniupnpd/files/miniupnpd.init +++ b/miniupnpd/files/miniupnpd.init @@ -68,7 +68,11 @@ start() { local extip port usesysuptime conffile serial_number model_number local uuid notify_interval presentation_url enable_upnp local upnp_lease_file clean_ruleset_threshold clean_ruleset_interval - local ipv6_listening_ip + local ipv6_listening_ip enabled + + config_get_bool enabled config enabled 1 + + [ "$enabled" -gt 0 ] || return 1 config_get extiface config external_iface config_get extzone config external_zone diff --git a/miniupnpd/files/upnpd.config b/miniupnpd/files/upnpd.config index 56cde57..9a65bfa 100644 --- a/miniupnpd/files/upnpd.config +++ b/miniupnpd/files/upnpd.config @@ -1,4 +1,5 @@ config upnpd config + option enabled 0 option enable_natpmp 1 option enable_upnp 1 option secure_mode 1 diff --git a/miniupnpd/patches/105-enable_check_portinuse.patch b/miniupnpd/patches/105-enable_check_portinuse.patch deleted file mode 100644 index 8bf6c33..0000000 --- a/miniupnpd/patches/105-enable_check_portinuse.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/genconfig.sh -+++ b/genconfig.sh -@@ -467,7 +467,7 @@ echo "/* Uncomment the following line to - if [ -n "$PORTINUSE" ]; then - echo "#define CHECK_PORTINUSE" >> ${CONFIGFILE} - else -- echo "/*#define CHECK_PORTINUSE*/" >> ${CONFIGFILE} -+ echo "#define CHECK_PORTINUSE" >> ${CONFIGFILE} - fi - echo "" >> ${CONFIGFILE} - diff --git a/miniupnpd/patches/106-enable_igdv2.patch b/miniupnpd/patches/106-enable_igdv2.patch deleted file mode 100644 index 26811a0..0000000 --- a/miniupnpd/patches/106-enable_igdv2.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/genconfig.sh -+++ b/genconfig.sh -@@ -516,7 +516,7 @@ echo " * control points, so enable with - if [ -n "$IGD2" ]; then - echo "#define IGD_V2" >> ${CONFIGFILE} - else -- echo "/*#define IGD_V2*/" >> ${CONFIGFILE} -+ echo "#define IGD_V2" >> ${CONFIGFILE} - fi - echo "" >> ${CONFIGFILE} - diff --git a/nat46/Makefile b/nat46/Makefile index 0283dd4..47b5a5b 100644 --- a/nat46/Makefile +++ b/nat46/Makefile @@ -9,14 +9,14 @@ include $(TOPDIR)/rules.mk include $(INCLUDE_DIR)/kernel.mk PKG_NAME:=nat46 -PKG_VERSION:=7 +PKG_VERSION:=8 PKG_RELEASE:=$(PKG_SOURCE_VERSION) PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) PKG_SOURCE_URL:=https://github.com/ayourtch/nat46.git PKG_SOURCE_PROTO:=git -PKG_SOURCE_VERSION:=8ff2ae59ec9840a7b8b45f976c51cae80abe0226 +PKG_SOURCE_VERSION:=1cd9fc7025906e1825767b05615d2cf02e1528da PKG_MAINTAINER:=Steven Barth PKG_LICENSE:=GPL-2.0 diff --git a/olsrd/Makefile b/olsrd/Makefile index cce17b9..9091efb 100644 --- a/olsrd/Makefile +++ b/olsrd/Makefile @@ -8,13 +8,13 @@ include $(TOPDIR)/rules.mk PKG_NAME:=olsrd -PKG_VERSION:=0.9.5 +PKG_VERSION:=0.9.6.1 PKG_RELEASE=$(PKG_SOURCE_VERSION) PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=https://github.com/OLSR/olsrd.git PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) -PKG_SOURCE_VERSION:=v0.9.5 +PKG_SOURCE_VERSION:=v0.9.6.1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz PKG_MIRROR_MD5SUM:= diff --git a/olsrd/files/olsrd.config b/olsrd/files/olsrd.config index f4ddfd0..15ea80a 100644 --- a/olsrd/files/olsrd.config +++ b/olsrd/files/olsrd.config @@ -14,10 +14,10 @@ config LoadPlugin list Net '0.0.0.0 0.0.0.0' config LoadPlugin - option library 'olsrd_nameservice.so.0.3' + option library 'olsrd_nameservice.so.0.4' config LoadPlugin - option library 'olsrd_txtinfo.so.0.1' + option library 'olsrd_txtinfo.so.1.1' option accept '0.0.0.0' config Interface diff --git a/olsrd/files/olsrd.hotplug.sh b/olsrd/files/olsrd.hotplug.sh index 99e834e..ee41a2e 100755 --- a/olsrd/files/olsrd.hotplug.sh +++ b/olsrd/files/olsrd.hotplug.sh @@ -15,14 +15,14 @@ olsrd_list_configured_interfaces() ;; esac - i=$(( $i + 1 )) + i=$(( i + 1 )) } done } olsrd_interface_already_in_config() { # e.g.: 'Interface "eth0.1" "eth0.2" "wlan0"' - if grep -s ^'Interface ' '/var/etc/$OLSRD.conf' | grep -q "\"$DEVICE\""; then + if grep -s ^'Interface ' "/var/etc/$OLSRD.conf" | grep -q "\"$DEVICE\""; then logger -t olsrd_hotplug -p daemon.debug "[OK] already_active: '$INTERFACE' => '$DEVICE'" return 0 else diff --git a/olsrd/files/olsrd.init b/olsrd/files/olsrd.init index 258c7a5..8e562c1 100644 --- a/olsrd/files/olsrd.init +++ b/olsrd/files/olsrd.init @@ -17,15 +17,15 @@ N=' ' log() { - logger -t olsrd -p daemon.info -s "${initscript}: $@" + logger -t olsrd -p daemon.info -s "${initscript}: $*" } error() { - logger -t olsrd -p daemon.err -s "${initscript}: ERROR: $@" + logger -t olsrd -p daemon.err -s "${initscript}: ERROR: $*" } warn() { - logger -t olsrd -p daemon.warn -s "${initscript}: WARNING: $@" + logger -t olsrd -p daemon.warn -s "${initscript}: WARNING: $*" } validate_varname() { @@ -124,22 +124,21 @@ olsrd_write_option() { fi fi - echo -n "${N}$param$option $value" - - return 0 + printf '%s' "${N}$param$option $value" } olsrd_write_plparam() { local funcname="olsrd_write_plparam" local param="$1" local cfg="$2" - validate_varname "$cfg" || return 1 local option="$3" - validate_varname "$option" || return 1 local value="$4" local option_type="$5" local _option oldIFS + validate_varname "$cfg" || return 1 + validate_varname "$option" || return 1 + if [ "$option_type" = bool ]; then case "$value" in 1|on|true|enabled|yes) value=yes;; @@ -177,25 +176,25 @@ olsrd_write_plparam() { else warning_invalid_value olsrd "$cfg" "NonOlsrIf" fi + [ -z "$ifname" ] || value=$ifname fi - echo -n "${N}${param}PlParam \"$option\" \"$value\"" - - return 0 + printf '%s' "${N}${param}PlParam \"$option\" \"$value\"" } config_update_schema() { local schema_varname="$1" - validate_varname "$schema_varname" || return 1 local command="$2" - validate_varname "$command" || return 1 local option="$3" - validate_varname "$option" || return 1 local value="$4" local schema local cur_option + validate_varname "$schema_varname" || return 1 + validate_varname "$command" || return 1 + validate_varname "$option" || return 1 + case "$varname" in *_LENGTH) return 0;; *_ITEM*) return 0;; @@ -274,7 +273,7 @@ config_write_options() { already_in_schema "speed" && { get_value_for_entry "speed" - if [ 2>/dev/null $value -gt 0 -a $value -le 20 ]; then + if test 2>/dev/null "$value" -gt 0 -a "$value" -le 20 ; then speed="$value" else log "$funcname() Warning: invalid speed-value: '$value' - allowed integers: 1...20, fallback to 6" @@ -290,30 +289,30 @@ config_write_options() { if [ -n "$speed" ]; then # like sven-ola freifunk firmware fff-1.7.4 case "$schema_entry" in HelloInterval) - value="$(( $speed / 2 + 1 )).0" + value="$(( speed / 2 + 1 )).0" ;; HelloValidityTime) - value="$(( $speed * 25 )).0" + value="$(( speed * 25 )).0" ;; - TcInterval) # todo: not fisheye? -> $(( $speed * 2 )) - value=$(( $speed / 2 )) + TcInterval) # todo: not fisheye? -> $(( speed * 2 )) + value=$(( speed / 2 )) [ $value -eq 0 ] && value=1 value="$value.0" ;; TcValidityTime) - value="$(( $speed * 100 )).0" + value="$(( speed * 100 )).0" ;; MidInterval) - value="$(( $speed * 5 )).0" + value="$(( speed * 5 )).0" ;; MidValidityTime) - value="$(( $speed * 100 )).0" + value="$(( speed * 100 )).0" ;; HnaInterval) - value="$(( $speed * 2 )).0" + value="$(( speed * 2 )).0" ;; HnaValidityTime) - value="$(( $speed * 25 )).0" + value="$(( speed * 25 )).0" ;; *) get_value_for_entry "$schema_entry" || continue @@ -396,6 +395,8 @@ olsrd_write_olsrd() { config_get smartgateway "$cfg" SmartGateway config_get smartgatewayuplink "$cfg" SmartGatewayUplink + export smartgateway + export smartgatewayuplink config_write_options "$OLSRD_OLSRD_SCHEMA" "$cfg" olsrd_write_option echo @@ -413,12 +414,10 @@ olsrd_write_ipcconnect() { [ "$IPCCONNECT_COUNT" -gt 0 ] && return 0 - echo -n "${N}IpcConnect${N}{" + printf '%s' "${N}IpcConnect${N}{" config_write_options "$OLSRD_IPCCONNECT_SCHEMA" "$cfg" olsrd_write_option "${T}" echo "${N}}" IPCCONNECT_COUNT=$((IPCCONNECT_COUNT + 1)) - - return 0 } olsrd_write_hna4() { @@ -441,11 +440,9 @@ olsrd_write_hna4() { return 0 fi - [ "$HNA4_COUNT" -le 0 ] && echo -n "${N}Hna4${N}{" - echo -n "${N}${T}${T}$netaddr $netmask" + [ "$HNA4_COUNT" -le 0 ] && printf '%s' "${N}Hna4${N}{" + printf '%s' "${N}${T}${T}$netaddr $netmask" HNA4_COUNT=$((HNA4_COUNT + 1)) - - return 0 } olsrd_write_hna6() { @@ -468,39 +465,60 @@ olsrd_write_hna6() { return 0 fi - [ "$HNA6_COUNT" -le 0 ] && echo -n "${N}Hna6${N}{" - echo -n "${N}${T}${T}$netaddr $prefix" + [ "$HNA6_COUNT" -le 0 ] && printf '%s' "${N}Hna6${N}{" + printf '%s' "${N}${T}${T}$netaddr $prefix" HNA6_COUNT=$((HNA6_COUNT + 1)) +} - return 0 +find_most_recent_plugin_libary() +{ + local library="$1" # e.g. 'olsrd_dyn_gw' or 'olsrd_txtinfo.so.1.1' + local file file_fullpath unixtime + + for file in "/lib/$library"* "/usr/lib/$library"* "/usr/local/lib/$library"*; do { + [ -f "$file" ] && { + file_fullpath="$file" + file="$( basename "$file" )" + # make sure that we do not select + # 'olsrd_dyn_gw_plain.so.0.4' if user wants + # 'olsrd_dyn_gw.so.0.5' -> compare part before 1st dot + [ "${library%%.*}" = "${file%%.*}" ] && { + unixtime="$( date +%s -r "$file_fullpath" )" + echo "$unixtime $file" + } + } + } done | sort -n | tail -n1 | cut -d' ' -f2 } -olsrd_write_loadplugin() { - local funcname="olsrd_write_loadplugin" +olsrd_write_loadplugin() +{ + local funcname='olsrd_write_loadplugin' local cfg="$1" + local ignore name suffix lat lon latlon_infile + validate_varname "$cfg" || return 0 - local ignore - local name - local suffix - local lat - local lon - local latlon_infile config_get_bool ignore "$cfg" ignore 0 [ "$ignore" -ne 0 ] && return 0 + # e.g. olsrd_txtinfo.so.1.1 or 'olsrd_txtinfo' config_get library "$cfg" library - if ! validate_olsrd_option "$library"; then - warning_invalid_value olsrd "$cfg" "library" - return 0 - fi - if ! [ -x "/lib/$library" -o -x "/usr/lib/$library" -o -x "/usr/local/lib/$library" ]; then + + library="$( find_most_recent_plugin_libary "$library" )" + if [ -z "$library" ]; then log "$funcname() Warning: Plugin library '$library' not found, skipped" return 0 + else + library="$( basename "$library" )" fi + validate_olsrd_option "$library" || { + warning_invalid_value olsrd "$cfg" 'library' + return 0 + } + case "$library" in - olsrd_nameservice.*) + 'olsrd_nameservice.'*) config_get name "$cfg" name [ -z "$name" ] && config_set "$cfg" name $SYSTEM_HOSTNAME @@ -527,16 +545,14 @@ olsrd_write_loadplugin() { [ -z "$latlon_file" ] && config_set "$cfg" latlon_file '/var/run/latlon.js' ;; - olsrd_watchdog.*) + 'olsrd_watchdog.'*) config_get wd_file "$cfg" file ;; esac - echo -n "${N}LoadPlugin \"$library\"${N}{" + printf '%s' "${N}LoadPlugin \"$library\"${N}{" config_write_options "$OLSRD_LOADPLUGIN_SCHEMA" "$cfg" olsrd_write_plparam "${T}" echo "${N}}" - - return 0 } olsrd_write_interface() { @@ -575,19 +591,17 @@ olsrd_write_interface() { [ -z "$ifnames" ] && return 0 - echo -n "${N}Interface$ifnames${N}{" + printf '%s' "${N}Interface$ifnames${N}{" config_write_options "$OLSRD_INTERFACE_SCHEMA" "$cfg" olsrd_write_option "${T}" echo "${N}}" INTERFACES_COUNT=$((INTERFACES_COUNT + 1)) - - return 0 } olsrd_write_interface_defaults() { local cfg="$1" validate_varname "$cfg" || return 0 - echo -n "${N}InterfaceDefaults$ifnames${N}{" + printf '%s' "${N}InterfaceDefaults$ifnames${N}{" config_write_options "$OLSRD_INTERFACE_DEFAULTS_SCHEMA" "$cfg" olsrd_write_option "${T}" echo "${N}}" @@ -596,13 +610,13 @@ olsrd_write_interface_defaults() { olsrd_update_schema() { local command="$1" - validate_varname "$command" || return 0 local varname="$2" - validate_varname "$varname" || return 0 local value="$3" local cfg="$CONFIG_SECTION" local cfgt - local cur_varname + + validate_varname "$command" || return 0 + validate_varname "$varname" || return 0 config_get cfgt "$cfg" TYPE case "$cfgt" in @@ -640,7 +654,7 @@ get_wan_ifnames() { local wanifnames word catch_next - which ip >/dev/null || return 1 + command -v ip >/dev/null || return 1 set -- $( ip route list exact 0.0.0.0/0 table all ) for word in $*; do @@ -669,8 +683,10 @@ get_wan_ifnames() olsrd_setup_smartgw_rules() { local funcname="olsrd_setup_smartgw_rules" - # Check if ipip is installed - [ -e /etc/modules.d/[0-9]*-ipip ] || { + local file= + + for file in /etc/modules.d/[0-9]*-ipip; do :; done + [ -e "$file" ] || { log "$funcname() Warning: kmod-ipip is missing. SmartGateway will not work until you install it." return 1 } @@ -683,8 +699,8 @@ olsrd_setup_smartgw_rules() { nowan=0 fi - IP4T=$(which iptables) - IP6T=$(which ip6tables) + IP4T="$( command -v iptables )" + IP6T="$( command -v ip6tables )" # Delete smartgw firewall rules first if [ "$UCI_CONF_NAME" = "olsrd6" ]; then @@ -706,15 +722,17 @@ olsrd_setup_smartgw_rules() { while $IP4T -t nat -D postrouting_rule -o tnl_+ -j MASQUERADE 2> /dev/null; do :;done fi + # var 'smartgateway' + 'smartgatewayuplink' build in olsrd_write_olsrd() if [ "$smartgateway" = "yes" ]; then log "$funcname() Notice: Inserting firewall rules for SmartGateway" + if [ ! "$smartgatewayuplink" = "none" ]; then if [ "$smartgatewayuplink" = "ipv4" ]; then # Allow everything to be forwarded to tnl_+ and use NAT for it $IP4T -I forwarding_rule -o tnl_+ -j ACCEPT $IP4T -t nat -I postrouting_rule -o tnl_+ -j MASQUERADE # Allow forwarding from tunl0 to (all) wan-interfaces - if [ "$nowan"="0" ]; then + if [ "$nowan" = '0' ]; then for IFACE in $wanifnames; do $IP4T -A forwarding_rule -i tunl0 -o $IFACE -j ACCEPT done @@ -725,7 +743,7 @@ olsrd_setup_smartgw_rules() { done elif [ "$smartgatewayuplink" = "ipv6" ]; then $IP6T -I forwarding_rule -o tnl_+ -j ACCEPT - if [ "$nowan"="0" ]; then + if [ "$nowan" = '0' ]; then for IFACE in $wanifnames; do $IP6T -A forwarding_rule -i tunl0 -o $IFACE -j ACCEPT done @@ -737,7 +755,7 @@ olsrd_setup_smartgw_rules() { $IP4T -t nat -I postrouting_rule -o tnl_+ -j MASQUERADE for IPT in $IP4T $IP6T; do $IPT -I forwarding_rule -o tnl_+ -j ACCEPT - if [ "$nowan"="0" ]; then + if [ "$nowan" = '0' ]; then for IFACE in $wanifnames; do $IPT -A forwarding_rule -i tunl0 -o $IFACE -j ACCEPT done diff --git a/olsrd/files/olsrd6.config b/olsrd/files/olsrd6.config index 37349e4..7a03f28 100644 --- a/olsrd/files/olsrd6.config +++ b/olsrd/files/olsrd6.config @@ -3,7 +3,7 @@ config olsrd #option config_file '/etc/olsrd6.conf' config LoadPlugin - option library 'olsrd_txtinfo.so.0.1' + option library 'olsrd_txtinfo.so.1.1' option accept '::' option port '2007' diff --git a/olsrd/patches/.gitignore b/olsrd/patches/.gitignore new file mode 100644 index 0000000..e69de29 diff --git a/olsrd/patches/missing-include-dirs-warning.patch b/olsrd/patches/missing-include-dirs-warning.patch deleted file mode 100644 index 2bf0895..0000000 --- a/olsrd/patches/missing-include-dirs-warning.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -ur olsrd-0.9.5_orig/lib/pud/nmealib/Makefile.inc olsrd-0.9.5/lib/pud/nmealib/Makefile.inc ---- olsrd-0.9.5_orig/lib/pud/nmealib/Makefile.inc 2016-12-22 12:23:42.175283967 +0100 -+++ olsrd-0.9.5/lib/pud/nmealib/Makefile.inc 2016-12-22 12:24:24.591015066 +0100 -@@ -63,7 +63,7 @@ - -Wmissing-format-attribute -Wno-multichar -Wno-deprecated-declarations -Wendif-labels -Wwrite-strings \ - -Wbad-function-cast -Wpointer-arith -Wcast-qual -Wshadow -Wformat -Wsequence-point -Wcast-align \ - -Wnested-externs -Winline -Wdisabled-optimization -funit-at-a-time -fPIC -ggdb -Wformat=2 -Winit-self \ -- -Wmissing-include-dirs -Wswitch-default -Wswitch-enum -Wconversion -Wdouble-promotion \ -+ -Wswitch-default -Wswitch-enum -Wconversion -Wdouble-promotion \ - -Werror=format-security -Wformat-security -Wformat-y2k -Wredundant-decls -Wundef -Wunreachable-code \ - -Wunused-parameter - diff --git a/vis/Makefile b/vis/Makefile new file mode 100644 index 0000000..316224a --- /dev/null +++ b/vis/Makefile @@ -0,0 +1,74 @@ +# +# Copyright (C) 2008-2011 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +include $(TOPDIR)/rules.mk + +PKG_NAME:=vis + +PKG_SOURCE_PROTO:=git +PKG_SOURCE_URL:=git://git.open-mesh.org/vis.git +PKG_REV:=e141311c6a4fc824efbad536c137ed279905d825 +PKG_VERSION:=1440 +PKG_RELEASE:=0 +PKG_LICENSE:=GPL-2.0 + +PKG_SOURCE_VERSION:=$(PKG_REV) +PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) +PKG_SOURCE:=$(PKG_SOURCE_SUBDIR).tar.gz +PKG_MIRROR_HASH:=fd4b337a56993eec9a03ad8e7918bccc7691aa8b2e5ab6dd7863350f07503285 +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_SOURCE_SUBDIR) + +PKG_EXTRA_CFLAGS=-DDEBUG_MALLOC -DMEMORY_USAGE -DPROFILE_DATA -DREVISION_VERSION=\"\ rv$(PKG_REV)\" -D_GNU_SOURCE + +include $(INCLUDE_DIR)/package.mk + +define Package/vis + SECTION:=net + CATEGORY:=Network + SUBMENU:=Routing and Redirection + DEPENDS:=+libpthread + TITLE:=visualization server for B.A.T.M.A.N. layer 3 + URL:=https://www.open-mesh.org/ + MAINTAINER:=Corinna "Elektra" Aichele +endef + +define Package/vis/description +visualization server for B.A.T.M.A.N. layer 3 +endef + +MAKE_VIS_ARGS += \ + EXTRA_CFLAGS='$(TARGET_CFLAGS) $(PKG_EXTRA_CFLAGS)' \ + CCFLAGS="$(TARGET_CFLAGS)" \ + OFLAGS="$(TARGET_CFLAGS)" \ + REVISION="$(PKG_REV)" \ + CC="$(TARGET_CC)" \ + NODEBUG=1 \ + UNAME="Linux" \ + INSTALL_PREFIX="$(PKG_INSTALL_DIR)" \ + STRIP="/bin/true" \ + vis install + + +define Build/Configure +endef + +define Build/Compile + $(MAKE) -C $(PKG_BUILD_DIR) $(MAKE_VIS_ARGS) +endef + +define Package/vis/install + $(INSTALL_DIR) $(1)/usr/sbin $(1)/etc/config $(1)/etc/init.d + $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/vis $(1)/usr/sbin/ + $(INSTALL_BIN) ./files/etc/init.d/vis $(1)/etc/init.d + $(INSTALL_DATA) ./files/etc/config/vis $(1)/etc/config +endef + +define Package/vis/conffiles +/etc/config/vis +endef + +$(eval $(call BuildPackage,vis)) diff --git a/vis/files/etc/config/vis b/vis/files/etc/config/vis new file mode 100644 index 0000000..6d30023 --- /dev/null +++ b/vis/files/etc/config/vis @@ -0,0 +1,3 @@ +config vis general + option interface ath0 + diff --git a/vis/files/etc/init.d/vis b/vis/files/etc/init.d/vis new file mode 100644 index 0000000..ef18eb7 --- /dev/null +++ b/vis/files/etc/init.d/vis @@ -0,0 +1,19 @@ +#!/bin/sh /etc/rc.common +START=90 + +start () { + interface=$(uci get vis.general.interface) + if [ "$interface" = "" ]; then + echo $1 Error, you must specify at least a network interface + exit + fi + vis_args=$interface + + vis $vis_args >/dev/null 2>&1 +} + +stop () { + killall vis +} + +