diff --git a/ChangeLog b/ChangeLog new file mode 100644 index 0000000..700e719 --- /dev/null +++ b/ChangeLog @@ -0,0 +1,7 @@ +All changes by André Lange - andredbl at hotmail dot com + + +Released 19 March 2017 v1.7.0 + Operating System support + Tested on OpenWrt Chaos Calmer v15.05.1 and v15.05 + Tested on x86_64 image of LEDE v17.01.0 and Snapshot r3778-312b9dc diff --git a/README.md b/README.md index cbba4d8..1a09158 100644 --- a/README.md +++ b/README.md @@ -25,7 +25,7 @@ IPv6 addresses are difficult to remember. DNS provides an abstraction layer, so 3. When you are accessing your LAN hosts either locally or remotely through VPN. If the local and remote IPv4 subnets conflicts you can still use IPv6 ULA addresses (e.g FDxx:xxxx:...) to connect to your services. DNS names make this *much* easier. -When using ip6neigh, names are applied to local IPv6 hosts, rather than cryptic IPv6 addresses, such as shown in this OpenWrt Realtime Connections page. +When using ip6neigh, names are applied to local IPv6 hosts, rather than cryptic IPv6 addresses, such as shown in this OpenWrt Realtime Connections page: ![luci connections](art/luci_connections_names.png?raw=true) ## Installation diff --git a/art/luci_connections_names.png b/art/luci_connections_names.png index 7256820..760ed79 100644 Binary files a/art/luci_connections_names.png and b/art/luci_connections_names.png differ diff --git a/etc/hotplug.d/iface/30-ip6neigh b/etc/hotplug.d/iface/30-ip6neigh index f73a74a..b43d4c4 100644 --- a/etc/hotplug.d/iface/30-ip6neigh +++ b/etc/hotplug.d/iface/30-ip6neigh @@ -1,6 +1,6 @@ #!/bin/sh -#ip6neigh hotplug script version 1.6.0 +#ip6neigh hotplug script version 1.7.0 readonly SERVICE_NAME="ip6neigh-svc.sh" diff --git a/etc/init.d/ip6neigh b/etc/init.d/ip6neigh index 6ce869f..498e4bb 100644 --- a/etc/init.d/ip6neigh +++ b/etc/init.d/ip6neigh @@ -4,7 +4,7 @@ START=96 -readonly VERSION="1.6.0" +readonly VERSION="1.7.0" readonly SBIN_PATH="/usr/sbin/" readonly SERVICE_NAME="ip6neigh-svc.sh" readonly SERVICE_SCRIPT="${SBIN_PATH}${SERVICE_NAME}" diff --git a/extra/ip6neigh-oui-download.sh b/extra/ip6neigh-oui-download.sh deleted file mode 100644 index f957622..0000000 --- a/extra/ip6neigh-oui-download.sh +++ /dev/null @@ -1,41 +0,0 @@ -#!/bin/sh - -################################################################################## -# -# Copyright (C) 2016 André Lange -# -# See the file "LICENSE" for information on usage and redistribution -# of this file, and for a DISCLAIMER OF ALL WARRANTIES. -# Distributed under GPLv2 License -# -################################################################################## - -# Script to download and format an OUI database to be used with ip6neigh script. -# -# by André Lange Dec 2016 - -readonly SHARE_DIR="/usr/share/ip6neigh/" - -echo "Downloading Nmap MAC prefixes..." -wget -O '/tmp/oui-raw.txt' 'http://linuxnet.ca/ieee/oui/nmap-mac-prefixes' || exit 1 - -echo -e "\nApplying filters..." - -cat /tmp/oui-raw.txt | \ - tr '\t' ' ' | \ - cut -d ' ' -f1-2 | \ - grep "^[^#]" | \ - sort -t' ' -k1 | \ - sed 's/[^[0-9,a-z,A-Z]]*//g' \ -> /tmp/oui-filt.txt - -rm /tmp/oui-raw.txt - -echo "Compressing database..." -mv /tmp/oui-filt.txt /tmp/oui -gzip -f /tmp/oui || exit 2 - -echo "Moving the file..." -mv /tmp/oui.gz "$SHARE_DIR" || exit 3 - -echo -e "\nThe new compressed OUI database file is at: ${SHARE_DIR}oui.gz" diff --git a/extra/ip6neigh_ddns.sh b/extra/ip6neigh_ddns.sh deleted file mode 100644 index 9f703b1..0000000 --- a/extra/ip6neigh_ddns.sh +++ /dev/null @@ -1,28 +0,0 @@ -#!/bin/sh - -################################################################################## -# -# Copyright (C) 2016 André Lange -# -# See the file "LICENSE" for information on usage and redistribution -# of this file, and for a DISCLAIMER OF ALL WARRANTIES. -# Distributed under GPLv2 License -# -################################################################################## - - -# Script for feeding public IPv6 addresses with dynamic prefix to update with -# OpenWrt DDNS Scripts. Usage example: -# -# ip6neigh_ddns.sh Server1.PUB.lan -# -# by André Lange Dec 2016 - -name="$1" -[ -n "$name" ] || exit 1 - -line=$(grep -m 1 " ${name}$" /tmp/hosts/ip6neigh 2>/dev/null) -[ "$?" = 0 ] || exit 2 - -echo "$line" | cut -d ' ' -f1 -return 0 diff --git a/extra/ip6neigh_hosts_show.sh b/extra/ip6neigh_hosts_show.sh deleted file mode 100644 index 4e9f7b0..0000000 --- a/extra/ip6neigh_hosts_show.sh +++ /dev/null @@ -1,65 +0,0 @@ -#!/bin/sh - -################################################################################## -# -# Copyright (C) 2016 André Lange & Craig Miller -# -# See the file "LICENSE" for information on usage and redistribution -# of this file, and for a DISCLAIMER OF ALL WARRANTIES. -# Distributed under GPLv2 License -# -################################################################################## - - -# Script to display ip6neigh hosts file with columnar formatting (via awk) -# Script is called by luci-app-command for a web interface, or can be run directly -# -# by André Lange & Craig Miller Dec 2016 - -readonly HOSTS_FILE="/tmp/hosts/ip6neigh" -readonly SERVICE_NAME="ip6neigh_svc.sh" - -#Check if received valid arguments -if [ -n "$1" ]; then - case "$1" in - "-p"|"-d");; - *) - #Display help text - echo "ip6neigh Hosts Display Script" - echo -e - echo "usage: $0 [option]" - echo -e - echo "where option is one of:" - echo -e - echo " -p Show only predefined SLAAC hosts" - echo " -d Show only discovered hosts" - echo -e - exit 1 - esac -fi - -#Shows nothing if the hosts file does not exist -[ -f "$HOSTS_FILE" ] || exit 1 - -#Check if the service is running -if ! pgrep -f "$SERVICE_NAME" >/dev/null; then - echo "#SERVICE SCRIPT IS NOT RUNNING. THE INFORMATION MAY BE OUTDATED." -fi - -#Get the line number that divides the two sections of the hosts file -ln=$(grep -n '^#Discovered' "$HOSTS_FILE" | cut -d ':' -f1) - -#Check if allowed to show predefined hosts -if [ "$1" != "-d" ]; then - echo "#Predefined hosts" - awk "NR>1&&NR<(${ln}-1)"' {printf "%-30s %s %s\n",$2,$1,$3}' "$HOSTS_FILE" | sort -k1 - [ "$1" = "-p" ] || echo -e -fi - -#Check if allowed to show discovered hosts -if [ "$1" != "-p" ]; then - echo "#Discovered hosts" - awk "NR>${ln}"' {printf "%-30s %s %s\n",$2,$1,$3}' "$HOSTS_FILE" | sort -k1 -fi - -exit 0 diff --git a/extra/oui.gz b/extra/oui.gz deleted file mode 100644 index 2c7b8d0..0000000 Binary files a/extra/oui.gz and /dev/null differ diff --git a/ip6neigh-setup.sh b/ip6neigh-setup.sh index fdcb944..60126d0 100644 --- a/ip6neigh-setup.sh +++ b/ip6neigh-setup.sh @@ -14,7 +14,7 @@ # # by André Lange Dec 2016 -readonly VERSION='1.6.1' +readonly VERSION='1.7.0' readonly BIN_DIR="/usr/bin/" readonly SBIN_DIR="/usr/sbin/" diff --git a/lib/ip6addr_functions.sh b/lib/ip6addr_functions.sh index e86602f..dc120a7 100644 --- a/lib/ip6addr_functions.sh +++ b/lib/ip6addr_functions.sh @@ -16,7 +16,7 @@ # by André Lange Fev 2017 #Program definitions -IP6ADDR_LIB_VERSION='1.6.0' +IP6ADDR_LIB_VERSION='1.7.0' #Print version info and return if requested if [ "$1" = '--version' ]; then diff --git a/extra/test_libip6addr.sh b/lib/test_libip6addr.sh old mode 100755 new mode 100644 similarity index 100% rename from extra/test_libip6addr.sh rename to lib/test_libip6addr.sh diff --git a/main/ip6neigh-svc.sh b/main/ip6neigh-svc.sh index 8a3abc8..0eb4053 100644 --- a/main/ip6neigh-svc.sh +++ b/main/ip6neigh-svc.sh @@ -17,7 +17,7 @@ # by André Lange Dec 2016 #Program definitions -readonly SVC_VERSION='1.6.1' +readonly SVC_VERSION='1.7.0' readonly CONFIG_FILE='/etc/config/ip6neigh' readonly HOSTS_FILE='/tmp/hosts/ip6neigh' readonly CACHE_FILE='/tmp/ip6neigh.cache' diff --git a/main/ip6neigh.sh b/main/ip6neigh.sh index 3d433a5..be8fbc8 100644 --- a/main/ip6neigh.sh +++ b/main/ip6neigh.sh @@ -21,7 +21,7 @@ . /lib/functions/network.sh #Program definitions -readonly CMD_TOOL_VERSION='1.6.1' +readonly CMD_TOOL_VERSION='1.7.0' readonly HOSTS_FILE='/tmp/hosts/ip6neigh' readonly CACHE_FILE='/tmp/ip6neigh.cache' readonly SERVICE_NAME='ip6neigh-svc.sh' diff --git a/setup/VERSION b/setup/VERSION index ce6a70b..9dbb0c0 100644 --- a/setup/VERSION +++ b/setup/VERSION @@ -1 +1 @@ -1.6.0 \ No newline at end of file +1.7.0 \ No newline at end of file diff --git a/shared/oui.gz b/shared/oui.gz new file mode 100644 index 0000000..c519b05 Binary files /dev/null and b/shared/oui.gz differ