]> git.ipfire.org Git - thirdparty/hostap.git/log
thirdparty/hostap.git
12 years agoMove ctrl_iface deinit into the end of interface deinit
Dmitry Shmidt [Sun, 29 Jan 2012 18:21:07 +0000 (20:21 +0200)] 
Move ctrl_iface deinit into the end of interface deinit

This allows TERMINATING ctrl_iface event to be sent at the end of the
deinit sequence to avoid race conditions with new operations that this
event may trigger while wpa_supplicant would still be running through
the deinitialization path.

Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
12 years agoDeinit driver before notifying interface has been removed
Dmitry Shmidt [Sun, 29 Jan 2012 18:18:48 +0000 (20:18 +0200)] 
Deinit driver before notifying interface has been removed

This avoids issues with some external program starting to use the
interface based on the interface removal event before wpa_supplicant
has completed deinitialization of the driver interface.

Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
12 years agoLet wpa_supplicant_deinit_iface() know that process is terminating
Dmitry Shmidt [Sun, 29 Jan 2012 18:15:48 +0000 (20:15 +0200)] 
Let wpa_supplicant_deinit_iface() know that process is terminating

This will be needed to be able to move ctrl_iface TERMINATING event to
the end of interface removal.

Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
12 years agonl80211: Sync with linux/nl80211.h in wireless-testing.git
Jouni Malinen [Sun, 29 Jan 2012 17:53:34 +0000 (19:53 +0200)] 
nl80211: Sync with linux/nl80211.h in wireless-testing.git

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agowpa_auth: Fix race in rejecting 4-way handshake for entropy
Nicolas Cavallari [Sun, 29 Jan 2012 16:11:43 +0000 (18:11 +0200)] 
wpa_auth: Fix race in rejecting 4-way handshake for entropy

When there is not enough entropy and there are two station associating
at the same time, one of the stations will be rejected, but during
that rejection, the "reject_4way_hs_for_entropy" flag gets cleared. This
may allow the second station to avoid rejection and complete a 4-Way
Handshake with a GTK that will be cleared as soon as more entropy is
available and another station connects.

This reworks the logic to ban all 4-way handshakes until enough entropy
is available.

Signed-hostap: Nicolas Cavallari <cavallar@lri.fr>

12 years agoSME: Fix processing of Authentication timeout and failure
Eyal Shapira [Sun, 29 Jan 2012 15:44:31 +0000 (17:44 +0200)] 
SME: Fix processing of Authentication timeout and failure

current_bss and pending_bssid weren't cleaned up so BSS
kept appearing in the scan results even when it was actually gone.
Use wpa_supplicant_mark_disassoc() to cleanup the wpa_s context
instead of just dropping wpa_state back to DISCONNECTED.

Reported-by: Vishal Mahaveer <vishalm@ti.com>
Signed-hostap: Eyal Shapira <eyal@wizery.com>

12 years agoInterleave wildcard and specific SSID scans when max_ssids=1
Eyal Shapira [Sun, 29 Jan 2012 15:39:08 +0000 (17:39 +0200)] 
Interleave wildcard and specific SSID scans when max_ssids=1

For drivers limited to scan a single SSID at a time, this prevents
waiting too long for a wildcard scan in case there are several
scan_ssid networks in the configuration.

Signed-hostap: Eyal Shapira <eyal@wizery.com>

12 years agoInstall only the binaries into BINDIR
Jouni Malinen [Sun, 29 Jan 2012 12:20:41 +0000 (14:20 +0200)] 
Install only the binaries into BINDIR

There is no point in installing *.service files into BINDIR.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agobuild: Fix install target parent directory prerequisites
Grant Erickson [Sun, 29 Jan 2012 12:18:22 +0000 (14:18 +0200)] 
build: Fix install target parent directory prerequisites

This changes the install target such that parent directories of
installed paths area created and each path is only installed
on a dependency basis.

Signed-off-by: Grant Erickson <marathon96@gmail.com>
12 years agodbus: Remove unused D-Bus version defines
Jouni Malinen [Sun, 29 Jan 2012 10:53:12 +0000 (12:53 +0200)] 
dbus: Remove unused D-Bus version defines

These have not been used since commit
8ddef94bd41747ba658ed4ed5dfa9e62b4b84cfa.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agonl80211: Subscribe management frames for WPA_IF_AP_BSS types
Yogesh Ashok Powar [Sun, 29 Jan 2012 10:33:05 +0000 (12:33 +0200)] 
nl80211: Subscribe management frames for WPA_IF_AP_BSS types

In multiple BSSes scenario for the drivers that do not use
monitor interface and do not implement AP SME, RX MGMT
frame subscription happens only for the default bss (first_bss).

Subscribe for RX MGMT frames for such BSSes.

Signed-off-by: Yogesh Ashok Powar <yogeshp@marvell.com>
12 years agonl80211: Derive frequency for BSSes other than the first
Yogesh Ashok Powar [Sun, 29 Jan 2012 10:28:35 +0000 (12:28 +0200)] 
nl80211: Derive frequency for BSSes other than the first

Commit e4fb21676972952b5434e8c2a049e239d457abe6 moved frequency
storage from driver struct to bss struct and is assigned in
wpa_driver_nl80211_set_freq. As this wpa_driver_nl80211_set_freq is
triggered only on the first_bss, bss->freq for other BSSes is never
being set to the correct value. This sends MLME frames on frequency zero
(initialized value of freq) for BSSes other than the first.

To fix this derive frequency value from first_bss.

Signed-off-by: Yogesh Ashok Powar <yogeshp@marvell.com>
12 years agoIBSS RSN: Provide ibss_rsn_get_peer() helper function
Antonio Quartulli [Sun, 29 Jan 2012 10:23:27 +0000 (12:23 +0200)] 
IBSS RSN: Provide ibss_rsn_get_peer() helper function

This is a useful function that simplifies some code and can eventually
be used somewhere else in future.

Signed-hostap: Antonio Quartulli <ordex@autistici.org>

