Subject: stf(4) and NAT
To: None <>
From: Martijn van Buul <>
List: tech-net
Date: 11/21/2005 13:52:27

I'm currently a happy owner of a IPv6 range in the 2001: range, but this
may change in the near future, as my tunnel broker might go bellyup. As
a result, I'm preemptively looking for alternatives, and before realising
that will probably provide me with a fresh new tunnel if I ask
them nicely, I tried 6-to-4. However, our stf(4) interface is giving me 

Unfortunately, I'm in the "happy" possession of a Wanadoo LiveBox, which
to my best knowledge refuses to behave like a bridging modem. Instead, it
insists on doing NAT. I managed to convice it that it should do forward all
incoming traffic to an IP on the private side of the modem, but that is as
far as I'll be able to get. This has two implications:

1) the "public" interface of my own NetBSD-based router is a private address.
2) And that address is going to be rewritten.

stf(4) refuses to cooperate because of this. First of all, it refuses to 
send from an interface with a private address, and secondly it fails to
locate the proper interface to begin with.

In order to comply with 6-to-4, my IPv6 range would be 2002:5591:54c5 /48,
since the public IP address of my modem is How do I specify
which interface stf(4) should use - namely fxp0, which has the private IP
address of, and that I know what I'm doing by overriding the
range it would use normally?

Martijn - who expects the answer to be "You can't, don't bother with stf", but
          nothing ventured, nothing gained...

    Martijn van Buul - -
	 Geek code: G--  - Visit OuterSpace: 3333
 The most exciting phrase to hear in science, the one that heralds new
discoveries, is not 'Eureka!' (I found it!) but 'That's funny ...' Isaac Asimov