尝试在 Kali linux 上安装 HostAPD 错误 = 驱动程序不支持身份验证/关联或连接命令

尝试在 Kali linux 上安装 HostAPD 错误 = 驱动程序不支持身份验证/关联或连接命令

我在虚拟机(vmware)中使用最新的 Kali 5.4.0-kali2-amd64 和 TP-Link TL-WN722N v2 加密狗,我尝试设置一个通过我的 Kali 虚拟机路由的接入点,以便我可以将 Android 设备连接到它用于测试,但 hostapd 拒绝启动

apt-get install isc-dhcp-server hostapd

根据 Ubuntu 文档,我已将 TP Link 设置为主模式,其中显示“我们需要无线“基站”或“接入点”是一个执行“主模式”的无线网卡”,可以使用iw配置:

https://unix.stackexchange.com/questions/92727/how-can-i-tell-if-my-wifi-dongle-has-access-point-capabilities

$ sudo iwconfig wlan0 mode master

root@kali:~# iwconfig
lo        no wireless extensions.

eth0      no wireless extensions.

wlan0     unassociated  ESSID:""  Nickname:"<WIFI@REALTEK>"
        Mode:Master  Frequency=2.412 GHz  Access Point: Not-Associated   
        Sensitivity:0/0  
        Retry:off   RTS thr:off   Fragment thr:off
        Encryption key:off
        Power Management:off
        Link Quality=0/100  Signal level=0 dBm  Noise level=0 dBm
        Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
        Tx excessive retries:0  Invalid misc:0   Missed beacon:0

使用以下 hostapd 配置数据:

        interface=wlan0
        driver=nl80211
        ssid=MyAP
        hw_mode=g
        channel=11
        wpa=1
        wpa_passphrase=MyPasswordHere
        wpa_key_mgmt=WPA-PSK
        wpa_pairwise=TKIP CCMP
        wpa_ptk_rekey=600

$ hostapd -dd /etc/hostapd/hostapd.conf

    root@kali:~# hostapd -dd /etc/hostapd/hostapd.conf
    random: getrandom() support available
    Configuration file: /etc/hostapd/hostapd.conf
    nl80211: Driver does not support authentication/association or connect commands
    nl80211: deinit ifname=wlan0 disabled_11b_rates=0
    nl80211: Remove monitor interface: refcount=0
    netlink: Operstate: ifindex=3 linkmode=0 (kernel-control), operstate=6 (IF_OPER_UP)
    nl80211: Set mode ifindex 3 iftype 2 (STATION)
    nl80211: Failed to set interface 3 to mode 2: -19 (No such device)
    nl80211 driver initialization failed.
    hostapd_interface_deinit_free(0x5615cd8809b0)
    hostapd_interface_deinit_free: num_bss=1 conf->num_bss=1
    hostapd_interface_deinit(0x5615cd8809b0)
    wlan0: interface state UNINITIALIZED->DISABLED
    hostapd_bss_deinit: deinit bss wlan0
    wlan0: AP-DISABLED 
    hostapd_cleanup(hapd=0x5615cd882000 (wlan0))
    wlan0: CTRL-EVENT-TERMINATING 
    hostapd_free_hapd_data: Interface wlan0 wasn't started
    hostapd_interface_deinit_free: driver=(nil) drv_priv=(nil) -> hapd_deinit
    hostapd_interface_free(0x5615cd8809b0)
    hostapd_interface_free: free hapd 0x5615cd882000
    hostapd_cleanup_iface(0x5615cd8809b0)
    hostapd_cleanup_iface_partial(0x5615cd8809b0)
    hostapd_cleanup_iface: free iface=0x5615cd8809b0

ifconfig 和 lsusb 的其他输出

    root@kali:~# ifconfig
    eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
            inet 192.168.2.131  netmask 255.255.255.0  broadcast 192.168.2.255
            inet6 fe80::20c:29ff:fee1:f92e  prefixlen 64  scopeid 0x20<link>
            ether 00:0c:29:e1:f9:2e  txqueuelen 1000  (Ethernet)
            RX packets 2759  bytes 4084142 (3.8 MiB)
            RX errors 0  dropped 0  overruns 0  frame 0
            TX packets 1407  bytes 98190 (95.8 KiB)
            TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

    lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
            inet 127.0.0.1  netmask 255.0.0.0
            inet6 ::1  prefixlen 128  scopeid 0x10<host>
            loop  txqueuelen 1000  (Local Loopback)
            RX packets 8  bytes 396 (396.0 B)
            RX errors 0  dropped 0  overruns 0  frame 0
            TX packets 8  bytes 396 (396.0 B)
            TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

    wlan0: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
            ether 50:3e:aa:7c:79:f4  txqueuelen 1000  (Ethernet)
            RX packets 788  bytes 0 (0.0 B)
            RX errors 0  dropped 0  overruns 0  frame 0
            TX packets 0  bytes 0 (0.0 B)
            TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

    root@kali:~# lsusb
    Bus 001 Device 002: ID 2357:010c TP-Link TL-WN722N v2
    Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
    Bus 002 Device 003: ID 0e0f:0002 VMware, Inc. Virtual USB Hub
    Bus 002 Device 002: ID 0e0f:0003 VMware, Inc. Virtual Mouse
    Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
    root@kali:~# 

附加信息,airmon-ng check kill以防万一有什么东西可能与之干扰,但没有运气

相关内容