The very first thing I would do is disable any security on the router. No WEP, WPA, WPA2, mac or IP filtering. Then enable dhcp if not enabled. Now make a plain connection to the router and see if it works. If it does then ndiswrapper is configured and working fine. Now you can start enabling WPA from here.
I don't use NetworkManager so I can show you as manually setup would go.
First generate the passphrase like so. If essis is capital be sure to use capital letters there. Must be exact case for characters.
/usr/sbin/wpa_passphrase YOUR_AP_SSID “YOUR_WPA_PSK_PASSPHRASE”
Place generated output in wpa_supplicant.conf.
Example of what would be in wpa_supplicant.conf
Code:
ctrl_interface=/var/run/wpa_supplicant
ctrl_interface_group=wheel
# update_config=1
network={
ssid="Your ESSID"
#psk="unencrpyt passphrase here if wanted"
psk=generate passphrase here
proto=RSN
}
The proto line is WPA for WPA and RSN for WPA2.
Next I would disable NetworkManager. /sbin/service NetworkManager stop
Now bring wlan0 up. I would make sure if you have a wired nic to disable since only one can be up if both use a defined or get their own gateway.
/sbin/ifdown eth0
/sbin/ifdown wlan0
/sbin/ifup wlan0
Now start wpa_supplicant.
Code:
/usr/sbin/wpa_supplicant -dddd -Dwext -iwlan0 -c /etc/wpa_supplicant/wpa_supplicant.conf &
Now ping the routers lan side IP. ping -c5 xxx.xxx.xxx.xxx
Does it ping? If so then you may need to do the following if you wish to forget about NetworkManager and also disable eth0 if present.
Edit /etc/sysconfig/network-scripts/ifcfg-eth0. In this file change ONBOOT=yes to ONBOOT=no
Then to disable NetworkManager on reboot.
/sbin/chkconfig --level 345 NetworkManager off
Then edit /etc/sysconfig/network-scripts/ifup-wireless and add the this to the end of it.
Code:
/usr/sbin/wpa_supplicant -dddd -Dwext -iwlan0 -c /etc/wpa_supplicant/wpa_supplicant.conf &
Brian