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

Author Message
cliff
[View user's profile]

Joined: 2016-07-20
Posts: 2
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
cliff
[View user's profile]

Joined: 2016-07-20
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!
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License