Не поднять wi-fi сеть (slackware 14.0 ; wpa-psk)

SLAX, Deep Style, ZenWalk

Модератор: Модераторы разделов

Ответить
QWERTYASDF
Сообщения: 989
Статус: Чайник со свистком
ОС: GNU/Linux

Не поднять wi-fi сеть

Сообщение QWERTYASDF »

Доброе время суток.

Недавно поставила дистрибутив, решила настроить сеть - проводной ethernet работает, беспроводной wi-fi не получается настроить. Network Manager не ставила - из принципа хочу настроить более штатными средствами. Читала эту тему, пыталась воспользоваться данными там рекомендациями, но все-равно ничего не вышло.

Код: Выделить всё

/etc/rc.d/rc.inet1 wlan0_restart
:
Spoiler
Error for wireless request "Set Nickname" (8B1C) : SET failed on device wlan0 ; Operation not supported
. Помогите мне пожалуйста.
Покажу мои конфиги:

/etc/rc.d/rc.inet1.conf:
Spoiler
# Config information for eth0:
IPADDR[0]="192.168.1.35"
NETMASK[0]="255.255.255.0"
USE_DHCP[0]=""
DHCP_HOSTNAME[0]=""

# Config information for eth1:
IPADDR[1]=""
NETMASK[1]=""
USE_DHCP[1]=""
DHCP_HOSTNAME[1]=""

# Config information for eth2:
IPADDR[2]=""
NETMASK[2]=""
USE_DHCP[2]=""
DHCP_HOSTNAME[2]=""

# Config information for eth3:
IPADDR[3]=""
NETMASK[3]=""
USE_DHCP[3]=""
DHCP_HOSTNAME[3]=""

# Default gateway IP address:
GATEWAY="192.168.1.1"

# Change this to "yes" for debugging output to stdout. Unfortunately,
# /sbin/hotplug seems to disable stdout so you'll only see debugging output
# when rc.inet1 is called directly.
DEBUG_ETH_UP="no"

# Example of how to configure a bridge:
# Note the added "BRNICS" variable which contains a space-separated list
# of the physical network interfaces you want to add to the bridge.
#IFNAME[0]="br0"
#BRNICS[0]="eth0"
#IPADDR[0]="192.168.0.1"
#NETMASK[0]="255.255.255.0"
#USE_DHCP[0]=""
#DHCP_HOSTNAME[0]=""

## Example config information for wlan0. Uncomment the lines you need and fill
## in your info. (You may not need all of these for your wireless network)
IFNAME[4]="wlan0"
IPADDR[4]="192.168.1.35"
NETMASK[4]="255.255.255.0"
#USE_DHCP[4]=""
#DHCP_HOSTNAME[4]="icculus-wireless"
#DHCP_KEEPRESOLV[4]="yes"
#DHCP_KEEPNTP[4]="yes"
#DHCP_KEEPGW[4]="yes"
#DHCP_IPADDR[4]=""
WLAN_ESSID[4]="666"
#WLAN_MODE[4]=Managed
#WLAN_RATE[4]="54M auto"
WLAN_CHANNEL[4]="auto"
##WLAN_KEY[4]="D5AD1F04ACF048EC2D0B1C80C7"
##WLAN_IWPRIV[4]="set AuthMode=WPAPSK | set EncrypType=TKIP | set WPAPSK=96389dc66eaf7e6efd5b5523ae43c7925ff4df2f8b7099495192d44a774fda16"
WLAN_WPA[4]="wpa_supplicant"
#WLAN_WPADRIVER[4]="ndiswrapper"
WLAN_WPADRIVER[4]="wext"

## Some examples of additional network parameters that you can use.
## Config information for wlan0:
#IFNAME[4]="wlan0" # Use a different interface name nstead of
# the default 'eth4'
#HWADDR[4]="00:01:23:45:67:89" # Overrule the card's hardware MAC address
#MTU[4]="" # The default MTU is 1500, but you might need
# 1360 when you use NAT'ed IPSec traffic.
#DHCP_KEEPRESOLV[4]="yes" # If you dont want /etc/resolv.conf overwritten
#DHCP_KEEPNTP[4]="yes" # If you don't want ntp.conf overwritten
#DHCP_KEEPGW[4]="yes" # If you don't want the DHCP server to change
# your default gateway
#DHCP_IPADDR[4]="" # Request a specific IP address from the DHCP
# server
#WLAN_ESSID[4]=DARKSTAR # Here, you can override _any_ parameter
# defined in rc.wireless.conf, by prepending
# 'WLAN_' to the parameter's name. Useful for
# those with multiple wireless interfaces.
#WLAN_IWPRIV[4]="set AuthMode=WPAPSK | set EncrypType=TKIP | set WPAPSK=thekey"
# Some drivers require a private ioctl to be
# set through the iwpriv command. If more than
# one is required, you can place them in the
# IWPRIV parameter (separated with the pipe (|)
# character, see the example).


/etc/wpa_supplicant.conf:
Spoiler
ctrl_interface=/var/run/wpa_supplicant
ctrl_interface_group=0
#ctrl_interface_group=root
ap_scan=1

network={
ssid="666"
proto= WPA RSN
key_mgmt=WPA-PSK
group=TKIP CCMP
pairwise=TKIP CCMP
psk=20b5a3708759e6695e259d3bee54103a240f5ff58841278941485d81b0f2ee2f
}


/etc/rc.d/rc.wireless.conf:
Spoiler
VERBOSE=1

case "$HWADDR" in

## NOTE : Comment out the following five lines to activate the samples below ...
## --------- START SECTION TO REMOVE -----------
## Pick up any Access Point, should work on most 802.11 cards
*)
INFO=""
ESSID="any"
;;
## ---------- END SECTION TO REMOVE ------------


# Here are a few examples with a few Wireless LANs supported...
# The matching is done on the first 3 bytes of the MAC address

