wpa_supplication的使用(1)

Wpa_supplicant

Wpa_supplicant是linux系统的无线网卡管理程序。

下面先给出我测试机TECNO-Phantom6 的wpa_supplication.conf

  • adb shell
  • cd data/misc/wifi
  • cat wpa_supplicant.conf
ctrl_interface=/data/misc/wifi/sockets
driver_param=use_p2p_group_interface=1
update_config=1
device_name=Phantom6
manufacturer=TECNO
model_name=Phantom6
model_number=Phantom6
serial_number=0123456789ABCDEF
device_type=10-0050F204-5
os_version=01020300
config_methods=physical_display virtual_push_button
p2p_no_group_iface=1
external_sim=1
wowlan_triggers=disconnect

network={
    ssid="transsion-tecno"
    psk="tecno1234"
    key_mgmt=WPA-PSK
    priority=15
}
network={
    ssid="ssss"
    scan_ssid=1 
    psk="11111111"
    key_mgmt=WPA-PSK
    priority=7
}

在手机wifi中保存的网络,会在该配置文件中以network节点保存
ssid :接入点名称
scan_ssid=1 :说明无线接入点是隐藏的

参考官方配置:wpa_supplicant官方配置文件(英文)

  • proto: ——支持的协议列表
  • WPA = WPA/IEEE 802.11i/D3.0
  • RSN = WPA2/IEEE 802.11i ———也能称为WPA2,它只是RSN的一个别名
  • 如果不设置,默认WPA RSN(WPA2)

  • key_mgmt: —认证密钥管理协议,支持的协议列表
  • WPA-PSK = WPA pre-shared key (this requires ‘psk’ field) —一般都是这个,这就包括了WPA、WPA2开始的那些方式
  • WPA-EAP = WPA using EAP authentication
  • IEEE8021X = IEEE 802.1X using EAP authentication and (optionally) dynamically generated WEP keys
  • NONE = WPA is not used; plaintext or static WEP could be used —这个是开放的,没密码、CMCC…
  • WPA-PSK-SHA256 = Like WPA-PSK but using stronger SHA256-based algorithms
  • WPA-EAP-SHA256 = Like WPA-EAP but using stronger SHA256-based algorithms
  • If not set, this defaults to: WPA-PSK WPA-EAP —如果未设置,默认支持WAP、WEP开头那些
  • pairwise: list of accepted pairwise (unicast) ciphers for WPA —WPA可用的加密方式列表
  • CCMP = AES in Counter mode with CBC-MAC [RFC 3610, IEEE 802.11i/D7.0] —这个就是AES
  • TKIP = Temporal Key Integrity Protocol [IEEE 802.11i/D7.0]
  • NONE = Use only Group Keys (deprecated, should not be included if APs support pairwise keys)
  • If not set, this defaults to: CCMP TKIP —不设置默认为CCMP TKIP
  • 1
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值