Windows OpenSSH 7.1 -- run as a service ignores Permit restrictions

Advertisement

cliff
Joined:
Posts:
2

Windows OpenSSH 7.1 -- run as a service ignores Permit restrictions

I installed openSSH on a windows system and finding that while sshd is running as a service it seems to ignore the sshd_config setting to prevent TTY login and root access. If I run the sshd from a local command line it seems to work fine. However, when the windows service is running there is a note about "Server refuses to allocate pty" which seems to indicate that the config file is loaded but it will continue past and log right into a command line console.

So... I'm not sure if there is a work around to make this work as a service. I've modified the service parameters to see if I can get around it in a few ways but no luck yet.

My config file has the following settings to prevent command line login to restrict only to sftp. These are ignored when running as a service.

PermitRootLogin no
PermitTTY no

Reply with quote

Advertisement

cliff
Joined:
Posts:
2

I changed the "sshd" service to run as "Administrator" and has been working this way. My service also has the argument '-f D:\openssh\sshd_conf' but this is probably not needed.

I'm looking into the minimum permissions to allow the service to kick off but if any of you come across the same problem hope it helps. Cheers!

Reply with quote

Advertisement

You can post new topics in this forum