# SMC2835W EZ Connect g 2.4GHz 54 Mbps Wireless Cardbus Adapter
00:04:E2:*)
INFO="SMC2835W EZ Connect g 2.4GHz 54 Mbps Wireless Cardbus Adapter"
# ESSID (extended network name) : My Network, any
ESSID=""
# NWID/Domain (cell identifier) : 89AB, 100, off
NWID=""
# Operation mode : Ad-Hoc, Managed, Master, Repeater, Secondary, auto
MODE="Managed"
# Frequency or channel : 1, 2, 3 (channel) ; 2.422G, 2.46G (frequency)
FREQ=""
CHANNEL="7"
# Sensitivity (cell size + roaming speed) : 1, 2, 3 ; -70 (dBm)
SENS=""
# Bit rate : auto, 1M, 11M,54M
RATE="auto"
# Encryption key : 4567-89AB-CD, s:password
# Example for 40-bit encryption:
#KEY="883e-aa67-21 [1] key 5501-d0da-87 [2] key 91f5-3368-6b [3] key 2d73-31b7-96 [4]"
# Example for 104-bit encryption (aka 128-bit WEP):
#KEY="d5ad2f05abd048ecf10b1c80c7"
KEY=""
# RTS threshold : off, 500
RTS=""
# Fragmentation threshold : off, 1000
FRAG=""
# Other iwconfig parameters : power off, ap 01:23:45:67:89:AB
IWCONFIG=""
# iwspy parameters : + 01:23:45:67:89:AB
IWSPY=""
# iwpriv parameters : set_port 2, set_histo 50 60
IWPRIV=""
;;

# Multiband Atheros based 802.11a/b/g universal NIC cards
00:05:4E:*)
INFO="Multiband Atheros based 802.11a/b/g universal NIC"
# ESSID (extended network name) : My Network, any
ESSID="any"
# Operation mode : Ad-Hoc, Managed, Master, Repeater, Secondary, auto
MODE="Managed"
# Frequency or channel : 1, 2, 3 (channel) ; 2.422G, 2.46G (frequency)
FREQ=""
CHANNEL="7"
# Bit rate : auto, 1M, 11M,54M
RATE="auto"
# Encryption key : 4567-89AB-CD, s:password
# Example for 40-bit encryption:
#KEY="883e-aa67-21 [1] key 5501-d0da-87 [2] key 91f5-3368-6b [3] key 2d73-31b7-96 [4]"
# Example for 104-bit encryption (aka 128-bit WEP):
#KEY="d5ad2f05abd048ecf10b1c80c7"
KEY=""
# Other iwconfig parameters : power off, ap 01:23:45:67:89:AB
IWCONFIG=""
# iwspy parameters : + 01:23:45:67:89:AB
IWSPY=""
# iwpriv parameters : set_port 2, set_histo 50 60
IWPRIV=""
;;

# Lucent Wavelan IEEE (+ Orinoco, RoamAbout and ELSA)
# Note : wvlan_cs driver only, and version 1.0.4+ for encryption support
00:60:1D:*|00:02:2D:*)
INFO="Wavelan IEEE example (Lucent default settings)"
ESSID="Wavelan Network"
MODE="Managed"
#RATE="auto"
KEY="s:secu1"
# To set all four keys, use :
#KEY="s:secu1 [1] key s:secu2 [2] key s:secu3 [3] key s:secu4 [4] key [1]"
# For the RG 1000 Residential Gateway: The ESSID is the identifier on
# the unit, and the default key is the last 5 digits of the same.
#ESSID="084d70"
#KEY="s:84d70"
;;

# Cisco/Aironet 4800/3x0
# Note : MPL driver only (airo/airo_cs), version 1.3 or later
00:40:96:*|00:02:8A:*)
INFO="Cisco/Aironet example (Cisco default settings)"
ESSID=""
# To set all four ESSID, use iwconfig v21 and the same trick as above
MODE="Managed"
#RATE="11M auto"
#KEY="d5ad2f05abd048ecf10b1c80c7"
KEY="off"
;;

# Samsung MagicLan (+ some other PrismII cards)
# Note : Samsung binary library driver, version 1.20 or later
00:00:F0:*|00:02:78:*)
INFO="Samsung MagicLan example (Samsung default settings)"
ESSID=""
MODE="Managed"
CHANNEL="4"
RATE="auto"
#KEY="883e-aa67-21 [1] key 5501-d0da-87 [2] key 91f5-3368-6b [3] key 2d73-31b7-96 [4]"
#IWCONFIG="power on"
;;

# Raytheon Raylink/WebGear Aviator2.4
# Note : doesn't work yet, please use for debugging only :-(
00:00:8F:*|00:00:F1:*)
INFO="Raylink/Aviator2.4 example (Aviator default ad-hoc setting)"
ESSID="ADHOC_ESSID"
MODE="Ad-Hoc"
RATE="auto"
IWPRIV="set_framing 1"
;;

# Old Lucent Wavelan
08:00:0E:*)
INFO="Wavelan example (Lucent default settings)"
NWID="0100"
MODE="Ad-Hoc"
FREQ="2.425G"
KEY="off"
;;

# Netwave (Xircom Netwave/Netwave Airsurfer)
00:80:C7:*)
INFO="Netwave example (Netwave default settings)"
NWID="100"
KEY="00"
;;

# Proxim RangeLan2/Symphony (what is the MAC address ???)
XX:XX:XX:*)
INFO="Proxim RangeLan2/Symphony example"
NWID="0"
MODE="Master"
CHANNEL="15"
IWPRIV="setsubchan 1"
;;

# No Wires Needed Swallow 550 and 1100 setting (what is the MAC address ???)
XX:XX:XX:*)
INFO="NWN Swallow example"
ESSID="session"
KEY="0000-0000-00 open"
;;

# Symbol Spectrum24 setting (what is the MAC address ???)
XX:XX:XX:*)
INFO="Symbol Spectrum24 example"
ESSID="Essid string"
;;

