summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--debian/changelog8
-rwxr-xr-xdebian/get-orig-source6
-rw-r--r--debian/patches/dbus-available-sta.patch120
-rw-r--r--wpa_supplicant/dbus/dbus_new.c45
4 files changed, 45 insertions, 134 deletions
diff --git a/debian/changelog b/debian/changelog
index 2d9b8fc..13c520d 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,11 @@
+wpa (2:2.6-17) unstable; urgency=medium
+
+ * Fix get-orig-source so that it can produce pre-release snapshots.
+ * Remove dbus changes to StaAuthorized/StaDeauthorized after discussions
+ with the upstream.
+
+ -- Andrej Shadura <andrewsh@debian.org> Fri, 08 Jun 2018 14:30:54 +0200
+
wpa (2:2.6-16) unstable; urgency=medium
* Fix README.Debian: MyNetWork, not NETBEER (Closes: #791333).
diff --git a/debian/get-orig-source b/debian/get-orig-source
index 89d0b41..bdbda55 100755
--- a/debian/get-orig-source
+++ b/debian/get-orig-source
@@ -17,11 +17,11 @@ fi
DEB_VER="$(echo ${VERSION} | sed 's,\-[0-9a-z\~\.]*,,')"
UP_VER="$(echo ${DEB_VER} | sed 's,\~,\-,g')"
-SNAPDATE="$(echo ${DEB_VER} | sed 's/.*\+git\([0-9]*\).*/\1/')"
+SNAPDATE="$(echo ${DEB_VER} | sed 's/.*[+~]git\([0-9]*\).*/\1/')"
case "${UP_VER}" in
-*+git[0-9\.]*+*)
- UP_VER_TAG="$(echo $UP_VER | sed 's,.*+git[0-9\.]*+,,')"
+*[+-]git[0-9\.]*+*)
+ UP_VER_TAG="$(echo $UP_VER | sed 's,.*[+-]git[0-9\.]*+,,')"
;;
*)
UP_VER_TAG="hostap_$(echo $UP_VER | sed -e 's,\.,_,g' -e 's,\-,_,g')"
diff --git a/debian/patches/dbus-available-sta.patch b/debian/patches/dbus-available-sta.patch
index 717e895..023644b 100644
--- a/debian/patches/dbus-available-sta.patch
+++ b/debian/patches/dbus-available-sta.patch
@@ -31,86 +31,7 @@ Signed-off-by: Andrej Shadura <andrewsh@debian.org>
#ifdef CONFIG_AP /* until needed by something else */
-@@ -878,15 +879,19 @@ void wpas_dbus_signal_eap_status(struct wpa_supplicant *wpa_s,
- * Notify listeners about event related with station
- */
- static void wpas_dbus_signal_sta(struct wpa_supplicant *wpa_s,
-- const u8 *sta, const char *sig_name)
-+ const u8 *sta, const char *sig_name,
-+ int properties)
- {
- struct wpas_dbus_priv *iface;
- DBusMessage *msg;
-- char sta_mac[WPAS_DBUS_OBJECT_PATH_MAX];
-- char *dev_mac;
-+ DBusMessageIter iter;
-+ char sta_obj_path[WPAS_DBUS_OBJECT_PATH_MAX];
-+ char *path;
-
-- os_snprintf(sta_mac, WPAS_DBUS_OBJECT_PATH_MAX, MACSTR, MAC2STR(sta));
-- dev_mac = sta_mac;
-+ os_snprintf(sta_obj_path, WPAS_DBUS_OBJECT_PATH_MAX,
-+ "%s/" WPAS_DBUS_NEW_STAS_PART "/" COMPACT_MACSTR,
-+ wpa_s->dbus_new_path, MAC2STR(sta));
-+ path = sta_obj_path;
-
- iface = wpa_s->global->dbus;
-
-@@ -899,15 +904,28 @@ static void wpas_dbus_signal_sta(struct wpa_supplicant *wpa_s,
- if (msg == NULL)
- return;
-
-- if (dbus_message_append_args(msg, DBUS_TYPE_STRING, &dev_mac,
-- DBUS_TYPE_INVALID))
-- dbus_connection_send(iface->con, msg, NULL);
-- else
-- wpa_printf(MSG_ERROR, "dbus: Failed to construct signal");
-+ dbus_message_iter_init_append(msg, &iter);
-+ if (!dbus_message_iter_append_basic(&iter, DBUS_TYPE_OBJECT_PATH,
-+ &path))
-+ goto err;
-+
-+ if (properties) {
-+ if (!wpa_dbus_get_object_properties(iface, path,
-+ WPAS_DBUS_NEW_IFACE_STA,
-+ &iter))
-+ goto err;
-+ }
-+
-+ wpa_printf(MSG_DEBUG, "dbus: Station MAC address '" MACSTR "' '%s'",
-+ MAC2STR(sta), sig_name);
-+
-+ dbus_connection_send(iface->con, msg, NULL);
- dbus_message_unref(msg);
-+ return;
-
-- wpa_printf(MSG_DEBUG, "dbus: Station MAC address '%s' '%s'",
-- sta_mac, sig_name);
-+err:
-+ wpa_printf(MSG_ERROR, "dbus: Failed to construct signal");
-+ dbus_message_unref(msg);
- }
-
-
-@@ -921,7 +939,7 @@ static void wpas_dbus_signal_sta(struct wpa_supplicant *wpa_s,
- void wpas_dbus_signal_sta_authorized(struct wpa_supplicant *wpa_s,
- const u8 *sta)
- {
-- wpas_dbus_signal_sta(wpa_s, sta, "StaAuthorized");
-+ wpas_dbus_signal_sta(wpa_s, sta, "StaAuthorized", TRUE);
- }
-
-
-@@ -935,7 +953,7 @@ void wpas_dbus_signal_sta_authorized(struct wpa_supplicant *wpa_s,
- void wpas_dbus_signal_sta_deauthorized(struct wpa_supplicant *wpa_s,
- const u8 *sta)
- {
-- wpas_dbus_signal_sta(wpa_s, sta, "StaDeauthorized");
-+ wpas_dbus_signal_sta(wpa_s, sta, "StaDeauthorized", FALSE);
- }
-
-
-@@ -1992,6 +2010,9 @@ void wpas_dbus_signal_prop_changed(struct wpa_supplicant *wpa_s,
+@@ -1992,6 +1993,9 @@
case WPAS_DBUS_PROP_BSSS:
prop = "BSSs";
break;
@@ -120,11 +41,10 @@ Signed-off-by: Andrej Shadura <andrewsh@debian.org>
case WPAS_DBUS_PROP_CURRENT_AUTH_MODE:
prop = "CurrentAuthMode";
break;
-@@ -2084,6 +2105,39 @@ void wpas_dbus_bss_signal_prop_changed(struct wpa_supplicant *wpa_s,
- }
+@@ -2085,6 +2089,39 @@
-+/**
+ /**
+ * wpas_dbus_sta_signal_prop_changed - Signals change of STA property
+ * @wpa_s: %wpa_supplicant network interface data
+ * @property: indicates which property has changed
@@ -157,10 +77,11 @@ Signed-off-by: Andrej Shadura <andrewsh@debian.org>
+ wpa_dbus_mark_property_changed(wpa_s->global->dbus, path,
+ WPAS_DBUS_NEW_IFACE_STA, prop);
+}
- /**
++/**
* wpas_dbus_signal_debug_level_changed - Signals change of debug param
* @global: wpa_global structure
-@@ -2698,6 +2752,164 @@ err:
+ *
+@@ -2698,6 +2735,164 @@
}
@@ -325,7 +246,7 @@ Signed-off-by: Andrej Shadura <andrewsh@debian.org>
static const struct wpa_dbus_method_desc wpas_dbus_interface_methods[] = {
{ "Scan", WPAS_DBUS_NEW_IFACE_INTERFACE,
(WPADBusMethodHandler) wpas_dbus_handler_scan,
-@@ -3267,6 +3479,10 @@ static const struct wpa_dbus_property_desc wpas_dbus_interface_properties[] = {
+@@ -3267,6 +3462,10 @@
NULL,
NULL
},
@@ -349,7 +270,7 @@ Signed-off-by: Andrej Shadura <andrewsh@debian.org>
#include "dbus_new_helpers.h"
#include "dbus_new.h"
#include "dbus_new_handlers.h"
-@@ -3571,6 +3575,315 @@ dbus_bool_t wpas_dbus_setter_iface_global(
+@@ -3571,6 +3575,315 @@
}
@@ -667,7 +588,7 @@ Signed-off-by: Andrej Shadura <andrewsh@debian.org>
{
--- a/wpa_supplicant/dbus/dbus_new_handlers.h
+++ b/wpa_supplicant/dbus/dbus_new_handlers.h
-@@ -22,6 +22,11 @@ struct bss_handler_args {
+@@ -22,6 +22,11 @@
unsigned int id;
};
@@ -679,7 +600,7 @@ Signed-off-by: Andrej Shadura <andrewsh@debian.org>
dbus_bool_t wpas_dbus_simple_property_getter(DBusMessageIter *iter,
const int type,
const void *val,
-@@ -159,6 +164,15 @@ DECLARE_ACCESSOR(wpas_dbus_getter_networks);
+@@ -159,6 +164,15 @@
DECLARE_ACCESSOR(wpas_dbus_getter_pkcs11_engine_path);
DECLARE_ACCESSOR(wpas_dbus_getter_pkcs11_module_path);
DECLARE_ACCESSOR(wpas_dbus_getter_blobs);
@@ -705,7 +626,7 @@ Signed-off-by: Andrej Shadura <andrewsh@debian.org>
struct wpa_global;
struct wpa_supplicant;
-@@ -28,6 +29,7 @@ enum wpas_dbus_prop {
+@@ -28,6 +29,7 @@
WPAS_DBUS_PROP_CURRENT_NETWORK,
WPAS_DBUS_PROP_CURRENT_AUTH_MODE,
WPAS_DBUS_PROP_BSSS,
@@ -713,7 +634,7 @@ Signed-off-by: Andrej Shadura <andrewsh@debian.org>
WPAS_DBUS_PROP_DISCONNECT_REASON,
WPAS_DBUS_PROP_ASSOC_STATUS_CODE,
};
-@@ -45,6 +47,10 @@ enum wpas_dbus_bss_prop {
+@@ -45,6 +47,10 @@
WPAS_DBUS_BSS_PROP_AGE,
};
@@ -724,7 +645,7 @@ Signed-off-by: Andrej Shadura <andrewsh@debian.org>
#define WPAS_DBUS_OBJECT_PATH_MAX 150
#define WPAS_DBUS_NEW_SERVICE "fi.w1.wpa_supplicant1"
-@@ -61,6 +67,9 @@ enum wpas_dbus_bss_prop {
+@@ -61,6 +67,9 @@
#define WPAS_DBUS_NEW_BSSIDS_PART "BSSs"
#define WPAS_DBUS_NEW_IFACE_BSS WPAS_DBUS_NEW_INTERFACE ".BSS"
@@ -734,7 +655,7 @@ Signed-off-by: Andrej Shadura <andrewsh@debian.org>
#define WPAS_DBUS_NEW_IFACE_P2PDEVICE \
WPAS_DBUS_NEW_IFACE_INTERFACE ".P2PDevice"
-@@ -161,6 +170,10 @@ int wpas_dbus_unregister_bss(struct wpa_supplicant *wpa_s,
+@@ -161,6 +170,10 @@
u8 bssid[ETH_ALEN], unsigned int id);
int wpas_dbus_register_bss(struct wpa_supplicant *wpa_s,
u8 bssid[ETH_ALEN], unsigned int id);
@@ -745,10 +666,11 @@ Signed-off-by: Andrej Shadura <andrewsh@debian.org>
void wpas_dbus_signal_blob_added(struct wpa_supplicant *wpa_s,
const char *name);
void wpas_dbus_signal_blob_removed(struct wpa_supplicant *wpa_s,
-@@ -333,6 +346,18 @@ static inline int wpas_dbus_register_bss(struct wpa_supplicant *wpa_s,
+@@ -332,6 +345,18 @@
+ {
return 0;
}
-
++
+static inline int wpas_dbus_unregister_sta(struct wpa_supplicant *wpa_s,
+ const u8 *sta)
+{
@@ -760,14 +682,12 @@ Signed-off-by: Andrej Shadura <andrewsh@debian.org>
+{
+ return 0;
+}
-+
+
static inline void wpas_dbus_signal_blob_added(struct wpa_supplicant *wpa_s,
const char *name)
- {
-
--- a/wpa_supplicant/notify.c
+++ b/wpa_supplicant/notify.c
-@@ -720,6 +720,9 @@ static void wpas_notify_ap_sta_authorized(struct wpa_supplicant *wpa_s,
+@@ -720,6 +720,9 @@
wpas_dbus_signal_p2p_peer_joined(wpa_s, p2p_dev_addr);
#endif /* CONFIG_P2P */
@@ -777,7 +697,7 @@ Signed-off-by: Andrej Shadura <andrewsh@debian.org>
/* Notify listeners a new station has been authorized */
wpas_dbus_signal_sta_authorized(wpa_s, sta);
}
-@@ -740,6 +743,9 @@ static void wpas_notify_ap_sta_deauthorized(struct wpa_supplicant *wpa_s,
+@@ -740,6 +743,9 @@
/* Notify listeners a station has been deauthorized */
wpas_dbus_signal_sta_deauthorized(wpa_s, sta);
diff --git a/wpa_supplicant/dbus/dbus_new.c b/wpa_supplicant/dbus/dbus_new.c
index 79dae8a..f21f138 100644
--- a/wpa_supplicant/dbus/dbus_new.c
+++ b/wpa_supplicant/dbus/dbus_new.c
@@ -879,19 +879,15 @@ void wpas_dbus_signal_eap_status(struct wpa_supplicant *wpa_s,
* Notify listeners about event related with station
*/
static void wpas_dbus_signal_sta(struct wpa_supplicant *wpa_s,
- const u8 *sta, const char *sig_name,
- int properties)
+ const u8 *sta, const char *sig_name)
{
struct wpas_dbus_priv *iface;
DBusMessage *msg;
- DBusMessageIter iter;
- char sta_obj_path[WPAS_DBUS_OBJECT_PATH_MAX];
- char *path;
+ char sta_mac[WPAS_DBUS_OBJECT_PATH_MAX];
+ char *dev_mac;
- os_snprintf(sta_obj_path, WPAS_DBUS_OBJECT_PATH_MAX,
- "%s/" WPAS_DBUS_NEW_STAS_PART "/" COMPACT_MACSTR,
- wpa_s->dbus_new_path, MAC2STR(sta));
- path = sta_obj_path;
+ os_snprintf(sta_mac, WPAS_DBUS_OBJECT_PATH_MAX, MACSTR, MAC2STR(sta));
+ dev_mac = sta_mac;
iface = wpa_s->global->dbus;
@@ -904,28 +900,15 @@ static void wpas_dbus_signal_sta(struct wpa_supplicant *wpa_s,
if (msg == NULL)
return;
- dbus_message_iter_init_append(msg, &iter);
- if (!dbus_message_iter_append_basic(&iter, DBUS_TYPE_OBJECT_PATH,
- &path))
- goto err;
-
- if (properties) {
- if (!wpa_dbus_get_object_properties(iface, path,
- WPAS_DBUS_NEW_IFACE_STA,
- &iter))
- goto err;
- }
-
- wpa_printf(MSG_DEBUG, "dbus: Station MAC address '" MACSTR "' '%s'",
- MAC2STR(sta), sig_name);
-
- dbus_connection_send(iface->con, msg, NULL);
+ if (dbus_message_append_args(msg, DBUS_TYPE_STRING, &dev_mac,
+ DBUS_TYPE_INVALID))
+ dbus_connection_send(iface->con, msg, NULL);
+ else
+ wpa_printf(MSG_ERROR, "dbus: Failed to construct signal");
dbus_message_unref(msg);
- return;
-err:
- wpa_printf(MSG_ERROR, "dbus: Failed to construct signal");
- dbus_message_unref(msg);
+ wpa_printf(MSG_DEBUG, "dbus: Station MAC address '%s' '%s'",
+ sta_mac, sig_name);
}
@@ -939,7 +922,7 @@ err:
void wpas_dbus_signal_sta_authorized(struct wpa_supplicant *wpa_s,
const u8 *sta)
{
- wpas_dbus_signal_sta(wpa_s, sta, "StaAuthorized", TRUE);
+ wpas_dbus_signal_sta(wpa_s, sta, "StaAuthorized");
}
@@ -953,7 +936,7 @@ void wpas_dbus_signal_sta_authorized(struct wpa_supplicant *wpa_s,
void wpas_dbus_signal_sta_deauthorized(struct wpa_supplicant *wpa_s,
const u8 *sta)
{
- wpas_dbus_signal_sta(wpa_s, sta, "StaDeauthorized", FALSE);
+ wpas_dbus_signal_sta(wpa_s, sta, "StaDeauthorized");
}