12 years agowpa_debug: Support outputting hexdumps into syslog
Nicolas Cavallari [Sun, 29 Jan 2012 10:13:43 +0000 (12:13 +0200)] 
wpa_debug: Support outputting hexdumps into syslog

This patch allows to log hexdumps into syslog.

This is useful when testing, as syslog's network logging
helps to collect debug outputs from several machines.

Signed-hostapd: Nicolas Cavallari <cavallar@lri.fr>

12 years agoEAP-AKA peer: Append realm when learning the pseudonym
Simon Baatz [Sat, 28 Jan 2012 17:41:19 +0000 (19:41 +0200)] 
EAP-AKA peer: Append realm when learning the pseudonym

The pseudonym identity should use a realm in environments where a realm is
used. Thus, the realm of the permanent identity is added to the pseudonym
username sent by the server.

Signed-hostap: Simon Baatz <gmbnomis@gmail.com>

12 years agoEAP-SIM peer: Append realm when learning the pseudonym
Simon Baatz [Sat, 28 Jan 2012 17:38:46 +0000 (19:38 +0200)] 
EAP-SIM peer: Append realm when learning the pseudonym

The pseudonym identity should use a realm in environments where a realm is
used. Thus, the realm of the permanent identity is added to the pseudonym
username sent by the server.

Signed-hostap: Simon Baatz <gmbnomis@gmail.com>

12 years agodbus: Fix endianness bug in Frequency and Signal properties
Sylvestre Gallon [Sat, 28 Jan 2012 15:57:48 +0000 (17:57 +0200)] 
dbus: Fix endianness bug in Frequency and Signal properties

These properties did not work on big endian PowerPC (always 100% for
Signal and 0 for Frequency) due to endianness problem (u32 to u16 data
loss).

Signed-off-by: Sylvestre Gallon <ccna.syl@gmail.com>
12 years agoRename systemd template files to avoid @ in the file name
Jouni Malinen [Sat, 28 Jan 2012 15:12:30 +0000 (17:12 +0200)] 
Rename systemd template files to avoid @ in the file name

Perforce does not like @ in the file name and since these template files
do not really need to have that in the name, make the files in
repository friendlier to Perforce. The generated *.service file will
maintain their old names.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agonl80211: Add IBSS BSSID fixing support
Nicolas Cavallari [Sat, 28 Jan 2012 09:35:32 +0000 (11:35 +0200)] 
nl80211: Add IBSS BSSID fixing support

If a BSSID and fixed-bssid are requested, fix the BSSID, so
the driver does not attempt to merge.

Signed-hostap: Nicolas Cavallari <cavallar@lri.fr>

12 years agoSupport fixing the BSSID in IBSS mode
Nicolas Cavallari [Sat, 28 Jan 2012 09:33:47 +0000 (11:33 +0200)] 
Support fixing the BSSID in IBSS mode

When the "bssid=" option is set for an IBSS network and ap_scan = 2,
ask the driver to fix this BSSID, if possible.

Previously, any "bssid=" option were ignored in IBSS mode when ap_scan=2.

Signed-hostap: Nicolas Cavallari <cavallar@lri.fr>

12 years agodbus: Create DBus getter/setter for FastReauth
Paul Stewart [Sat, 28 Jan 2012 09:21:37 +0000 (11:21 +0200)] 
dbus: Create DBus getter/setter for FastReauth

Provide a means over DBus to set the conf->fast_reauth
property, which controls whether TLS session resumption
should be attempted for EAP-TLS 802.1X networks.

Signed-off-by: Paul Stewart <pstew@chromium.org>
12 years agoWPS: Fix an interoperability issue with mixed mode and AP Settings
Jouni Malinen [Fri, 27 Jan 2012 20:32:15 +0000 (22:32 +0200)] 
WPS: Fix an interoperability issue with mixed mode and AP Settings

It looks like Windows 7 WPS implementation does not like multiple
Authentication/Encryption Type bits to be set in M7 AP Settings
attributes, i.e., it refused to add a network profile if the AP
was configured for WPA/WPA2 mixed mode and AP PIN was used to
enroll the network.

Leave only a single bit set in the Authentication/Encryption Type
attributes in M7 when the AP is acting as an Enrollee to avoid this
issue.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

12 years agoP2P: Fix WSC IE inclusion for P2P disabled case
Jouni Malinen [Fri, 27 Jan 2012 19:09:34 +0000 (21:09 +0200)] 
P2P: Fix WSC IE inclusion for P2P disabled case

wpas_wps_in_use() was forcing WPS to be enabled unconditionally if P2P
support was included in the build. This is not really the correct
behavior for the case when P2P has been disabled at runtime. Change the
code here to verify runtime configuration of P2P before forcing WPS to
be enabled. This allows WSC IE to be left out from Probe Request frames
when scanning for APs without P2P or WPS being in use.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

12 years agonl80211: Fix send_action on off-channel in P2P GO role
Jouni Malinen [Thu, 26 Jan 2012 15:44:11 +0000 (17:44 +0200)] 
nl80211: Fix send_action on off-channel in P2P GO role

A P2P Action frame may need to be sent on another channel than the GO's
operating channel. This information was lost in
wpa_driver_nl80211_send_action() in the case the interface was in AP
mode. Pass the frequence and related parameters to send_mlme mechanism
to allow the correct frequence to be used with the send frame command in
AP (P2P GO) mode.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

12 years agoFix ap_sta_disconnect() to clear EAPOL/WPA authenticator state
Jouni Malinen [Wed, 25 Jan 2012 20:32:58 +0000 (22:32 +0200)] 
Fix ap_sta_disconnect() to clear EAPOL/WPA authenticator state

Number of places in hostapd use ap_sta_disconnect() instead of
ap_sta_disassociate() or ap_sta_deauthenticate(). There are some
differences between these functions, e.g., in the area how quickly
the EAPOL state machines get deinitialized. This can result in
somewhat unexpected events since the EAPOL/WPA authenticator
state machines could remain running after deauthentication.

