wok rev 4628

Add icmptx
author Pascal Bellard <pascal.bellard@slitaz.org>
date Sun Dec 20 21:22:25 2009 +0100 (2009-12-20)
parents 43851b0813ec
children aa502dab7c89
files icmptx/receipt
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/icmptx/receipt	Sun Dec 20 21:22:25 2009 +0100
     1.3 @@ -0,0 +1,45 @@
     1.4 +# SliTaz package receipt.
     1.5 +
     1.6 +PACKAGE="icmptx"
     1.7 +VERSION="0.01"
     1.8 +CATEGORY="network"
     1.9 +SHORT_DESC="Tunnel IP connections using ICMP echo request."
    1.10 +MAINTAINER="pascal.bellard@slitaz.org"
    1.11 +TARBALL="$PACKAGE-$VERSION.tar.gz"
    1.12 +WEB_SITE="http://thomer.com/icmptx"
    1.13 +WGET_URL="$WEB_SITE/$TARBALL"
    1.14 +
    1.15 +# Rules to configure and make the package.
    1.16 +compile_rules()
    1.17 +{
    1.18 +	cd $src
    1.19 +	make
    1.20 +}
    1.21 +
    1.22 +# Rules to gen a SliTaz package suitable for Tazpkg.
    1.23 +genpkg_rules()
    1.24 +{
    1.25 +	mkdir -p $fs/usr/bin
    1.26 +	cp $src/$PACKAGE $fs/usr/bin
    1.27 +}
    1.28 +
    1.29 +# Pre and post install commands for Tazpkg.
    1.30 +post_install()
    1.31 +{
    1.32 +	cat << EOT
    1.33 +Server side example (on icmp-gateway) :
    1.34 +# icmptx -d 10.0.1.1 &
    1.35 +# ifconfig tun0 mtu 65535 up 10.0.1.1 netmask 255.255.255.0
    1.36 +# echo 1 > /proc/sys/net/ipv4/icmp_echo_ignore_all
    1.37 +# echo 1 > /proc/sys/net/ipv4/ip_forward
    1.38 +# iptables -t nat -A POSTROUTING -s 10.0.0.0/8 -j MASQUERADE
    1.39 +
    1.40 +client side example (assume 192.168.1.1 as default gw for wlan interface) :
    1.41 +# icmptx -c icmp-gateway &
    1.42 +# ifconfig tun0 mtu 65535 up 10.0.1.2 netmask 255.255.255.0
    1.43 +# route add -host icmp-gateway gw 192.168.1.1 dev wlan0
    1.44 +# route add default gw 10.0.1.1 tun0
    1.45 +
    1.46 +EOT
    1.47 +}
    1.48 +