Control: retitle -1 openssh-client: ssh cannot be interrupted early after the 
connection
Control: found -1 1:10.6p2-1

On 2020-11-19 01:58:38 +0100, Vincent Lefevre wrote:
> and at this point, ssh is stuck. This is probably a server side issue,
> but on the client side, I want to interrupt it. Neither Ctrl-C, Ctrl-\
> nor [Return]~. works.

Same problem. This time, the server did not respond after a few steps
due to Debian bugs 1154101 / 1154108 in the kernel of the server. But
when such an issue occurs, there should always be a way to interrupt
the client.

Here, a "ssh -vvv" gave:

[...]
Authenticated to joooj.vinc17.net ([2001:4b99:1:3:216:3eff:fe20:ac98]:22) using 
"publickey".
debug3: channel 0: classify type "(null)" (no TTY) as interactive
debug3: channel 0: classify type "session" (no TTY) as bulk
debug1: channel 0: new session [client-session] (inactive timeout: 0.000000)
debug3: channel 0: classify type "session" (with TTY) as interactive
debug3: ssh_session2_open: channel_new: 0 (tty)
debug2: channel 0: send open
debug3: send packet: type 90
debug1: Requesting [email protected]
debug3: send packet: type 80
debug1: Entering interactive session.
debug1: pledge: filesystem
debug3: client_repledge: enter
debug2: client_loop: session QoS is now interactive
debug2: fd 3 setting TCP_NODELAY
debug3: set_sock_tos: set socket 3 IPV6_TCLASS 0xb8
debug3: send packet: type 80

At this point, neither Ctrl-C, Ctrl-\, Ctrl-Z, nor [Return]~. had
any effect.

qaa:~> strace -p 658788
strace: Process 658788 attached
ppoll([{fd=3, events=POLLIN}, {fd=3, events=0}], 2, {tv_sec=276, 
tv_nsec=741470207}, [], 8

qaa:~> gdb -p 658788
[...]
(gdb) bt
#0  __internal_syscall_cancel (a1=<optimized out>, a2=<optimized out>,
    a3=<optimized out>, a4=<optimized out>, a5=a5@entry=8, a6=a6@entry=0,
    nr=271) at ./nptl/cancellation.c:44
#1  0x00007f060b09ba1d in __syscall_cancel (a1=<optimized out>,
    a2=<optimized out>, a3=<optimized out>, a4=<optimized out>, a5=a5@entry=8,
    a6=a6@entry=0, nr=271) at ./nptl/cancellation.c:75
#2  0x00007f060b11049e in __GI_ppoll (fds=<optimized out>,
    nfds=<optimized out>, timeout=<optimized out>,
    sigmask=sigmask@entry=0x7ffe5fb45a20)
    at ../sysdeps/unix/sysv/linux/ppoll.c:42
#3  0x000055e1c4e5807f in ppoll (__fds=<optimized out>, __nfds=<optimized out>,
    __timeout=<optimized out>, __ss=0x7ffe5fb45a20)
    at /usr/include/x86_64-linux-gnu/bits/poll2.h:101
#4  client_wait_until_can_do_something (ssh=0x55e1c50351c0,
    pfdp=0x7ffe5fb45958, npfd_allocp=0x7ffe5fb45950,
    npfd_activep=0x7ffe5fb45954, channel_did_enqueue=<optimized out>,
    sigsetp=0x7ffe5fb45a20, conn_in_readyp=<synthetic pointer>,
    conn_out_readyp=<synthetic pointer>) at ../../clientloop.c:731
#5  client_loop (ssh=0x55e1c50351c0, have_pty=1,
    escape_char_arg=<optimized out>, ssh2_chan_id=<optimized out>)
    at ../../clientloop.c:1608
#6  0x000055e1c4e4610d in ssh_session2 (ssh=ssh@entry=0x55e1c50351c0,
    cinfo=cinfo@entry=0x55e1c50391d0) at ../../ssh.c:2349
#7  0x000055e1c4e4284b in main (ac=<optimized out>, av=<optimized out>)
    at ../../ssh.c:1834

-- 
Vincent Lefèvre <[email protected]> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / Pascaline project (LIP, ENS-Lyon)

Reply via email to