[CUWiN-Dev] CUWiN routers tunnel "home" through NATs

John Atkinson john.atkinson at gmail.com
Tue Sep 19 16:32:46 CDT 2006


Is this slated specifically for the Urbana network?

On 9/15/06, cu-wireless-dev-request at lists.cuwireless.net <
cu-wireless-dev-request at lists.cuwireless.net> wrote:

> Message: 1
> Date: Thu, 14 Sep 2006 15:49:19 -0500
> From: David Young <dyoung at pobox.com>
> Subject: [CUWiN-Dev] CUWiN routers tunnel "home" through NATs
> To: cu-wireless-dev at ucimc.org
> Message-ID: <20060914204919.GL24076 at che.ojctech.com>
> Content-Type: text/plain; charset=us-ascii
>
> I have some routers on the Urbana testbed phoning home like the little
> E.T.'s they are.  I use GRE over UDP tunnels (a feature I recently added
> to NetBSD) to tunnel back and forth through NAT routers that come between
> CUWiN routers and the Internet.  This means that soon we can reach all
> routers for diagnostic/upgrade purposes from the CUWiN office, including
> the "pod" that surrounds my house, the "pod" on Elm east of Vine, etc.
> Yay!
>
> I have put my UDP tunnel daemon, utd, on the CUWiN routers.  It runs in
> "client mode" and automatically creates tunnels.  At my office, I have
> made an old UltraSPARC workstation into a tunnel concentrator; it runs
> utd in "server mode."  Below is the present configuration of the ethernet
> and the tunnels on my tunnel concentrator. :-)
>
> hme0:
> flags=8a63<UP,BROADCAST,NOTRAILERS,RUNNING,ALLMULTI,SIMPLEX,MULTICAST> mtu
> 1500
>         capabilities=3c00<TCP4CSUM_Rx,TCP4CSUM_Tx,UDP4CSUM_Rx,UDP4CSUM_Tx>
>         enabled=0
>         address: 08:00:20:f9:60:ee
>         media: Ethernet autoselect (100baseTX full-duplex)
>         status: active
>         inet 64.198.255.12 netmask 0xfffffff0 broadcast 64.198.255.15
> gre66: flags=d051<UP,POINTOPOINT,RUNNING,LINK0,LINK2,MULTICAST> mtu 1476
>         tunnel inet 64.198.255.12,2525 --> 70.225.175.231,17336
>         inet 192.168.49.1 -> 192.168.49.70 netmask 0xffffff00
> gre67: flags=d051<UP,POINTOPOINT,RUNNING,LINK0,LINK2,MULTICAST> mtu 1476
>         tunnel inet 64.198.255.12,2525 --> 64.198.255.14,15859
>         inet 192.168.49.1 -> 192.168.49.71 netmask 0xffffff00
> gre68: flags=d051<UP,POINTOPOINT,RUNNING,LINK0,LINK2,MULTICAST> mtu 1476
>         tunnel inet 64.198.255.12,2525 --> 70.225.175.231,18859
>         inet 192.168.49.1 -> 192.168.49.72 netmask 0xffffff00
>
> The 'tunnel inet' lines tell us what address/port pairs are at the
> end of the tunnel.  Note that because of NAT, the tunnel on the CUWiN
> router may not precisely agree with the tunnel on the concentrator.
> E.g., this tunnel interface, which is on a router that sits on my desk,
> corresponds with gre67, above:
>
> gre392: flags=d051<UP,POINTOPOINT,RUNNING,LINK0,LINK2,MULTICAST> mtu 1476
>         tunnel inet 10.0.246.46,65533 --> 64.198.255.12,2525
>         inet 192.168.49.71 -> 192.168.49.1 netmask 0xffffff00
>
> A NAT router at a gateway node is translating 10.0.246.46,65533 to
> 64.198.255.14,15859.
>
> My tunnel concentrator assigns addresses to the CUWiN routers out of
> the private subnet 192.168.49/24.
>
> There is not yet any easy way to map a gre instance or 192.168.49.x
> address to a particular router in Urbana.  There is more than one way
> to do it, including running hslsd on the tunnel interfaces.
>
> Hmm.  Experimenting, I see that the concentrator can ping6 the all-hosts
> multicast on any gre---e.g., ping6 ff02::1%gre68---and get a reply from
> both itself and the router at the other end of the tunnel.  The router's
> IPv6 number will suffice to identify it:
>
> % ping6 ff02::1%gre68
> PING6(56=40+8+8 bytes) fe80::a00:20ff:fef9:60ee%gre68 --> ff02::1%gre68
> 16 bytes from fe80::a00:20ff:fef9:60ee%gre68, icmp_seq=0 hlim=64 time=
> 0.317 ms
> 16 bytes from fe80::202:6fff:fe20:b23f%gre68, icmp_seq=0 hlim=64 time=
> 97.621 ms(DUP!)
>
> Dave
>
> --
> David Young             OJC Technologies
> dyoung at ojctech.com      Urbana, IL * (217) 278-3933
>
>
> ------------------------------
>
> Message: 2
> Date: Thu, 14 Sep 2006 16:37:39 -0500
> From: David Young <dyoung at pobox.com>
> Subject: Re: [CUWiN-Dev] new netbsd snapshot
> To: cu-wireless-dev at ucimc.org
> Message-ID: <20060914213739.GM24076 at che.ojctech.com>
> Content-Type: text/plain; charset=us-ascii
>
> On Thu, Sep 14, 2006 at 04:22:12PM -0500, Bill Comisky wrote:
> > On Wed, 13 Sep 2006, David Young wrote:
> >
> > >A snapshot of my latest NetBSD sources is on cuw at
> > >~dyoung/cuwin-netbsd-snap-13-Sep-2006.tgz.  We should use those sources
> > >for the release.
> > >
> >
> > The cuw_pc kernel configuration (for ISO builds) needs to be updated for
> > this snapshot.  The patch below was a minimal change that got it
> compiling
> > here.  I saw the last update to the geode kernel config was more
> > substantial, so maybe there are other things you'd like to update?  If
> not
> > I'll commit.. suppose this should be merged to the new release branch
> too.
>
> Here is my procedure for bringing CUWiN's kernel configurations up-to-date
> with its NetBSD sources.  This deserves to be documented somewhere.
>
> 1 Find out what NetBSD configuration (filename & version) the config
>   derives from:
>
>         % cd $CUWIN_TRUNK/src/boot-image
>         % ident kernel-conf/cuw_pc
>         kernel-conf/cuw_pc:
>              $NetBSD: GENERIC,v 1.758 2006/06/19 15:44:44 gdamore Exp $
>              $Revision: 1.758 $
>
> 2 Use cvs to find the differences between GENERIC rev 1.758 and the
>   new NetBSD revision, rev BASE:
>
>         % cd $CUWIN_NETBSD_SRC/sys/arch/i386/
>         % cvs diff -r 1.758 -r BASE conf/GENERIC > /tmp/Gd
>
> 3 Apply the differences between 1.758 and BASE to cuw_pc:
>
>         % cd $CUWIN_TRUNK/src/boot-image
>         % patch kernel-conf/cuw_pc  < /tmp/Gd
>         Hmm...  Looks like a unified diff to me...
>         The text leading up to this was:
>         --------------------------
>         |Index: conf/GENERIC
>
>         |===================================================================
>         |RCS file: /cvsroot/src/sys/arch/i386/conf/GENERIC,v
>         |retrieving revision 1.758
>         |retrieving revision 1.781
>         |diff -p -u -r1.758 -r1.781
>         |--- conf/GENERIC       19 Jun 2006 15:44:44 -0000      1.758
>         |+++ conf/GENERIC       10 Sep 2006 15:45:56 -0000      1.781
>         --------------------------
>         Patching file kernel-conf/cuw_pc using Plan A...
>         Hunk #1 succeeded at 1.
>         Hunk #2 succeeded at 24 with fuzz 2 (offset 2 lines).
>         Hunk #3 succeeded at 49 with fuzz 2 (offset 5 lines).
>         Hunk #4 failed at 89.
>         Hunk #5 failed at 185.
>         Hunk #6 failed at 203.
>         Hunk #7 succeeded at 280 (offset -42 lines).
>         Hunk #8 succeeded at 353 (offset 5 lines).
>         Hunk #9 succeeded at 326 (offset -42 lines).
>         Hunk #10 succeeded at 426 with fuzz 1 (offset 5 lines).
>         Hunk #11 succeeded at 531 (offset -63 lines).
>         Hunk #12 failed at 591.
>         Hunk #13 failed at 645.
>         Hunk #14 succeeded at 647 with fuzz 2 (offset -107 lines).
>         Hunk #15 failed at 733.
>         Hunk #16 failed at 758.
>         Hunk #17 failed at 913.
>         Hunk #18 failed at 1009.
>         Hunk #19 failed at 1058.
>         Hunk #20 succeeded at 893 with fuzz 2 (offset -360 lines).
>         Hunk #21 succeeded at 1162 with fuzz 2 (offset -107 lines).
>         Hunk #22 failed at 1192.
>         Hunk #23 failed at 1241.
>         Hunk #24 succeeded at 995 with fuzz 2 (offset -392 lines).
>         12 out of 24 hunks failed--saving rejects to
> kernel-conf/cuw_pc.rej
>         done
>
> 4 Resolve "conflicts," i.e., discard or manually apply the "rejected"
>   hunks from above.  Remove cuw_pc.{rej,orig}.
>
> 5 Build and test.
>
> 6 Commit.
>
> Dave
>
> --
> David Young             OJC Technologies
> dyoung at ojctech.com      Urbana, IL * (217) 278-3933
>
>
> ------------------------------
>
> Message: 3
> Date: Thu, 14 Sep 2006 16:22:12 -0500 (CDT)
> From: Bill Comisky <bcomisky at pobox.com>
> Subject: Re: [CUWiN-Dev] new netbsd snapshot
> To: David Young <dyoung at pobox.com>
> Cc: cu-wireless-dev at ucimc.org
> Message-ID: <Pine.LNX.4.64.0609141618260.20458 at twain.bcomisky.com>
> Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed
>
> On Wed, 13 Sep 2006, David Young wrote:
>
> > A snapshot of my latest NetBSD sources is on cuw at
> > ~dyoung/cuwin-netbsd-snap-13-Sep-2006.tgz.  We should use those sources
> > for the release.
> >
>
> The cuw_pc kernel configuration (for ISO builds) needs to be updated for
> this snapshot.  The patch below was a minimal change that got it compiling
> here.  I saw the last update to the geode kernel config was more
> substantial, so maybe there are other things you'd like to update?  If not
> I'll commit.. suppose this should be merged to the new release branch too.
>
> Bill
>
> --
> Bill Comisky
> bcomisky at pobox.com
>
> Index: src/boot-image/kernel-conf/cuw_pc
> ===================================================================
> --- src/boot-image/kernel-conf/cuw_pc   (revision 4201)
> +++ src/boot-image/kernel-conf/cuw_pc   (working copy)
> @@ -773,8 +773,8 @@
>   # Bluetooth PCMCIA Controllers
>   bt3c* at pcmcia? function ?           # 3Com 3CRWB6096-A
>
> -# Bluetooth remote device 'hub'
> -pseudo-device bthub
> +# Bluetooth Device Hub
> +bthub* at bt3c?
>
>   # Bluetooth HID support
>   bthidev* at bthub?
> @@ -788,7 +788,7 @@
>   wskbd* at btkbd? console ? mux 1
>
>   # Bluetooth Audio support
> -bthset* at bthub?
> +btsco* at bthub?
>
>   # Cryptographic Devices
>
>
>
> ------------------------------
>
> _______________________________________________
> CU-Wireless-Dev mailing list
> CU-Wireless-Dev at lists.cuwireless.net
> http://lists.chambana.net/cgi-bin/listinfo/cu-wireless-dev
>
>
> End of CU-Wireless-Dev Digest, Vol 29, Issue 10
> ***********************************************
>



-- 
Regards,

John Atkinson
Director - Wireless Ghana
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.chambana.net/mailman/archive/cu-wireless-dev/attachments/20060919/85a343bc/attachment.html


More information about the CU-Wireless-Dev mailing list