effect scp -O (use legacy SCP procotol) per host in .ssh/config?

Jochen Bern Jochen.Bern at binect.de
Wed Jun 22 18:48:58 AEST 2022


On 21.06.22 22:17, Christian Weisgerber wrote:
> "Brian J. Murrell":
> 
>> Is there a .ssh/config option I can set to force scp with that host to
>> use the legacy protocol?
> 
> No, because scp doesn't read ~/.ssh/config.  scp spawns ssh, which
> does, but that only affects ssh's operation.

For what it's worth: I had a quick look what a wrapper script can do, 
and found that "ssh -G $TARGETHOST" can tell you whether that host has 
an ssh_config setting of, for example, "sendenv NO_SFTP" (which will 
hopefully never *actually* send anything, as IIUC the env var would need 
to be *set* for that).

Now if only we could get the hostname(s) without entirely duplicating 
scp's command line parsing ....... ?

Regards,
-- 
Jochen Bern
Systemingenieur

Binect GmbH
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 3449 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://lists.mindrot.org/pipermail/openssh-unix-dev/attachments/20220622/10d2645b/attachment-0001.p7s>


More information about the openssh-unix-dev mailing list