[connections/gnome-41] rdp: Fix interactive authentication



commit 156c2c05bc4006784bceedb26fe500fd775302f0
Author: Felipe Borges <felipeborges gnome org>
Date:   Thu Sep 2 11:49:01 2021 +0200

    rdp: Fix interactive authentication

 src/rdp-connection.vala | 14 ++++++++++----
 subprojects/gtk-frdp    |  2 +-
 2 files changed, 11 insertions(+), 5 deletions(-)
---
diff --git a/src/rdp-connection.vala b/src/rdp-connection.vala
index d1bc319..7c520a9 100644
--- a/src/rdp-connection.vala
+++ b/src/rdp-connection.vala
@@ -60,9 +60,11 @@ namespace Connections {
             display.bind_property ("password", this, "password", BindingFlags.BIDIRECTIONAL);
 
             display.rdp_connected.connect (() => { show (); });
-            display.rdp_needs_authentication.connect (on_rdp_auth_credential_cb);
+            //display.rdp_needs_authentication.connect (on_rdp_auth_credential_cb);
             display.rdp_auth_failure.connect (auth_failed);
             //display.size_allocate.connect (scale);
+
+            need_username = need_password = true;
         }
 
         public RdpConnection (string uuid) {
@@ -83,9 +85,15 @@ namespace Connections {
         public override void connect_it () {
             if (connected)
                 return;
-            connected = true;
+
+            if (username == null && password == null) {
+                handle_auth ();
+
+                return;
+            }
 
             display.open_host (host, port);
+            connected = true;
         }
 
         public override void disconnect_it () {
@@ -104,8 +112,6 @@ namespace Connections {
             need_username = need_password = true;
 
             handle_auth ();
-
-            disconnect_it ();
         }
     }
 
diff --git a/subprojects/gtk-frdp b/subprojects/gtk-frdp
index f591dcf..62659b0 160000
--- a/subprojects/gtk-frdp
+++ b/subprojects/gtk-frdp
@@ -1 +1 @@
-Subproject commit f591dcf456a1e126c0cdf6e49d436485556d8999
+Subproject commit 62659b094065e333c4db9a5c3e125609351ad0d7


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]