# Generic example (decribe all possible settings)
*)
INFO="Fill with your own settings..."
# ESSID (extended network name) : My Network, any
ESSID=""
# NWID/Domain (cell identifier) : 89AB, 100, off
NWID=""
# Operation mode : Ad-Hoc, Managed, Master, Repeater, Secondary, auto
MODE=""
# Frequency or channel : 1, 2, 3 (channel) ; 2.422G, 2.46G (frequency)
FREQ=""
CHANNEL=""
# Sensitivity (cell size + roaming speed) : 1, 2, 3 ; -70 (dBm)
SENS=""
# Bit rate : auto, 1M, 11M
RATE=""
# Encryption key : 4567-89AB-CD, s:password
KEY=""
# RTS threshold : off, 500
RTS=""
# Fragmentation threshold : off, 1000
FRAG=""
# Other iwconfig parameters : power off, ap 01:23:45:67:89:AB
IWCONFIG=""
# iwspy parameters : + 01:23:45:67:89:AB
IWSPY=""
# iwpriv parameters : set_port 2, set_histo 50 60
IWPRIV=""
;;
esac


Здесь, в секции "START SECTION TO REMOVE" ESSID ставила и "666" и "any" - результат тот-же.

Команды.

Код: Выделить всё

iwlist wlan0 scan
:
Spoiler
Address: 40:4A:03:63:F1:BC
Channel:6
Frequency:2.437 GHz (Channel 6)
Quality=70/70 Signal level=-39 dBm
Encryption key:on
ESSID:"666"
Bit Rates:1 Mb/s; 2 Mb/s; 5.5 Mb/s; 11 Mb/s; 6 Mb/s
9 Mb/s; 12 Mb/s; 18 Mb/s
Bit Rates:24 Mb/s; 36 Mb/s; 48 Mb/s; 54 Mb/s
Mode:Master
Extra:tsf=00000000a8100a3e
Extra: Last beacon: 924ms ago
IE: Unknown: 0003393934
IE: Unknown: 010882848B960C121824
IE: Unknown: 030106
IE: IEEE 802.11i/WPA2 Version 1
Group Cipher : TKIP
Pairwise Ciphers (2) : CCMP TKIP
Authentication Suites (1) : PSK
IE: WPA Version 1
Group Cipher : TKIP
Pairwise Ciphers (2) : CCMP TKIP
Authentication Suites (1) : PSK
IE: Unknown: 2A0100
IE: Unknown: 32043048606C
IE: Unknown: DD180050F2020101090003A4000027A4000042435E0062322F00
IE: Unknown: DD1E00904C334E101BFF00000000000000000000000000000000000000000000
IE: Unknown: 2D1A4E101BFF00000000000000000000000000000000000000000000
IE: Unknown: DD1A00904C3406071900000000000000000000000000000000000000
IE: Unknown: 3D1606071900000000000000000000000000000000000000
IE: Unknown: DD0900037F01010000FF7F
IE: Unknown: DD0A00037F04010000000000


Код: Выделить всё

iwconfig wlan0
:
Spoiler
wlan0 IEEE 802.11bgn ESSID:off/any
Mode:Managed Frequency:2.437 GHz Access Point: Not-Associated
Tx-Power=15 dBm
Retry long limit:7 RTS thr:off Fragment thr:off
Encryption key:off
Power Management:on


После остановки интерфейса

Код: Выделить всё

/etc/rc.d/rc.inet1 wlan0_stop
вывод

Код: Выделить всё

wpa_supplicant -c/etc/wpa_supplicant.conf -iwlan0 -d
:
Spoiler
wpa_supplicant v1.0
random: Trying to read entropy from /dev/random
Initializing interface 'wlan0' conf '/etc/wpa_supplicant.conf' driver 'default' ctrl_interface 'N/A' bridge 'N/A'
Configuration file '/etc/wpa_supplicant.conf' -> '/etc/wpa_supplicant.conf'
Reading configuration file '/etc/wpa_supplicant.conf'
ctrl_interface='/var/run/wpa_supplicant'
ctrl_interface_group='0'
ap_scan=1
Priority group 0
id=0 ssid='666'
WEXT: cfg80211-based driver detected
wext: interface wlan0 phy: phy0
rfkill: initial event: idx=0 type=1 op=0 soft=0 hard=0
SIOCGIWRANGE: WE(compiled)=22 WE(source)=21 enc_capa=0xf
capabilities: key_mgmt 0xf enc 0xf flags 0x0
netlink: Operstate: linkmode=1, operstate=5
wlan0: Own MAC address: e0:b9:a5:05:38:b8
wpa_driver_wext_set_key: alg=0 key_idx=0 set_tx=0 seq_len=0 key_len=0
wpa_driver_wext_set_key: alg=0 key_idx=1 set_tx=0 seq_len=0 key_len=0
wpa_driver_wext_set_key: alg=0 key_idx=2 set_tx=0 seq_len=0 key_len=0
wpa_driver_wext_set_key: alg=0 key_idx=3 set_tx=0 seq_len=0 key_len=0
wpa_driver_wext_set_countermeasures
wlan0: RSN: flushing PMKID list in the driver
wlan0: Setting scan request: 0 sec 100000 usec
WPS: Set UUID for interface wlan0
WPS: UUID based on MAC address - hexdump(len=16): 3b 76 50 06 dc f7 55 ed b4 47 c2 bd 5f 8e 85 29
EAPOL: SUPP_PAE entering state DISCONNECTED
EAPOL: Supplicant port status: Unauthorized
EAPOL: KEY_RX entering state NO_KEY_RECEIVE
EAPOL: SUPP_BE entering state INITIALIZE
EAP: EAP entering state DISABLED
EAPOL: Supplicant port status: Unauthorized
EAPOL: Supplicant port status: Unauthorized
ctrl_interface_group=0
wlan0: Added interface wlan0
random: Got 20/20 bytes from /dev/random
RTM_NEWLINK: operstate=0 ifi_flags=0x1003 ([UP])
RTM_NEWLINK, IFLA_IFNAME: Interface 'wlan0' added
WEXT: if_removed already cleared - ignore event
RTM_NEWLINK: operstate=0 ifi_flags=0x1003 ([UP])
RTM_NEWLINK, IFLA_IFNAME: Interface 'wlan0' added
WEXT: if_removed already cleared - ignore event
Wireless event: cmd=0x8b06 len=8
RTM_NEWLINK: operstate=0 ifi_flags=0x1003 ([UP])
RTM_NEWLINK, IFLA_IFNAME: Interface 'wlan0' added
WEXT: if_removed already cleared - ignore event
Wireless event: cmd=0x8b1a len=8
wlan0: State: DISCONNECTED -> SCANNING
wlan0: Starting AP scan for wildcard SSID
Scan requested (ret=0) - scan timeout 10 seconds
EAPOL: disable timer tick
EAPOL: Supplicant port status: Unauthorized
RTM_NEWLINK: operstate=0 ifi_flags=0x1003 ([UP])
RTM_NEWLINK, IFLA_IFNAME: Interface 'wlan0' added
WEXT: if_removed already cleared - ignore event
Wireless event: cmd=0x8b19 len=8
wlan0: Event SCAN_RESULTS (3) received
Scan results did not fit - trying larger buffer (8192 bytes)
Received 6624 bytes of scan results (15 BSSes)
wlan0: BSS: Start scan result update 1
wlan0: BSS: Add new id 0 BSSID 40:4a:03:63:f1:bc SSID '666'

...еще куча точек...

wlan0: New scan results available
wlan0: Selecting BSS from priority group 0
wlan0: 0: 40:4a:03:63:f1:bc ssid='666' wpa_ie_len=26 rsn_ie_len=24 caps=0x11 level=-41
wlan0: selected based on RSN IE
wlan0: selected BSS 40:4a:03:63:f1:bc ssid='666'
wlan0: Request association: reassociate: 0 selected: 40:4a:03:63:f1:bc bssid: 00:00:00:00:00:00 pending: 00:00:00:00:00:00 wpa_state: SCANNING
wlan0: Trying to associate with 40:4a:03:63:f1:bc (SSID='666' freq=2437 MHz)
wlan0: Cancelling scan request
wlan0: WPA: clearing own WPA/RSN IE
wlan0: Automatic auth_alg selection: 0x1
wlan0: RSN: using IEEE 802.11i/D9.0
wlan0: WPA: Selected cipher suites: group 8 pairwise 24 key_mgmt 2 proto 2
WPA: set AP WPA IE - hexdump(len=28): dd 1a 00 50 f2 01 01 00 00 50 f2 02 02 00 00 50 f2 04 00 50 f2 02 01 00 00 50 f2 02
WPA: set AP RSN IE - hexdump(len=26): 30 18 01 00 00 0f ac 02 02 00 00 0f ac 04 00 0f ac 02 01 00 00 0f ac 02 00 00
wlan0: WPA: using GTK TKIP
wlan0: WPA: using PTK CCMP
wlan0: WPA: using KEY_MGMT WPA-PSK
WPA: Set own WPA IE default - hexdump(len=22): 30 14 01 00 00 0f ac 02 01 00 00 0f ac 04 01 00 00 0f ac 02 00 00
wlan0: No keys have been configured - skip key clearing
wlan0: State: SCANNING -> ASSOCIATING
wpa_driver_wext_set_operstate: operstate 0->0 (DORMANT)
netlink: Operstate: linkmode=-1, operstate=5
wpa_driver_wext_associate
wpa_driver_wext_set_drop_unencrypted
wpa_driver_wext_set_psk
wlan0: Setting authentication timeout: 10 sec 0 usec
EAPOL: External notification - EAP success=0
EAPOL: Supplicant port status: Unauthorized
EAPOL: External notification - EAP fail=0
EAPOL: Supplicant port status: Unauthorized
EAPOL: External notification - portControl=Auto
EAPOL: Supplicant port status: Unauthorized
RSN: Ignored PMKID candidate without preauth flag
wlan0: Checking for other virtual interfaces sharing same radio (phy0) in event_scan_results
RTM_NEWLINK: operstate=0 ifi_flags=0x1003 ([UP])
RTM_NEWLINK, IFLA_IFNAME: Interface 'wlan0' added
WEXT: if_removed already cleared - ignore event
Wireless event: cmd=0x8b1a len=8
RTM_NEWLINK: operstate=0 ifi_flags=0x1003 ([UP])
RTM_NEWLINK, IFLA_IFNAME: Interface 'wlan0' added
WEXT: if_removed already cleared - ignore event
Wireless event: cmd=0x8b06 len=8
RTM_NEWLINK: operstate=0 ifi_flags=0x1003 ([UP])
RTM_NEWLINK, IFLA_IFNAME: Interface 'wlan0' added
WEXT: if_removed already cleared - ignore event
Wireless event: cmd=0x8b04 len=12
RTM_NEWLINK: operstate=0 ifi_flags=0x1003 ([UP])
RTM_NEWLINK, IFLA_IFNAME: Interface 'wlan0' added
WEXT: if_removed already cleared - ignore event
Wireless event: cmd=0x8b1a len=11
RTM_NEWLINK: operstate=0 ifi_flags=0x11003 ([UP][LOWER_UP])
RTM_NEWLINK, IFLA_IFNAME: Interface 'wlan0' added
WEXT: if_removed already cleared - ignore event
RTM_NEWLINK: operstate=0 ifi_flags=0x11003 ([UP][LOWER_UP])
RTM_NEWLINK, IFLA_IFNAME: Interface 'wlan0' added
WEXT: if_removed already cleared - ignore event
Wireless event: cmd=0x8c08 len=185
AssocResp IE wireless event - hexdump(len=177): 01 08 82 84 8b 0c 12 96 18 24 32 04 30 48 60 6c dd 18 00 50 f2 02 01 01 09 00 03 a4 00 00 27 a4 00 00 42 43 5e 00 62 32 2f 00 dd 09 00 03 7f 01 01 00 00 ff 7f dd 0a 00 03 7f 04 01 00 00 00 00 00 dd 1e 00 90 4c 33 4e 10 1b ff 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 2d 1a 4e 10 1b ff 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 dd 1a 00 90 4c 34 06 07 19 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 3d 16 06 07 19 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
RTM_NEWLINK: operstate=0 ifi_flags=0x11003 ([UP][LOWER_UP])
RTM_NEWLINK, IFLA_IFNAME: Interface 'wlan0' added
WEXT: if_removed already cleared - ignore event
Wireless event: cmd=0x8b15 len=20
Wireless event: new AP: 40:4a:03:63:f1:bc
wlan0: Event ASSOCINFO (4) received
wlan0: Association info event
resp_ies - hexdump(len=177): 01 08 82 84 8b 0c 12 96 18 24 32 04 30 48 60 6c dd 18 00 50 f2 02 01 01 09 00 03 a4 00 00 27 a4 00 00 42 43 5e 00 62 32 2f 00 dd 09 00 03 7f 01 01 00 00 ff 7f dd 0a 00 03 7f 04 01 00 00 00 00 00 dd 1e 00 90 4c 33 4e 10 1b ff 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 2d 1a 4e 10 1b ff 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 dd 1a 00 90 4c 34 06 07 19 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 3d 16 06 07 19 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
wlan0: Event ASSOC (0) received
wlan0: State: ASSOCIATING -> ASSOCIATED
wpa_driver_wext_set_operstate: operstate 0->0 (DORMANT)
netlink: Operstate: linkmode=-1, operstate=5
wlan0: Associated to a new BSS: BSSID=40:4a:03:63:f1:bc
wlan0: No keys have been configured - skip key clearing
wlan0: Associated with 40:4a:03:63:f1:bc
wlan0: WPA: Association event - clear replay counter
wlan0: WPA: Clear old PTK
EAPOL: External notification - portEnabled=0
EAPOL: Supplicant port status: Unauthorized
EAPOL: External notification - portValid=0
EAPOL: Supplicant port status: Unauthorized
EAPOL: External notification - EAP success=0
EAPOL: Supplicant port status: Unauthorized
EAPOL: External notification - portEnabled=1
EAPOL: SUPP_PAE entering state CONNECTING
EAPOL: enable timer tick
EAPOL: SUPP_BE entering state IDLE
wlan0: Setting authentication timeout: 10 sec 0 usec
wlan0: Cancelling scan request
EAPOL: startWhen --> 0
EAPOL: disable timer tick
EAPOL: SUPP_PAE entering state CONNECTING
EAPOL: enable timer tick
EAPOL: txStart
WPA: drop TX EAPOL in non-IEEE 802.1X mode (type=1 len=0)
wlan0: RX EAPOL from 40:4a:03:63:f1:bc
wlan0: Setting authentication timeout: 10 sec 0 usec
wlan0: IEEE 802.1X RX: version=1 type=3 length=95
wlan0: EAPOL-Key type=2
wlan0: key_info 0x8a (ver=2 keyidx=0 rsvd=0 Pairwise Ack)
wlan0: key_length=16 key_data_length=0
replay_counter - hexdump(len=8): 00 00 00 00 00 00 00 02
key_nonce - hexdump(len=32): 60 b7 43 dd 9a e1 9f ff f5 59 cc 8d fd 3a dd 9a 60 9d 99 a1 68 78 d7 9a 5e 7f 18 b8 97 6c bc e1
key_iv - hexdump(len=16): 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
key_rsc - hexdump(len=8): 00 00 00 00 00 00 00 00
key_id (reserved) - hexdump(len=8): 00 00 00 00 00 00 00 00
key_mic - hexdump(len=16): 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
wlan0: State: ASSOCIATED -> 4WAY_HANDSHAKE
wlan0: WPA: RX message 1 of 4-Way Handshake from 40:4a:03:63:f1:bc (ver=2)
RSN: msg 1/4 key data - hexdump(len=0):
WPA: Renewed SNonce - hexdump(len=32): 4b 87 7f b6 52 67 fc b7 dc a6 60 21 34 c2 cb bb b8 95 86 8a f2 ec fd f7 66 15 9b e3 f5 d3 7f e0
WPA: PTK derivation - A1=e0:b9:a5:05:38:b8 A2=40:4a:03:63:f1:bc
WPA: Nonce1 - hexdump(len=32): 4b 87 7f b6 52 67 fc b7 dc a6 60 21 34 c2 cb bb b8 95 86 8a f2 ec fd f7 66 15 9b e3 f5 d3 7f e0
WPA: Nonce2 - hexdump(len=32): 60 b7 43 dd 9a e1 9f ff f5 59 cc 8d fd 3a dd 9a 60 9d 99 a1 68 78 d7 9a 5e 7f 18 b8 97 6c bc e1
WPA: PMK - hexdump(len=32): [REMOVED]
WPA: PTK - hexdump(len=48): [REMOVED]
WPA: WPA IE for msg 2/4 - hexdump(len=22): 30 14 01 00 00 0f ac 02 01 00 00 0f ac 04 01 00 00 0f ac 02 00 00
WPA: Replay Counter - hexdump(len=8): 00 00 00 00 00 00 00 02
wlan0: WPA: Sending EAPOL-Key 2/4
WPA: KCK - hexdump(len=16): [REMOVED]
WPA: Derived Key MIC - hexdump(len=16): 31 5a 73 cc 92 e4 07 f7 b9 2a 78 87 88 97 a2 37
wlan0: RX EAPOL from 40:4a:03:63:f1:bc
wlan0: IEEE 802.1X RX: version=1 type=3 length=199
wlan0: EAPOL-Key type=2
wlan0: key_info 0x13ca (ver=2 keyidx=0 rsvd=0 Pairwise Install Ack MIC Secure Encr)
wlan0: key_length=16 key_data_length=104
replay_counter - hexdump(len=8): 00 00 00 00 00 00 00 03
key_nonce - hexdump(len=32): 60 b7 43 dd 9a e1 9f ff f5 59 cc 8d fd 3a dd 9a 60 9d 99 a1 68 78 d7 9a 5e 7f 18 b8 97 6c bc e1
key_iv - hexdump(len=16): 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
key_rsc - hexdump(len=8): 00 00 00 00 00 00 00 00
key_id (reserved) - hexdump(len=8): 00 00 00 00 00 00 00 00
key_mic - hexdump(len=16): 82 d5 13 dc 76 a4 58 b3 df f0 8c 11 8a 82 1c 16
RSN: encrypted key data - hexdump(len=104): 4c 19 35 f6 f3 69 70 be b9 d5 11 64 47 91 02 b5 68 d0 af 4e bf dc cd be ee df eb f6 2c 11 97 dc d6 01 ca bc 82 bd a6 56 67 db 4d 92 a6 05 85 7d d4 e9 01 aa dd 47 79 28 32 9f a4 87 3b a4 78 7d 73 9d da 83 6d 6e a8 a7 3c 43 c5 14 ed d5 a3 d9 57 95 d7 70 31 82 1c 87 e9 ab d3 5b 82 90 f9 bc 98 01 b4 5c 7f c5 9e c3
WPA: decrypted EAPOL-Key key data - hexdump(len=96): [REMOVED]
wlan0: State: 4WAY_HANDSHAKE -> 4WAY_HANDSHAKE
wlan0: WPA: RX message 3 of 4-Way Handshake from 40:4a:03:63:f1:bc (ver=2)
WPA: IE KeyData - hexdump(len=96): 30 18 01 00 00 0f ac 02 02 00 00 0f ac 04 00 0f ac 02 01 00 00 0f ac 02 00 00 dd 1a 00 50 f2 01 01 00 00 50 f2 02 02 00 00 50 f2 04 00 50 f2 02 01 00 00 50 f2 02 dd 26 00 0f ac 01 01 00 37 04 c5 54 75 fa 77 51 dd eb 55 55 46 7f 97 2d 40 81 92 f7 cc 34 43 06 33 77 92 49 af cd 77 36 dd 00
WPA: RSN IE in EAPOL-Key - hexdump(len=26): 30 18 01 00 00 0f ac 02 02 00 00 0f ac 04 00 0f ac 02 01 00 00 0f ac 02 00 00
WPA: WPA IE in EAPOL-Key - hexdump(len=28): dd 1a 00 50 f2 01 01 00 00 50 f2 02 02 00 00 50 f2 04 00 50 f2 02 01 00 00 50 f2 02
WPA: GTK in EAPOL-Key - hexdump(len=40): [REMOVED]
wlan0: WPA: Sending EAPOL-Key 4/4
WPA: KCK - hexdump(len=16): [REMOVED]
WPA: Derived Key MIC - hexdump(len=16): 78 19 c2 ba 7a 7c 23 52 9c bc 2a 76 9f 10 3d 79
wlan0: WPA: Installing PTK to the driver
wpa_driver_wext_set_key: alg=3 key_idx=0 set_tx=1 seq_len=6 key_len=16
EAPOL: External notification - portValid=1
wlan0: State: 4WAY_HANDSHAKE -> GROUP_HANDSHAKE
RSN: received GTK in pairwise handshake - hexdump(len=34): [REMOVED]
WPA: Group Key - hexdump(len=32): [REMOVED]
wlan0: WPA: Installing GTK to the driver (keyidx=1 tx=0 len=32)
WPA: RSC - hexdump(len=6): 00 00 00 00 00 00
wpa_driver_wext_set_key: alg=2 key_idx=1 set_tx=0 seq_len=6 key_len=32
wlan0: WPA: Key negotiation completed with 40:4a:03:63:f1:bc [PTK=CCMP GTK=TKIP]
wlan0: Cancelling authentication timeout
wlan0: State: GROUP_HANDSHAKE -> COMPLETED
wlan0: CTRL-EVENT-CONNECTED - Connection to 40:4a:03:63:f1:bc completed (auth) [id=0 id_str=]
wpa_driver_wext_set_operstate: operstate 0->1 (UP)
netlink: Operstate: linkmode=-1, operstate=6
EAPOL: External notification - portValid=1
EAPOL: External notification - EAP success=1
EAPOL: SUPP_PAE entering state AUTHENTICATING
EAPOL: SUPP_BE entering state SUCCESS
EAP: EAP entering state DISABLED
EAPOL: SUPP_PAE entering state AUTHENTICATED
EAPOL: Supplicant port status: Authorized
EAPOL: SUPP_BE entering state IDLE
EAPOL authentication completed successfully
RTM_NEWLINK: operstate=1 ifi_flags=0x11043 ([UP][RUNNING][LOWER_UP])
RTM_NEWLINK, IFLA_IFNAME: Interface 'wlan0' added
WEXT: if_removed already cleared - ignore event
wlan0: RX EAPOL from 40:4a:03:63:f1:bc
wlan0: IEEE 802.1X RX: version=1 type=3 length=143
wlan0: EAPOL-Key type=2
wlan0: key_info 0x1392 (ver=2 keyidx=1 rsvd=0 Group Ack MIC Secure Encr)
wlan0: key_length=32 key_data_length=48
replay_counter - hexdump(len=8): 00 00 00 00 00 00 00 04
key_nonce - hexdump(len=32): 17 66 1a 61 77 d0 30 9f ac 1f 02 35 aa c2 48 96 6a d7 9c c7 51 44 78 b5 0f 61 25 63 0b 9a 93 6b
key_iv - hexdump(len=16): 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
key_rsc - hexdump(len=8): 00 00 00 00 00 00 00 00
key_id (reserved) - hexdump(len=8): 00 00 00 00 00 00 00 00
key_mic - hexdump(len=16): 83 5b d2 bf 5e bb bb 33 eb 10 f2 c3 ab f1 11 38
RSN: encrypted key data - hexdump(len=48): de 99 a0 dd 89 7d 6e bf 7d a6 f6 02 6b 75 ed 96 5b c4 81 7d 82 2b 4f 29 81 4f 7e a0 d7 8f 24 1e 16 48 99 eb 59 00 8e 01 24 20 f9 14 47 ca 67 f3
WPA: decrypted EAPOL-Key key data - hexdump(len=40): [REMOVED]
wlan0: WPA: RX message 1 of Group Key Handshake from 40:4a:03:63:f1:bc (ver=2)
RSN: msg 1/2 key data - hexdump(len=40): dd 26 00 0f ac 01 01 00 37 04 c5 54 75 fa 77 51 dd eb 55 55 46 7f 97 2d 40 81 92 f7 cc 34 43 06 33 77 92 49 af cd 77 36
WPA: GTK in EAPOL-Key - hexdump(len=40): [REMOVED]
RSN: received GTK in group key handshake - hexdump(len=34): 01 00 37 04 c5 54 75 fa 77 51 dd eb 55 55 46 7f 97 2d 40 81 92 f7 cc 34 43 06 33 77 92 49 af cd 77 36
wlan0: State: COMPLETED -> GROUP_HANDSHAKE
WPA: Group Key - hexdump(len=32): [REMOVED]
wlan0: WPA: Installing GTK to the driver (keyidx=1 tx=0 len=32)
WPA: RSC - hexdump(len=6): 00 00 00 00 00 00
wpa_driver_wext_set_key: alg=2 key_idx=1 set_tx=0 seq_len=6 key_len=32
wlan0: WPA: Sending EAPOL-Key 2/2
WPA: KCK - hexdump(len=16): [REMOVED]
WPA: Derived Key MIC - hexdump(len=16): 83 26 c2 8b 07 ba 5e d8 67 2e 38 4f dd a9 0e a8
wlan0: WPA: Group rekeying completed with 40:4a:03:63:f1:bc [GTK=TKIP]
wlan0: Cancelling authentication timeout
wlan0: State: GROUP_HANDSHAKE -> COMPLETED
EAPOL: startWhen --> 0
EAPOL: disable timer tick
wlan0: BSS: Expire BSS 1 due to age
...

