Go Back   DaemonForums > OpenBSD > OpenBSD General

OpenBSD General Other questions regarding OpenBSD which do not fit in any of the categories below.

Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #1   (View Single Post)  
Old 11th November 2011
amrogers3 amrogers3 is offline
Port Guard
Join Date: Oct 2011
Posts: 20
Default Using public keys for SSH authentication

Got a question regarding authentication using public key on openBSD 4.9. SSHd is on BSD and I am using a MAC OSX 5.4 to access SSHd server.

So I created a 2048 bit RSA key using ssh-keygen. I placed the .pub key on the openBSD SSHD server by using
scp ~/.ssh/id_rsa.pub root@
I know, I know using root is terrible.

I ran chmod 600 on id_rsa.pub and moved .pub file on BSD box(I now realize I should have ran chmod 600 after moving file)
mv /id_rsa.pub /etc/.ssh/authorized_keys
I then modified the /etc/sshd_config on BSD box by removing the "#" and changing "yes" to "no"
#PasswordAuthentication yes (removed this line)
PasswordAuthentication no (added this line)
Already enabled, no changes made for publickey:
#publickeyauthentication yes
sshd_config files says to leave "#" on each line unless you change the default value. Only value I changed was PasswordAuthentication from yes to no.

Was able to log in using password before but now can't seem to log in. I did a good amount of research to get this far but now I am stuck. Any ideas what may be preventing me from logging in?

Error is:
user$ssh root@
Permission denied (publickey,keyboard-interactive).

Last edited by amrogers3; 11th November 2011 at 05:02 PM. Reason: corrected ssh-keygen
Reply With Quote

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
ncurses & function keys JimC OpenBSD General 1 24th October 2011 02:36 PM
NTLM Authentication plexter FreeBSD Security 1 7th January 2011 08:43 PM
Creative uses for SSH and SSH keys backrow Off-Topic 1 21st June 2010 01:09 AM
Generating keys from radio echoes J65nko News 0 4th March 2010 06:37 PM
arrow keys in X idefix FreeBSD General 8 25th September 2009 08:16 AM

All times are GMT. The time now is 05:22 AM.

Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick