path: root/wpa_supplicant/notify.c
Commit message (Collapse)AuthorAgeFilesLines
* PASN: Support PASN with SAE key derivationIlan Peer31 hours1-0/+5
| | | | Signed-off-by: Ilan Peer <ilan.peer@intel.com>
* Extend server certificate TOD policy reporting to include TOD-TOFUJouni Malinen2019-08-161-2/+3
| | | | | | | | | The previously used single TOD policy was split into two policies: TOD-STRICT and TOD-TOFU. Report these separately in the CTRL-EVENT-EAP-PEER-CERT events (tod=1 for TOD-STRICT and tod=2 for TOD-TOFU). Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
* Remove useless NULL comparison for an arrayJouni Malinen2019-07-071-8/+5
| | | | | | | | | Now that the TLS peer_cert information is provided as a full struct to handler functions, the altsubject pointer shows up as an array and causes static analyzers to warn about unnecessary NULL comparison. Get rid of that comparison now that it is clearly not needed anymore. Signed-off-by: Jouni Malinen <j@w1.fi>
* Report TOD policy in peer certificate eventsJouni Malinen2019-06-141-2/+3
| | | | | | | Add tod=1 to CTRL-EVENT-EAP-PEER-CERT events if the peer certificate includes the TOD policy in the X.509v3 Certificate Policies extension. Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
* Pass full struct to peer certificate callbacksJouni Malinen2019-06-141-15/+17
| | | | | | | | This makes it easier to add new information to the callbacks without having to modify each callback function type in EAPOL and EAP code every time. Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
* Replace int status/reason_code with u16 variableJouni Malinen2019-04-221-2/+2
| | | | | | | | | These cases are for the IEEE 802.11 Status Code and Reason Code and those fields are unsigned 16 bit values, so use the more appropriate type consistently. This is mainly to document the uses and to make the source code easier to understand. Signed-off-by: Jouni Malinen <j@w1.fi>
* wpa_supplicant: Drop the old D-Bus interface supportLubomir Rintel2019-03-091-26/+4
| | | | | | | | | | | | This drops support for the fi.epitest.hostap.WPASupplicant D-Bus name along with the associated CONFIG_CTRL_IFACE_DBUS option. Nothing should really be using this since 2010. This is a just a straightforward removal. Perhaps the dbus_common.c and dbus_new.c can be merged now. Also, the "_NEW" suffix of the config option seems to make even less sense than it used to. Signed-off-by: Lubomir Rintel <lkundrak@v3.sk>
* dbus: Expose authentication status to D-BusAlex Khouderchah2019-01-021-0/+9
| | | | | | | | | | | wpa_supplicant currently logs CTRL-EVENT-AUTH-FAILED errors when authentication fails, but doesn't expose any property to the D-Bus interface related to this. This change adds the "AuthStatusCode" property to the interface, which contains the IEEE 802.11 status code of the last authentication. Signed-off-by: Alex Khouderchah <akhouderchah@chromium.org>
* dbus: Export BSS Transition Management statusMatthew Wang2019-01-021-0/+9
| | | | | | | | Add new Interface properties "BSSTMStatus", which carries the status of the most recent BSS Transition Management request. This property will be logged in UMA to measure 802.11v success. Signed-off-by: Matthew Wang <matthewmwang@chromium.org>
* dbus: Export roam time, roam complete, and session lengthMatthew Wang2019-01-021-0/+27
| | | | | | | | | | | Add new Interface properties "RoamTime", "RoamComplete", and "SessionLength". "RoamTime" carries the roam time of the most recent roam in milliseconds. "RoamComplete" carries True or False corresponding to the success status of the most recent roam. "SessionLength" carries the number of milliseconds corresponding to how long the connection to the last AP was before a roam or disconnect happened. Signed-off-by: Matthew Wang <matthewmwang@chromium.org>
* dbus: Expose connected stations on D-BusAndrej Shadura2018-12-231-0/+6
| | | | | | | | | | | | | | | | Make it possible to list connected stations in AP mode over D-Bus, along with some of their properties: rx/tx packets, bytes, capabilities, etc. Signed-off-by: Mathieu Trudel-Lapierre <mathieu.trudel-lapierre@canonical.com> Rebased by Julian Andres Klode <juliank@ubuntu.com> and updated to use the new getter API. Further modified by Andrej Shadura to not error out when not in AP mode and to send separate StationAdded/StationRemoved signals instead of changing signatures of existing StaAuthorized/StaDeauthorized signals. Signed-off-by: Andrej Shadura <andrew.shadura@collabora.co.uk>
* Propagate the EAP method error codeAhmed ElArabawy2018-03-311-0/+6
| | | | | | | | | | | | | | | | | | In the current implementation, upon an EAP method failure, followed by an EAP failure, the EAP Status is propagated up in wpa_supplicant with a general failure parameter string "failure". This parameter is used for a notification on the dbus. This commit reports the EAP method failure error code in a separate callback. The solution in this commit is generic to all EAP methods, and can be used by any method that need to pass its error code. However, this commit only implements the reporting for EAP-SIM and EAP-AKA methods where the Notification Code (in AT_NOTIFICATION) is used as the method specific error code value. Signed-off-by: Ahmed ElArabawy <arabawy@google.com>
* dbus: Add MeshPeerDisconnected signalSaurav Babu2017-09-091-0/+10
| | | | | | This is similar to the control interface event MESH-PEER-DISCONNECTED. Signed-off-by: Saurav Babu <saurav.babu@samsung.com>
* dbus: Add MeshPeerConnected signalSaurav Babu2017-09-091-0/+10
| | | | | | This is similar to the control interface event MESH-PEER-CONNECTED. Signed-off-by: Saurav Babu <saurav.babu@samsung.com>
* dbus: Add MeshGroupRemoved signalSaurav Babu2017-09-091-0/+14
| | | | | | This is similar to the control interface event MESH-GROUP-REMOVED. Signed-off-by: Saurav Babu <saurav.babu@samsung.com>
* dbus: Add MeshGroupStarted signalSaurav Babu2017-09-091-0/+12
| | | | | | | This introduces a new interface for mesh and adds a signal that is similar to the control interface event MESH-GROUP-STARTED. Signed-off-by: Saurav Babu <saurav.babu@samsung.com>
* D-Bus: Send P2P IP address assignment info with GroupStarted eventNishant Chaprana2016-11-211-2/+2
| | | | | | | This commit adds IP address information into GroupStarted event on the P2P client side like it is sent over the control interface. Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
* D-Bus: Remove unused wpas_dbus_signal_p2p_group_started() parameterJouni Malinen2016-05-301-1/+1
| | | | | | The ssid pointer was not used. Signed-off-by: Jouni Malinen <j@w1.fi>
* D-Bus: Indicate whether created group is persistent or notNishant Chaprana2016-05-301-2/+2
| | | | | | | | | This adds an extra parameter in GroupStarted signal to indicate whether the created group is Persistent or not. It is similar to the [PERSISTENT] tag which comes in P2P-GROUP-STARTED over the control interface. Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
* binder: Add binder skeletal code for AndroidRoshan Pius2016-04-021-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | Create the skeletal binder interface for wpa_supplicant. The interface hierarchy is based off the existing dbus interface(https://w1.fi/wpa_supplicant/devel/dbus.html). Since we use libbinder, the binder interface codebase needs to be written in C++ and can only be compiled on Android platform for now. The aidl files define binder RPC interfaces. The Android build system generates the corresponding C++ interface classes which needs to be implemented by the server process. The clients can obtain a reference to the binder service (root object) using: android::String16 service_name("fi.w1.wpa_supplicant"); android::sp<android::IBinder> binder = android::defaultServiceManager()->getService(service_name); Once a reference to the root object is retrieved, the clients can obtain references to other RPC objects using that root object methods. Signed-off-by: Roshan Pius <rpius@google.com>
* D-Bus: Add association response status code property for failure casesNaveen Singh2016-03-061-0/+9
| | | | | | | | | | (Re)Association Response frame with status code other than 0 is now notified over DBUS as a part of PropertiesChanged signal. This can be used by application in case AP is denying association with status code 17 (band steering) so that it does not interfere in the BSSID selection logic of wpa_supplicant. Signed-off-by: Naveen Singh <nasingh@google.com>
* D-Bus: Add InvitationReceived SignalManeesh Jain2015-09-271-0/+10
| | | | | | | | This is equivalent to the P2P_EVENT_INVITATION_RECEIVED signal on the control interface. It can be used to sent the Invitation Received signal to applications written using D-Bus. Signed-off-by: Maneesh Jain <maneesh.jain@samsung.com>
* P2P: Add D-Bus signal GroupFormationFailureNishant Chaprana2015-09-051-0/+8
| | | | | | | This is similar to the control interface event P2P-GROUP-FORMATION-FAILURE. Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
* FST: Integration into wpa_supplicantAnton Nayshtut2015-07-161-0/+11
| | | | | | This commit integrates the FST into the wpa_supplicant. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
* P2P: Fix persistent group profile on manual disabled=2 changeJouni Malinen2015-06-101-0/+2
| | | | | | | | | | | ssid->p2p_persistent_group was left to its old value when changing a network profile to/from P2P persistent group type (disabled=2). This could result in unexpected behavior when using an incomplete persistent group profile. This was mainly visible through D-Bus network profile handling where a persistent group would not be unregistered insome cases. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
* D-Bus: Add WPS pbc-overlap EventAvichal Agarwal2015-06-101-0/+10
| | | | | | | This sends an Event D-Bus signal with name "pbc-overlap" for WPS-EVENT-OVERLAP. Signed-off-by: Avichal Agarwal <avichal.a@samsung.com>
* P2P: Add GO Intent of connecting device in GO Negotiation Request eventMAYANK HAARIT2015-06-061-2/+2
| | | | | | | | | Add GO Intent information of connecting device in GO Negotiation Request event which will help applications to decide its own GO intent value in advance and can avoid failure cases when both devices use GO Intent 15 depending on application requirement. Signed-off-by: Mayank Haarit <mayank.h@samsung.com>
* P2P: Add D-Bus FindStopped to notify P2P-FIND-STOPPED eventNishant Chaprana2015-05-251-0/+7
| | | | | | | Add D-Bus notification mechanism of P2P-FIND-STOPPED event on fi.w1.wpa_supplicant1.Interface.P2PDevice interface. Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
* Fix wpas_notify_network_removed()Jouni Malinen2015-04-291-4/+2
| | | | | | | | | Commit bb3df9a569e4a33445c89ebc50019ba46b4f6704 ('notify: Do not raise any signal from a P2P management interface') was supposed to only change D-Bus behavior, but it ended up disabling non-D-Bus functionality as well for some sequences where the P2P Device interface is used. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
* D-Bus: Fix network block type changeJouni Malinen2015-02-071-0/+19
| | | | | | | | | | | It is possible for a network profile to change its type from P2P persistent group to a normal network and back. The D-Bus interface uses different types of objects for those, so the object needs to re-registered in case of type change. This fixes issues in leaving behind an incorrect type of object and leaking memory when freeing such a network block that has had its disabled parameter changed. Signed-off-by: Jouni Malinen <j@w1.fi>
* Add peer certificate alt subject name information to EAP eventsJouni Malinen2015-01-141-4/+13
| | | | | | | | | | | | | | | A new "CTRL-EVENT-EAP-PEER-ALT depth=<i> <alt name>" event is now used to provide information about server certificate chain alternative subject names for upper layers, e.g., to make it easier to configure constraints on the server certificate. For example: CTRL-EVENT-EAP-PEER-ALT depth=0 DNS:server.example.com Currently, this includes DNS, EMAIL, and URI components from the certificates. Similar information is priovided to D-Bus Certification signal in the new altsubject argument which is a string array of these items. Signed-off-by: Jouni Malinen <j@w1.fi>
* D-Bus: Fix P2P persistent group removal from non-D-Bus triggersJouni Malinen2014-12-291-0/+3
| | | | | | | | | | It is possible for the persistent group object to be added and removed by non-D-Bus triggers (e.g., ctrl_iface commands). The add part was already handled, but removal was not. That resulted in memory leaks when a P2P persistent group was removed without using an explicit D-Bus command for this even if the object was added without D-Bus involvement. Signed-off-by: Jouni Malinen <j@w1.fi>
* D-Bus: Fix P2P peer joined/disconnected handlersJouni Malinen2014-12-291-2/+4
| | | | | | | | | It is possible for the peer to be a non-P2P device and as such, for p2p_dev_addr to be NULL. This resulted in NULL pointer dereference if D-Bus interface was enabled for the interface when a legacy STA joined a group. Signed-off-by: Jouni Malinen <j@w1.fi>
* notify: Do not raise any signal from a P2P management interfaceTomasz Bursztyka2014-10-271-0/+102
| | | | | | | Such interface is not registered on DBus, thus there is no need to raise any signal from it. Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
* Add support for driver command to update roaming policyJouni Malinen2014-09-111-0/+15
| | | | | | | | | | | | | The network block bssid parameter can be used to force a specific BSS to be used for a connection. It is also possible to modify this parameter during an association. Previously, that did not result in any notification to the driver which was somewhat problematic with drivers that take care of BSS selection. Add a new mechanism to allow wpa_supplicant to provide a driver update if the bssid parameter change for the current connection modifies roaming policy (roaming allowed/disallowed within ESS). Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
* dbus: add BSS Age property to indicate last-seen timeDan Williams2014-09-071-0/+6
| | | | | | | | | | | | | | "Age" is the age in seconds since the BSS was last seen, and is emitted as a PropertyChanged signal whenever the BSS is updated from a scan result. It also returns the correct age when queried directly. This property can be used to resolve issues where, if no other properties of the BSS changed from scan results (for example, if the BSS always had 100% signal) no D-Bus signals would be emitted to indicate that the BSS had just been seen in the scan. Signed-hostap: Dan Williams <dcbw@redhat.com>
* dbus: Declare and implement GroupFinished as for GroupStartedTomasz Bursztyka2014-07-311-2/+2
| | | | | | | | First for better concistancy but also to tell about the group_object that is getting removed, thus the client will know about it and will be able to act accordingly. Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
* dbus: Remove GroupMember object type and use Peer insteadTomasz Bursztyka2014-06-291-17/+5
| | | | | | | GroupMember is unusable in itself and all the necessary informations are stored in Peer objects, thus replace the use of GroupMember by Peer. Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
* P2P: Clean up by moving ifdef CONFIG_P2P to p2p_suppplicant.hJouni Malinen2014-06-151-4/+0
| | | | | | | | This removes number of unnecessary #ifdef CONFIG_P2P blocks from generic code by hiding the conditional build into p2p_supplicant.h with empty inline functions. Signed-off-by: Jouni Malinen <j@w1.fi>
* Interworking: Prefer last added network during network selectionJouni Malinen2014-02-251-0/+2
| | | | | | | | | | | | | Previously, any network block could be used to select the BSS to connect to when processing scan results after Interworking network selection. This can result in somewhat unexpected network selection in cases where credential preferences indicated that a specific network was selected, but another network ended up getting used for the connection. While the older networks continue to be valid, add special processing for this initial post-interworking-connect case to get more consistent network selection to match with the Interworking network selection result. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
* Android: Add SSID in supplicant change eventDmitry Shmidt2013-11-171-2/+6
| | | | | | | In addition, change wpa_s->pending_bssid to wpa_s->bssid for the BSSID value in the event. Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
* D-Bus: Do not send network notification for all P2P groupsJouni Malinen2013-08-311-2/+2
| | | | | | | | | Previously, network added event was skipping during group formation. However, this did not necessarily catch all cases of temporary P2P network blocks. Check ssid->p2p_group to make this behavior more consistent by avoiding all P2P groups. Signed-hostap: Jouni Malinen <j@w1.fi>
* D-Bus: Emit signal when a station is authorized or deauthorizedChengyi Zhao2013-06-221-0/+6
| | | | | | | | | | Add "StaAuthorized" and "StaDeauthorized" D-Bus interface in AP mode. After enabling the AP mode of wpa_supplicant, the other process need to get the MAC address and authorization status of every station, so wpa_supplicant emits signal when the station is authorized or deauthorized. Signed-hostap: Chengyi Zhao <chengyix.zhao@gmail.com>
* Provide TLS alerts to CLI/UI over control interfaceChris Hessing2013-04-231-0/+3
| | | | | | | Harmonize EAP status events over control interface to provide same functionality as existing D-Bus callback. Signed-hostap: Chris Hessing <chris.hessing@cloudpath.net>
* dbus: Add getter for WPS propertiesSven Neumann2012-11-031-0/+3
| | | | | | | Add "WPS" property to the DBus interface that allows to identify the active WPS method of a BSS. Signed-hostap: Sven Neumann <s.neumann@raumfeld.com>
* Export disconnect reason code to dbusGary Morain2012-06-301-0/+6
| | | | | | | | | | | In the properties changed signal, added a new property "DisconnectReason", which carries the IEEE 802.11 reason code of the most recent disassociation or deauthentication event. The reason code is negative if it is locally generated. The property is sent to the DBUS immediately so as to prevent it from being coalesced with other disconnect events. Signed-off-by: Gary Morain <gmorain@chromium.org>
* wpa_supplicant: Report EAP connection progress to DBusPaul Stewart2012-06-041-0/+7
| | | | | | | | | | | | | | | | | | | | | Send an "EAP" signal via the new DBus interface under various conditions during EAP authentication: - During method selection (ACK and NAK) - During certificate verification - While sending and receiving TLS alert messages - EAP success and failure messages This provides DBus callers a number of new tools: - The ability to probe an AP for available EAP methods (given an identity). - The ability to identify why the remote certificate was not verified. - The ability to identify why the remote peer refused a TLS connection. Signed-hostap: Paul Stewart <pstew@chromium.org>
* P2P: Notify about disconnection only when neededEliad Peller2012-04-011-1/+1
| | | | | | | | | | wpas_notify_state_changed() notified about disconnection when new_state < WPA_ASSOCIATED, without checking the old state. This results in extra processing which can be avoided by checking that old_state was connected. Signed-hostap: Eliad Peller <eliad@wizery.com> intended-for: hostap-1
* DBus: Add ability to report probe requestsJohannes Berg2012-04-011-0/+10
| | | | | | | | | | | | | | | | Some applications require knowing about probe requests to identify devices. This can be the case in AP mode to see the devices before they connect, or even in P2P mode when operating as a P2P device to identify non-P2P peers (P2P peers are identified via PeerFound signals). As there are typically a lot of probe requests, require that an interested application subscribes to this signal so the bus isn't always flooded with these notifications. The notifications in DBus are then unicast only to that application. A small test script is also included. Signed-hostap: Johannes Berg <johannes.berg@intel.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>