wlan0: CTRL-EVENT-TERMINATING - signal 2 received
wlan0: Removing interface wlan0
wpa_driver_wext_deauthenticate
wpa_driver_wext_set_key: alg=0 key_idx=0 set_tx=0 seq_len=0 key_len=0
wpa_driver_wext_set_key: alg=0 key_idx=1 set_tx=0 seq_len=0 key_len=0
wpa_driver_wext_set_key: alg=0 key_idx=2 set_tx=0 seq_len=0 key_len=0
wpa_driver_wext_set_key: alg=0 key_idx=3 set_tx=0 seq_len=0 key_len=0
wpa_driver_wext_set_key: alg=0 key_idx=0 set_tx=0 seq_len=0 key_len=0
wlan0: State: COMPLETED -> DISCONNECTED
wpa_driver_wext_set_operstate: operstate 1->0 (DORMANT)
netlink: Operstate: linkmode=-1, operstate=5
EAPOL: External notification - portEnabled=0
EAPOL: SUPP_PAE entering state DISCONNECTED
EAPOL: Supplicant port status: Unauthorized
EAPOL: SUPP_BE entering state INITIALIZE
EAPOL: Supplicant port status: Unauthorized
EAPOL: External notification - portValid=0
EAPOL: Supplicant port status: Unauthorized
EAPOL: External notification - portValid=0
EAPOL: Supplicant port status: Unauthorized
EAPOL: External notification - EAP success=0
EAPOL: Supplicant port status: Unauthorized
wpa_driver_wext_set_countermeasures
wlan0: No keys have been configured - skip key clearing
wlan0: BSS: Remove id 0 BSSID 40:4a:03:63:f1:bc SSID '666'
wlan0: Cancelling scan request
wlan0: Cancelling authentication timeout
netlink: Operstate: linkmode=0, operstate=6