Address this by forcing EAPOL/WPA authenticator state machines
to disabled state whenever ap_sta_disconnect() is called instead
of waiting for the deauthentication callback or other timeout
to clear the STA.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

12 years agopcsc: Fix compiler warning on signed vs. unsigned comparison
Jouni Malinen [Wed, 25 Jan 2012 15:41:59 +0000 (17:41 +0200)] 
pcsc: Fix compiler warning on signed vs. unsigned comparison

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoP2P: Do not expire peer entry if we are connected to the peer
Jouni Malinen [Wed, 25 Jan 2012 15:27:47 +0000 (17:27 +0200)] 
P2P: Do not expire peer entry if we are connected to the peer

Even though we may not update P2P peer entry while connected to the
peer as a P2P client, we should not be expiring a P2P peer entry while
that peer is the GO in a group where we are connected as a P2P client.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

12 years agoP2P: Do not expire peer entry if peer is connected as a client
Jouni Malinen [Wed, 25 Jan 2012 15:00:59 +0000 (17:00 +0200)] 
P2P: Do not expire peer entry if peer is connected as a client

Even though we may not receive a Probe Response from the peer during
the connection, we should not be expiring a P2P peer entry while that
peer is connected to a group where we are the GO.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

12 years agonl80211: P2P: Pass cookie parameter in send action frame
Deepthi Gowri [Mon, 23 Jan 2012 18:12:06 +0000 (20:12 +0200)] 
nl80211: P2P: Pass cookie parameter in send action frame

The cookie value needs to be fetched in GO mode, too, to be able to
indicate TX status callbacks with drivers that handle AP mode SME
functionality internally. This fixes issues with client discoverability
where TX status callback for GO Discoverability Request is needed to
trigger the GO to send Device Discoverability Response.

12 years agoStop sched_scan in number of cases where it should not be running
Jouni Malinen [Mon, 23 Jan 2012 16:26:09 +0000 (18:26 +0200)] 
Stop sched_scan in number of cases where it should not be running

When a P2P group is removed, we better not leave possibly started
sched_scan running. This could happen when a separate group interface
was not used.

In addition, it looks safer to explicitly stop sched_scan before
starting P2P Listen or Find operations to make sure the offloaded
scanning is not running when doing similar P2P operations.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

12 years agoUpdate WPA/RSN IE properly for driver based BSS selection
Sujith Manoharan [Mon, 23 Jan 2012 15:34:39 +0000 (17:34 +0200)] 
Update WPA/RSN IE properly for driver based BSS selection

This patch fixes an issue with roaming for drivers that set
WPA_DRIVER_FLAGS_BSS_SELECTION (currently ath6kl). On moving to an AP
with a different BSSID, an EVENT_ASSOC is received and the subsequent
4-way handshake may fail because of a mismatch between the RSN IE in
message 3/4 and in Beacon/Probe Response. This happens only when the APs
use different RSN IE contents and ap_scan is set to 1, since
wpa_supplicant fails to update its cached IEs.

Initial association may fail, too, in case of multiple APs with
the same SSID, since BSSID selection is done by the driver and again
a mismatch could be seen.

Fix these two issues by clearing and updating the cached IEs on
receiving an Association event from the driver. Also, retrieve the
scan results when the new BSS information is not present locally.

Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
12 years agoAdd preliminary MNC length determination based on IMSI
Jouni Malinen [Sun, 22 Jan 2012 19:33:57 +0000 (21:33 +0200)] 
Add preliminary MNC length determination based on IMSI

Some SIM cards do not include MNC length with in EF_AD. Try to figure
out the MNC length based on the MCC/MNC values in the beginning of the
IMSI. This covers a prepaid Elisa/Kolumbus card that would have ended
up using incorrect MNC length based on the 3-digit default.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoAvoid unnecessary memory allocation in building of SIM realm
Jouni Malinen [Sun, 22 Jan 2012 19:29:35 +0000 (21:29 +0200)] 
Avoid unnecessary memory allocation in building of SIM realm

The temporary IMSI buffer can be used for this without needing the
extra memory allocation. In addition, the implementation is easier
to understand when the extra identity prefix value for EAP-SIM/AKA
is not included while fetching MCC/MNC from the IMSI.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoEAP-SIM/EAP-AKA peer: Support realms according to 3GPP TS 23.003
Simon Baatz [Sun, 22 Jan 2012 19:11:24 +0000 (21:11 +0200)] 
EAP-SIM/EAP-AKA peer: Support realms according to 3GPP TS 23.003

If the identity is derived from the SIM, use a realm according
to 3GPP TS 23.003.

Signed-hostap: Simon Baatz <gmbnomis@gmail.com>

12 years agoReject too short IMSI in EAP-SIM/AKA identity generation
Jouni Malinen [Sun, 22 Jan 2012 19:12:51 +0000 (21:12 +0200)] 
Reject too short IMSI in EAP-SIM/AKA identity generation

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoeapol_test: Show MNC length in debug output
Jouni Malinen [Sun, 22 Jan 2012 18:59:00 +0000 (20:59 +0200)] 
eapol_test: Show MNC length in debug output

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoSIM/USIM: Add function to get the MNC length from the SIM/USIM
Simon Baatz [Sun, 22 Jan 2012 17:28:24 +0000 (19:28 +0200)] 
SIM/USIM: Add function to get the MNC length from the SIM/USIM

The EF-AD (administrative data) file may contain information about the
length of the MNC (2 or 3 digits) in the IMSI. This can be used to
construct the realm according to 3GPP TS 23.003 during EAP-SIM or
EAP-AKA authentication.

Signed-hostap: Simon Baatz <gmbnomis@gmail.com>

12 years agoP2P: Notify upper framework on stopping the p2p_find(SEARCH)
Jithu Jance [Sun, 22 Jan 2012 15:20:53 +0000 (17:20 +0200)] 
P2P: Notify upper framework on stopping the p2p_find(SEARCH)

