2

I preformed a fresh install of Kali Linux on my laptop,so now the only operating system available is Kali Linux.

Here's my problem: My laptop cannot connect to the Internet through the already built-in wireless card. My laptop wireless card is: Intel Corporation Centrino Advanced-N 6200 2x2 AGN and although the system says that it using the kernal drivers for iwlwifi there is still no wireless Internet connection.

I tried changing the interfaces file under /etc/network/interfaces and added:
# The primary network interfaces
auto wlan0
allow-hotplug wlan0
iface wlan0 inet dhcp
Still no luck.
Here's the ifconfig details:

eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 192.168.1.77  netmask 255.255.255.0  broadcast 192.168.1.255
        inet6 fe80::223:18ff:febe:ab8e  prefixlen 64  scopeid 0x20<link>
        ether 00:23:18:be:ab:8e  txqueuelen 1000  (Ethernet)
        RX packets 27689  bytes 27448393 (26.1 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 15299  bytes 1495734 (1.4 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
        device interrupt 20  memory 0xd4600000-d4620000  

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 1  (Local Loopback)
        RX packets 2460  bytes 187820 (183.4 KiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 2460  bytes 187820 (183.4 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

wlan0: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
        ether 00:27:10:94:a8:3c  txqueuelen 1000  (Ethernet)
        RX packets 0  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


Here's the iwconfig details:

lo        no wireless extensions.

wlan0     IEEE 802.11abgn  ESSID:"ATT653"  
          Mode:Managed  Access Point: Not-Associated   Tx-Power=15 dBm   
          Retry short limit:7   RTS thr:off   Fragment thr:off
          Encryption key:off
          Power Management:off

eth0      no wireless extensions.

NOTE: For the ESSID, I manually added "ATT653" using

ifconfig wlan0 up
iwconfig wlan0 essid "ATT653"
dhclient wlan0

This didn't work because my network is WPA2 encrypted.
Here's the wireless card information:

root@kali:~# lspci
02:00.0 Network controller: Intel Corporation Centrino Advanced-N 6200 (rev 35)


and

root@kali:~# lspci -vq
02:00.0 Network controller: Intel Corporation Centrino Advanced-N 6200 (rev 35)
    Subsystem: Intel Corporation Centrino Advanced-N 6200 2x2 AGN
    Flags: bus master, fast devsel, latency 0, IRQ 29
    Memory at d4400000 (64-bit, non-prefetchable) [size=8K]
    Capabilities: [c8] Power Management version 3
    Capabilities: [d0] MSI: Enable+ Count=1/1 Maskable- 64bit+
    Capabilities: [e0] Express Endpoint, MSI 00
    Capabilities: [100] Advanced Error Reporting
    Capabilities: [140] Device Serial Number 00-27-10-ff-ff-94-a8-3c
    Kernel driver in use: iwlwifi
    Kernel modules: iwlwifi

1 Answer 1

1

The way to connect to a WPA2-PSK network manually is the following:

wpa_passphrase NetworkBSSID NetworkPassword > somefile.txt
ip link set dev wlan0 down
ip addr flush dev wlan0
pkill -9 dhclient
pkill -9 wpa_supplicant
ip link set dev wlan0 up
wpa_supplicant -B -Dnl80211 -i wlan0 -c somefile.txt 
dhclient -v wlan0

After this exchange, make sure that your DHCP server has passed you both a default gateway (ip route show | grep default) and suitable name servers (cat /etc/resolv.conf). If not, you need to correct this:

ip route add default via IP.Address.Of.YourGW
echo "nameserver 8.8.8.8" >> /etc/resolv.conf
echo "nameserver 8.8.4.4" >> /etc/resolv.conf

Of the bunch of 8 commands above, the first command is needed only once, of course. The following five commands clean up after previous connection attempts. The call to wpa_supplicant is what you really missed. The use of the nl80211 driver is made possible by the fact that iwlwifi is a fully 80211-compliant driver, hence you do not need to use the old driver, wext.

Please do not be confused: in the wpa_supplicant call, you should not use the name of your kernel-space driver, iwlwifi: you must use the name of your user-space driver, nl80211.

Lastly, the commands you use, ifconfig and iwconfig, are obsolete, pls use ip instead.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .