CVE-2020-15778 icon indicating copy to clipboard operation
CVE-2020-15778 copied to clipboard

Authoritative Evidence from Vendor

Open duckfez opened this issue 4 years ago • 3 comments

Do you have a link to a public statement from OpenSSH team saying they do not intend to fix this at this time? I've checked a few places, and find several references to the OpenSSH team's statement - but they all lead back to your site as the authority.

duckfez avatar Dec 03 '20 15:12 duckfez

There is no public statement. This was from the conversation with OpenSSH in email.

cpandya2909 avatar Jan 18 '21 11:01 cpandya2909

hey do not intend to fix this at this time

This could be reviewed again now that https://github.com/openssh/openssh-portable/pull/194 has been merged in https://github.com/openssh/openssh-portable/commit/197e29f1cca190d767c4b2b63a662f9a9e5da0b3

cfi-gb avatar Aug 04 '21 07:08 cfi-gb

Correct me if I’ve missed something, but the vulnerability is server-side, is it not? The “fix” in OpenSSH 9 involves modifying the scp command to use sftp for file transfers, deprecating the original scp method. But this fix is only done client-side; the server still remains vulnerable to malicious clients forcing the older protocol (or indeed use of the standard client-side scp command with the -O option, conveniently provided for just this purpose!).

A proper fix needs to be done server-side. I don’t know enough about SSH to suggest how, but two obvious techniques come to mind from my own past experience with this sort of problem:

  • Don’t spawn a shell, instead invoke the command directly via execve(2) or one of its wrapper calls

  • If you have to spawn a shell, pass argument values via environment variables. E.g. if VAR contains some arbitrary string, then passing it to «cmd» via

    «cmd» "$VAR"
    

    is safe. (Assuming «cmd» can deal safely with the value.)

Depending on the situation, the printf(1) command provided by GNU Coreutils might also be useful in a shell script, since that seems to know how to do correct quoting of shell specials (with printf %q).

ldo avatar Aug 13 '22 02:08 ldo