<html>
  <head>
    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <p>Hi,</p>
    <p><br>
    </p>
    <p>First of all, thanks for the answers! <br>
    </p>
    <p>Regarding your comments, it looks I did not made myself very
      clear! I answered below.<br>
    </p>
    <br>
    <blockquote
cite="mid:CAA0dE=W38V-G0B2YMKG2SHk7bL5V1brj1S9iVmNuQP=sjGocKg@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div>This property of remembering mappings is what makes NAT64<br>
          "stateful". Its advantage is that you're using a few G64
          addresses<br>
          to grant a potentially large and dynamic number of IPv6 nodes<br>
          access to IPv4 ones. The drawback is that IPv4 nodes cannot
          start<br>
          communication with v6 ones because G64 doesn't initially know
          who<br>
          they are talking to.<br>
          <br>
          (Unless you predefine mappings yourself. You can find more<br>
          information at <a moz-do-not-send="true"
            href="https://jool.mx/en/bib.html">https://jool.mx/en/bib.html</a>
          and<br>
          <a moz-do-not-send="true"
            href="https://jool.mx/en/usr-flags-bib.html">https://jool.mx/en/usr-flags-bib.html</a>)<br>
        </div>
      </div>
    </blockquote>
    I understand the mapping concept, and this question was for when G64
    already created the mapping for UDP between the IPv6 address and the
    IPv4 one (when using a pool4).<br>
    This drawback is exactly why I would want some kind DHCPing to
    happen: I.E. when Jool creates a mapping between one IPv6 and an
    IPv4 (this would only happen on A6-initiated traffic), I would like
    for it to ask to the DHCP for an address instead of randomly
    grabbing one from the pool4. And this mapping would have the same
    TTL as the allocation from the DHCP server.<br>
    <br>
    I read the doc for the bib entries, it would be perfect, except my
    only problem with those is that I would have to manually add every
    device as soon as it appears on the network. And I'm not sure how to
    do that (yet! Maybe I could broadcast a ping or use neighbour
    discovery to find IPv6 devices and attribute them a fixed entry, all
    from within a script that would also push new bib commands).<br>
    <br>
    <br>
    <blockquote
cite="mid:CAA0dE=W38V-G0B2YMKG2SHk7bL5V1brj1S9iVmNuQP=sjGocKg@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div>One of the downsides of SIIT is that this
          "predetermination" of<br>
          address mappings is not going to be friendly with your "Every
          IPv6<br>
          device has a somewhat unpredictable IP where the prefix is<br>
          fg01::/64" requirement.<br>
          <br>
          You can either find a way to impose more order to your address<br>
          assignment policies (so they will be friendlier to SIIT's<br>
          constraints) </div>
      </div>
    </blockquote>
    Yes, this is why I can't use SIIT. I can't impose more constraints
    on the IP of these devices...<br>
    <br>
    <br>
    <blockquote
cite="mid:CAA0dE=W38V-G0B2YMKG2SHk7bL5V1brj1S9iVmNuQP=sjGocKg@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div>or you can try Taiga (<a moz-do-not-send="true"
            href="http://www.litech.org/tayga/">http://www.litech.org/tayga/</a>).<br>
          Tayga is a SIIT/NAT64 hybrid in that it can assign v4
          addresses to<br>
          IPv6 nodes on the fly, and then the entire address (not just
          an<br>
          address and port) are assigned to the IPv6 node. I can't vouch
          for<br>
          Tayga because I don't use it and hasn't received updates in a
          long<br>
          time, but perhaps you can squeeze something out of it.<br>
        </div>
      </div>
    </blockquote>
    I tried it! But it doesn't compile out of the box for kernel 4.1.15.
    I didn't have time to investigate where the problem comes from.<br>
    <br>
    <br>
    <blockquote
cite="mid:CAA0dE=W38V-G0B2YMKG2SHk7bL5V1brj1S9iVmNuQP=sjGocKg@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div><br>
          Alternatively, you might want to open this hybrid operation
          mode as<br>
          a feature request for Jool: <a moz-do-not-send="true"
            href="https://github.com/NICMx/Jool/issues">https://github.com/NICMx/Jool/issues</a><br>
        </div>
      </div>
    </blockquote>
    That's an idea! I'll try and define more precisely the expected
    behavior before putting it up in Github.<br>
    <br>
    <br>
    <blockquote
cite="mid:CAA0dE=W38V-G0B2YMKG2SHk7bL5V1brj1S9iVmNuQP=sjGocKg@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div>> Here, I reckon that the gateway does not know that
          packets on the<br>
          > network with the 192.168.0.54 address are in fact
          destined to<br>
          > her, because when I manually add this IP to eth0 (with ip
          addr<br>
          > add <a moz-do-not-send="true"
            href="http://192.168.0.54/24">192.168.0.54/24</a> dev eth0
          ), suddenly, it works!<br>
          <br>
          A NAT64 is a device that masks IPv6 nodes behind it using its
          own<br>
          IPv4 address (or addresses).<br>
          An SIIT is a device that renames your IPv6 nodes, each using a<br>
          separate IPv4 address, without them realizing it.<br>
          <br>
          Pay special attention to the part where I say "using its own
          IPv4<br>
          address". NAT64 does not rename v6 nodes like SIIT does; it<br>
          pretends it itself is the IPv6 nodes it is masking. That's why
          they<br>
          are called "masks" :)<br>
          <br>
          So yes; the v4 nodes need to be fooled into thinking that G64
          *is*<br>
          the v6 network. One way to do that is by adding the addresses
          to<br>
          G64's interface. (So G64 answers ARP "neighbor" requests to
          these<br>
          packets.)<br>
          <br>
        </div>
      </div>
    </blockquote>
    Yes, I got that. But then, when we define a pool4, it stops doing
    this when it maps an IPv6 traffic to an IPv4. Or maybe I don't
    understand the use of pool4?<br>
    <br>
    <br>
    <blockquote
