Bug 3378

Summary: Make "Shared connectio to <host> closed." message silenceable, while Not silencing ALL messages
Product: Portable OpenSSH Reporter: Wayne Walker <wwalker>
Component: sshAssignee: Assigned to nobody <unassigned-bugs>
Status: CLOSED FIXED    
Severity: enhancement CC: djm
Priority: P5    
Version: 8.8p1   
Hardware: Other   
OS: Linux   
Bug Depends on:    
Bug Blocks: 3353    
Attachments:
Description Flags
Change "Shared connection ..closed" message from "always" to VERBOSE none

Description Wayne Walker 2022-01-10 07:49:15 AEDT
Created attachment 3563 [details]
Change "Shared connection ..closed" message from "always" to VERBOSE

The message "Shared connectio to <host> closed." cannot be silenced without silencing ALL messages from ssh.

Please change it to be of LogLevel INFO, or VERBOSE, or add a config option to silence it (e.g. MuxMessages default yes).

```
$ ssh -t daplane ls > /dev/null
Shared connection to 172.16.16.1 closed.
$
```

I understand that there are workarounds (e.g.,don't use -t, but sometimes the remote tool needs a tty); however, one should be able to silence the message (e.g., change LogLevel to ERROR) without silencing ERROR and FATAL messages.

Attached is a simple patch that should suffice.
Comment 1 Damien Miller 2022-01-10 16:39:35 AEDT
It is silenceable though. "ssh -q" or setting LogLevel=quiet stops it
Comment 2 Wayne Walker 2022-01-11 02:24:48 AEDT
@djm  Yes, -q or LogLevel=QUIET silences it, but that also silences even FATAL and ERROR messages.  If it we set to an actual LogLevel, then one could set LogLevel to ERROR and silence it while still receiving ERROR and FATAL messages, should they occur.
Comment 3 Damien Miller 2022-01-11 12:29:28 AEDT
This has been committed and will be in OpenSSH 8.9

commit 1385513b95a12b38e8270ddf34c2d5dc4aeb806b (HEAD -> master)
Author: djm@openbsd.org <djm@openbsd.org>
Date:   Tue Jan 11 01:26:47 2022 +0000

    upstream: suppress "Connection to xxx closed" messages at LogLevel >=
    
    error bz3378; ok dtucker@
Comment 4 Damien Miller 2022-02-25 13:56:42 AEDT
closing bugs resolved before openssh-8.9