Package: ipmasq Version: 4.0.2 Followup-For: Bug #309629 Hi,
I have experienced the same bug (it is therefore confirmed) and solved it in almost the same way independently (I should have checked before the BTS). Please notice that in the file F31routes.rul I believe the variable i should be substituted to the j (see the patch below) for the latter `if' test to make sense. ---------------------------------------------------------------------- diff -Naur /usr/share/doc/ipmasq/examples/routes/F31routes.rul /tmp/ipmasq-309629/F31routes.rul --- /usr/share/doc/ipmasq/examples/routes/F31routes.rul 2004-07-27 21:37:24.000000000 +0200 +++ /tmp/ipmasq-309629/F31routes.rul 2005-06-28 18:41:03.711288480 +0200 @@ -1,10 +1,10 @@ #: Forward packets among internal and routed networks if [ -n "$ROUTES" ]; then for route in $ROUTES; do - j=${$route%%:*} + j=${route%%:*} dest=${route##*:} for r in $ROUTES; do - j=${$r%%:*} + i=${r%%:*} src=${r##*:} if [ "$i" != "$j" ]; then case $MASQMETHOD in ---------------------------------------------------------------------- Just for the record my alternative patch to A01routes.rul is also included below. ---------------------------------------------------------------------- diff -Naur /usr/share/doc/ipmasq/examples/routes/A01routes.rul /tmp/ipmasq-309629/A01routes.rul --- /usr/share/doc/ipmasq/examples/routes/A01routes.rul 2004-07-28 22:51:24.000000000 +0200 +++ /tmp/ipmasq-309629/A01routes.rul 2005-06-28 18:41:03.711288480 +0200 @@ -18,9 +18,11 @@ return } -for route in `route -n | grep '^[1-9]'`; do +routelines=`route -n | grep '^[1-9]'` +for (( i=1 ; $i <= `echo "$routelines" | wc -l` ; i++ )) do + route=`echo "$routelines" | head -n $i | tail -n 1` IFACE=$( echo $route | { read X X X X X X X Y ; echo $Y ; } ) - if echo $INTERNAL | grep -q $IFACE; then + if `echo $INTERNAL | grep -q $IFACE -` ; then # $IFACE is in $INTERNAL NDEST=$( echo $route | { read Y X X X X X X X ; echo $Y ; } ) NMASK=$( echo $route | { read X X Y X X X X X ; echo $Y ; } ) ---------------------------------------------------------------------- Otherwise, I have the same typos for files I31routes.rul, M71masq.rul and O31routes.rul as original bug submitter (not included). Thanks for the works of both of you and best regards, Frederic Lehobey -- System Information: Debian Release: 3.1 APT prefers testing APT policy: (500, 'testing') Architecture: sparc (sparc64) Kernel: Linux 2.6.8-2-sparc64 Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968) Versions of packages ipmasq depends on: ii debconf 1.4.30.13 Debian configuration management sy ii ipchains 1.3.10-15 Network firewalling for Linux 2.2. ii iptables 1.2.11-10 Linux kernel 2.4+ iptables adminis -- debconf information: ipmasq/ppp-turn-on: * ipmasq/start: true ipmasq/move-ipmasq.rules: true ipmasq/external-rules-moved: true * ipmasq/start-location: After network services have been started ipmasq/dpkg-conffiles: * ipmasq/ppp-recompute: true * ipmasq/ppp-turn-off: ipmasq/old-ipmasq.conf: true ipmasq/old-rc.boot-file: true -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]