All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] iwd: Fix connection with invalid passphrase format
       [not found] <20220411075458.78136-1-Emmanuel.VAUTRIN@cpexterne.org>
@ 2022-04-11  8:03 ` VAUTRIN Emmanuel (Canal Plus Prestataire)
  2022-04-14 18:47   ` Daniel Wagner
  0 siblings, 1 reply; 3+ messages in thread
From: VAUTRIN Emmanuel (Canal Plus Prestataire) @ 2022-04-11  8:03 UTC (permalink / raw)
  To: connman

[-- Attachment #1: Type: text/plain, Size: 1171 bytes --]

It is no more possible to connect to a secure network, after entering
an invalid passphrase format, for example 64 characters.
In this case, the user agent still needs to be called, to request a new
passphrase.
---
 plugins/iwd.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/plugins/iwd.c b/plugins/iwd.c
index ee3ed83e5957..f2d368336d1a 100644
--- a/plugins/iwd.c
+++ b/plugins/iwd.c
@@ -241,7 +241,9 @@ static void cm_network_connect_cb(DBusMessage *message, void *user_data)
                        return;

                DBG("%s connect failed: %s", path, dbus_error);
-               if (!strcmp(dbus_error, "net.connman.iwd.Failed"))
+               if (!strcmp(dbus_error, "net.connman.iwd.Failed") ||
+                                       !strcmp(dbus_error,
+                                       "net.connman.iwd.InvalidFormat"))
                        connman_network_set_error(iwdn->network,
                                        CONNMAN_NETWORK_ERROR_INVALID_KEY);
                else if (!iwdn->autoconnect)
--
2.25.1

Hello,

Please find the well formatted patch in attachment.

Emmanuel


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-iwd-Fix-connection-with-invalid-passphrase-format.patch --]
[-- Type: text/x-patch; name="0001-iwd-Fix-connection-with-invalid-passphrase-format.patch", Size: 1109 bytes --]

From 8cbd34aa536284a5349ee61a0bdba126b8b42fbf Mon Sep 17 00:00:00 2001
From: Emmanuel VAUTRIN <Emmanuel.VAUTRIN@cpexterne.org>
Date: Fri, 8 Apr 2022 17:24:19 +0200
Subject: [PATCH] iwd: Fix connection with invalid passphrase format

It is no more possible to connect to a secure network, after entering
an invalid passphrase format, for example 64 characters.
In this case, the user agent still needs to be called, to request a new
passphrase.
---
 plugins/iwd.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/plugins/iwd.c b/plugins/iwd.c
index ee3ed83e5957..f2d368336d1a 100644
--- a/plugins/iwd.c
+++ b/plugins/iwd.c
@@ -241,7 +241,9 @@ static void cm_network_connect_cb(DBusMessage *message, void *user_data)
 			return;
 
 		DBG("%s connect failed: %s", path, dbus_error);
-		if (!strcmp(dbus_error, "net.connman.iwd.Failed"))
+		if (!strcmp(dbus_error, "net.connman.iwd.Failed") ||
+					!strcmp(dbus_error,
+					"net.connman.iwd.InvalidFormat"))
 			connman_network_set_error(iwdn->network,
 					CONNMAN_NETWORK_ERROR_INVALID_KEY);
 		else if (!iwdn->autoconnect)
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] iwd: Fix connection with invalid passphrase format
  2022-04-11  8:03 ` [PATCH] iwd: Fix connection with invalid passphrase format VAUTRIN Emmanuel (Canal Plus Prestataire)
@ 2022-04-14 18:47   ` Daniel Wagner
  2022-04-14 20:15     ` VAUTRIN Emmanuel (Canal Plus Prestataire)
  0 siblings, 1 reply; 3+ messages in thread
From: Daniel Wagner @ 2022-04-14 18:47 UTC (permalink / raw)
  To: VAUTRIN Emmanuel (Canal Plus Prestataire); +Cc: connman

On Mon, Apr 11, 2022 at 08:03:38AM +0000, VAUTRIN Emmanuel (Canal Plus Prestataire) wrote:
> It is no more possible to connect to a secure network, after entering
> an invalid passphrase format, for example 64 characters.
> In this case, the user agent still needs to be called, to request a new
> passphrase.

Thanks, patch applied.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* RE: [PATCH] iwd: Fix connection with invalid passphrase format
  2022-04-14 18:47   ` Daniel Wagner
@ 2022-04-14 20:15     ` VAUTRIN Emmanuel (Canal Plus Prestataire)
  0 siblings, 0 replies; 3+ messages in thread
From: VAUTRIN Emmanuel (Canal Plus Prestataire) @ 2022-04-14 20:15 UTC (permalink / raw)
  To: connman

> Thanks, patch applied.
Great. Thank you Daniel!

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2022-04-14 20:15 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <20220411075458.78136-1-Emmanuel.VAUTRIN@cpexterne.org>
2022-04-11  8:03 ` [PATCH] iwd: Fix connection with invalid passphrase format VAUTRIN Emmanuel (Canal Plus Prestataire)
2022-04-14 18:47   ` Daniel Wagner
2022-04-14 20:15     ` VAUTRIN Emmanuel (Canal Plus Prestataire)

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.