libeap.git
14 years agoMerge hostapd/sta_flags.h into sta_info.h
Jouni Malinen [Sun, 13 Dec 2009 09:41:46 +0000 (11:41 +0200)]
Merge hostapd/sta_flags.h into sta_info.h

The separate header file is not needed since none of the driver wrappers
include it anymore. Move the WLAN_STA_* definitions back to be together
with struct sta_info definition.

14 years agoMap STA flags into values defined in driver.h
Jouni Malinen [Sun, 13 Dec 2009 09:35:39 +0000 (11:35 +0200)]
Map STA flags into values defined in driver.h

This removes need for including hostapd/sta_flags.h into driver
wrappers and removes any remaining dependencies between driver flags
and internal hostapd flags.

14 years agoRemove unneeded hostapd_wmm_sta_config()
Jouni Malinen [Sun, 13 Dec 2009 09:14:21 +0000 (11:14 +0200)]
Remove unneeded hostapd_wmm_sta_config()

The WMM STA flag is already taken care of by handle_assoc_cb() and there
is no point trying to do this unless hostapd is taking care MLME
processing, so no need to call this from drv_callbacks.c.

14 years agoRemove usused flags parameter from sta_add() driver op
Jouni Malinen [Sun, 13 Dec 2009 09:05:22 +0000 (11:05 +0200)]
Remove usused flags parameter from sta_add() driver op

14 years agodriver_bsd: Fix build after previous commit
Jouni Malinen [Sat, 12 Dec 2009 21:55:09 +0000 (23:55 +0200)]
driver_bsd: Fix build after previous commit

14 years agoAdd more WPA/IEEE 802.1X parameters into set_ieee8021x() driver op
Jouni Malinen [Sat, 12 Dec 2009 21:50:29 +0000 (23:50 +0200)]
Add more WPA/IEEE 802.1X parameters into set_ieee8021x() driver op

This gets rid of the need to touch internal hostapd data structures
directly from the driver wrappers.

14 years agodriver_bsd: Fix build (eapol_sm.h is not needed anymore)
Jouni Malinen [Sat, 12 Dec 2009 21:33:43 +0000 (23:33 +0200)]
driver_bsd: Fix build (eapol_sm.h is not needed anymore)

14 years agoChange set_ieee8021x driver op to use parameters structure
Jouni Malinen [Sat, 12 Dec 2009 21:32:44 +0000 (23:32 +0200)]
Change set_ieee8021x driver op to use parameters structure

This makes it easier to extent the set of parameters passed to
this driver wrapper function.

14 years agoReplace direct driver call to wpa_ft_rrb_rx() with driver event
Jouni Malinen [Sat, 12 Dec 2009 20:43:26 +0000 (22:43 +0200)]
Replace direct driver call to wpa_ft_rrb_rx() with driver event

This avoids need to include hostapd/wpa.h into the driver wrappers.

14 years agodriver_wired: Share multicast membership add/drop function
Jouni Malinen [Sat, 12 Dec 2009 20:18:37 +0000 (22:18 +0200)]
driver_wired: Share multicast membership add/drop function

14 years agodriver_wired: Remove unneeded conditional building blocks
Jouni Malinen [Sat, 12 Dec 2009 20:07:29 +0000 (22:07 +0200)]
driver_wired: Remove unneeded conditional building blocks

14 years agoRemove obsolete Prism54.org driver support (driver_prism54.c)
Jouni Malinen [Sat, 12 Dec 2009 18:52:12 +0000 (20:52 +0200)]
Remove obsolete Prism54.org driver support (driver_prism54.c)

The Prism54.org project seems have been dead for a while and it does not
look like this driver would ever be maintained again. Furthermore, it is
difficult to find a version that would work with the driver_prism54.c
wrapper and there is another driver for these card in the Linux kernel
tree.

The hostapd integration in driver_prism54.c is quite different from the
other driver wrappers and would require major effort to get it cleaned
up. Since there does not seem to be any real users for the cleaned up
version, there does not seem to be justification to spend this effort on
the wrapper. This old code is making it much more difficult to clean up
the driver interface and at this point, the best option seems to be to
remove the driver wrappers. Should someone really still need this, the
old code will continue to be available in hostapd 0.6.x.

