Harden release readiness gates
ci / test (push) Has been cancelled
ci / fuzz-smoke (push) Has been cancelled
ci / windows-client (push) Has been cancelled
ci / package-release (linux-x86_64, ubuntu-latest) (push) Has been cancelled
ci / package-release (macos-aarch64, macos-14) (push) Has been cancelled
ci / package-release (macos-x86_64, macos-13) (push) Has been cancelled
ci / package-release (windows-x86_64, windows-latest) (push) Has been cancelled
ci / remote-bench (push) Has been cancelled
ci / test (push) Has been cancelled
ci / fuzz-smoke (push) Has been cancelled
ci / windows-client (push) Has been cancelled
ci / package-release (linux-x86_64, ubuntu-latest) (push) Has been cancelled
ci / package-release (macos-aarch64, macos-14) (push) Has been cancelled
ci / package-release (macos-x86_64, macos-13) (push) Has been cancelled
ci / package-release (windows-x86_64, windows-latest) (push) Has been cancelled
ci / remote-bench (push) Has been cancelled
This commit is contained in:
+18
-13
@@ -905,7 +905,7 @@ async fn run_doctor_for_host(
|
||||
match try_native_auth_check(
|
||||
&socket,
|
||||
config,
|
||||
&requested,
|
||||
requested,
|
||||
&server,
|
||||
ssh_port,
|
||||
&udp_host,
|
||||
@@ -1776,6 +1776,7 @@ fn select_session(requested: Option<&str>, _force_new: bool) -> String {
|
||||
protocol::generate_implicit_session_name()
|
||||
}
|
||||
|
||||
#[allow(clippy::too_many_arguments)]
|
||||
fn ssh_bootstrap(
|
||||
server: &str,
|
||||
ssh_port: Option<u16>,
|
||||
@@ -1836,10 +1837,10 @@ fn ssh_destination_host(server: &str) -> String {
|
||||
.split('/')
|
||||
.next()
|
||||
.unwrap_or(without_user);
|
||||
if let Some(stripped) = without_path.strip_prefix('[') {
|
||||
if let Some((host, _)) = stripped.split_once(']') {
|
||||
return host.to_string();
|
||||
}
|
||||
if let Some(stripped) = without_path.strip_prefix('[')
|
||||
&& let Some((host, _)) = stripped.split_once(']')
|
||||
{
|
||||
return host.to_string();
|
||||
}
|
||||
without_path
|
||||
.split_once(':')
|
||||
@@ -2068,6 +2069,7 @@ fn resolve_addr(host: &str, port: u16) -> Result<SocketAddr> {
|
||||
.ok_or_else(|| anyhow!("no UDP address resolved for {host}:{port}"))
|
||||
}
|
||||
|
||||
#[allow(clippy::too_many_arguments)]
|
||||
async fn try_native_auth(
|
||||
socket: &UdpSocket,
|
||||
config: &dosh::config::ClientConfig,
|
||||
@@ -2173,7 +2175,7 @@ async fn try_native_auth(
|
||||
let auth = sign_native_user_auth(
|
||||
config,
|
||||
cli_identity,
|
||||
&ssh_config,
|
||||
ssh_config,
|
||||
&hello,
|
||||
&server_hello.hello,
|
||||
requested_forwardings,
|
||||
@@ -2230,6 +2232,7 @@ async fn try_native_auth(
|
||||
Ok((frame, cred))
|
||||
}
|
||||
|
||||
#[allow(clippy::too_many_arguments)]
|
||||
async fn try_native_auth_check(
|
||||
socket: &UdpSocket,
|
||||
config: &dosh::config::ClientConfig,
|
||||
@@ -2329,7 +2332,7 @@ async fn try_native_auth_check(
|
||||
let auth = sign_native_user_auth(
|
||||
config,
|
||||
cli_identity,
|
||||
&ssh_config,
|
||||
ssh_config,
|
||||
&hello,
|
||||
&server_hello.hello,
|
||||
Vec::new(),
|
||||
@@ -2757,6 +2760,7 @@ where
|
||||
}
|
||||
}
|
||||
|
||||
#[allow(clippy::too_many_arguments)]
|
||||
async fn run_terminal(
|
||||
socket: UdpSocket,
|
||||
mut cred: CachedCredential,
|
||||
@@ -3844,6 +3848,7 @@ async fn send_stream_data(
|
||||
send_stream_packet(socket, addr, cred, send_seq, PacketKind::StreamData, &body).await
|
||||
}
|
||||
|
||||
#[allow(clippy::too_many_arguments)]
|
||||
async fn queue_or_send_stream_data(
|
||||
socket: &UdpSocket,
|
||||
addr: SocketAddr,
|
||||
@@ -3884,6 +3889,7 @@ async fn queue_or_send_stream_data(
|
||||
send_stream_data(socket, addr, cred, send_seq, stream_id, offset, bytes).await
|
||||
}
|
||||
|
||||
#[allow(clippy::too_many_arguments)]
|
||||
async fn flush_stream_pending_data(
|
||||
socket: &UdpSocket,
|
||||
addr: SocketAddr,
|
||||
@@ -3898,10 +3904,7 @@ async fn flush_stream_pending_data(
|
||||
let Some(pending) = stream_pending_data.get_mut(&stream_id) else {
|
||||
return Ok(());
|
||||
};
|
||||
loop {
|
||||
let Some(bytes) = pending.front() else {
|
||||
break;
|
||||
};
|
||||
while let Some(bytes) = pending.front() {
|
||||
let credit = stream_send_credit.get(&stream_id).copied().unwrap_or(0);
|
||||
if credit < bytes.len() {
|
||||
break;
|
||||
@@ -5391,8 +5394,10 @@ mod tests {
|
||||
let path = dir.path().join("id_ed25519");
|
||||
let signing = SigningKey::from_bytes(&[63u8; 32]);
|
||||
write_identity(&path, &signing);
|
||||
let mut config = ClientConfig::default();
|
||||
config.identity_files = vec![path.display().to_string()];
|
||||
let config = ClientConfig {
|
||||
identity_files: vec![path.display().to_string()],
|
||||
..ClientConfig::default()
|
||||
};
|
||||
let ssh_config = SshConfig {
|
||||
identities_only: true,
|
||||
..SshConfig::default()
|
||||
|
||||
Reference in New Issue
Block a user