[CUWiN-Dev] cuwireless.net name service use-cases & architecture

David Young dyoung at pobox.com
Thu Mar 10 00:41:08 CST 2005


Below is an overview of use-cases and architecture for the cuwireless.net
name service.  It's very IETF Zeroconf-centric.  Your feedback, please?

[In the auto-configuration area, there are both IETF Zeroconf (aka
Apple Rendezvous/Liaison) and Microsoft's UPnP.  I don't know too much
about UPnP.  Maybe somebody can give me a 10,000-foot overview of what
it does, whether it's open, and how/whether it's important?]

There's a lot of programming to be done.  I've tried to break things
down into discrete tasks, here:

          critique architecture :-)

          add Opaque LSAs to HSLS routing implementation; finish Opaque
          LSA client API for name service to use

          program web interface for a user to set pass/block rules,
          nameservers, domain name

          write a library for originating/receiving 'domain',
          'nameserver', 'srv', and 'txt'-type Opaque LSAs (use cases
          #0-#5)

          configure nsd(8) based on received 'domain'-type LSAs (see
          use-case #0)

          for non-Zeroconf hosts, originate appropriate LSAs and emit
          IP-redirect directives for IP Filter (use-case #1)

          program library (or adapt existing) for Multicast DNS and
          DNS Service Discovery with support for both querying and
          responding to iChat TXT and SRV records (use-cases #2-#4) (docs
          at <http://www.multicastdns.org/> and <http://www.dns-sd.org/>)
          [The 'howl' library's callback API is a good start.  I
           am wary of the implementation code, the Apple license terms,
           and the IPv4-centrism....  There is an Apple library & API for
           POSIX, but I cannot find API docs except a line-wrapped .h,
           the license is questionable, and they make stupid assumptions
           (like running mDNS on *every* interface, sheesh).]

          issue appropriate SRV / TXT records for received
          'srv'/'txt'-type Opaque LSAs

          apply pass/block filters to SRV records; originate appropriate
          LSAs and emit IP-redirect directives for IP Filter (use-cases
          #2-#4)

C-U Wireless Name Service Architecture
--- -------- ---- ------- ------------

Here is a C-U Wireless network.

         Alice's Node, 10.0.0.2
   +-+       +-+
   | |       | |----|
   +-+       +-+    |--powerbook._ichat._tcp.local (SRV record?)
      \     / ftp1--|
       \   /        |--192.168.1.19 by name ______ (A record)
        +-+   ftp2--|          ___________
        | |         |-        /           \       (serves urbana.il.us)
        +-+   ftp3--|  +--+  /             \     +------------+
         |          |--|gw|-|  Internet     |----| dns server |
         |             +--+  \             /     +------------+
        +-+                   \___________/\
        | | Bob's Node, 10.0.0.3            \
        +-+                                  \ (serves cuwireless.net)
         |                                    +-------------------+
        -|                                    | Zach's DNS server |
         |--server._http._tcp.local           +-------------------+
        -|
         |--ibook._ichat._tcp.local
        -|
         |--imac._ichat._tcp.local

On the left hand side is the wireless mesh.  In the middle is Alice's
home ethernet (ladder-looking thing).  Attached to Alice's ethernet
segment is a home gateway (gw).  Beyond the gateway is the Internet,
where there are a couple of domain name servers.  Bob's node is also
connected to the mesh.  He also has an ethernet segment attached to
his node.  Three PCs connect to the ethernet.

Use cases:

        0 Alice arranges with Zach, admin of domain cuwireless.net, to
          delegate alice.cuwireless.net to the nameserver on her node.
          Alice loads her mesh node's configuration web page at
          http:///192.168.0.1/, and adds to the list of domains her
          router is authoritative DNS for, alice.cuwireless.net.

          Implementation:

                  Alice's node originates an 'domain'-type opaque LSA
                  that maps alice.cuwireless.net to server 10.0.0.2.

                  As other nodes receive Alice's opaque LSAs, they
                  re-write their nsd(8) configuration so that queries
                  for names under alice.cuwireless.net are referred to
                  10.0.0.2, and reload nsd(8).

        1 Alice wants for her neighbors to be able to reach her HTTP
          server at 192.168.1.19 by the name www.alice.cuwireless.net.
          She loads her node's configuration web page at
          http://192.168.0.1/, clicks "sharing," enters a sharing
          "rule" that says to share 192.168.1.19 by the name
          www.alice.cuwireless.net.

          Implementation:

                Alice's node

                * maps 192.168.1.19 to an IP number that is routed
                  by HSLS, using NAT, and opens appropriate firewall
                  ports.

                * loads the name www into the nsd(8) configuration;
                  reloads nsd(8)

        2 Alice wants for her neighbors to be able to reach her at
          iChat on her Powerbook.  She loads her node's configuration
          web page and tells it to share powerbook._ichat._tcp.local
          with the world.

          Implementation:

                * Alice's node begins to listen/query for
                  powerbook._ichat._tcp.local on all ethernets, and

                * if/when a powerbook._ichat._tcp.local SRV record
                  is heard, Alice's node

                        * redirects address2/port2, for some arbitrary
                          address2 on a connected interface, to the
                          host/port in the SRV record

                        * originates an 'srv'-type opaque LSA that
                          associates host2/port2 with
                          powerbook._ichat._tcp.alice.cuwireless.net.
                          Relevant records of the SRV RR (TTL, etc.) are
                          copied to the 'srv'-type opaque LSA.

                Others' nodes, when they receive the 'srv'-type opaque
                LSA,

                * redirect an arbitrary address3/port3 on a connected
                  interface to address2/port2---perhaps we we can answer
                  powerbook._ichat._tcp.local queries with address2/port2,
                  instead of redirecting?

                * begin to respond to powerbook._ichat._tcp.local
                  on all ethernet segments, or if powerbook is taken,

                * begin to respond to powerbook-alice._ichat._tcp.local,
                  or if powerbook-alice is taken,

                * begin to respond to powerbook-alice-cuwireless-net, or
                  if powerbook-alice is taken,

                * begin to respond to
                  address2-powerbook-alice-cuwireless-net

                TBD How to relay TXT RRs with "presence" info?
                Introduce a 'txt'-type Opaque LSA?

        3 Bob wants for his neighbors to be able to reach his
          web server at 'server'.  He wants for the neighbors to reach him
          at iChat on any of his Macs.  He uses the configuration webpage
          for his node to tell the node to share server._http._tcp.local
          and _ichat._tcp.local.

          Implementation:

                Much as in #2, except Bob's node queries/listens for
                _ichat._tcp.local, originating an 'srv'-type opaque LSA
                for every answer.

        4 Alice wants for her neighbors to reach her radio servers
          at radio1._radiocast._udp.local, radio2..., radio3..., and so
          on, but she wants to protect radio9.  She uses the configuration
          webpage on her node to advertise _radiocast._udp.local, but
          she sets a "block" rule for radio9._radiocast._udp.local.

          Implementation:

                As in #2 and #3, but no 'srv'-type opaque LSA is created
                for radio9.

        5 Alice elects to advertise one of her ISP's
          nameservers to the neighborhood.  She has configured her node
          to use (and to send to DHCP clients) the nameservers w.x.y.z
          and a.b.c.d, using her node's web interface.  Alice uses the
          web interface to mark a.b.c.d as advertisable.

          Implementation:

                Alice's node originates a 'nameserver'-type opaque
                LSA for each nameserver that she elects to advertise.
                When others' nodes receive the 'nameserver'-type opaque
                LSA, they test that the nameserver works, and then
                they re-write their resolv.conf and dhcpd.conf files.
                [Possibly re-write nsd(8) config, too??]

Dave

-- 
David Young             OJC Technologies
dyoung at ojctech.com      Urbana, IL * (217) 278-3933


More information about the CU-Wireless-Dev mailing list