path: root/hostapd
Commit message (Collapse)AuthorAgeFilesLines
* Beacon request through hostapd control interfaceJouni Malinen2017-01-031-0/+43
| | | | | | | | | | The new control interface command "REQ_BEACON <STA addr> [req_mode=<mode>] <beacon request>" can now be used to request hostapd to transmit a measurement request to request a beacon report from an associated STA. This command returns the assigned dialog token (1-255) or FAIL on failure. Signed-off-by: Jouni Malinen <j@w1.fi>
* Add hostapd configuration parameter rrm_beacon_reportJouni Malinen2017-01-032-0/+9
| | | | | | | | rrm_beacon_report=1 can now be used to make hostapd advertise capability for beacon reports (passive, active, table). Actual mechanism for sending out beacon requests will be added in separate commits. Signed-off-by: Jouni Malinen <j@w1.fi>
* Update copyright notices for the new year 2017Jouni Malinen2017-01-034-7/+7
| | | | Signed-off-by: Jouni Malinen <j@w1.fi>
* GAS: Remove unnecessarily duplicate gas_frag_limit configurationJouni Malinen2016-12-292-9/+9
| | | | | | | | The actual BSS configuration parameter can be updated with the SET control interface command, so there is no need to maintain a separate per-BSS parameter and a separate control interface handling for this. Signed-off-by: Jouni Malinen <j@w1.fi>
* Remove deprecated tx_queue_* params from hostapd.conf notesJouni Malinen2016-12-281-1/+1
| | | | | | | | The after_beacon and beacon TX queue parameters has not been configurable through this mechanism for years, so do not list them in hostapd.conf notes. Signed-off-by: Jouni Malinen <j@w1.fi>
* Fix memory leak on hostapd eap_user_file parsing error pathsJouni Malinen2016-12-281-8/+3
| | | | | | | Need to free all the pending completed EAP users if a parsing error prevents the file from being used. Signed-off-by: Jouni Malinen <j@w1.fi>
* hostapd: Remove unnecessary NULL check from parser functionsJouni Malinen2016-12-281-6/+0
| | | | | | The fname argument cannot be NULL in these location. Signed-off-by: Jouni Malinen <j@w1.fi>
* Fix memory leak in hostapd BSS_TM_REQ error path handlingJouni Malinen2016-12-281-4/+9
| | | | | | | The optional url=<URL> parameter was stored in allocated memory and that memory was leaked if some following parameter parsing attempts failed. Signed-off-by: Jouni Malinen <j@w1.fi>
* hostapd: Add TERMINATE as per-interface commandJouni Malinen2016-12-271-0/+2
| | | | | | | This was already avaialble through the global control interface, but not the per-interface one. Signed-off-by: Jouni Malinen <j@w1.fi>
* hostapd: Do not update dtim_period with invalid valueJouni Malinen2016-12-271-3/+5
| | | | | | | Previously, the update command was rejected, but the actual value was updated. Signed-off-by: Jouni Malinen <j@w1.fi>
* hostapd: Do not update invalid wep_key_len_unicastJouni Malinen2016-12-271-6/+7
| | | | | | | Previously, the update command was rejected, but the configuration parameter value was updated anyway. Signed-off-by: Jouni Malinen <j@w1.fi>
* hostapd: Do not update rejected wep_key_len_broadcastJouni Malinen2016-12-271-7/+7
| | | | | | | Previously, update command with invalid value got rejected, but the actual configuration data was updated anyway. Signed-off-by: Jouni Malinen <j@w1.fi>
* hostapd: Do not update eapol_version with rejected valueJouni Malinen2016-12-271-3/+5
| | | | | | | Previously, an invalid eapol_version update command was rejected, but the actual configuration value was updated. Signed-off-by: Jouni Malinen <j@w1.fi>
* hostapd: Reject invalid macaddr_acl valueJouni Malinen2016-12-271-5/+8
| | | | | | | Previously, this was noted in error log, but the invalid value was stored in the configuration without rejecting it. Signed-off-by: Jouni Malinen <j@w1.fi>
* hostapd: Check driver parameter before replacing previous valueJouni Malinen2016-12-271-4/+5
| | | | | | | This leaves the previously configured value in place if "SET driver ..." command fails. Signed-off-by: Jouni Malinen <j@w1.fi>
* hostapd_cli: Add completion for get commandMikael Kanstrup2016-12-211-1/+26
| | | | | | Add command completion support for get command. Signed-off-by: Mikael Kanstrup <mikael.kanstrup@sonymobile.com>
* hostapd_cli: Add completion for set commandMikael Kanstrup2016-12-211-1/+39
| | | | | | Add command completion support for set command. Signed-off-by: Mikael Kanstrup <mikael.kanstrup@sonymobile.com>
* hostapd_cli: Completion for further commands with STA parameterMikael Kanstrup2016-12-211-4/+5
| | | | | | | | | Yet some more commands take STA address as the only parameter. Add command completion support for the following commands: signature, sa_query, send_qos_map_conf and req_lci Signed-off-by: Mikael Kanstrup <mikael.kanstrup@sonymobile.com>
* hostapd_cli: Use common completion for commands that use stationsMikael Kanstrup2016-12-211-34/+4
| | | | | | | More than one command takes STA address as the only parameter. Make use of a common completion routine. Signed-off-by: Mikael Kanstrup <mikael.kanstrup@sonymobile.com>
* hostapd_cli: Add missing command help descriptionsMikael Kanstrup2016-12-211-27/+60
| | | | | | | | Some commands are missing help description making them not show up in the list of supported commands. Add command help description for all missing commands. Signed-off-by: Mikael Kanstrup <mikael.kanstrup@sonymobile.com>
* FILS: Separate FILS realm configuration from ERP domainJouni Malinen2016-12-172-0/+33
| | | | | | | | | The new hostapd configuration parameter fils_realm=<realm> can now be used to configure one or more FILS realms to advertise for ERP domains when using FILS. This replaces the use of erp_domain=<domain> parameter for the FILS use case. Signed-off-by: Jouni Malinen <j@w1.fi>
* Allow hostapd wep_key# parameters to be clearedJouni Malinen2016-12-051-1/+19
| | | | | | | | Setting wep_key# to an empty string will now clear a previously configured key. This is needed to be able to change WEP configured AP to using WPA/WPA2 through the hostapd control interface SET commands. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
* Add multicast to unicast supportMichael Braun2016-12-042-0/+18
| | | | | | | | | | | | | | | | | | | | This adds support for nl80211 NL80211_CMD_SET_MULTICAST_TO_UNICAST command. By setting the new hostapd configuration option multicast_to_unicast=1, hostapd configures this AP to perform multicast to unicast conversion. When enabled, all multicast packets with ethertype ARP, IPv4, or IPv6 (possibly within an 802.1Q header) will be sent out to each station once with the destination (multicast) MAC address replaced by the station's MAC address. Note that this may break certain expectations of the receiver, e.g., the ability to drop unicast IP packets encapsulated in multicast L2 frames, or the ability to not send destination unreachable messages in such cases. This also does not implement Directed Multicast Service (DMS). Signed-off-by: Michael Braun <michael-dev@fami-braun.de>
* Add MGMT_RX_PROCESS test command for hostapdJouni Malinen2016-11-291-0/+73
| | | | | | | | | | | | | | This makes it easier to write hwsim test cases to verify management frame processing sequences with dropped or modified frames. When ext_mgmt_frame_handling is used, this new command can be used to request hostapd to process a received a management frame, e.g., based on information reported in the MGMT-RX events. This is more or less identical to the earlier wpa_supplicant commit 4de70e2330c54c32f42a5fc93517d65c0a2c3be9 ('Add MGMT_RX_PROCESS test command for wpa_supplicant'), but for hostapd. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
* Add support for user configurable Beacon frame data rate for AP modePurushottam Kushwaha2016-11-252-0/+47
| | | | | | | | | | | | | | | Allow configuration of Beacon frame TX rate from hostapd.conf with "beacon_rate=xx" option. The following format is used to set legacy/HT/VHT beacon rates: Legacy (CCK/OFDM rates): beacon_rate=<legacy rate in 100 kbps> HT: beacon_rate=ht:<HT MCS> VHT: beacon_rate=vht:<VHT MCS> Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
* FT: Complete CONFIG_IEEE80211R_AP renaming for hostapdJouni Malinen2016-11-192-10/+10
| | | | | | | | | | | | Commit 4ec1fd8e42bad9390f14a58225b6e5f6fb691950 ('FT: Differentiate between FT for station and for AP in build') renamed all CONFIG_IEEE80211R instances within src/ap/* to CONFIG_IEEE80211R_AP, but it did not change hostapd/* files to match. While this does not cause much harm for normal use cases, this broke some test builds where wpa_supplicant build is used to build in hostapd/*.c files for analysis. Fix this by completing CONFIG_IEEE80211R_AP renaming. Signed-off-by: Jouni Malinen <j@w1.fi>
* Fix hostapd usage entry style for -TJouni Malinen2016-11-191-1/+1
| | | | | | | | Remove the extra equals sign from the line since hostapd usage text does not have it for other entries either (while wpa_supplicant does and this was likely copy-pasted from there). Signed-off-by: Jouni Malinen <j@w1.fi>
* Rename a function argument to avoid shadowing a variable in global scopeJouni Malinen2016-11-121-3/+3
| | | | | | | Do not use optarg as a function argument since a variable with that name is in the global scope. Signed-off-by: Jouni Malinen <j@w1.fi>
* FT: Differentiate between FT for station and for AP in buildIlan Peer2016-10-292-2/+2
| | | | | | | | | | | | | | Previously, CONFIG_IEEE80211R enabled build that supports FT for both station mode and AP mode. However, in most wpa_supplicant cases only station mode FT is required and there is no need for AP mode FT. Add support to differentiate between station mode FT and AP mode FT in wpa_supplicant builds by adding CONFIG_IEEE80211R_AP that should be used when AP mode FT support is required in addition to station mode FT. This allows binary size to be reduced for builds that require only the station side FT functionality. Signed-off-by: Ilan Peer <ilan.peer@intel.com>
* hostapd: Add a configuration to set an AP as stationaryDavid Spinadel2016-10-294-5/+21
| | | | | | | | | | | Add a configuration option in hostapd.conf and in neighbor report that sets an AP as stationary. To enable this option on the current AP set the config option stationary_ap to 1. To set a neighbor entry to be marked as stationary add the word stat to the SET_NEIGHBOR command. This option tells hostapd to send LCI data even if it is older than requested by max age subelement in RRM request. Signed-off-by: David Spinadel <david.spinadel@intel.com>
* hostapd: Clear location configuration when it is resetIlan Peer2016-10-291-0/+8
| | | | | | | | In case that LCI or location civic configuration is cleared, free the buffer holding the corresponding information to avoid cases that the information is considered as valid/useful. Signed-off-by: Ilan Peer <ilan.peer@intel.com>
* hostapd: Added signal level to STA trackingKevin Mahoney2016-10-281-2/+3
| | | | | | | Add signal level information to the station tracking information. Also make it available via the "TRACK_STA_LIST" control command. Signed-off-by: Kevin Mahoney <k.mahoney@cablelabs.com>
* Remove duplicate dl_list_init() for global_ctrl_dstMichael Braun2016-10-281-2/+0
| | | | | | | | | | | | | | Commit 56885eecf4026b0199d5ba75bd50395a17d323cc ('hostapd: Add UDP support for ctrl_iface') added dl_list_init() for global_ctrl_dst to hostapd_global_ctrl_iface_init(). Though, hostapd_global_ctrl_iface_init() is only called from main.c:main(), which already initializes global_ctrl_dst unconditionally before. Same with global_ctrl_sock. Remove this duplicate initialization. Signed-off-by: Michael Braun <michael-dev@fami-braun.de>
* hostapd_cli: Remove duplicate const in hostapd_cli_cmd()Dmitry Shmidt2016-10-281-1/+1
| | | | Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
* hostapd_cli: Mark number of char *cmd constantJouni Malinen2016-10-161-4/+4
| | | | Signed-off-by: Jouni Malinen <j@w1.fi>
* cli: Add list_sta commandMikael Kanstrup2016-10-161-0/+19
| | | | | | | Add list_sta command to print addresses of all stations. Command added to both wpa_cli and hostapd_cli. Signed-off-by: Mikael Kanstrup <mikael.kanstrup@sonymobile.com>
* hostapd_cli: Process events received following control iface commandsMikael Kanstrup2016-10-161-0/+2
| | | | | | | | | | | Events received as an immediate result of control interface commands end up on the control request message callback function instead of the registered read socket. This makes for example the station list used for complete functions for disassociate and deauthenticate out of sync. Process events in the message callback function too to ensure no events are missed. Signed-off-by: Mikael Kanstrup <mikael.kanstrup@sonymobile.com>
* hostapd_cli: Refactor control iface reconnects with common helperMikael Kanstrup2016-10-161-45/+38
| | | | | | | | Code for connecting/reconnecting to the hostapd control interface is found duplicated a number of times. Create a common reconnect helper function to avoid code duplication. Signed-off-by: Mikael Kanstrup <mikael.kanstrup@sonymobile.com>
* hostapd_cli: Refresh stations list on control interface reconnectMikael Kanstrup2016-10-161-4/+27
| | | | | | | | | Whenever reconnecting the control interface the hostapd station list is unknown as stations might have dropped or connected. Refresh the list of stations used for command completion on cli connect, reconnect and interface change. Signed-off-by: Mikael Kanstrup <mikael.kanstrup@sonymobile.com>
* hostapd_cli: Add completion for sta commandMikael Kanstrup2016-10-161-1/+16
| | | | Signed-off-by: Mikael Kanstrup <mikael.kanstrup@sonymobile.com>
* hostapd_cli: Enable command completion and history for AndroidMikael Kanstrup2016-10-162-0/+6
| | | | Signed-off-by: Mikael Kanstrup <mikael.kanstrup@sonymobile.com>
* hostapd_cli: Add support for cli history fileMikael Kanstrup2016-10-161-2/+19
| | | | Signed-off-by: Mikael Kanstrup <mikael.kanstrup@sonymobile.com>
* hostapd: Add CONFIG_WPA_CLI_EDIT to defconfigMikael Kanstrup2016-10-161-0/+4
| | | | | | | As hostapd_cli now supports command completion add documentation of the config option to defconfig. Disabled per default. Signed-off-by: Mikael Kanstrup <mikael.kanstrup@sonymobile.com>
* Check for NULL qsort() base pointersJoel Cunningham2016-10-151-1/+2
| | | | | | | | | | There are a couple of places in wpa_supplicant/hostapd where qsort() can be called with a NULL base pointer. This results in undefined behavior according to the C standard and with some standard C libraries (ARM RVCT 2.2) results in a data abort/memory exception. Fix this by skipping such calls since there is nothing needing to be sorted. Signed-off-by: Joel Cunningham <joel.cunningham@me.com>
* FILS: Use AEAD cipher to check received EAPOL-Key frames (AP)Jouni Malinen2016-10-102-0/+8
| | | | | | | | | | | | This changes 4-way handshake authenticator processing to decrypt the EAPOL-Key frames using an AEAD cipher (AES-SIV with FILS AKMs) before processing the Key Data field. This replaces Key MIC validation for the cases where AEAD cipher is used. This needs to move the EAPOL-Key msg 2/4 RSN element processing to happen only after the PTK has been derived and validated. That is done for all AKMs to avoid extra complexity with having to maintain two code paths for this. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
* FILS: Add hostapd configuration optionsJouni Malinen2016-10-106-0/+82
| | | | | | | This adds CONFIG_FILS=y build configuration option and new key management options for FILS authentication. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
* FT: Allow PMK-R0 and PMK-R1 for FT-PSK to be generated locallyMichael Braun2016-10-092-0/+10
| | | | | | | | | | | | | | | | | | Station should be able to connect initially without ft_pmk_cache filled, so the target AP has the PSK available and thus the same information as the origin AP. Therefore neither caching nor communication between the APs with respect to PMK-R0 or PMK-R1 or VLANs is required if the target AP derives the required PMKs locally. This patch introduces the generation of the required PMKs locally for FT-PSK. Additionally, PMK-R0 is not stored (and thus pushed) for FT-PSK. So for FT-PSK networks, no configuration of inter-AP communication is needed anymore when using ft_psk_generate_local=1 configuration. The default behavior (ft_psk_generate_local=0) remains to use the pull/push protocol. Signed-off-by: Michael Braun <michael-dev@fami-braun.de>
* Change version number to v2.6 for the releasehostap_2_6Jouni Malinen2016-10-021-1/+1
| | | | Signed-off-by: Jouni Malinen <j@w1.fi>
* Update ChangeLog files for v2.6Jouni Malinen2016-09-251-2/+20
| | | | | | This adds a summary of new changes since the last update. Signed-off-by: Jouni Malinen <j@w1.fi>
* Passive Client TaxonomyDenton Gentry2016-09-214-0/+36
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Implement the signature mechanism described in the paper "Passive Taxonomy of Wifi Clients using MLME Frame Contents" published by Denton Gentry and Avery Pennarun. http://research.google.com/pubs/pub45429.html https://arxiv.org/abs/1608.01725 This involves: 1. Add a CONFIG_TAXONOMY compile option. Enabling taxonomy incurs a memory overhead of up to several kilobytes per associated station. 2. If enabled, store the Probe Request and (Re)Associate Request frame in struct sta_info. 3. Implement code to extract the ID of each Information Element, plus selected fields and bitmasks from certain IEs, into a descriptive text string. This is done in a new source file, src/ap/taxonomy.c. 4. Implement a "signature qq:rr:ss:tt:uu:vv" command in hostapd_cli to retrieve the signature. Signatures take the form of a text string. For example, a signature for the Nexus 5X is: wifi4|probe:0,1,127,45,191,htcap:01ef,htagg:03,htmcs:0000ffff,vhtcap:338061b2, vhtrxmcs:030cfffa,vhttxmcs:030cfffa,extcap:00000a0201000040|assoc:0,1,48,45, 221(0050f2,2),191,127,htcap:01ef,htagg:03,htmcs:0000ffff,vhtcap:339071b2, vhtrxmcs:030cfffa,vhttxmcs:030cfffa,extcap:0000000000000040 Signed-off-by: dgentry@google.com (Denton Gentry) Signed-off-by: denny@geekhold.com (Denton Gentry) Signed-off-by: rofrankel@google.com (Richard Frankel) Signed-off-by: richard@frankel.tv (Richard Frankel)