Спасибо сказали:
Аватара пользователя
bormant
Сообщения: 1354

Re: Не поднять wi-fi сеть

Сообщение bormant »

В rc.inet1.conf нужно убрать дублирование ip:
IPADDR[0]="192.168.1.35"
IPADDR[4]="192.168.1.35"

rc.inet1 поднимает все настроенные интерфейсы -- будет конфликт.

На ошибку Set nickname можно внимания не обращать (или закомментировать соответствующий код).

Код: Выделить всё

RTM_NEWLINK: operstate=1 ifi_flags=0x11043 ([UP][RUNNING][LOWER_UP])
RTM_NEWLINK, IFLA_IFNAME: Interface 'wlan0' added
канал успешно поднят, авторизация пройдена.

Пара вопросов:
1) wlan0: BSS: Expire BSS 1 due to age
...
это происходит без каких-либо пауз?

2) wlan0: CTRL-EVENT-TERMINATING - signal 2 received
если причиной был ^C, то всё в порядке.

Выполните (без -d): # wpa_supplicant -c/etc/wpa_supplicant.conf -iwlan0
и после установления соединения в другом терминале (другой консоли) посмотрите
# iwconfig wlan0
если всё в порядке,
# ifconfig wlan0 192.168.1.35/24
# ping -c4 ip_шлюза

