[gvfs] sftp: Be more robust when parsing login messages



commit 3efa295cd61b6390acc87c4604e4b7f3902dbae7
Author: Ross Lagerwall <rosslagerwall gmail com>
Date:   Fri Mar 13 23:31:28 2015 +0000

    sftp: Be more robust when parsing login messages
    
    Handle the case when the fingerprint could not be parsed from SSH's
    output.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=545445

 daemon/gvfsbackendsftp.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/daemon/gvfsbackendsftp.c b/daemon/gvfsbackendsftp.c
index e6c1d5b..d89c090 100644
--- a/daemon/gvfsbackendsftp.c
+++ b/daemon/gvfsbackendsftp.c
@@ -1205,7 +1205,8 @@ handle_login (GVfsBackend *backend,
                                       "The identity sent by the remote computer is ā€œ%sā€. "
                                       "If you want to be absolutely sure it is safe to continue, "
                                       "contact the system administrator."),
-                                    hostname ? hostname : op_backend->host, fingerprint);
+                                     hostname ? hostname : op_backend->host,
+                                     fingerprint ? fingerprint : "???");
 
          g_free (hostname);
          g_free (fingerprint);


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