cite="mid:CAA0dE=W38V-G0B2YMKG2SHk7bL5V1brj1S9iVmNuQP=sjGocKg@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div>> How can I tell my eth0 interface that its should be
          concerned by<br>
          packets adressed on the 192.168.0.54 (which it used to send
          packets<br>
          beforehand since pinging worked), but without statically<br>
          configuring it with this IP address?<br>
          <br>
          You need to realize that 192.168.0.54 belongs to C4's network<br>
          (<a moz-do-not-send="true" href="http://192.168.0.54/100">192.168.0.54/100</a>),
          so C4 is expecting .54 to be one of its<br>
          neighbors. For this reason, it doesn't intend to send the
          packet<br>
          via any gateways.<br>
        </div>
      </div>
    </blockquote>
    Agreed, but I think the problem comes from G64 that does not know
    that indeed .54 traffic is expected to be for it (more specifically
    for one of its services).<br>
    <br>
    <br>
    <blockquote
cite="mid:CAA0dE=W38V-G0B2YMKG2SHk7bL5V1brj1S9iVmNuQP=sjGocKg@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div>That said, you can always instead inform C4 that any
          traffic<br>
          towards 192.168.0.54 should be routed via G64:<br>
          <br>
              romain@c4$ ip route add <a moz-do-not-send="true"
            href="http://192.168.0.54/32">192.168.0.54/32</a> via
          192.168.0.100<br>
          <br>
          But perhaps by this point you have realized that you should
          more<br>
          likely redesign the setup :p<br>
        </div>
      </div>
    </blockquote>
    Yes, and this is something I would like to avoid.<br>
    <br>
    <br>
    <blockquote
cite="mid:CAA0dE=W38V-G0B2YMKG2SHk7bL5V1brj1S9iVmNuQP=sjGocKg@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div>> Can jool automatically and dynamically requests a new
          IPv4 from a<br>
          DHCP server for an IPv6 device hidden behind?<br>
          <br>
          No, but why would you want to do that? (maybe I'm missing<br>
          something)<br>
        </div>
      </div>
    </blockquote>
    I explained in the beginning of this email why I want this.<br>
    <br>
    <br>
    <blockquote
cite="mid:CAA0dE=W38V-G0B2YMKG2SHk7bL5V1brj1S9iVmNuQP=sjGocKg@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div>> Can jool automatically set up new address on the eth0
          interface<br>
          (when they are allocated by the DHCP server)?<br>
          <br>
          No, but can't a shell script do it?<br>
        </div>
      </div>
    </blockquote>
    It definitely could! I think Michael's proposal is quite
    interesting, I'll start playing with macvlan to see how it behaves
    with the dhcp and everything.<br>
    <br>
    <br>
    <blockquote
cite="mid:CAA0dE=W38V-G0B2YMKG2SHk7bL5V1brj1S9iVmNuQP=sjGocKg@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div><br>
          By the way: It seems that you're having trouble understanding
          these<br>
          concepts from the documentation. Any tips on how to improve
          it?<br>
        </div>
      </div>
    </blockquote>
    I don't yet. I think that when I have better grasp on all those
    things I will be able to find areas that can be improved (if there
    are any).<br>
    <br>
    <br>
    <br>
    <br>
    Romain Bazile<br>
    <br>
  </body>
</html>