aboutsummaryrefslogtreecommitdiffstats
path: root/hostapd/ctrl_iface.c
Commit message (Collapse)AuthorAgeFilesLines
* hostapd: enable dynamic modification of acl policyNadim Zubidat2012-11-061-0/+42
| | | | | | | | | add APIs for dynamically changing the macaddr_acl policy and mac addresses lists. once changed, hostapd will deauth stations which do not pass the new policy. Signed-off-by: Nadim Zubidat <nadimz@ti.com>
* hostapd: add support for android created sockets (/dev/socket/)Yotam Rubin2012-08-021-0/+14
| | | | | | | | | | | | | | | | Add the same support that wpa_supplicant has with sockets created by the Android system using the init.rc services options Just as the supplicant, if the ctrl_iface is a name and not a path (i.e. doesn't start with '/') the hostapd will assume that this is an Android created socket named wpa_$(ctrl_iface) which is opened in /dev/socket/ hostapd_cli sockets will be created in /data/misc/wifi/sockets The hardcoded configuration is set in the Android.mk of hostapd just like it is with the supplicant. In addition, the hostapd_cli needs an Android property by the name ap.interface to hold the ctrl_iface name to connect to the hostapd's socket.
* WPS: Add support for NCF password token from APJouni Malinen2012-06-281-0/+49
| | | | | | | | | | | | | | | | The new hostapd ctrl_iface command WPS_NFC_TOKEN can now be used to manage AP-as-Enrollee operations with NFC password token. WPS/NDEF parameters to this command can be used to generate a new NFC password token. enable/disable parameters can be used to enable/disable use of NFC password token (instead of AP PIN) for external Registrars. A preconfigured NFS password token can be used by providing its parameters with new hostapd.conf fields wps_nfc_dev_pw_id, wps_nfc_dh_pubkey, wps_nfc_dh_privkey, and wps_nfc_dev_pw. This use will also depend on WPS_NFC_TOKEN enable/disable commands, i.e., the configured NFS password token is disabled by default. Signed-hostap: Jouni Malinen <j@w1.fi>
* WPS: Add new mechanism for generation NFC configuration tokenJouni Malinen2012-06-281-0/+33
| | | | | | | | The new hostapd ctrl_iface command WPS_NFC_CONFIG_TOKEN can now be used to fetch payload for an NFC configuration token so that an external program can be used to write this on an NFC tag. Signed-hostap: Jouni Malinen <j@w1.fi>
* WPS: Add new mechanism for communicating NFC tag read eventsJouni Malinen2012-06-271-1/+35
| | | | | | | | | | | hostapd ctrl_iface can now be used to deliver payload from read operation of an NFC tag. This allows operations without having to have low-level NFC code within hostapd. For now, the new wps_nfc_tag_read command can be used with NFC password tokens for the case where the AP has an NFC device that is used to read an NFC tag from the station Enrollee. Signed-hostap: Jouni Malinen <j@w1.fi>
* Make bind failure messages uniqueBen Greear2012-04-061-1/+1
| | | | | | This helps someone know which part of the code is complaining. Signed-hostap: Ben Greear <greearb@candelatech.com>
* Add wps_cancel for hostapd_cliAnirban Sirkhell2012-03-301-0/+3
| | | | | | | Implement wps_cancel for hostapd similarly to how it was already supported in wpa_supplicant AP mode. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
* Interworking: Add GAS server support for AP modeJay Katabathuni2012-02-261-0/+8
| | | | | | | | | | | This adds GAS/ANQP implementation into hostapd. This commit brings in the basic GAS/ANQP functionality, but only the ANQP Capability List element is supported. For testing purposes, hostapd control interface SET command can be used to set the gas_frag_limit parameter dynamically. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
* Add wpa_supplicant AP mode STA deauthenticate/disassociate commandsJithu Jance2012-02-251-167/+0
| | | | | | | | Move disassociate and deauthenticate commands to ctrl_iface_ap.c, so that they ares accessible for wpa_supplicant AP mode and wpa_cli (with CONFIG_AP option enabled). Signed-hostap: Jithu Jance <jithu@broadcom.com>
* hostapd: Make sure ctrl_iface is not initialized multiple timesShan Palanisamy2012-02-161-1/+4
| | | | Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
* hostapd: Allow config parameters to be set through ctrl_ifaceShan Palanisamy2012-02-161-1/+2
| | | | Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
* Remove the GPL notification from files contributed by Jouni MalinenJouni Malinen2012-02-111-8/+2
| | | | | | | Remove the GPL notification text from the files that were initially contributed by myself. Signed-hostap: Jouni Malinen <j@w1.fi>
* AP: Convert some wpa_printf to wpa_msg/dbgBen Greear2011-12-101-5/+7
| | | | | | | This generates better log messages when running multiple interfaces in one process. Signed-off-by: Ben Greear <greearb@candelatech.com>
* Allow MLME frames to be sent without expecting an ACK (no retries)Helmut Schaa2011-11-191-1/+1
| | | | | | | | | | In some situations it might be benefical to send a unicast frame without the need for getting it ACKed (probe responses for example). In order to achieve this add a new noack parameter to the drivers send_mlme callback that can be used to advise the driver to not wait for an ACK for this frame. Signed-hostap: Helmut Schaa <helmut.schaa@googlemail.com>
* Remove unused header file inclusionJouni Malinen2011-11-171-1/+0
| | | | Signed-hostap: Jouni Malinen <j@w1.fi>
* WNM: Add BSS Transition Management Request for ESS Disassoc ImminentJouni Malinen2011-10-161-0/+54
| | | | | | | "hostapd_cli ess_disassoc (STA addr) (URL)" can now be used to send an ESS Dissassociation Imminent notification to the STA. This event is shown in wpa_supplicant ctrl_iface monitors (e.g., wpa_cli): "WNM: ESS Disassociation Imminent - session_info_url=http://example.com/session/"
* P2P: Allow WPS_PBC command on GO to select on P2P Device AddressJouni Malinen2011-02-071-1/+1
| | | | | | | | | | | | | | An optional parameter, p2p_dev_addr, can now be given to WPS_PBC command on P2P GO to indicate that only the P2P device with the specified P2P Device Address is allowed to connect using PBC. If any other device tries to use PBC, a session overlap is indicated and the negotiation is rejected with M2D. The command format for specifying the address is "WPS_PBC p2p_dev_addr=<address>", e.g., WPS_PBC p2p_dev_addr=02:03:04:05:06:07 In addition, show the PBC session overlap indication as a WPS failure event on an AP/GO interface. This particular new case shows up as "WPS-FAIL msg=4 config_error=12".
* hostapd: Allow logging to fileBen Greear2011-02-061-0/+3
| | | | | | Also supports 'relog' CLI command to re-open the log file. Signed-off-by: Ben Greear <greearb@candelatech.com>
* hostapd_driver_ops reductionJouni Malinen2010-11-241-2/+3
| | | | | set_sta_vlan, get_inact_sec, sta_deauth, sta_disassoc, and sta_remove to use inline functions instead of extra abstraction.
* Drop local stations on broadcast deauth/disassoc requestJouni Malinen2010-11-101-0/+4
| | | | | | When hostapd_cli deauth/disassoc is used with ff:ff:ff:ff:ff:ff address, drop all local STA entries in addition to sending out the broadcast deauth/disassoc frame.
* Add ctrl_iface command 'GET version'Jouni Malinen2010-10-311-1/+23
| | | | | This can be used to fetch the wpa_supplicant/hostapd version string.
* hostapd: Add wps_config ctrl_interface command for configuring APJouni Malinen2010-10-211-0/+30
| | | | | | This command can be used to configure the AP using the internal WPS registrar. It works in the same way as new AP settings received from an ER.
* WPS: Update Beacon/ProbeResp IE on wps_version_number changesJouni Malinen2010-10-191-1/+2
| | | | | | This test command is supposed to change the WPS version number in all places immediately, so make sure that the IEs used in management frames get updated immediately.
* Fix hostapd_cli get_config not to show key when WPA is disabledJouni Malinen2010-10-081-4/+6
| | | | | Previously, incorrectly configured passphrase or group cipher type could be shown even if WPA was disabled.
* Mark ctrl_iface RX debug for PING commands excessiveJouni Malinen2010-09-241-1/+4
| | | | | | This cleans up debug log from unnecessary entries when using wpa_cli/hostapd_cli or other ctrl_iface monitors that PING periodically to check connectivity.
* WPS: Add hostapd_cli get_config commandJouni Malinen2010-09-231-0/+169
| | | | This can be used by a WPS UI to display the current AP configuration.
* WPS: Add wps_check_pin command for processing PIN from user inputJouni Malinen2010-09-231-0/+49
| | | | | UIs can use this command to process a PIN entered by a user and to validate the checksum digit (if present).
* WPS: Make testing operations configurable at runtimeJouni Malinen2010-09-211-0/+44
| | | | | | | | | | | | | | | | | | | Instead of build time options (CONFIG_WPS_TESTING_EXTRA_CRED and CONFIG_WPS_EXTENSIBILITY_TESTING), use a single build option (CONFIG_WPS_TESTING) and runtime configuration of which testing operations are enabled. This allows a single binary to be used for various tests. The runtime configuration can be done through control interface with wpa_cli/hostapd_cli commands: Enable extensibility tests: set wps_version_number 0x57 Disable extensibility tests (WPS2 build): set wps_version_number 0x20 Enable extra credential tests: set wps_testing_dummy_cred 1 Disable extra credential tests: set wps_testing_dummy_cred 0
* P2P: Add preliminary P2P Manager AP support for hostapdJouni Malinen2010-09-091-0/+69
|
* WPS 2.0: Add support for AuthorizedMACs attributeJouni Malinen2010-09-091-1/+9
| | | | | | | | | | Advertize list of authorized enrollee MAC addresses in Beacon and Probe Response frames and use these when selecting the AP. In order to provide the list, the enrollee MAC address should be specified whenever adding a new PIN. In addition, add UUID-R into SetSelectedRegistrar action to make it potentially easier for an AP to figure out which ER sent the action should there be multiple ERs using the same IP address.
* WPS: Add support for dynamic AP PIN managementJouni Malinen2010-08-241-0/+56
| | | | | | | | | A new hostapd_cli command, wps_ap_pin, can now be used to manage AP PIN at runtime. This can be used to generate a random AP PIN and to only enable the AP PIN for short period (e.g., based on user action on the AP device). Use of random AP PIN that is only enabled for short duration is highly recommended to avoid security issues with a static AP PIN.
* Fix a typo in Disassociation frame buildingJouni Malinen2010-07-171-1/+1
| | | | | This did not really change any behavior since Deauthentication frame uses the same format.
* Add test commands for sending deauth/disassoc without dropping stateJouni Malinen2010-03-291-0/+50
| | | | | | | | | | | This can be used to test 802.11w by sending a protected or unprotected deauth/disassoc frame. hostapd_cli deauth <dst addr> test=<0/1> hostapd_cli disassoc <dst addr> test=<0/1> test=0: unprotected test=1: protected
* Add deauthenticate/disassociate ctrl_iface commandsJouni Malinen2010-03-291-0/+48
|
* Verify that os_get_random() success for SA Query idJouni Malinen2010-01-101-2/+2
|
* Include header files explicitly in *.c, not via header filesJouni Malinen2009-12-261-0/+1
|
* Rename some src/ap files to avoid duplicate file namesJouni Malinen2009-12-261-6/+6
| | | | | | Doxygen and some build tools may get a bit confused about same file name being used in different directories. Clean this up a bit by renaming some of the duplicated file names in src/ap.
* Move ctrl_iface_ap.c into src/apJouni Malinen2009-12-251-1/+1
|
* Move wps_hostapd.c into src/apJouni Malinen2009-12-251-1/+1
|
* Move generic AP functionality implementation into src/apJouni Malinen2009-12-251-8/+8
| | | | | | | | | | This code can be shared by both hostapd and wpa_supplicant and this is an initial step in getting the generic code moved to be under the src directories. Couple of generic files still remain under the hostapd directory due to direct dependencies to files there. Once the dependencies have been removed, they will also be moved to the src/ap directory to allow wpa_supplicant to be built without requiring anything from the hostapd directory.
* Remove conditional no-RADIUS build from src/radiusJouni Malinen2009-12-061-0/+2
| | | | | Make it responsibility of the src/radius user to handle conditional build rules.
* Conver hostapd specific files to include common.hJouni Malinen2009-11-291-0/+1
| | | | | | Instead of getting this via hostapd.h, include it as the first non-system header file in all source code files in the same way as used in all other files.
* Fix hostapd wpa_msg() calls ctx for wpa_supplicant AP modeJouni Malinen2009-09-291-0/+1
| | | | Need to use wpa_s pointer, not hapd pointer, for these calls.
* Move STA list ctrl_iface handlers to a separate fileJouni Malinen2009-09-081-82/+1
| | | | | This makes it easier to share the hostapd station table query functionality with wpa_supplicant AP mode operations.
* WPS: Store device info and make it available through AP ctrl_ifaceJouni Malinen2009-09-071-0/+4
| | | | | | | | Store a copy of device attributes during WPS protocol run and make it available for external programs via the control interface STA MIB command for associated stations. This gives access to device name and type which can be useful when showing user information about associated stations.
* Replace NEED_MLME with NEED_AP_MLMEJohannes Berg2009-08-141-4/+4
| | | | | This makes it clearer that it's about the AP, not client-side MLME, even when built into the client (wpa_supplicant).
* WPS: Add support for setting timeout for PINJouni Malinen2009-05-261-1/+12
| | | | | | | hostapd_cli wps_pin command can now have an optional timeout parameter that sets the PIN lifetime in seconds. This can be used to reduce the likelihood of someone else using the PIN should an active PIN be left in the Registrar.
* Add code to re-use an existing ctrl_iface socket fileJouni Malinen2009-05-061-2/+29
| | | | | | Port the code from wpa_supplicant to re-use an existing ctrl_iface socket file if the file does not seem to be in use. This allows hostapd to recover from unclean shutdown of the control interface.
* Merge wpa_supplicant and hostapd driver wrapper implementationsJouni Malinen2009-04-091-1/+5
| | | | | | | | This commit merges the driver_ops structures and implementations from hostapd/driver*.[ch] into src/drivers. This is only an initial step and there is room for number of cleanups to share code between the hostapd and wpa_supplicant parts of the wrappers to avoid unnecessary source code duplication.
* Fix UNIX domain socket address handling to be more portableJouni Malinen2009-03-211-8/+19
| | | | | | Remove all fields before sun_path before printing or comparing sun_path contents. Using offsetof should be portable. In addition, set sun_len for FreeBSD.