Hostap -> routing issue

Mike Saywell ms at ecs.soton.ac.uk
Wed May 14 15:27:12 EDT 2003


On Wed, May 14, 2003 at 03:06:51PM -0400, Rob O'Connor wrote:
> eth0 is connected to the router and the box can ping the outside world.
> (eth0: 192.168.0.5 netmask 255.255.255.0)
> wlan0 (192.168.0.9 netmask: 255.255.255.0 running in Master mode)

This isn't really a hostap issue...  Remember that hostap just presents
the network with an interface, it does nothing special in terms of routing
or birdging.  You cant just stick 2 interfaces in the same subnet.

Either bridge the 2 interfaces and assign a single IP to br0.  The laptop
should get an IP from whatever DHCP server is running on your external
LAN.

Or if you want to go the routed approach you will need to assign a
different subnet to wlan0.  e.g. 192.168.1.x

However then you will have the problem that your LAN router has no idea
where 192.168.1.x has come from.  Also neither do any client machines.

You could get around this by natting on eth0 on the AP but that's ick.

The best thing to do is add a second wired interface to the AP and
connect the router directly to that.

i.e.

Router
  |
  |
HostAP----> LAN
  ~ 
  ~
 WLan

Each network needs a different subnet.

Hope that helps you out.

Regards,

Mike



More information about the HostAP mailing list