Subject: Re: disabling source routing and ip-forwarding in current?
To: David Jones <dej@eecg.toronto.edu>
From: Mark P. Gooderum <mark@nirvana.good.com>
List: current-users
Date: 04/06/1995 10:26:18
> > can it be done? if so, how would i go about it?
>
> Simply remove options IPFORWARDING and options GATEWAY from the config file.
Wrong. Even with IPFORWARDING and GATEWAY off NetBSD (and all BSD IP
stacks by default including BSDI 1.1 and 2.0) still pass source routed packets.
You have to modify ip_dooptions() in ip_input.c. At the bottom of the
function where it says
if (forward) {
ip_forward(m, 1);
return (1);
}
Change it to look something like:
if (forward) {
#ifndef SROKAY
m_free(m);
#else
ip_forward(m, 1);
#endif
return (1);
}