diff --git a/lib/src/gpg_signing.rs b/lib/src/gpg_signing.rs index 7d1385597..53826b5ac 100644 --- a/lib/src/gpg_signing.rs +++ b/lib/src/gpg_signing.rs @@ -67,9 +67,11 @@ fn parse_gpg_verify_output( } fn run_sign_command(command: &mut Command, input: &[u8]) -> Result, GpgError> { + tracing::info!(?command, "running GPG signing command"); let process = command.stderr(Stdio::piped()).spawn()?; let write_result = process.stdin.as_ref().unwrap().write_all(input); let output = process.wait_with_output()?; + tracing::info!(?command, ?output.status, "GPG signing command exited"); if output.status.success() { write_result?; Ok(output.stdout) @@ -82,9 +84,11 @@ fn run_sign_command(command: &mut Command, input: &[u8]) -> Result, GpgE } fn run_verify_command(command: &mut Command, input: &[u8]) -> Result, GpgError> { + tracing::info!(?command, "running GPG signing command"); let process = command.stderr(Stdio::null()).spawn()?; let write_result = process.stdin.as_ref().unwrap().write_all(input); let output = process.wait_with_output()?; + tracing::info!(?command, ?output.status, "GPG signing command exited"); match write_result { Ok(()) => Ok(output.stdout), // If the signature format is invalid, gpg will terminate early. Writing diff --git a/lib/src/ssh_signing.rs b/lib/src/ssh_signing.rs index 4e3378851..34266c158 100644 --- a/lib/src/ssh_signing.rs +++ b/lib/src/ssh_signing.rs @@ -59,9 +59,11 @@ fn parse_utf8_string(data: Vec) -> SshResult { } fn run_command(command: &mut Command, stdin: &[u8]) -> SshResult> { + tracing::info!(?command, "running SSH signing command"); let process = command.spawn()?; let write_result = process.stdin.as_ref().unwrap().write_all(stdin); let output = process.wait_with_output()?; + tracing::info!(?command, ?output.status, "SSH signing command exited"); if output.status.success() { write_result?; Ok(output.stdout) @@ -150,8 +152,10 @@ impl SshBackend { // will return a non-0 exit code if no principals are found. // // In this case we don't want to error out, just return None. + tracing::info!(?command, "running SSH signing command"); let process = command.spawn()?; let output = process.wait_with_output()?; + tracing::info!(?command, ?output.status, "SSH signing command exited"); let principal = parse_utf8_string(output.stdout)? .split('\n')