On Mon, Nov 26, 2001 at 10:05:59PM +0100, Oskar Sandberg wrote:
> On Mon, Nov 26, 2001 at 09:08:46PM +0100, Volker Stolz wrote:
> > In local.freenet, you wrote:
> > > A cross-platform solution (though a kludgy one) would be to open up a 
> > > ServerSocket on 
> > > port n, then have a Socket open up a connection to localhost:n, then read 
> > > the IP with 
> > > Socket.getLocalAddress().  Will that work?
> > 
> > No. How are you going to guess whether I want the node to use
> > eth0 or eth1 on my Linux machine? Or 192.168.1.1, 192.168.2.1,
> > 192.168.3.1 or the only correct choice, which is my dynamic IP
> > from yet another interface?
> 
> Yeah, and inside Fred I am loath to make any assumptions like there
> being only one Internet, or one Freenet. I would rather have such
> functionality kept in wrappers and install programs, and keep Fred's
> core idealistic and naive (at lack of better terms).
> 
> In theory this problem is intractable. On a multihomed host it is
> impossible to determine a single global address for the host (because
> there is no such thing). In practice we can work under the assumption
> that the node should be named as it is known to the Internet at large.
> There are, as far as I can tell, two ways to do this:
> 
> - We figure out way to probe not only for all the IPs, but also for
> their netmasks and gateways, and reimplement part of IP routing to
> figure out which is the Internet home.
Something in the rc file listing netmasks and addresses (or a flag not to
talk on that i/f), to allow multi-freenet nodes (eg WANs where some but not
all nodes have access to the "real" internet), and some platform specific
scripts; I have heard this can be done under win32, but I don't have
experience there (writing the unix scripts should be fairly easy)... this
would be similar to 0.3 behaviour once the platform specific support is in
place, and even allow tunneled private freenets over PPTP.
> 
> - We open a socket to a host that is known not to be local, let the
> kernel take care of routing, and use the local address on that socket. I
> don't think doing this in the installer is too bad, if we just add a
> warning, give people the possibility of writing in whatever address they
> want, and keep the option of specifying the local address manually. 
> 
> 
> The problem gets more complicated if you consider the situation with
> ARKs and nodes with semi-transient addresses. Then we need to some way
> to detect when the address changes so that the references can be updated
> and republished, and preferably without restarting the node or user
> intervention...
Is it? This can be done with wrappers reasonably easily on at least Win32
(so I am told) and Linux (/etc/ppp/ip-up.d, ifconfig)... restarting the node
takes a matter of seconds, is it such a big deal?
> 
> > -- 
> > Volker Stolz * vs at foldr.org * PGP + S/MIME
> > 
> > _______________________________________________
> > Devl mailing list
> > Devl at freenetproject.org
> > http://lists.freenetproject.org/mailman/listinfo/devl
> 
> -- 
> 
> Oskar Sandberg
> oskar at freenetproject.org
> 
> _______________________________________________
> Devl mailing list
> Devl at freenetproject.org
> http://lists.freenetproject.org/mailman/listinfo/devl

-- 
The road to Tycho is paved with good intentions

_______________________________________________
Devl mailing list
Devl at freenetproject.org
http://lists.freenetproject.org/mailman/listinfo/devl

Reply via email to