《通过命令连接wifi》 https://blog.csdn.net/cupidove/article/details/45340145
1、iwconfig 查看网络接口状态,记住无线网口的名字,比如wlan0 ,wls20等
2、如果是wep 加密,直接连接
sudo iwconfig wlan0 essid "MyHome" key 0123-4567-89
3、如果是wpa/wpa2 加密
#生成配置文件,写入网络号和密码
sudo wpa_passphrase [essid] [password] >> /etc/wpa_supplicant/wireless.conf
#使用配置文件
wpa_supplicant -B -D wext -i wlan0 -c /etc/wpa_supplicant/wireless.conf
- B means run wpa_supplicant in the background.
- -D specifies the wireless driver. wext is the generic driver.
- -c specifies the path for the configuration file.
#使用动态IP
dhclient wlan0
4、将配置写入文件,下次系统启动时自动加载
《关于kali无线网络配置》https://blog.csdn.net/myweaven/article/details/79305305
编辑配置文件 gedit /etc/network/interfaces,追加
auto wlan0
iface wlan0 inet dhcp
wpa-conf /etc/wpa_supplicant/wireless.conf