diff --git a/src/server/client.rs b/src/server/client.rs index ff6fa7f675c..5e68d3cbf97 100644 --- a/src/server/client.rs +++ b/src/server/client.rs @@ -128,8 +128,12 @@ fn client_thread( next_serial += 1; promises.insert(serial, promise); - pdu.encode(reconnectable.stream(), serial)?; - reconnectable.stream().flush()?; + pdu.encode(reconnectable.stream(), serial) + .context("encoding a PDU to send to the server")?; + reconnectable + .stream() + .flush() + .context("flushing PDU to server")?; } }, Err(TryRecvError::Empty) => break, @@ -166,7 +170,8 @@ fn client_thread( Ok(Some(decoded)) => { log::trace!("decoded serial {}", decoded.serial); if decoded.serial == 0 { - process_unilateral(local_domain_id, decoded)?; + process_unilateral(local_domain_id, decoded) + .context("processing unilateral PDU from server")?; } else if let Some(mut promise) = promises.remove(&decoded.serial) { promise.result(Ok(decoded.pdu)); } else { @@ -582,7 +587,7 @@ impl Reconnectable { .configure()? .verify_hostname(!tls_client.accept_invalid_hostnames); - ui.output_str(&format!("Connecting to {}\n", remote_address)); + ui.output_str(&format!("Connecting to {} using TLS\n", remote_address)); let stream = TcpStream::connect(remote_address) .with_context(|| format!("connecting to {}", remote_address))?; stream.set_nodelay(true)?; @@ -606,7 +611,7 @@ impl Reconnectable { ) })?, ); - ui.output_str("Connected!\n"); + ui.output_str("TLS Connected!\n"); self.stream.replace(stream); Ok(()) } diff --git a/src/server/domain.rs b/src/server/domain.rs index 0df953bd15f..db1d326c1cf 100644 --- a/src/server/domain.rs +++ b/src/server/domain.rs @@ -302,9 +302,14 @@ impl Domain for ClientDomain { } }; + ui.output_str("Version check OK! Requesting tab list...\n"); let tabs = client.list_tabs().await?; - + ui.output_str(&format!( + "Server has {} tabs. Attaching to local UI...\n", + tabs.tabs.len() + )); ClientDomain::finish_attach(domain_id, client, tabs)?; + ui.output_str("Attached!\n"); drop(activity); ui.close(); Ok(()) diff --git a/src/ssh.rs b/src/ssh.rs index c60e22a2708..29c55bcfbd2 100644 --- a/src/ssh.rs +++ b/src/ssh.rs @@ -63,11 +63,11 @@ pub fn ssh_connect_with_ui( } }; - ui.output_str(&format!("Connecting to {}\n", remote_address)); + ui.output_str(&format!("Connecting to {} using SSH\n", remote_address)); let tcp = TcpStream::connect(&remote_address) .with_context(|| format!("ssh connecting to {}", remote_address))?; - ui.output_str("Connected OK!\n"); + ui.output_str("SSH: Connected OK!\n"); tcp.set_nodelay(true)?; sess.set_tcp_stream(tcp); sess.handshake() @@ -185,7 +185,7 @@ pub fn ssh_connect_with_ui( "Password authentication for {}@{}\n", username, remote_address )); - let pass = ui.password("Password: ")?; + let pass = ui.password("🔐 Password: ")?; if let Err(err) = sess.userauth_password(username, &pass) { log::error!("while attempting password auth: {}", err); }