если всё в порядке, останавливаем запущенный выше wpa_supplicant, проверяем, как справляются с задачей скрипты:
# /etc/rc.d/rc.inet1 eth0_stop # на время эксперимента выключим проводной интерфейс
# /etc/rc.d/rc.inet1 wlan0_restart
# iwconfig wlan0; ifconfig wlan0; route
# ping -c ip_шлюза

если всё нормально, не забываем настроить резолвер, дописываем в /etc/resolv.conf сервера DNS (не более 4, по одному в строке nameserver), например,
nameserver 8.8.8.8

проверяем хождение пакетов наружу:
# ping ya.ru
# traceroute -n ya.ru
Спасибо сказали:
QWERTYASDF
Сообщения: 989
Статус: Чайник со свистком
ОС: GNU/Linux

Re: Не поднять wi-fi сеть

Сообщение QWERTYASDF »

bormant

Спасибо большое! Wi-Fi заработал, видимо все дело было в наличии второго (eth0) интерфейса. А также в моем роутере - он зависает при необходимости коннекта с разными интерфейсами моего ноута (естессно на них настроены разные ip)...И поэтому вопрос - а как отключить автозапуск eth0 так, чтобы при необходимости можно было его без лишних движений поднять командой вида ifconfig eth0 up? Лазить в /etc/rc.d/rc.inet1 как-то не охота, пока просто закомментила описание eth0 в /etc/rc.d/rc.inet1.conf.