This patch notifies the upper framework that an on-going discovery has
been stopped. This is useful in cases where a p2p_find with a timeout
value initiated by the upper framework has been finished or when the
framework initiated "p2p_find" is stopped by a "p2p_connect".

Signed-hostap: Jithu Jance <jithu@broadcom.com>

12 years agoWork around interop issue with WPA type EAPOL-Key 4/4 in WPA2 mode
Jouni Malinen [Sun, 22 Jan 2012 10:23:28 +0000 (12:23 +0200)] 
Work around interop issue with WPA type EAPOL-Key 4/4 in WPA2 mode

Some deployed station implementations seem to send msg 4/4 with
incorrect type value in WPA2 mode. Add a workaround to ignore that issue
so that such stations can interoperate with hostapd authenticator. The
validation checks were added in commit
f8e96eb6fd960a017793942cff0eb43b09f444c6.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agodbus: Validate SSID length in new D-Bus scan request
Sam Leffler [Sun, 22 Jan 2012 10:00:44 +0000 (12:00 +0200)] 
dbus: Validate SSID length in new D-Bus scan request

Validate the length of each SSID passed in a new D-Bus protocol
Scan request.

12 years agoP2P: Use Device ID attribute to filter Probe Request frames as GO
Jouni Malinen [Sun, 8 Jan 2012 17:35:33 +0000 (09:35 -0800)] 
P2P: Use Device ID attribute to filter Probe Request frames as GO

The Device ID attribute was already used in Listen state, but it was
ignored in GO role. Verify that there is a match with Device ID in
GO rule, too, before replying to the Probe Request frame.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoP2P: Allow Device ID to be specified for p2p_find command
Jouni Malinen [Sun, 8 Jan 2012 17:25:29 +0000 (09:25 -0800)] 
P2P: Allow Device ID to be specified for p2p_find command

dev_id=<P2P Device Addr> can now be specified as an argument to
p2p_find to request P2P find for a specific P2P device.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoAllow SNonce update after sending EAPOL-Key 3/4 if 1/4 was retransmitted
Jouni Malinen [Mon, 2 Jan 2012 20:36:11 +0000 (22:36 +0200)] 
Allow SNonce update after sending EAPOL-Key 3/4 if 1/4 was retransmitted

Some supplicant implementations (e.g., Windows XP WZC) update SNonce for
each EAPOL-Key 2/4. This breaks the workaround on accepting any of the
pending requests, so allow the SNonce to be updated even if we have
already sent out EAPOL-Key 3/4.

While the issue was made less likely to occur when the retransmit
timeout for the initial EAPOL-Key msg 1/4 was increased to 1000 ms,
this fixes the problem even if that timeout is not long enough.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

12 years agoDo not disconnect STA based on inactivity on driver failure
Jouni Malinen [Mon, 2 Jan 2012 19:27:06 +0000 (21:27 +0200)] 
Do not disconnect STA based on inactivity on driver failure

Now that we can use driver_nl80211.c with non-mac80211 drivers that
implement SME/MLME internally, we may not get inactivity time from the
driver. If that is the case, we need to skip disconnection based on
maximum inactivity timeout. This fixes some unexpected disconnection
cases with ath6kl in AP mode.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

12 years agoRemove test-https on "make clean"
Jouni Malinen [Sun, 1 Jan 2012 17:09:18 +0000 (19:09 +0200)] 
Remove test-https on "make clean"

This is not included in the TESTS list, but should be removed anyway.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoUpdate copyright notices to include year 2012
Jouni Malinen [Sun, 1 Jan 2012 16:59:16 +0000 (18:59 +0200)] 
Update copyright notices to include year 2012

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoDo not trigger fast reconnection on locally generated deauth/disassoc
Jouni Malinen [Sun, 1 Jan 2012 16:53:12 +0000 (18:53 +0200)] 
Do not trigger fast reconnection on locally generated deauth/disassoc

The deauthentication and disassociation events from nl80211 were being
processed identically regardless of whether the frame was generated by
the local STA or the AP. This resulted in fast reconnection mechanism
getting triggered even in the case where the disconnection was detected
locally (e.g., due to beacon loss) while this was supposed to happen
only in the case where the AP is sending an explicit Deauthentication
or Disassociation frame with a specific reason code.

Fix this by adding a new deauth/disassoc event variable to indicate
whether the event was generated locally.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoFix BSS property names in the example D-Bus script
Jouni Malinen [Sun, 1 Jan 2012 16:50:31 +0000 (18:50 +0200)] 
Fix BSS property names in the example D-Bus script

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agodbus: Fix extra semicolon
Syam Sidhardhan [Sun, 1 Jan 2012 12:39:24 +0000 (14:39 +0200)] 
dbus: Fix extra semicolon

Signed-off-by: Syam Sidhardhan <syamsidhardh@gmail.com>
12 years agodbus: Increase buffer size to fix Introspect XML
Jouni Malinen [Sat, 31 Dec 2011 15:40:49 +0000 (17:40 +0200)] 
dbus: Increase buffer size to fix Introspect XML

Commit e9c3c1afedd2d0c6a0939f40c40701af8c450e1f added a new D-Bus
method and that was enough to push the Introspect XML buffer over
the previously allocated 8000 bytes. Increase the buffer size to
make enough room for P2P interface. In addition, add a debug
message to indicate if an XML segment does not fit into the buffer
to make this types of failures somewhat easier to catch.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoClear EAPOL authWhile and heldWhile values when port is disabled
Jouni Malinen [Sat, 31 Dec 2011 11:42:23 +0000 (13:42 +0200)] 
Clear EAPOL authWhile and heldWhile values when port is disabled

IEEE Std 802.1X-2004 does not clear authWhile and heldWhile in this
case, but doing so allows the timer tick to be stopped more quickly when
the port is not enabled. Since these variables are used only within HELD
and RECEIVE states, clearing them on initialization does not change
actual state machine behavior. This reduces some unnecessary operations
in port disabled state and cleans up the wpa_supplicant debug log after
disconnection.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoRemove possible authentication timeout on connection failure
Jouni Malinen [Sat, 31 Dec 2011 11:25:37 +0000 (13:25 +0200)] 
Remove possible authentication timeout on connection failure