14 years agodriver_wired: Move STA entry processing away from driver wrapper
Jouni Malinen [Sat, 12 Dec 2009 18:39:25 +0000 (20:39 +0200)]
driver_wired: Move STA entry processing away from driver wrapper

Get rid of hostapd/sta_info.h dependency by introducing a new driver
callback function for hostapd.

14 years agoWPS: Handle Selected Registrar as a union of info from all Registrars
Jouni Malinen [Sat, 12 Dec 2009 14:54:59 +0000 (16:54 +0200)]
WPS: Handle Selected Registrar as a union of info from all Registrars

Instead of using the latest selected registrar change, collect selected
registrar information separately from all registrars and use the union
of this information when building the WPS IE for Beacon and Probe
Response frames.

Note: SetSelectedRegistrar UPnP action does not include a unique
identifier, so the ER matching routine is based only on the IP address
of the ER. In theory, there could be multiple ERs using the same IP
address (but different port or URL), so there may be some corner cases
that would not always match the correct ER entry at the AP. Anyway, this
is not really expected to occur in normal use cases and even if it did
happen, the selected registrar information is not any worse than it was
before when only the last change from any registrar for being
advertized.

14 years agoWPS: Add display and keypad config methods for WPS ER
Jouni Malinen [Sat, 12 Dec 2009 14:49:33 +0000 (16:49 +0200)]
WPS: Add display and keypad config methods for WPS ER

14 years agoWPS: Move POST URL validation into web_connection_parse_post()
Jouni Malinen [Sat, 12 Dec 2009 14:48:50 +0000 (16:48 +0200)]
WPS: Move POST URL validation into web_connection_parse_post()

This is more logical location for checking the URL and potentially
handling a call to another URL handler. In addition, return 404 error,
not invalid UPnP action, if the URL does not match.

14 years agoWPS: Remove an obsolete comment about UPnP actions and callbacks
Jouni Malinen [Sat, 12 Dec 2009 14:48:18 +0000 (16:48 +0200)]
WPS: Remove an obsolete comment about UPnP actions and callbacks

14 years agoWPS: Remove unnecessary GetDevice and PutMessage callbacks
Jouni Malinen [Sat, 12 Dec 2009 14:47:39 +0000 (16:47 +0200)]
WPS: Remove unnecessary GetDevice and PutMessage callbacks

These callbacks can be handled internally within core WPS code, so there
is no need to go through wps_hostapd.c with a callback function that is
just calling back into the core WPS code.

14 years agoWPS: Remove unnecessary SetSelectedRegistrar callback
Jouni Malinen [Sat, 12 Dec 2009 14:46:33 +0000 (16:46 +0200)]
WPS: Remove unnecessary SetSelectedRegistrar callback

This can be handled internally within core WPS code, so there is no
need to go through wps_hostapd.c with a callback function that is just
calling back into the core WPS code.

14 years agoUpdate git instructions to use more modern command line structure
Jouni Malinen [Sat, 12 Dec 2009 14:45:23 +0000 (16:45 +0200)]
Update git instructions to use more modern command line structure

14 years agoFix dh_groups.o build for some configurations
Jouni Malinen [Fri, 11 Dec 2009 15:24:42 +0000 (17:24 +0200)]
Fix dh_groups.o build for some configurations

Need to include dh_groups.o in the build even if not all DH groups
are included. Only internal crypto build case was doing this properly.

14 years agoFix hostapd build without RADIUS server
Jouni Malinen [Fri, 11 Dec 2009 14:29:28 +0000 (16:29 +0200)]
Fix hostapd build without RADIUS server

14 years agoMerge get_seqnum_igtk() driver op with get_seqnum()
Jouni Malinen [Thu, 10 Dec 2009 22:15:54 +0000 (00:15 +0200)]
Merge get_seqnum_igtk() driver op with get_seqnum()

IEEE 802.11w uses distinct key indexes (4 and 5) so the same
get_seqnum() handler can be used to fetch packet number for both
TKIP/CCMP and BIP(using IGTK).

