summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Haller <thaller@redhat.com>2020-01-20 18:47:09 +0100
committerThomas Haller <thaller@redhat.com>2020-02-10 19:11:50 +0100
commit2a831a9eaea2229dbab6647f4b8947957f0e2bce (patch)
tree0db9617fe8baf06a6aeafb9f1dc64e711e67b650
parent2685079c63ac9f310d0952582aad8127cbdeffb4 (diff)
supplicant: drop unused detection for credreq
-rw-r--r--src/supplicant/nm-supplicant-interface.c50
1 files changed, 2 insertions, 48 deletions
diff --git a/src/supplicant/nm-supplicant-interface.c b/src/supplicant/nm-supplicant-interface.c
index a63110bdb..d280e8600 100644
--- a/src/supplicant/nm-supplicant-interface.c
+++ b/src/supplicant/nm-supplicant-interface.c
@@ -104,7 +104,6 @@ NM_GOBJECT_PROPERTIES_DEFINE (NMSupplicantInterface,
typedef struct _NMSupplicantInterfacePrivate {
char * dev;
NMSupplicantDriver driver;
- gboolean has_credreq; /* Whether querying 802.1x credentials is supported */
NMSupplCapMask global_capabilities;
NMSupplCapMask iface_capabilities;
guint32 max_scan_ssids;
@@ -630,37 +629,6 @@ iface_check_ready (NMSupplicantInterface *self)
}
static void
-iface_check_netreply_cb (GDBusProxy *proxy, GAsyncResult *result, gpointer user_data)
-{
- NMSupplicantInterface *self;
- NMSupplicantInterfacePrivate *priv;
- gs_unref_variant GVariant *variant = NULL;
- gs_free_error GError *error = NULL;
-
- /* We know NetworkReply is supported if the NetworkReply method returned
- * successfully (which is unexpected since we sent a bogus network
- * object path) or if we got an "InvalidArgs" (which indicates NetworkReply
- * is supported). We know it's not supported if we get an
- * "UnknownMethod" error.
- */
-
- variant = g_dbus_proxy_call_finish (proxy, result, &error);
- if (g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED))
- return;
-
- self = NM_SUPPLICANT_INTERFACE (user_data);
- priv = NM_SUPPLICANT_INTERFACE_GET_PRIVATE (self);
-
- if (variant || _nm_dbus_error_has_name (error, "fi.w1.wpa_supplicant1.InvalidArgs"))
- priv->has_credreq = TRUE;
-
- _LOGD ("supplicant %s network credentials requests",
- priv->has_credreq ? "supports" : "does not support");
-
- iface_check_ready (self);
-}
-
-static void
iface_set_pmf_cb (GDBusProxy *proxy, GAsyncResult *result, gpointer user_data)
{
NMSupplicantInterface *self;
@@ -1583,21 +1551,6 @@ on_iface_proxy_acquired (GDBusProxy *proxy, GAsyncResult *result, gpointer user_
NULL,
NULL);
- /* Check whether NetworkReply and AP mode are supported.
- * ready_count was initialized to 1 in interface_add_done().
- */
- g_dbus_proxy_call (priv->iface_proxy,
- "NetworkReply",
- g_variant_new ("(oss)",
- "/fff",
- "foobar",
- "foobar"),
- G_DBUS_CALL_FLAGS_NONE,
- -1,
- priv->init_cancellable,
- (GAsyncReadyCallback) iface_check_netreply_cb,
- self);
-
if (_get_capability (priv, NM_SUPPL_CAP_TYPE_PMF) == NM_TERNARY_TRUE) {
/* Initialize global PMF setting to 'optional' */
priv->ready_count++;
@@ -1630,6 +1583,8 @@ on_iface_proxy_acquired (GDBusProxy *proxy, GAsyncResult *result, gpointer user_
(GAsyncReadyCallback) iface_introspect_cb,
self);
}
+
+ iface_check_ready (self);
}
static void
@@ -1683,7 +1638,6 @@ interface_add_done (NMSupplicantInterface *self, const char *path)
_LOGD ("interface added to supplicant");
- /* Iface ready check happens in iface_check_netreply_cb */
priv->ready_count = 1;
priv->object_path = g_strdup (path);