The authentication timeout could be triggered after the connection has
already been known to have failed. The event at that point can be
confusing, so better cancel the timeout when processing connection
failure.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoWPS: Use single channel scan if AP channel already known
Jouni Malinen [Sat, 31 Dec 2011 11:17:20 +0000 (13:17 +0200)] 
WPS: Use single channel scan if AP channel already known

If the BSSID of the AP is specified in the WPS command, the target
AP is likely already in the BSS table and its operating channel is
known. Use this information to speed up connection by only scanning
the known channel.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agonl80211: Mark Beacon event debug excessive
Jouni Malinen [Fri, 30 Dec 2011 12:10:15 +0000 (14:10 +0200)] 
nl80211: Mark Beacon event debug excessive

This can show up way too frequently in AP mode to make debug logs
readable at debug level.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoUse correct (multi-user) target when installing systemd units
Michał Górny [Thu, 29 Dec 2011 19:39:34 +0000 (21:39 +0200)] 
Use correct (multi-user) target when installing systemd units

The 'network.target' is special (per systemd.special(7)), and is to be
brought up indirectly when network is actually configured (i.e. through
DHCP or static address settings).

Irrelevant of that, all services should be always installed in
multi-user.target.

[Bug 427]

12 years agoWPS: Cancel previous registered wps_registrar_pbc_timeout
Spencer Chang [Thu, 29 Dec 2011 19:32:06 +0000 (21:32 +0200)] 
WPS: Cancel previous registered wps_registrar_pbc_timeout

Since wps_registrar_pbc_timeout is called to stop PBC, previously
registered wps_registrar_pbc_timeout must be canceled when canceling
the WPS operation.

Signed-off-by: Spencer Chang <jungwalk@gmail.com>
12 years agonl80211: Fix NL80211_CMD_FRAME to not try offchannel without driver support
Jouni Malinen [Thu, 29 Dec 2011 12:15:31 +0000 (14:15 +0200)] 
nl80211: Fix NL80211_CMD_FRAME to not try offchannel without driver support

The offchanok parameter is hardcoded to one in number of paths and that
added NL80211_ATTR_OFFCHANNEL_TX_OK attribute to NL80211_CMD_FRAME
unconditional. cfg80211 rejects this with EINVAL if the driver does not
indicate support for offchannel TX. Fix this by not requesting
offchannel TX depending on driver capabilities. Remain-on-channel
operation was used for those cases anyway, so the additional attribute
was not really needed for these in the first place.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

12 years agoP2P: Stop remain-on-channel prior to starting join-a-group client
Jouni Malinen [Thu, 29 Dec 2011 11:28:17 +0000 (13:28 +0200)] 
P2P: Stop remain-on-channel prior to starting join-a-group client

This fixes issues with drivers that do not handle concurrent
remain-on-channel and scan operations in a case where Provision
Discovery Response frame is not received to stop the Action frame
handshake.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

12 years agoP2P: Reject p2p_group_add if forced frequency is not acceptable
Neeraj Kumar Garg [Tue, 27 Dec 2011 21:21:45 +0000 (23:21 +0200)] 
P2P: Reject p2p_group_add if forced frequency is not acceptable

If the freq parameter is specified and we are already running legacy STA
on a different frequency with a driver that does not support
multi-channel concurrency, reject p2p_group_add. Same code already
exists in the path of P2P connection with go negotiation but is missing
for autonomous GO.

Signed-hostap: Neeraj Garg <neerajkg@broadcom.com>

12 years agonl80211: Do not stop AP mode Probe Request reporting on Listen stop
Jouni Malinen [Tue, 27 Dec 2011 18:32:29 +0000 (20:32 +0200)] 
nl80211: Do not stop AP mode Probe Request reporting on Listen stop

When nl80211_setup_ap() has enabled Probe Request reporting, this must
not be disabled when P2P Listen state is stopped to avoid breaking AP
mode operations. This could happen, e.g., if a Probe Request frame was
received from a P2P device that the we are trying to invite to our group
(i.e., when operating in GO role). p2p_probe_req_rx() calls
p2p_invite_start() in this case and that ends up calling
p2p->cfg->stop_listen() which calls probe_req_report() driver op.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

12 years agoP2P: Use global->p2p_dev_addr instead of parent->own_addr
Jouni Malinen [Sun, 25 Dec 2011 21:58:03 +0000 (23:58 +0200)] 
P2P: Use global->p2p_dev_addr instead of parent->own_addr

Start using global->p2p_dev_addr more consistently as the P2P Device
Address.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoAdd BSSID into blacklist and do not clean blacklist during countermeasures
Bartosz Markowski [Sun, 25 Dec 2011 19:09:17 +0000 (21:09 +0200)] 
Add BSSID into blacklist and do not clean blacklist during countermeasures

If scanning continues during TKIP countermeasures, try to avoid selecting
the BSS that triggered the counter measures.

12 years agohostapd: Make inactivity polling configurable
Yogesh Ashok Powar [Sun, 25 Dec 2011 18:57:01 +0000 (20:57 +0200)] 
hostapd: Make inactivity polling configurable

hostapd uses the poll method to check if the station is alive
after the station has been inactive for ap_max_inactivity seconds.
Make the poll mechanism configurable so that user can choose to
disconnect idle clients.

This can be especially useful when some devices/firmwares have
restrictions on the number of clients that can connect to the AP
and that limit is smaller than the total number of stations trying
to use the AP.

Signed-off-by: Yogesh Ashok Powar <yogeshp@marvell.com>
Signed-off-by: Nishant Sarmukadam <nishants@marvell.com>
12 years agoRemove obsolete comment on removed PTK rekeying operation
Jouni Malinen [Sat, 24 Dec 2011 11:55:03 +0000 (13:55 +0200)] 
Remove obsolete comment on removed PTK rekeying operation

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoIncrease initial group key handshake retransmit timeout to 500 ms
Jouni Malinen [Sat, 24 Dec 2011 11:50:59 +0000 (13:50 +0200)] 
Increase initial group key handshake retransmit timeout to 500 ms