Since the new get_seqnum_igtk() handler was not actually implemented by
any driver wrapper, this may also fix BIP/IGTK sequence number reporting
with driver_nl80211.c.

14 years agoAdd Doxygen comments for rest of struct wpa_driver_ops members
Jouni Malinen [Thu, 10 Dec 2009 19:11:33 +0000 (21:11 +0200)]
Add Doxygen comments for rest of struct wpa_driver_ops members

All members have now at least minimal documentation.

14 years agoMove vendor-specific IE type defines away from driver.h
Jouni Malinen [Thu, 10 Dec 2009 10:27:46 +0000 (12:27 +0200)]
Move vendor-specific IE type defines away from driver.h

These are generic IEEE 802.11 defines and do not really need to be in
the driver interface specific header file.

14 years agoAdd more documentation for driver ops
Jouni Malinen [Wed, 9 Dec 2009 23:21:01 +0000 (01:21 +0200)]
Add more documentation for driver ops

14 years agoEAP-TTLS/PAP: User-Password obfuscation for zero length password
Masashi Honma [Wed, 9 Dec 2009 21:42:54 +0000 (23:42 +0200)]
EAP-TTLS/PAP: User-Password obfuscation for zero length password

The password in User-Password AVP is padded to a multiple of 16 bytes
on EAP-TTLS/PAP. But when the password length is zero, no padding is
added. It doesn't cause connectivity issue. In fact, I could connect
with hostapd RADIUS server with zero length password.

I think it's better for obfuscation to pad the 16 bytes data when the
password length is zero with this patch.

14 years agohostapd: Remove unused bridge_packets configuration option
Jouni Malinen [Wed, 9 Dec 2009 20:06:43 +0000 (22:06 +0200)]
hostapd: Remove unused bridge_packets configuration option

There was code for configuring this, but no driver wrapper actually
implements the actual setting. Remove this for now to reduce potential
confusion and to simply the driver interface.

14 years agoRemove struct hostapd_rate_data from driver API
Jouni Malinen [Wed, 9 Dec 2009 19:57:50 +0000 (21:57 +0200)]
Remove struct hostapd_rate_data from driver API

In addition to the bitrate, the only other variable in this structure
is used internally in hostapd. Move this structure into hostapd.h and
make the driver API use simpler data structure (array of bitrates).

14 years agoRemove unused rate flags from driver use
Jouni Malinen [Wed, 9 Dec 2009 19:38:14 +0000 (21:38 +0200)]
Remove unused rate flags from driver use

These are not really used and can be removed to clean up the driver
interface definition. The only remaining flag (HOSTAPD_RATE_BASIC) can
be removed once the basic rate set indication can be handled
differently.

14 years agoMerge bss_add/bss_remove drivers ops into if_add/if_remove
Jouni Malinen [Wed, 9 Dec 2009 14:49:28 +0000 (16:49 +0200)]
Merge bss_add/bss_remove drivers ops into if_add/if_remove

if_add/if_remove can now be used as the generic driver ops for adding
and removing virtual interfaces of various types. In addition,
driver_nl80211.c is now including this code unconditionally, so that
the functions are not limited only for hostapd.

14 years agoRemove unused if_update() driver op
Jouni Malinen [Wed, 9 Dec 2009 13:47:20 +0000 (15:47 +0200)]
Remove unused if_update() driver op

14 years agoFix driver_bsd.c build
Masashi Honma [Mon, 7 Dec 2009 19:35:35 +0000 (21:35 +0200)]
Fix driver_bsd.c build

On NetBSD 5.0.1, driver_bsd.c build fails with message below.

../src/drivers/driver_bsd.c: In function 'wpa_driver_bsd_associate':
../src/drivers/driver_bsd.c:1170: warning: implicit declaration of function 'wpa_driver_bsd_set_auth_alg'
../src/drivers/driver_bsd.c: At top level:
../src/drivers/driver_bsd.c:1204: error: static declaration of 'wpa_driver_bsd_set_auth_alg' follows non-static declaration
../src/drivers/driver_bsd.c:1170: error: previous implicit declaration of 'wpa_driver_bsd_set_auth_alg' was here
gmake: *** [../src/drivers/driver_bsd.o] Error 1

