Is there anyway to configure OpenSSH to use a non-windows account for authentication? I want to create a kind of virtual user, where I can login with credentials I've created specifically to login in to my windows SSH server.

Is this possible? I'm using OpenSSH installed in Cygwin, windows account authentication works absolutely fine.


No, it's not possible.

Cygwin mimics Unix and provides /etc/passwd and /etc/group, but make no mistake, Cygwin needs and uses standard Windows user accounts. /etc/passwd and /etc/group are populated to reflect this.

There's no useradd in Cygwin.

Cygwin does a great job as a Linux-like environment, but it's not an operating system. It uses Windows users/groups and the standard Windows security model (see http://cygwin.com/cygwin-ug-net/ntsec.html):

(...) the Windows security model is utilized in Cygwin to implement POSIX-like permissions (...) The Windows authentication model is used to allow cygwin applications to switch users in a POSIX-like fashion.

For example, in Configuring Cygwin on a Windows server we can read:

Create the accounts that will be able to log in [using CYGWIN sshd] to the computer:

  • Create the Windows accounts first. Click Start > Settings > Control Panel > User Accounts. Make each user a member of the Administrators group. (...)

That all means that you're stuck with using Windows accounts for authentication, also for sshd.

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.