The 100 ms timeout on retransmitting group key message can be too short
for stations that are in power save mode or if there is a large number
of association stations. While the retransmission of the EAPOL-Key frame
should allow this to be recovered from, it is useful to avoid
unnecessary frames to save soem CPU and power.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoDrop priority level of the logger message for unexpected replay counter
Jouni Malinen [Sat, 24 Dec 2011 11:39:40 +0000 (13:39 +0200)] 
Drop priority level of the logger message for unexpected replay counter

This can happen frequently during normal EAPOL-Key exchanges and there
is no need to log it at info level.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agonl80211: Fix mgmt RX for device SME in AP mode without monitor
Jouni Malinen [Fri, 23 Dec 2011 16:15:07 +0000 (18:15 +0200)] 
nl80211: Fix mgmt RX for device SME in AP mode without monitor

Drivers that use device SME in AP mode may still need to be
subscribed for Action frame RX when monitor interface is not used.
This fixes number of P2P GO operations with ath6kl.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

12 years agonl80211: Fix use_monitor driver capability for non-mac80211 drivers
Jouni Malinen [Fri, 23 Dec 2011 16:13:01 +0000 (18:13 +0200)] 
nl80211: Fix use_monitor driver capability for non-mac80211 drivers

Poll command may be enough for mac80211 to figure out whether monitor
interface is to be used, but this change did not take into account
non-mac80211 drivers that support AP mode without monitor interface.
For example, ath6kl needs to get use_monitor disabled.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

12 years agonl80211: Show station flush failures in debug log
Jouni Malinen [Fri, 23 Dec 2011 16:12:07 +0000 (18:12 +0200)] 
nl80211: Show station flush failures in debug log

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

12 years agonl80211: Add debug prints for mgmt RX subscription
Jouni Malinen [Fri, 23 Dec 2011 16:10:59 +0000 (18:10 +0200)] 
nl80211: Add debug prints for mgmt RX subscription

This makes it easier to figure out which management frames has been
subscribed to for RX events.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

12 years agoP2P: Maintain a list of P2P Clients for persistent group on GO
Jouni Malinen [Thu, 22 Dec 2011 20:47:41 +0000 (22:47 +0200)] 
P2P: Maintain a list of P2P Clients for persistent group on GO

Add a new persistent group network block field, p2p_client_list, to
maintain a list of P2P Clients that have connected to a persistent
group. This allows GO of a persistent group to figure out more easily
whether re-invocation of a persistent group can be used with a specific
peer device.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoP2P: Show persistent group info on P2P_PEER data
Jouni Malinen [Thu, 22 Dec 2011 19:45:20 +0000 (21:45 +0200)] 
P2P: Show persistent group info on P2P_PEER data

Add "persistent=<network id>" line to P2P_PEER ctrl_iface data
if a persistent group credentials are available for this peer.
This makes it easier for external programs to figure out when
a persistent group could be re-invoked with this peer.

For now, this information is only available on the P2P client,
but similar information can be added for GO once a list of P2P
clients is maintained with the persistent group data.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoP2P: Move public P2P_PEER info generation into ctrl_iface
Jouni Malinen [Thu, 22 Dec 2011 19:26:31 +0000 (21:26 +0200)] 
P2P: Move public P2P_PEER info generation into ctrl_iface

The P2P module provides access to public peer data in struct
p2p_peer_info. Use this to build the P2P_PEER information in
ctrl_iface.c instead of providing such text format data from the P2P
module.

The internal data that was previously built in p2p_get_peer_info() as
part of the text format peer data is now available through a separate
p2p_get_peer_info_txt() function. This is still included in P2P_PEER
output to maintain backwards compatibility with external programs that
could have started to use this. However, it should be noted that this
data is not really supposed to be used for anything else apart from
debugging purposes and its format is subject to change.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoP2P: Replace p2p_get_peer_info with p2p_peer_known when applicable
Jouni Malinen [Thu, 22 Dec 2011 19:04:41 +0000 (21:04 +0200)] 
P2P: Replace p2p_get_peer_info with p2p_peer_known when applicable

p2p_get_peer_info() was used in multiple places just to check whether a
specific peer is known. This was not the designed use for the function,
so introduce a simpler function for that purpose to make it obvious that
the p2p_get_peer_info() function is actually used only in ctrl_iface.c.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoP2P: Fix a typo in a function documentation
Jouni Malinen [Thu, 22 Dec 2011 18:55:51 +0000 (20:55 +0200)] 
P2P: Fix a typo in a function documentation

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agowlantest: Store last received GTK for each STA
Jouni Malinen [Thu, 22 Dec 2011 14:59:25 +0000 (16:59 +0200)] 
wlantest: Store last received GTK for each STA

This allows info_sta command to be used to fetch the last received GTK
separately for each STA.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agowlantest: Fix EAPOL-Key Key Data decryption for rekey case
Jouni Malinen [Thu, 22 Dec 2011 14:39:17 +0000 (16:39 +0200)] 
wlantest: Fix EAPOL-Key Key Data decryption for rekey case

KEK from TPTK needs to be used instead of from PTK when processing
rekeying case similarly to what was already done with KCK.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoP2P: Send D-Bus ServiceDiscoveryRequest signal for external SD processing
윤민홍 [Wed, 21 Dec 2011 22:34:29 +0000 (00:34 +0200)] 
P2P: Send D-Bus ServiceDiscoveryRequest signal for external SD processing

wpas_notify_p2p_sd_request() needs to be called when
p2p_sd_over_ctrl_iface is set to provide SD events over D-Bus similarly
to the ctrl_iface events.