This patch solves this issue.

14 years agoAdd support for building IEEE 802.11n support into wpa_supplicant AP
Jouni Malinen [Sun, 6 Dec 2009 17:50:40 +0000 (19:50 +0200)]
Add support for building IEEE 802.11n support into wpa_supplicant AP

14 years agoFix conditional EAP-SIM/AKA DB code selection
Jouni Malinen [Sun, 6 Dec 2009 17:48:25 +0000 (19:48 +0200)]
Fix conditional EAP-SIM/AKA DB code selection

14 years agoMove IEEE 802.11n HT management code into a separate file
Jouni Malinen [Sun, 6 Dec 2009 17:41:47 +0000 (19:41 +0200)]
Move IEEE 802.11n HT management code into a separate file

14 years agoRemove unnecessary CONFIG_IEEE80211N use
Jouni Malinen [Sun, 6 Dec 2009 17:17:54 +0000 (19:17 +0200)]
Remove unnecessary CONFIG_IEEE80211N use

14 years agoRemove unused phytype RX info variable
Jouni Malinen [Sun, 6 Dec 2009 16:54:58 +0000 (18:54 +0200)]
Remove unused phytype RX info variable

14 years agoRemove unused hostapd reconfig code
Jouni Malinen [Sun, 6 Dec 2009 16:48:30 +0000 (18:48 +0200)]
Remove unused hostapd reconfig code

14 years agoFix some issues with test program builds
Jouni Malinen [Sun, 6 Dec 2009 16:30:12 +0000 (18:30 +0200)]
Fix some issues with test program builds

14 years agoMove EAP-SIM DB conditional build into hostapd
Jouni Malinen [Sun, 6 Dec 2009 16:23:53 +0000 (18:23 +0200)]
Move EAP-SIM DB conditional build into hostapd

14 years agoMove test_x509v3 into the new tests subdirectory
Jouni Malinen [Sun, 6 Dec 2009 16:10:52 +0000 (18:10 +0200)]
Move test_x509v3 into the new tests subdirectory

14 years agoRemove forgotten asn1_test build target
Jouni Malinen [Sun, 6 Dec 2009 15:57:23 +0000 (17:57 +0200)]
Remove forgotten asn1_test build target

This is now in tests/Makefile.

14 years agoRemove conditional no-RADIUS build from src/radius
Jouni Malinen [Sun, 6 Dec 2009 15:53:59 +0000 (17:53 +0200)]
Remove conditional no-RADIUS build from src/radius

Make it responsibility of the src/radius user to handle conditional
build rules.

14 years agoResolve circular library references with --start-group
Jouni Malinen [Sun, 6 Dec 2009 15:18:28 +0000 (17:18 +0200)]
Resolve circular library references with --start-group

src/crypto/libcrypto.a and src/tls/libtls.a have circular references
and will need special handling with the linker at least for the time
being. This could be cleaned up eventually, but for now, provide a
mechanism to get the programs linked.

14 years agoMove asn1_test.c into tests subdirectory and split it in two
Jouni Malinen [Sun, 6 Dec 2009 14:45:36 +0000 (16:45 +0200)]
Move asn1_test.c into tests subdirectory and split it in two

The new test-asn1 and test-x509 tools are built using libraries
from src/{utils,crypto,tls}. Currently, cross dependencies between
crypto and tls are still preventing the test-x509 from being linked
properly.

14 years agoMove hlr_auc_gw into hostapd directory
Jouni Malinen [Sun, 6 Dec 2009 14:33:19 +0000 (16:33 +0200)]
Move hlr_auc_gw into hostapd directory

This is a separate program and is used mainly with hostapd, so it is
better to move this into the hostapd subdirectory now that Milenage
code has already been moved into src/crypto. Milenage was the only
generic component in hlr_auc_gw.