1) wlan0: BSS: Expire BSS 1 due to age
...
это происходит без каких-либо пауз?


Ну, сейчас попробовала повторить - после строчки выше ("EAPOL: disable timer tick") большая пауза - пришлость жать ^С. Более никаких пауз примечательных не было.

wlan0: CTRL-EVENT-TERMINATING - signal 2 received
если причиной был ^C, то всё в порядке


Да, очевидно он и был.

iwconfig wlan0; ifconfig wlan0; route


Вроде все в порядке:

Spoiler
wlan0 IEEE 802.11bgn ESSID:"666"
Mode:Managed Frequency:2.437 GHz Access Point: 40:4A:03:63:F1:BC
Bit Rate=150 Mb/s Tx-Power=15 dBm
Retry long limit:7 RTS thr:off Fragment thr:off
Encryption key:off
Power Management:on
Link Quality=70/70 Signal level=-33 dBm
Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0
Tx excessive retries:1 Invalid misc:3 Missed beacon:0

wlan0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.1.35 netmask 255.255.255.0 broadcast 192.168.1.255
inet6 fe80::e2b9:a5ff:fe05:38b8 prefixlen 64 scopeid 0x20<link>
ether e0:b9:a5:05:38:b8 txqueuelen 1000 (Ethernet)
RX packets 126 bytes 9284 (9.0 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 34 bytes 3756 (3.6 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
default 192.168.1.1 0.0.0.0 UG 1 0 0 wlan0
loopback * 255.0.0.0 U 0 0 0 lo
localnet * 255.255.255.0 U 0 0 0 wlan0


Пинги все и через ip и через dns идут.
Спасибо сказали:
Аватара пользователя
bormant
Сообщения: 1354

Re: Не поднять wi-fi сеть

Сообщение bormant »

QWERTYASDF писал(а):
24.07.2013 16:47
И поэтому вопрос - а как отключить автозапуск eth0 так, чтобы при необходимости можно было его без лишних движений поднять командой вида ifconfig eth0 up?

А если в /etc/rc.d/rc.local прописать:
/etc/rc.d/rc.inet1 eth0_stop
или даже
ifconfig eth0 down
? То есть, rc.inet1 отработает в части выставления настроек, поднимет интерфейс, а потом его rc.local опустит.

Другой вариант: убрать настройки eth0 из rc.inet1.conf, в rc.local по старинке вписать что-то вроде:
ifconfig eth0 192.168.1.35/24 down

Ещё вариант: настроить оба интерфейса, но активному интерфейсу дать приоритетную метрику и указать через него маршрут по умолчанию.

Ещё вариант: написать сценарий, который поднимает один интерфейс и опускает второй, и дёргать его при необходимости.

Ещё вариант: поставить wicd и управлять сетью через него. Он умеет поддерживать проводные соединения, имеет консольный, curses и графический клиенты.

А про вариант объединения wlan0 и eth0 в мост (с версии 14 настройка моста поддерживается в rc.inet1.conf), пока ничего сказать не готов, это надо пробовать и смотреть, стоит ли овчинка выделки.
Спасибо сказали:
QWERTYASDF
Сообщения: 989
Статус: Чайник со свистком
ОС: GNU/Linux

Re: Не поднять wi-fi сеть

Сообщение QWERTYASDF »

bormant писал(а):
24.07.2013 20:11
Ещё вариант: написать сценарий, который поднимает один интерфейс и опускает второй, и дёргать его при необходимости.

Написала сценарии, но есть проблема. Сценарии:

Переключение с wlan0 на eth0:
Spoiler
#!/bin/bash

#Отключаем wlan0
ifconfig wlan0 down

#Задержка 10 секунд
sleep 10

#Поднимаем eth0
ifconfig eth0 192.168.1.35/24 up

#Задержка 5 секунды

sleep 5

#Определяем шлюз
route add default gw 192.168.1.1


Переключение с eth0 на wlan0:
Spoiler
#!/bin/bash

#Отключаем eth0
ifconfig eth0 down

#Задержка 10 секунд
sleep 10

#Поднимаем wlan0
ifconfig wlan0 up

#Задержка 5 секунды
sleep 5

#Определяем шлюз
route add default gw 192.168.1.1


Изначально была версия без задержек. Но с ними и без них проблема одна - выполнение полного переключения зависит от солнечного ветра. Т.е. выводы ifconfig, route показывают порядок - ненужный интерфейс отключен, нужный подключен, в таблице маршрутизации имеются маршрут в локалхост и дефолтный маршрут через нужный интерфейс, и кроме петли более маршрутов нет. Но до шлюза и в интернет пинги не идут. При этом после переключения через скрипт всегда есть пинги до 2-го компа в локалхосте.

Конечно грешу на роутер т.к. после его перезагрузки сразу появляется пинг до шлюза/в интернет, но вдруг чего-то и в скриптах нужно подправить? Чего я не понимаю?...
Спасибо сказали:
Ответить