12 years agoProcess EVENT_SCHED_SCAN_STOPPED partially if interface is disabled
Jouni Malinen [Wed, 21 Dec 2011 11:36:58 +0000 (13:36 +0200)] 
Process EVENT_SCHED_SCAN_STOPPED partially if interface is disabled

The internal sched_scanning state needs to be cleared on this event
even if the events happen to get ordered in a way that the interface
gets disabled just prior to EVENT_SCHED_SCAN_STOPPED event.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

12 years agoIgnore disassociation event in wpa_supplicant AP mode
Jouni Malinen [Wed, 21 Dec 2011 11:36:13 +0000 (13:36 +0200)] 
Ignore disassociation event in wpa_supplicant AP mode

If the driver was associated in station mode just before the AP mode was
started, the station mode disassociation event may end up getting
delivered to wpa_supplicant only after the AP mode has been started.
This can result in unexpected attempt to reassociate back to the network
that was previously used in station mode. Avoid this by ignoring the
disassociation event.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

12 years agoP2P: Do not allow pending listen command override connect
Jouni Malinen [Wed, 21 Dec 2011 11:35:18 +0000 (13:35 +0200)] 
P2P: Do not allow pending listen command override connect

If p2p_listen is issued during a p2p_scan, a pending after-scan operation
is scheduled. However, since there is support for only a single pending
operation, this was able to override a previously scheduled pending
connect command. This can break some command sequences, so give higher
priority to pending connect operation.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

12 years agoP2P: Fix GO start on interface that has active station connection
Jouni Malinen [Wed, 21 Dec 2011 11:34:25 +0000 (13:34 +0200)] 
P2P: Fix GO start on interface that has active station connection

The active station connection triggered wpa_supplicant AP mode startup
to try to update Beacon IEs before the AP mode was properly initialized
and that resulted in NULL pointer dereference in driver_nl80211.c. Fix
this by skipping the IE update before the AP mode is initialized.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

12 years agoAndroid: nl80211: Work around limited genl_ctrl_resolve()
Jouni Malinen [Wed, 30 Nov 2011 11:41:55 +0000 (13:41 +0200)] 
Android: nl80211: Work around limited genl_ctrl_resolve()

Android ICS system/core/libnl_2 has very limited genl_ctrl_resolve()
implementation that cannot handle names other than nlctrl. Work
around that by implementing more complete genl_ctrl_resolve()
functionality within driver_nl80211.c for Android builds.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

12 years agoAdd AP-STA-CONNECTED and DISCONNECTED events to wpa_cli -a
Neeraj Kumar Garg [Mon, 19 Dec 2011 23:07:42 +0000 (01:07 +0200)] 
Add AP-STA-CONNECTED and DISCONNECTED events to wpa_cli -a

Signed-hostap: Neeraj Kumar Garg <neerajkg@broadcom.com>

12 years agoP2P: Use hardcoded idle timeout of 10 seconds in P2P client role
Jouni Malinen [Sun, 18 Dec 2011 20:21:22 +0000 (22:21 +0200)] 
P2P: Use hardcoded idle timeout of 10 seconds in P2P client role

The p2p_group_idle configuration parameter is much more useful for
GO role, so use a separate hardcoded value of 10 seconds in P2P
client role. In practice, this means that the P2P client role will
automatically tear down the group when the GO tears down the group.

The 10 second timeout is enough to recover from temporary disconnections
without unnecessary tearing down the group if the GO is still present
and allows the client to connect.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoP2P: Fix disconnect event not to increase idle timeout
Jouni Malinen [Sun, 18 Dec 2011 20:18:42 +0000 (22:18 +0200)] 
P2P: Fix disconnect event not to increase idle timeout

When P2P client is processing a disconnection event, make sure the P2P
idle timeout does not get increased, i.e., set a new timeout only if no
timeout is in use. wpa_state changes between DISCONNECTED and SCANNING
can generate multiple calls to wpas_p2p_notif_disconnect() and
previously this was enough to force the idle timeout never hit in
practice when in P2P client role.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoLower RX_MGMT driver event debug level for Beacon frames
Jouni Malinen [Sun, 18 Dec 2011 19:48:25 +0000 (21:48 +0200)] 
Lower RX_MGMT driver event debug level for Beacon frames

This event can be very frequent in AP mode when Beacon frames from
neighboring BSSes are delivered to user space. Drop the debug
message priority from DEBUG to EXCESSIVE for Beacon frames.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoAllow linking with libnl-3 (libnl 3.2 and newer)
Ben Greear [Sun, 18 Dec 2011 19:12:05 +0000 (21:12 +0200)] 
Allow linking with libnl-3 (libnl 3.2 and newer)

I needed this patch to compile against the latest
libnl code. I added this to my config file:

CONFIG_LIBNL32=y

Signed-hostap: Ben Greear <greearb@candelatech.com>

12 years agoP2P: Reduce the idle time in Wait peer connect state
Neeraj Kumar Garg [Sun, 18 Dec 2011 16:01:11 +0000 (18:01 +0200)] 
P2P: Reduce the idle time in Wait peer connect state

When waiting for go_neg frame from the peer in WAIT_PEER_CONNECT state,
I have observed that sometimes it takes 20 to 30 secs for successful GO
negotiation. I also found out that it is because of 1 second idle time,
in WAIT_PEER_CONNECT state. While it is good to have 1 second idle time
[for doing power-save or doing some other legacy STA Scan or some other
useful stuff], this makes GO Negotiation process slow.

We wait for 1 second idle and then listen for a random time between
100(min)-300(max) ms. Assume P1 is in WAIT_PEER_CONNECT state and P2 is
the one which is now to send go_neg frame. If P2 sends GO Negotiation
frame just at the boundary of 300 ms of P1 and assume that P2 takes
close to 600-800 ms for one iteration of sending go_neg request (one
iteration is GO Negotiation Request frame time + dwell time +
listen_time), P2 needs to transmit at least 16-18 Action frames for
hitting the listen time of P1.

Following patch reduces the idle time to 500 ms. Alternatively we can
increase the listen time interval to 500 ms just for WAIT_PEER_CONNECT
state.

