Hi,
I assume your network is set up like this:
10.0.0.1-253 / 255.255.255.0 Clients
10.0.0.254 / 255.255.255.0 Eth0 of your Linux box
192.168.1.2 / 255.255.255.0 Wlan0 of your Linux box
192.168.1.1 / 255.255.255.0 WLan adapter of the modem/router
then your routing table must look like:
Code:
# route -n
Destination Gateway Genmask Indic Metric Ref Use Iface
10.0.0.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0
192.168.1.0 0.0.0.0 255.255.255.0 U 0 0 0 wlan0
0.0.0.0 192.168.1.1 0.0.0.0 UG 0 0 0 wlan0
to configure the default gateway, if it hasn't been already done, the command line is "route add default gw 192.168.1.1"
this command won't be kept after restarting the network (or the machine), you have to write that in some config file (depends on your distro...)
then you want to be able to forward packets from wlan0 to eth0 and vice versa... that's what you tried to do by editing sysctl.conf. As far as I'm concerned, i'm doing it manually (well in my iptables script) by doing "echo 1 > /proc/sys/net/ipv4/ipforward".
so to check if forwarding is enabled, you can always do a "cat /proc/sys/net/ipv4/ipforward". Whatever the method used to enable forwarding, the answer should be 1.
If the file doesn't exist, then you're missing some module i'd guess.
once this is done/checked, you've got 2 solutions, depending on whether you can reconfigre the modem/router or not. If you can, then the easiest (but unsecure) way to achieve what you want is, as morgolis said, to add the route info for the 10.0.0.0 network in your modem/router. Unfortunatly, I won't be able to help unless you tell us what kind of machine it is...
if you can't do that, then you'll need to NAT the 10.0.0.x machines. It means that all packets coming from 10.0.0.x will have their source IP address changed to the one of your Linux wlan adapter. This way the router/modem won't even know that there are some machines in the 10.0.0.0 network.
to make things simple, this is done by using the following iptable command:
iptables -t nat -A FORWARD -o wlan0 -j MASQUERADE
to do that, you need to have at least the CONFIG_IP_NF_TARGET_MASQUERADE module enabled in your kernel.
Note that NATing is not firewalling, if you want to add some security, you'll still need to filter which packets are allowed and which are not.