Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

SSH1 vs. SSH2 - compression level

1 view
Skip to first unread message

Tomasz Chmielewski

unread,
Nov 6, 2003, 10:44:10 AM11/6/03
to
Hello,

I was searching for this information virtually everywhere, but as I
couldn't find it - I'm asking here.


I was wondering, why setting the Compression Level was removed in SSH2,
and if on, is always set to 6.

In SSH1 it was possible to set the Compression Level from 1 to 9.

I have made some tests with Compression Levels using scp: SSH1,
compression 9 (highest available for SSH1), vs. SSH2, compression 6 (the
only available for SSH2), and, no wonder, SSH1 *always* won, no matter
if it was tar'red /etc (lots of txt files), a long pdf file, or even
long avi file.

Why not let the user what best suits him?

Or maybe there is some way to turn it on in SSH2?


Regards,

Tomasz Chmielewski

_______________________________________________
openssh-unix-dev mailing list
openssh-...@mindrot.org
http://www.mindrot.org/mailman/listinfo/openssh-unix-dev

Damien Miller

unread,
Nov 7, 2003, 4:38:56 PM11/7/03
to
On Fri, 2003-11-07 at 02:36, Tomasz Chmielewski wrote:
> Hello,
>
> I was searching for this information virtually everywhere, but as I
> couldn't find it - I'm asking here.
>
> I was wondering, why setting the Compression Level was removed in SSH2,
> and if on, is always set to 6.

IIRC protocol 2 doesn't allow negotiation of compression levels, so
we have to choose something. 6 is a good tradeoff between CPU and size.

> In SSH1 it was possible to set the Compression Level from 1 to 9.
>
> I have made some tests with Compression Levels using scp: SSH1,
> compression 9 (highest available for SSH1), vs. SSH2, compression 6 (the
> only available for SSH2), and, no wonder, SSH1 *always* won, no matter
> if it was tar'red /etc (lots of txt files), a long pdf file, or even
> long avi file.

I'm pretty surprised that compressionlevel made any difference with avi
or pdf files, which are usually precompressed. Your speed differences
were probably due to the fact that protocol 1 is more lightweight (crc
instead of MAC, etc - thus also less secure).

-d

Markus Friedl

unread,
Nov 10, 2003, 5:23:12 AM11/10/03
to
On Thu, Nov 06, 2003 at 04:36:27PM +0100, Tomasz Chmielewski wrote:
> Or maybe there is some way to turn it on in SSH2?

no, the protocol does not allow negotiation.

Darren Tucker

unread,
Nov 11, 2003, 8:41:24 PM11/11/03
to
Tomasz Chmielewski wrote:
[snip]

> I was wondering, why setting the Compression Level was removed in SSH2,
> and if on, is always set to 6.

Unless I read it wrong, the SSHv2 protocol standard does not provide a way
to set the compression level [0]. I don't know why this is, perhaps
someone else knows the reasoning behind it?

See section 5.2 here:
http://www.ietf.org/internet-drafts/draft-ietf-secsh-transport-17.txt

Compare with the SSHv1 RFC:
http://www.zip.com.au/~dtucker/openssh/ssh-rfc-v1.txt
(see the description of the SSH_CMSG_REQUEST_COMPRESSION packet type).

[0] Ignoring implementation-specific extensions, eg "zli...@openssh.com"
through "zli...@openssh.com" or something.

--
Darren Tucker (dtucker at zip.com.au)
GPG key 8FF4FA69 / D9A3 86E9 7EEE AF4B B2D4 37C9 C982 80C7 8FF4 FA69
Good judgement comes with experience. Unfortunately, the experience
usually comes from bad judgement.

Markus Friedl

unread,
Nov 12, 2003, 4:05:37 AM11/12/03
to
On Fri, Nov 07, 2003 at 11:32:00AM +1100, Darren Tucker wrote:
> [0] Ignoring implementation-specific extensions, eg "zli...@openssh.com"
> through "zli...@openssh.com" or something.

yes, but i don't think it's worth the trouble.

0 new messages