[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Problem with compression and samplesshd-tty


Hi,

I have tested the samplesshd-tty
(master: 1973e833f2f8987c7be494e5dff86008a8557758) and it works really fine
without compression. But if I enable it on the client side it fails as
follow:

The zlib is activated:

$ grep WITH_ZLIB CMakeCache.txt
WITH_ZLIB:BOOL=ON

The client:

$ ssh -C -p 42 libssh@xxxxxxxxx
libssh@xxxxxxxxx's password:
buffer_uncompress: inflate returned -3
$ ssh -V
OpenSSH_5.5p1 Debian-4ubuntu6, OpenSSL 0.9.8o 01 Jun 2010

The server:

$ sudo ./examples/samplesshd-tty -v -p 42 --dsakey=~/.ssh/id_dsa
--rsakey=~/.ssh/id_rsa 127.0.0.1
Enter PEM pass phrase:
Enter PEM pass phrase:
Started sample libssh sshd on port 42
You can login as the user libssh with the password libssh
[2012/03/02 19:13:13.433631, 3]   Enabling POLLOUT for socket
[2012/03/02 19:13:13.434431, 3]   Received banner: SSH-2.0-OpenSSH_5.5p1
Debian-4ubuntu6
[2012/03/02 19:13:13.434469, 1]   SSH client banner: SSH-2.0-OpenSSH_5.5p1
Debian-4ubuntu6
[2012/03/02 19:13:13.434496, 1]   Analyzing banner: SSH-2.0-OpenSSH_5.5p1
Debian-4ubuntu6
[2012/03/02 19:13:13.434532, 1]   We are talking to an OpenSSH client
version: 5.5 (50500)
[2012/03/02 19:13:13.434645, 3]   Enabling POLLOUT for socket
[2012/03/02 19:13:13.434674, 3]   packet: wrote
[len=372,padding=5,comp=366,payload=366]
[2012/03/02 19:13:13.434721, 3]   packet: read type 20
[len=844,padding=6,comp=837,payload=837]
[2012/03/02 19:13:13.434751, 3]   Dispatching handler for packet type 20
[2012/03/02 19:13:13.434885, 3]   Set output algorithm aes128-ctr
[2012/03/02 19:13:13.434918, 3]   Set input algorithm aes128-ctr
[2012/03/02 19:13:13.475206, 3]   packet: read type 30
[len=140,padding=5,comp=134,payload=134]
[2012/03/02 19:13:13.475250, 3]   Dispatching handler for packet type 30
[2012/03/02 19:13:13.475261, 3]   Received SSH_MSG_KEXDH_INIT
[2012/03/02 19:13:13.522191, 3]   Enabling POLLOUT for socket
[2012/03/02 19:13:13.522243, 3]   packet: wrote
[len=700,padding=9,comp=690,payload=690]
[2012/03/02 19:13:13.522263, 3]   packet: wrote
[len=12,padding=10,comp=1,payload=1]
[2012/03/02 19:13:13.522276, 3]   SSH_MSG_NEWKEYS sent
[2012/03/02 19:13:13.522301, 3]   Enabling POLLOUT for socket
[2012/03/02 19:13:13.533343, 3]   packet: read type 21
[len=12,padding=10,comp=1,payload=1]
[2012/03/02 19:13:13.533385, 3]   Dispatching handler for packet type 21
[2012/03/02 19:13:13.533399, 2]   Received SSH_MSG_NEWKEYS
[2012/03/02 19:13:13.533436, 3]   Processing 52 bytes left in socket buffer
[2012/03/02 19:13:13.533502, 3]   packet: read type 5
[len=28,padding=10,comp=17,payload=17]
[2012/03/02 19:13:13.533519, 3]   Dispatching handler for packet type 5
[2012/03/02 19:13:13.533534, 3]   Received a SERVICE_REQUEST for service
ssh-userauth
[2012/03/02 19:13:13.533553, 3]   ssh_handle_key_exchange: Actual state : 7
[2012/03/02 19:13:13.533581, 3]   Sending a SERVICE_ACCEPT for service
ssh-userauth
[2012/03/02 19:13:13.533640, 3]   Enabling POLLOUT for socket
[2012/03/02 19:13:13.533658, 3]   packet: wrote
[len=28,padding=10,comp=17,payload=17]
[2012/03/02 19:13:13.535811, 3]   packet: read type 50
[len=44,padding=6,comp=37,payload=37]
[2012/03/02 19:13:13.535878, 3]   Dispatching handler for packet type 50
[2012/03/02 19:13:13.535928, 3]   Auth request for service ssh-connection,
method none for user 'libssh'
User libssh wants to auth with unknown auth 1
[2012/03/02 19:13:13.535977, 3]   Sending a auth failure. methods that can
continue: keyboard-interactive,password
[2012/03/02 19:13:13.536077, 3]   Enabling POLLOUT for socket
[2012/03/02 19:13:13.536110, 3]   packet: wrote
[len=44,padding=8,comp=35,payload=35]
[2012/03/02 19:13:13.536217, 3]   packet: read type 50
[len=76,padding=14,comp=61,payload=61]
[2012/03/02 19:13:13.536249, 3]   Dispatching handler for packet type 50
[2012/03/02 19:13:13.536279, 3]   Auth request for service ssh-connection,
method keyboard-interactive for user 'libssh'
User libssh wants to auth with unknown auth 16
[2012/03/02 19:13:13.536321, 3]   Sending a auth failure. methods that can
continue: keyboard-interactive,password
[2012/03/02 19:13:13.536417, 3]   Enabling POLLOUT for socket
[2012/03/02 19:13:13.536449, 3]   packet: wrote
[len=44,padding=8,comp=35,payload=35]
[2012/03/02 19:13:16.807432, 3]   packet: read type 50
[len=124,padding=71,comp=52,payload=52]
[2012/03/02 19:13:16.807482, 3]   Dispatching handler for packet type 50
[2012/03/02 19:13:16.807508, 3]   Auth request for service ssh-connection,
method password for user 'libssh'
User libssh wants to auth with pass libssh
[2012/03/02 19:13:16.807628, 3]   Enabling POLLOUT for socket
[2012/03/02 19:13:16.807660, 3]   packet: wrote
[len=12,padding=10,comp=1,payload=1]
[2012/03/02 19:13:16.808021, 3]   packet: read type 120
[len=28,padding=4,comp=23,payload=23]
[2012/03/02 19:13:16.808047, 3]   Dispatching handler for packet type 120
[2012/03/02 19:13:16.808062, 1]   Couldn't do anything with packet type 120
[2012/03/02 19:13:16.808121, 3]   Enabling POLLOUT for socket
[2012/03/02 19:13:16.808151, 3]   packet: wrote
[len=12,padding=6,comp=5,payload=5]
[2012/03/02 19:13:16.808496, 1]   Socket exception callback: 1 (0)
[2012/03/02 19:13:16.808558, 1] ssh_socket_exception_callback  Error:
Socket error: Success
Error: cleint did not ask for a channel session (Socket error: Success)

I have a linux box:
$ lsb_release -a
LSB Version:
core-2.0-ia32:core-2.0-noarch:core-3.0-ia32:core-3.0-noarch:core-3.1-ia32:core-3.1-noarch:core-3.2-ia32:core-3.2-noarch:core-4.0-ia32:core-4.0-noarch:cxx-3.0-ia32:cxx-3.0-noarch:cxx-3.1-ia32:cxx-3.1-noarch:cxx-3.2-ia32:cxx-3.2-noarch:cxx-4.0-ia32:cxx-4.0-noarch:desktop-3.1-ia32:desktop-3.1-noarch:desktop-3.2-ia32:desktop-3.2-noarch:desktop-4.0-ia32:desktop-4.0-noarch:graphics-2.0-ia32:graphics-2.0-noarch:graphics-3.0-ia32:graphics-3.0-noarch:graphics-3.1-ia32:graphics-3.1-noarch:graphics-3.2-ia32:graphics-3.2-noarch:graphics-4.0-ia32:graphics-4.0-noarch:languages-3.2-ia32:languages-3.2-noarch:languages-4.0-ia32:languages-4.0-noarch:multimedia-3.2-ia32:multimedia-3.2-noarch:multimedia-4.0-ia32:multimedia-4.0-noarch:printing-3.2-ia32:printing-3.2-noarch:printing-4.0-ia32:printing-4.0-noarch:qt4-3.1-ia32:qt4-3.1-noarch
Distributor ID: Ubuntu
Description: Ubuntu 10.10
Release: 10.10
Codename: maverick

Any idea?

Best regards,

-- 
Nicolas Desprès

Archive administrator: postmaster@lists.cynapses.org