search for: chan_input_open

Displaying 20 results from an estimated 22 matches for "chan_input_open".

2000 Jan 20
0
OpenSSH problem report on Linux 2.2.14.
...to ostate must be 128 before the message was printed. It turns out CHAN_OUTPUT_CLOSED is the value, 128, we are looking for. nchan.h:#define CHAN_OUTPUT_CLOSED 0x80 Now what is the state 1 for istate? It turns out the the following states (in nchan.h) describe the status. #define CHAN_INPUT_OPEN 0x01 So the message was printed when istate was CHAN_INPUT_OPEN and ostate was CHAN_OUTPUT_CLOSED. cf. From nchan.h. /* possible input states */ #define CHAN_INPUT_OPEN 0x01 #define CHAN_INPUT_WAIT_DRAIN 0x02 #define CHAN_INPUT_WAIT_OCLOSE 0x04 #...
2001 Sep 28
1
[PATCH] fix for Linux hang on exit bug in 2.9.9p2
...-2.9.9p2J/channels.c --- openssh-2.9.9p2/channels.c Mon Sep 17 23:53:12 2001 +++ openssh-2.9.9p2J/channels.c Thu Sep 27 22:12:43 2001 @@ -1527,8 +1527,18 @@ c = channels[i]; if (c == NULL) continue; - if (ftab[c->type] != NULL) + if (ftab[c->type] != NULL) { + if(c->istate == CHAN_INPUT_OPEN && c->rfd == -1) { + int type=c->type; + c->type=SSH_CHANNEL_CLOSED; + if(channel_find_open() == -1) + shutdown(packet_get_connection_out(), + SHUT_RDWR); + c->type=type; + continue; + } (*ftab[c->type])(c, readset, writeset); + } i...
2001 Feb 22
3
intermittent stderr
The command "ssh ls -l /doesnotexist" gives various responses: Running from a 200 MHz PentiumPro with dsa key added to ssh-agent: Mistakes worst to fast machine: To a faster 600 MHz dual processor i686 600 MHz machine: ls: /doesnotexist: No such file or directory -- correct nothing at all -- wrong ls: select: Bad file descriptor -- wrong
2001 Nov 14
6
[PATCH]: Patch to fix hang on exit bug under Linux and add optional exit delay
...penssh-3.0p1J/channels.c --- openssh-3.0p1/channels.c Thu Oct 11 19:35:05 2001 +++ openssh-3.0p1J/channels.c Tue Nov 13 16:02:32 2001 @@ -1553,8 +1553,18 @@ c = channels[i]; if (c == NULL) continue; - if (ftab[c->type] != NULL) + if (ftab[c->type] != NULL) { + if(c->istate == CHAN_INPUT_OPEN && c->rfd == -1) { + int type=c->type; + c->type=SSH_CHANNEL_CLOSED; + if(channel_find_open() == -1) + shutdown(packet_get_connection_out(), + SHUT_RDWR); + c->type=type; + continue; + } (*ftab[c->type])(c, readset, writeset); + } c...
2000 Jan 07
2
possible clue on tcp forwarding problems
When I encounter the problem with TCP port forwarding locking up, I'll see this on the client window (if I haven't invoked ssh with -q): chan_shutdown_read failed for #1/fd6: Transport endpoint is not connected chan_shutdown_read failed for #1/fd6: Transport endpoint is not connected This is with Blowfish encryption. I have to kill and restart the client when this happens. Phil
2001 May 04
19
SSH connection hanging on logout
I am running OpenSSH 2.9p1 on SunOS 5.7 w/4-24-2001 patch cluster. Like many other users I am seeing the hanging session on logout with background processes. This is a huge problem for me as I centrally manage 50+ machines with rdist across ssh. Instead of just complaining about the problem I thought I would put my CS degree to use and try to track down the problem myself. For starters,
2007 Mar 23
7
4.6p1 chan_read_failed error
The 4.6p1 sshd is logging this error during remote commands or file transfers: error: channel 0: chan_read_failed for istate 3 Platform is Solaris 8, 4.6p1 + OpenSSL 0.9.8d. The commands and transfers work correctly, so the error message appears to be spurious. The error message does not appear when processing logins. Otherwise 4.6p1 is running without any apparent problems. This error
2001 Sep 05
2
sshd hangs on logout -- is this a bug?
In the changelog, there is an entry: 20001129 - (djm) Back out all the serverloop.c hacks. sshd will now hang again if there are background children with open fds. Does this mean that this is regarded as expected (and correct) behavior, that should not change in the future, or does it mean that this behavior is a known problem that someone will eventually fix? --Adam -- Adam McKenna
2008 May 15
0
[Bug 52] ssh hangs on exit
..., that is to say, it exits until sleep 50 secs. and when i use an infinite loop and make it run background, and then use exit to logout, ssh will still hang there. i debug the code, and found in channel_garbage_collect(channels.c), chan_is_dead is return 1 for c->isatate and c->ostate equals CHAN_INPUT_OPEN. so the channel remains open. Can someone help me check this problem. the script i use is just this: #! /sbin/sh while (( 1 )) do sleep 10 >/dev/null 2>&1 done -- Configure bugmail: https://bugzilla.mindrot.org/userprefs.cgi?tab=email ------- You are receiving this mail because: ----...
2000 Nov 15
1
[PATCH]: nchan.c : internal error: we do not read, but chan_read
...----- *** nchan.c.orig Wed Nov 15 12:50:04 2000 --- nchan.c Wed Nov 15 12:53:17 2000 *************** *** 98,103 **** --- 98,106 ---- { debug("channel %d: read failed", c->self); switch (c->istate) { + case CHAN_INPUT_WAIT_DRAIN: + case CHAN_INPUT_CLOSED: + break; case CHAN_INPUT_OPEN: debug("channel %d: input open -> drain", c->self); chan_shutdown_read(c);
2002 Jan 27
0
[PATCH] Fix for hang-on-exit bug in OpenSSH-3.0.2p1
...2p1/session.c openssh-3.0.2p1J2/session.c --- openssh-3.0.2p1/session.c Sat Dec 1 16:37:08 2001 +++ openssh-3.0.2p1J2/session.c Sat Jan 19 15:56:32 2002 @@ -1929,6 +1929,8 @@ */ if (c->ostate != CHAN_OUTPUT_CLOSED) chan_write_failed(c); + if (s->ttyfd != -1 && c->istate == CHAN_INPUT_OPEN) + chan_read_failed(c); s->chanid = -1; }
2004 Jul 13
1
channel->input buffer bug and patch
...2004-07-13 09:37:20.000000000 -0400 @@ -702,6 +702,8 @@ channel_pre_open(Channel *c, fd_set * readset, fd_set * writeset) { u_int limit = compat20 ? c->remote_window : packet_get_maxsize(); + if (limit > 0x10000) + limit = 0x10000; if (c->istate == CHAN_INPUT_OPEN && limit > 0 && Common subdirectories: openssh-3.8.1p1/contrib and openssh-3.8.1p1-bugfix/contrib Common subdirectories: openssh-3.8.1p1/openbsd-compat and openssh-3.8.1p1-bugfix/openbsd-compat Common subdirectories: openssh-3.8.1p1/regress and openssh-3.8.1p1-bugfix/...
2002 Mar 25
0
[Bug 184] New: 3.1p1 openssh fails to build a working sshd on Trusted HP-UX 10.26
...nes from a patch at: + // <http://www.math.ualberta.ca/imaging/snfs/> + //by John C. Bowman + //There is some speculation that you could possibly + //see data loss from this on usenet. But without + //this sshd does not exit on logout. + if (s->ttyfd != -1 && c->istate == CHAN_INPUT_OPEN) + chan_read_failed(c); + #endif s->chanid = -1; } diff -cr openssh-3.1p1.orig/sshd.c openssh-3.1p1/sshd.c *** openssh-3.1p1.orig/sshd.c Tue Mar 5 01:31:30 2002 --- openssh-3.1p1/sshd.c Fri Mar 22 22:32:56 2002 *************** *** 45,50 **** --- 45,54 ---- #include <openssl/dh.h&...
2004 Jul 14
1
New dynamic window patch (with limits)
..._set * readset, fd_set * writeset) { u_int limit = compat20 ? c->remote_window : packet_get_maxsize(); + if (!c->input.unlimited && limit > 0x10000) + limit = 0x10000; + else if (c->input.unlimited && limit > MAXBUFSZ) + limit = MAXBUFSZ; if (c->istate == CHAN_INPUT_OPEN && limit > 0 && @@ -1488,14 +1493,29 @@ !(c->flags & (CHAN_CLOSE_SENT|CHAN_CLOSE_RCVD)) && c->local_window < c->local_window_max/2 && c->local_consumed > 0) { + u_int32_t tcpwinsz = 0; + socklen_t optsz = sizeof(tcpw...
2007 Apr 09
10
[Bug 1306] Spurious : "chan_read_failed for istate 3" errors from sshd
http://bugzilla.mindrot.org/show_bug.cgi?id=1306 Summary: Spurious : "chan_read_failed for istate 3" errors from sshd Product: Portable OpenSSH Version: 4.6p1 Platform: Other OS/Version: All Status: NEW Severity: normal Priority: P2 Component: sshd AssignedTo:
2000 Nov 08
1
internal error: we do not read, but chan_read_failed
Hello, The error message in the subject line occurs with the new 2.3.0 openssh version and appeared in the previous snapshots on our Solaris systems. As far as I remember it was reported, but have not seen any more about this. I have looked into it a little bit. First, the file session.c (line 1849 onwards): debug("session_exit_message: release channel %d", s->chanid);
2002 Feb 05
0
New forkoff() and chan_wont_read/write() API
...n_event_fn *chan_wont_write = NULL; chan_event_fn *chan_obuf_empty = NULL; /* * ACTIONS: should never update the channel states @@ -137,6 +139,28 @@ } } static void +chan_wont_read_12(Channel *c) +{ + debug("channel %d: wont read", c->self); + switch (c->istate) { + case CHAN_INPUT_OPEN: + debug("channel %d: input open -> drain", c->self); + chan_shutdown_read(c); + c->istate = CHAN_INPUT_WAIT_DRAIN; +#if 0 + if (buffer_len(&c->input) == 0) { + debug("channel %d: input: no drain shortcut", c->self); + chan_ibuf_empty(c); + } +#endif...
2020 Oct 14
2
Connection hang, can't stop SSH
Using OpenSSH_8.3p1 I had an open (working) connection to some other box; after a bit of inactivity, some device in the middle seems to have forgotten about the TCP connection (NAT) and broke it. I've got an EscapeChar defined, though; so first I tried to send a BREAK and, when that didn't help (TCP already gone, packets get lost!), I tried (just out of curiosity) a Rekey. Now I can see
2010 Jan 14
1
ssh(1) multiplexing rewrite
...t;ctl_chan); buffer_append(&buffer, buf, strlen(buf)); continue; default: @@ -834,9 +839,6 @@ channel_pre_open(Channel *c, fd_set *rea FD_SET(c->efd, readset); } /* XXX: What about efd? races? */ - if (compat20 && c->ctl_fd != -1 && - c->istate == CHAN_INPUT_OPEN && c->ostate == CHAN_OUTPUT_OPEN) - FD_SET(c->ctl_fd, readset); } /* ARGSUSED */ @@ -981,6 +983,26 @@ channel_pre_x11_open(Channel *c, fd_set } } +static void +channel_pre_mux_client(Channel *c, fd_set *readset, fd_set *writeset) +{ + if (c->istate == CHAN_INPUT_OPEN &am...
2002 Jul 31
18
so-called-hang-on-exit
...* Note that for the non-pty case we must not call 'chan_read_failed', + * since there could * be some more data waiting in the pipe. */ if (c->ostate != CHAN_OUTPUT_CLOSED) chan_write_failed(c); + /* allow data loss on pty */ + if (s->ttyfd != -1 && c->istate == CHAN_INPUT_OPEN) + chan_read_failed(c); s->chanid = -1; }