Subject: Re: "proxy arp" for ipv6?
To: None <tech-net@netbsd.org>
From: der Mouse <mouse@Rodents.Montreal.QC.CA>
List: tech-net
Date: 05/02/2002 01:15:49
>> Is there anything functionally akin to proxy arp for IPv6?  [...]
> One thing you may want to look at is the use of IPv6 Anycast
> addresses.

I don't _think_ an anycast address is suitable here.  See below.

> So explain what you want to accomplish and maybe we'll have a change
> of giving a correct answer.

A reasonable point.  But if this had been a wrong place to ask, or it's
a trivial question if only I'd read the right doc, I didn't want to
bother the list with a long missive.

Okay, I have a /28.  Let's pretend for the purposes of this message
that it's 192.168.1.0/28; it's not, but I'd rather not put the actual
numbers in a message that's going to show up in webbable list archives.
One of the hosts in it is actually run by a friend of mine.  Since I
don't run it (even though I basically trust the guy who does, or I
wouldn't've set it up in the first place), I don't want it capable of
sniffing the house LAN. Since I had a spare Ethernet card and I don't
want to shell out for a switch, I set this up:

---+-------------+-----+-------+----------- 192.168.1.0/28
   |192.168.1.1  | ... |    le0|192.168.1.2
+--+--+           other     +--+--+          +-----+
|  E  |        local boxen  |  G  |          |  S  |
+--+--+                     +--+--+          +--+--+
   |                        le1|10.0.0.1     le0|10.0.0.2
outside        10.0.0.0/30 ----+----------------+--------

Since I mention srt interfaces, below, and they're nonstandard, I
should say what they are.  The srt interface is a little hack of mine
designed to make routing decisions based on ip_src addresses (somewhat
like the ipf "pass in quick to le1 on le0 from a.b.c.d/w to any" that
was discussed not so very long ago).  It's POINTOPOINT, with a separate
control device (and associated program) to control its "routing table".

S is the box in question.  G ("gateway") is another machine on the
house LAN; E ("external") is my house LAN's gateway to the outside
world.  S has 192.168.1.3 allocated to it.  On S, I have srt0
configured 192.168.1.3 -> 10.0.0.4, with S's default route pointing to
10.0.0.4; srtconfig routes 0/0 out le0 with next-hop 10.0.0.1.  On G, I
have a proxy arp entry installed for 192.168.1.3 and a host route for
192.168.1.3 pointing to 10.0.0.2.  The 10.0.0.0/30 net between S and G
is a little two-foot piece of thinnet with only S and G on it (thinnet
rather than 10baseT purely out of what networking hardware was
convenient).

Traffic from the world to S, then, is routed to E because
192.168.1.0/28 is.  E then arps for it, G answers, gets the packet,
routes it to S's MAC address on the thinnet, S gets it, and accepts it
as local because srt0 is configured with 192.168.1.3 as its local
address.

Response traffic from S to the world follows the default route to srt0,
which redirects it to le1:10.0.0.1; G receives it and sends it to its
own default route, which points to E, and everything works.

Traffic originating with S is the same as response traffic, except that
there is the question of what IP address to use as ip_src; because the
default route points out srt0, it uses srt0's local address,
192.168.1.3.  (This is the only reason srt0 is involved; except for
this address issue, I would just point the default route on S out le0,
and configure le0 with 192.168.1.3 as an alias to get S to accept
incoming traffic.)

Now, the question is, how can I do this for IPv6?  If we assume I'm
using (say) 0300::/96 on the house LAN, how can I get G to respond to
neighbour sols for S's address as well as G's own?  Everything else, I
believe, I can handle; it's all static routes, and instead of the 10.*
addresses I can use site-local addresses.

/~\ The ASCII				der Mouse
\ / Ribbon Campaign
 X  Against HTML	       mouse@rodents.montreal.qc.ca
/ \ Email!	     7D C8 61 52 5D E7 2D 39  4E F1 31 3E E8 B3 27 4B