# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
allow-hotplug eth0
iface eth0 inet dhcp

allow-hotplug eth1
iface eth1 inet static
 address 192.168.0.1
 netmask 255.255.255.0

auto wlan0
iface wlan0 inet static
 address 192.168.1.1
 netmask 255.255.255.0
 wireless-essid HomeNet
 wireless-mode ad-hoc
 wireless-channel 11
 wireless-rate 22Mb/s

post-up iptables -t nat -A POSTROUTING -p all -o eth0 -j MASQUERADE
post-up echo 1 > /proc/sys/net/ipv4/ip_forward

Add a code snippet to your website: www.paste.org