Understanding ChannelException issues

I am using a tool built off of RobotFramework, and specifically the SSHLibrary. The test SSH’s to some linux boxes and run “chronyc” to get the time server expected. On four of six tests I’m getting:

ChannelException(1, “Administratively prohibited”)

This may be in the read_until_promt section of SSHLibrary, but I haven’t been able to fully track it down. Suggestions?

Thanks!

ADDENDUM This is being run from a Windows 10 machine to various Linux hosts. Not sure if that’s relevant or not.

Hi Leam,

My initial thoughts are this sounds like a permissions issue, and the user simply doesn’t have permissions to run that application ….

Have you tried manually logging to those servers with SSH with the same user and running the same command? Do you get the same error or a different result?

Dave.

AFAIK, this happens when sshd on remote end of your connection doesnt allow side channels - which afaik at least read_until_prompt most likely uses as that expects interactive shell and thats not default way to connect into remote via SSHLibrary.

So essentially if you have this sort of scenario and it works for bunch of servers but not for others, i’d start looking at /etc/sshd/sshd_config (or where ever the default sshd_config is) and diffing it against differences in working and non-working servers. For config keywords to look out specifically are: AllowTCPForwarding & PermitOpen

1 Like