wpa_supplicant & iwconfig

2015-10-27 echo tools

wpa_supplicant

用wpa_passphrase生成最基本的wpa_supplicant配置文件:

wpa_passphrase TPLINK 12345678 |sudo tee -a /etc/wpa_supplicant/wpa_supplicant.conf 

wpa_supplication.conf的模板如下:
ctrl_interface=/var/run/wpa_supplicant
ctrl_interface_group=wheel
update_config=1

network={
 ssid="xxxx"
 scan_ssid=1
 psk=xxxxxxxxx37bca5cf24a345f514d319211822f568bba28f8f0b74c894e7644
 proto=RSN
 key_mgmt=WPA-PSK
 pairwise=CCMP
 auth_alg=OPEN
}


连接命令:
wpa_supplicant -B -d -iwlan0 -c/etc/wpa_supplicant.conf

动态获取IP:
dhclient wlan0


iwconfig

扫描AP节点:

iwlist wlan4 scanning

配置MYSSID:
iwconfig wlan0 essid "myssid"

加密码:
iwconfig wlan0 key s:xxxxx/xxxxxxxxxxxxx(40-bit为5个ASSIC字符,128-bit为13个ASSIC字符,以字符为密钥时,密钥之前需要加s:表示字符)



标签: 网络


版权所有: 本文发布于DD'echo
转载请保留原文链接: http://echo.z-dd.net/post-27.html
除非注明,文章均为 echo >> 原创 ,欢迎转载!转载请注明本文地址,谢谢!

友荐云推荐

发表评论:

Copyright @ 2015 DD'echo All rights reserved. Powered by emlog