12 years agoP2P: Fix PROBE_REQ_ONLY flag use for Provision Discovery Request
Neeraj Kumar Garg [Sun, 18 Dec 2011 15:42:11 +0000 (17:42 +0200)] 
P2P: Fix PROBE_REQ_ONLY flag use for Provision Discovery Request

Provision discovery from a known peer should actually check for
dev->flags & P2P_DEV_PROBE_REQ_ONLY. This is creating an issue of
updating the listen frequency of peer with the PD request frame
frequency. PD request frame will be sent by the peer on our local listen
frequency. This patch fixes that error. Suggested check has already been
implemented in the invitation req receive path.

12 years agoP2P: Fix Provision Discovery channel for some join-GO cases
Jouni Malinen [Sun, 18 Dec 2011 15:21:25 +0000 (17:21 +0200)] 
P2P: Fix Provision Discovery channel for some join-GO cases

The Provision Discovery Request needs to be sent on the operating
channel of the GO and as such, the frequency from the BSS table
(scan results) need to override the frequency in the P2P peer
table that could be based on the Listen channel of the GO.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agowpa_supplicant/dbus AP: Add support for WPS Internal Registrar
Gustavo Sverzut Barbieri [Sun, 18 Dec 2011 15:06:31 +0000 (17:06 +0200)] 
wpa_supplicant/dbus AP: Add support for WPS Internal Registrar

When in AP mode, wpa_supplicant is now enabling WPS (only Internal
Registrar). WPS.Start() call can be used to initiate WPS negotiation
similarly to how this is done in station mode.

This was done to ctrl_iface by Jouni Malinen on April 21, 2009 (commit
3ec97afe571f159ea95213262c1c6b89965827d4)

Signed-hostap: Gustavo Sverzut Barbieri <barbieri@profusion.mobi>

12 years agoP2P: Make GO negotiation peer and group information available over D-Bus
Reinette Chatre [Sun, 18 Dec 2011 14:52:33 +0000 (16:52 +0200)] 
P2P: Make GO negotiation peer and group information available over D-Bus

The GO negotiation response is very cryptic at the moment. For a success
message we only know on which interface the negotiation succeeded, not
which peer. For a failure we know the interface also and a status code
(number).

It will be very useful for clients to know upon receipt of such a message
which peer the negotiation occurred with.

Now that the peer information is available and the API is changed
already, the function composing the D-Bus message might as well include
all GO negotiation information. This is done with a dict to make things
easier on clients if this result information changes down the line.

Signed-hostap: Reinette Chatre <reinette.chatre@intel.com>
Signed-hostap: Johannes Berg <johannes.berg@intel.com>

12 years agoP2P: Do not include own information in the peer table
Marek Kwaczynski [Sun, 18 Dec 2011 14:38:48 +0000 (16:38 +0200)] 
P2P: Do not include own information in the peer table

When the station is connected to P2P GO after calling p2p_find command
the device sees itself. It is related to lack of filtering itself from
clients connected to P2P GO.

Step by step:
1. dev1: p2p_group_add
2. dev2: p2p_connect <MAC1> pbc join
3. dev1: wps_pbc
4. dev2: p2p_find

Skip P2P client information for our own device from a GO with which
we are connected.

12 years agoPCSC: Accept 0x67 (Wrong length) as a response to READ RECORD
Jouni Malinen [Sun, 18 Dec 2011 12:44:03 +0000 (14:44 +0200)] 
PCSC: Accept 0x67 (Wrong length) as a response to READ RECORD

It looks like some USIM cards respond with 0x67 (Wrong length) instead
of 0x6c to 00 b2 01 04 ff. This was getting rejected in
scard_get_record_len(). ETSI TS 102 221 is not very clear on this
detail, but it looks fine to accept the 0x67 error value, too, to learn
the record length.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoFix CONFIG_NO_SCAN_PROCESSING=y build with ctrl_iface
Jouni Malinen [Sat, 17 Dec 2011 16:07:58 +0000 (18:07 +0200)] 
Fix CONFIG_NO_SCAN_PROCESSING=y build with ctrl_iface

Need to remove ROAM command processing since the needed functionality
for it gets removed with CONFIG_NO_SCAN_PROCESSING=y.

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoctrl_iface: Check for IEEE8021X_EAPOL definition
Antonio Quartulli [Sat, 17 Dec 2011 16:04:50 +0000 (18:04 +0200)] 
ctrl_iface: Check for IEEE8021X_EAPOL definition

The whole wpa_supplicant_ctrl_iface_ctrl_rsp_handle() function operates
on the ssid->eap field which exists only if IEEE8021X_EAPOL has been
defined. Therefore the whole function body needs to be enclosed within
an #ifdef/endif block.

Signed-hostap: Antonio Quartulli <ordex@autistici.org>

12 years agoMake hostapd_eid_wmm_valid() return more logical return values
Jouni Malinen [Sat, 17 Dec 2011 10:41:00 +0000 (12:41 +0200)] 
Make hostapd_eid_wmm_valid() return more logical return values

Return 1/0 instead 0/-1 to indicate valid/invalid element so that
the if statement makes more sense with !wmm_valid().

Signed-hostap: Jouni Malinen <j@w1.fi>

12 years agoAP: Pass station's WMM configuration to driver wrappers
Jason Young [Sat, 17 Dec 2011 10:38:06 +0000 (12:38 +0200)] 
AP: Pass station's WMM configuration to driver wrappers

This updates a previous patch did more or less the same thing by
providing the qosinfo as a single variable to the driver wrappers.

Signed-hostap: Jason Young <jason.young@dspg.com>

12 years agonl80211: Fix memory leaks on nla_put_failure error paths
Jouni Malinen [Sat, 17 Dec 2011 10:27:11 +0000 (12:27 +0200)] 
nl80211: Fix memory leaks on nla_put_failure error paths

Signed-hostap: Jouni Malinen <j@w1.fi>