Patch to Prevent client from not opening channel

Sami Hartikainen hasa100 at hotmail.com
Mon Sep 22 23:33:19 EST 2014


>i had the problem that it wasn't possible to prevent the client from not
>opening a channel.
>This is necessary for me because i have written a custom shell which is
>doing some cleanup work after the connection is closed, which is not
>possible in case the shell isn't started at all.

Are you actually attempting to deny a connection without running a *remote command* -- e.g. the custom shell you mention?

If this is the case, clearing the alarm in channel_post_open() will not enforce that. Consider this: if the client opens a connection and just sets up port forwarding channel(s), the channel_post_open() gets called when such a forwarding channel is opened for communication with whatever is on those forwarded ports. 

--
Sami 		 	   		  


More information about the openssh-unix-dev mailing list