14 years agoAdd rules for building src/tls/libtls.a and use it with eap_example
Jouni Malinen [Sun, 6 Dec 2009 14:27:54 +0000 (16:27 +0200)]
Add rules for building src/tls/libtls.a and use it with eap_example

eap_example is now using src/crypto/libcrypto.a and src/tls/libtls.a
instead of providing own rules for building the files for these
components. TLS library selection is temporarily disabled for
eap_example (it will be built using internal crypto/TLS), but the
configuration option for this will eventually be restored with a new
libcrypto.a configuration option.

14 years agoInclude functionality to support EAP-FAST unconditionally
Jouni Malinen [Sun, 6 Dec 2009 14:20:32 +0000 (16:20 +0200)]
Include functionality to support EAP-FAST unconditionally

Clean up the internal TLS implementation by removing conditional
build blocks for (mostly) EAP-FAST specific functionality. This
will increase the size a big for non-EAP-FAST builds, but is quite
helpful in making src/tls/libtls.a with single build options. If
the potential size reduction is considered significant in the future,
this can be reconsider with a more library compatible way (e.g.,
external file with registration function, etc.).

14 years agoRemove unneeded CONFIG_INTERNAL_X509 and NEED_SHA256 defines
Jouni Malinen [Sun, 6 Dec 2009 14:19:13 +0000 (16:19 +0200)]
Remove unneeded CONFIG_INTERNAL_X509 and NEED_SHA256 defines

14 years agoSplit crypto_internal.c into parts to clean up build
Jouni Malinen [Sun, 6 Dec 2009 12:37:46 +0000 (14:37 +0200)]
Split crypto_internal.c into parts to clean up build

This makes it easier to make src/libcrypto.a and only link in
code that is really used.

14 years agoFix rsn_preauth_scan_result() inline wrapper for no-EAP builds
Jouni Malinen [Sun, 6 Dec 2009 12:29:12 +0000 (14:29 +0200)]
Fix rsn_preauth_scan_result() inline wrapper for no-EAP builds

14 years agoUse thin archives to allow libraries to be merged
Jouni Malinen [Sun, 6 Dec 2009 11:49:31 +0000 (13:49 +0200)]
Use thin archives to allow libraries to be merged

This allows libeap.a and libeap.so to be built by merging in multiple
libraries from src subdirectories. In addition, this avoids wasting
extra space and time for local builds.

14 years agoIncrease EAP server extra room for encryption overhead (for GnuTLS)
Jouni Malinen [Sun, 6 Dec 2009 10:02:28 +0000 (12:02 +0200)]
Increase EAP server extra room for encryption overhead (for GnuTLS)

This fixes issues with some GnuTLS versions that seem to be adding
quite a bit of extra data into TLS messages. The EAP server code is
now using the same 300 byte extra room that was already used in the
EAP peer implementation.

14 years agoeap_example: Fix build after recent crypto changes
Jouni Malinen [Sun, 6 Dec 2009 09:59:51 +0000 (11:59 +0200)]
eap_example: Fix build after recent crypto changes

14 years agoRemove obsolete comment about wpa_supplicant header files
Jouni Malinen [Sun, 6 Dec 2009 09:30:39 +0000 (11:30 +0200)]
Remove obsolete comment about wpa_supplicant header files

14 years agoMove EAP method registration away from src/eap_{peer,server}
Jouni Malinen [Sun, 6 Dec 2009 09:28:41 +0000 (11:28 +0200)]
Move EAP method registration away from src/eap_{peer,server}

This makes it easier to make a library out of EAP methods without
losing possiblity of binary size optimization by linker dropping
unreferenced code.

14 years agoRemove unnecessary defines
Jouni Malinen [Sat, 5 Dec 2009 20:51:08 +0000 (22:51 +0200)]
Remove unnecessary defines

The following defines are not really needed in most places, so
remove them to clean up source code and build scripts:
EAP_TLS_FUNCS
EAP_TLS_OPENSSL
EAP_TLS_GNUTLS
CONFIG_TLS_INTERNAL

14 years agoResolve compiler warnings in the test programs
Jouni Malinen [Sat, 5 Dec 2009 20:32:45 +0000 (22:32 +0200)]
Resolve compiler warnings in the test programs

14 years agoAdd forgotten files into libcrypto.a
Jouni Malinen [Sat, 5 Dec 2009 20:25:50 +0000 (22:25 +0200)]
Add forgotten files into libcrypto.a

14 years agoMove more tests from wpa_supplicant/tests into tests
Jouni Malinen [Sat, 5 Dec 2009 20:25:32 +0000 (22:25 +0200)]
Move more tests from wpa_supplicant/tests into tests

14 years agoUse simpler make rules for test programs
Jouni Malinen [Sat, 5 Dec 2009 20:14:55 +0000 (22:14 +0200)]
Use simpler make rules for test programs

14 years agoGet rid of some compiler warnings
Jouni Malinen [Sat, 5 Dec 2009 20:13:33 +0000 (22:13 +0200)]
Get rid of some compiler warnings

14 years agoMove MD4 test from wpa_supplicant/tests into tests
Jouni Malinen [Sat, 5 Dec 2009 20:11:50 +0000 (22:11 +0200)]
Move MD4 test from wpa_supplicant/tests into tests

14 years agoAdd rules for building src/crypto as a library
Jouni Malinen [Sat, 5 Dec 2009 20:03:46 +0000 (22:03 +0200)]
Add rules for building src/crypto as a library

For now, this is hardcoded to support only the internal crypto
implementation.

14 years agoInclude needed header files to avoid compiler warnings
Jouni Malinen [Sat, 5 Dec 2009 19:40:44 +0000 (21:40 +0200)]
Include needed header files to avoid compiler warnings

14 years agoAdd build rules for building a library from src/utils files
Jouni Malinen [Sat, 5 Dec 2009 19:39:41 +0000 (21:39 +0200)]
Add build rules for building a library from src/utils files

This is an initial step on providing an alternative build system that
uses libraries from src subdirectories.

14 years agoRemove Milenage test from hostapd/Makefile
Jouni Malinen [Sat, 5 Dec 2009 19:27:19 +0000 (21:27 +0200)]
Remove Milenage test from hostapd/Makefile

14 years agoMove Milenage test code into the new tests directory
Jouni Malinen [Sat, 5 Dec 2009 19:14:08 +0000 (21:14 +0200)]
Move Milenage test code into the new tests directory

14 years agoMove milenage.[ch] into src/crypto
Jouni Malinen [Sat, 5 Dec 2009 19:00:52 +0000 (21:00 +0200)]
Move milenage.[ch] into src/crypto

14 years agoUse auto-generated dependency files and clean them
Jouni Malinen [Sat, 5 Dec 2009 18:44:12 +0000 (20:44 +0200)]
Use auto-generated dependency files and clean them

14 years agoMove base64 test code into a new tests subdirectory
Jouni Malinen [Sat, 5 Dec 2009 18:43:07 +0000 (20:43 +0200)]
Move base64 test code into a new tests subdirectory

14 years agoIBSS RSN: Add more verbose debug info for key setup
Jouni Malinen [Fri, 4 Dec 2009 20:55:28 +0000 (22:55 +0200)]
IBSS RSN: Add more verbose debug info for key setup

14 years agonl80211: Add extra IEs into IBSS join request
Jouni Malinen [Fri, 4 Dec 2009 20:20:59 +0000 (22:20 +0200)]
nl80211: Add extra IEs into IBSS join request

This allows RSN IE to be added into Beacon and Probe Response frames
when using RSN IBSS.

14 years agoIBSS RSN: Wait for connection event and do not use auth timeout
Jouni Malinen [Fri, 4 Dec 2009 20:09:06 +0000 (22:09 +0200)]
IBSS RSN: Wait for connection event and do not use auth timeout

Wait for connection (IBSS join completed) event before marking state
completed. In addition, do not use the station mode authentication
timeout since that can trigger full disconnection from IBSS when
there is a timeout with just one of the peers.

14 years agoSME: Do not process disassoc frame unless SME is used
Jouni Malinen [Fri, 4 Dec 2009 19:44:13 +0000 (21:44 +0200)]
SME: Do not process disassoc frame unless SME is used

This avoids an infinite loop with driver_test.c when using IBSS.

14 years agoFix build with both CONFIG_AP=y and CONFIG_IBSS_RSN=y enabled
Jouni Malinen [Fri, 4 Dec 2009 19:34:34 +0000 (21:34 +0200)]
Fix build with both CONFIG_AP=y and CONFIG_IBSS_RSN=y enabled

14 years agoFix hostapd build with WPS disabled
Jouni Malinen [Thu, 3 Dec 2009 22:29:10 +0000 (00:29 +0200)]
Fix hostapd build with WPS disabled

14 years agonl80211: Add support for IBSS networks
Jouni Malinen [Thu, 3 Dec 2009 22:15:32 +0000 (00:15 +0200)]
nl80211: Add support for IBSS networks

14 years agodbus: switch dbus APIs initialization order
Witold Sowa [Thu, 3 Dec 2009 19:17:49 +0000 (21:17 +0200)]
dbus: switch dbus APIs initialization order

Initialize the new DBus API before the old one, so new applications
which can use both, the old and the new API will be notified first
that new API is available.

14 years agodbus: Enable -u option when only the new DBus API is included
Witold Sowa [Thu, 3 Dec 2009 19:12:42 +0000 (21:12 +0200)]
dbus: Enable -u option when only the new DBus API is included

14 years agoFix wpa_priv compilation after driver_ops changes
Jouni Malinen [Thu, 3 Dec 2009 19:03:58 +0000 (21:03 +0200)]
Fix wpa_priv compilation after driver_ops changes

14 years agoFix wpa_priv memory leak in wpa_priv_get_scan_results2()
Dmitry Shmidt [Thu, 3 Dec 2009 18:59:27 +0000 (20:59 +0200)]
Fix wpa_priv memory leak in wpa_priv_get_scan_results2()

I suspect that new scan results format demands more complex free
procedure.

14 years agoAdd more Doxygen documentation for RADIUS server implementation
Jouni Malinen [Wed, 2 Dec 2009 19:29:32 +0000 (21:29 +0200)]
Add more Doxygen documentation for RADIUS server implementation

14 years agonl80211: Clear BSS state mismatches with deauth as a workaround
Jouni Malinen [Wed, 2 Dec 2009 15:54:57 +0000 (17:54 +0200)]
nl80211: Clear BSS state mismatches with deauth as a workaround

There seem to be some cases in which wpa_supplicant and
cfg80211/mac80211 seem to have different understanding on
authentication/association state. Since cfg80211/mac80211 is very strict
on when it accepts new authentication/association/scan commands, try our
best at clearing such state mismatches by explicitly deauthenticating
from BSSes with which the driver claims we are associated with if we do
not have local information about such association.

14 years agoSME: Deauthenticate to clear state after disassociation events
Jouni Malinen [Wed, 2 Dec 2009 15:26:28 +0000 (17:26 +0200)]
SME: Deauthenticate to clear state after disassociation events

cfg80211/mac80211 can get into somewhat confused state if the AP only
disassociates us and leaves us in authenticated state. For now, force
the state to be cleared with deauthentication to avoid confusing errors
if we try to associate with the AP again. This gets rid of 30 second
delay (scan timeout) in cases where only a disassociation frame is
received from the AP.

14 years agonl80211: Add debug prints for BSS status in scan results
Jouni Malinen [Wed, 2 Dec 2009 14:45:31 +0000 (16:45 +0200)]
nl80211: Add debug prints for BSS status in scan results

Print what the kernel believes the current BSS status (authenticated
or associated) is in scan results. In addition, check whether this
matches with the state that wpa_supplicant believes the driver to be
in.

This does not change the actual behavior, but will provide information
that will help in debugging potential issues where cfg80211/mac80211
seems to get into a different state from wpa_supplicant. In addition,
this provides an easy location for a workaround that could be added to
clear cfg80211/mac80211 state for unknown BSSes.

14 years agoFix driver initialization not to crash if driver does not use init2()
Jouni Malinen [Wed, 2 Dec 2009 14:43:09 +0000 (16:43 +0200)]
Fix driver initialization not to crash if driver does not use init2()

8a5ab9f5e56cd2f5781c2d92f41495e60d544780 fixed global driver context
for init2(), but it also broke driver initialization with driver
wrappers that do not use init2().. Fix this by setting wpa_s->global
before it gets dereferenced.

14 years agoMove internal EAPOL authenticator defines into their own file
Jouni Malinen [Sun, 29 Nov 2009 21:16:04 +0000 (23:16 +0200)]
Move internal EAPOL authenticator defines into their own file

This is an initial step in further cleaning up the EAPOL authenticator
use to avoid requiring direct accesses to the internal data structures.
For now, number of external files are still including the internal
definitions from eapol_auth_sm_i.h, but eventually, these direct
references should be removed.

14 years agoRemove src/crypto from default include path
Jouni Malinen [Sun, 29 Nov 2009 21:04:43 +0000 (23:04 +0200)]
Remove src/crypto from default include path

In addition, start ordering header file includes to be in more
consistent order: system header files, src/utils, src/*, same
directory as the *.c file.

14 years agoSplit handle_assoc() into number of helper functions
Jouni Malinen [Sun, 29 Nov 2009 20:14:57 +0000 (22:14 +0200)]
Split handle_assoc() into number of helper functions

14 years agoMark IE input to hostapd_eid_wmm_valid() const
Jouni Malinen [Sun, 29 Nov 2009 20:10:38 +0000 (22:10 +0200)]
Mark IE input to hostapd_eid_wmm_valid() const

14 years agoCheck AID availability before handling HT state updates on association
Jouni Malinen [Sun, 29 Nov 2009 19:11:10 +0000 (21:11 +0200)]
Check AID availability before handling HT state updates on association

14 years agoAllocate sta->ht_capabilities dynamically
Jouni Malinen [Sun, 29 Nov 2009 19:07:52 +0000 (21:07 +0200)]
Allocate sta->ht_capabilities dynamically

This avoids need for conditional inclusion of header file into
sta_info.h and cleans up the code a bit.

14 years agoInclude src/eapol_auth in Doxygen documents
Jouni Malinen [Sun, 29 Nov 2009 18:23:55 +0000 (20:23 +0200)]
Include src/eapol_auth in Doxygen documents

14 years agoAdd Makefile for the new src/eapol_auth directory
Jouni Malinen [Sun, 29 Nov 2009 18:21:25 +0000 (20:21 +0200)]
Add Makefile for the new src/eapol_auth directory

14 years agoMake HOSTAPD_DUMP_STATE configurable with CONFIG_NO_DUMP_STATE
Jouni Malinen [Sun, 29 Nov 2009 18:18:47 +0000 (20:18 +0200)]
Make HOSTAPD_DUMP_STATE configurable with CONFIG_NO_DUMP_STATE

This removes the hardcoded definition from Makefile and cleans up
source code by moving the mail HOSTAPD_DUMP_STATE blocks into separate
files to avoid conditional compilation within files.

14 years agoMove EAPOL authenticator state machine into src/eapol_auth
Jouni Malinen [Sun, 29 Nov 2009 18:03:28 +0000 (20:03 +0200)]
Move EAPOL authenticator state machine into src/eapol_auth

This is now completely independent from hostapd-specific code, so
it can be moved to be under the src tree.

14 years agoChange EAPOL authenticator hapd pointers to be opaque context
Jouni Malinen [Sun, 29 Nov 2009 17:49:14 +0000 (19:49 +0200)]
Change EAPOL authenticator hapd pointers to be opaque context

This cleans up the eapol_sm.c interface to not depend on any
hostapd-specific data structures.

14 years agoRemove dependency on sta_info.h from eapol_sm.c
Jouni Malinen [Sun, 29 Nov 2009 17:40:47 +0000 (19:40 +0200)]
Remove dependency on sta_info.h from eapol_sm.c

Instead of fetching WPS IE from struct sta_info, pass this as a
parameter to eapol_auth_alloc().