Running instance of OpenSSH's sshd on OS X, but it won't accept valid user passwords

StackOverflow https://stackoverflow.com/questions/16001880

  •  03-04-2022
  •  | 
  •  

Pergunta

I'm running a instance of OpenSSH's sshd on OS X (10.8.3), but it won't accept valid user passwords. It simply responds, "Permission denied, please try again." I'm ssh'ing to localhost. If I add my public key to .ssh/authorized_keys, I can connect without issue.

I assumed that OS X was preventing the application from accessing OS X's auth system (i.e. /etc/shadow?), so then tried running sshd under sudo, but ran into an issue of sshd immediately crashing upon a client connecting with this error on the server (see update 2 below):

ssh_sandbox_child: ssandbox_init: dlopen(/usr/lib/libsandbox.1.dylib, 261): image not found [preauth]

Any help on either of these issues is appreciated.

In case it's worth noting: I am not trying to replace my existing sshd service on OS X, but simply want to run this one in parallel for something I'm testing.

Update: I forgot to mention that this same code and configuration works perfectly fine compiled and ran on an Ubuntu 12.10 system. On the linux box, I'm not running under sudo.

Update 2: I resolved the server's issue of running under sudo by setting UsePrivilegeSeparation yes in my sshd_config, but passwords are still not accepted.

Foi útil?

Solução

Thanks to Bart for pointing me in the right direction (OS X is expecting PAM).

As described here, to build OpenSSH with PAM, one must configure to use via: ./configure --with-pam before running make.

Adding UsePAM yes to sshd_config as Bart suggested is also needed.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top